Portage is a package management system used by Gentoo Linux
# ChangeLog for games-roguelike/nethack
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
# $Header: /var/cvsroot/gentoo-x86/games-roguelike/nethack/ChangeLog,v 1.29 2008/06/05 19:55:11 wolf31o2 Exp $
05 Jun 2008; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
Small typo fix.
07 Mar 2008; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
QA cleanup: Fix quoting.
14 Jan 2008; Fabian Groffen
Dropped ppc-macos keyword, see you in prefix
01 Apr 2007; Michael Sterrett
nethack-3.4.3-r1.ebuild:
fix deps for bug #172945
12 Mar 2007; Marius Mauch
Replacing einfo with elog
07 Mar 2007; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
Change all instances of [ to [[.
18 Nov 2006; Saleem Abdulrasool
drop gnome useflag for gnome-1.x removal
24 Jun 2006; Doug Goldstein
USE flag change qt->qt3/qt4 bug #137785
22 May 2006; Diego Pettenò
nethack-3.4.3-r1.ebuild:
Add ~x86-fbsd keyword, after setting GAMEUID and GAMEGRP (to install clean
on FreeBSD) and set CC on last make call (bug #134054).
24 Jan 2006; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
Added modular X dependencies and closing bug #119031.
22 Nov 2005; Fabian Groffen
nethack-3.4.3-r1.ebuild:
Adding small patch for OSX and compilation helper. Marked ~ppc-macos (bug
#106117)
22 Nov 2005;
Added ~hppa keyword (bug 109191).
16 Oct 2005; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
Added desktop entry using make_desktop_entry and closing bug #100788.
28 Jul 2005; Caleb Tennis
made qt dep qt3 explicit per bug #100235
17 May 2005; Chris Gianelloni
nethack-3.4.3-r1.ebuild:
Cleanup for bug #92745.
28 Dec 2004; Ciaran McCreesh
Change encoding to UTF-8 for GLEP 31 compliance
24 Sep 2004; Michael Sterrett
nethack-3.4.3-r1.ebuild:
Bring the help functionality back when using the external pager (bug #57410)
sed patch from Benoit Boissinot
10 Sep 2004; Michael Sterrett
nethack-3.4.3-r1.ebuild, -nethack-3.4.3.ebuild:
clean older ebuilds; fix deps
31 Aug 2004; Chris Gianelloni
+files/3.4.3-bison.patch, nethack-3.4.3-r1.ebuild:
Added bison patch and closing bug #61140.
*nethack-3.4.3-r1 (10 Jul 2004)
10 Jul 2004; Michael Sterrett
+nethack-3.4.3-r1.ebuild:
Work around buggy makefiles so we get to use emake
Set DEF_PAGER from $PAGER (bug #52122)
Use ${GAMES_STATEDIR} saving code in games.eclass instead of hacking it
in the ebuild.
Error check ; tidy
30 Mar 2004; Michael Sterrett
nethack-3.4.3.ebuild:
virtual/x11; use flag cleanup; error check sed
20 Jan 2004; Jon Portnoy
AMD64 keywords.
*nethack-3.4.3 (01 Jan 2003)
01 Jan 2003; Mike Frysinger
Version bump #35558.
*nethack-3.4.2 (15 Sep 2003)
17 Sep 2003; Chuck Short
Marked stable for sparc, closes bug #28449.
15 Sep 2003; Mike Frysinger
Version bump #27875 + saved games fix #28104 + new qt ver #23149.
*nethack-3.4.1-r1 (07 Aug 2003)
07 Aug 2003; Mike Frysinger
Fix file permissions/writable file locations #26085
*nethack-3.4.1 (03 Mar 2003)
11 Jul 2003; Mike Frysinger
Don't overwrite saved games and stuff ... #16428
22 Jun 2003; Mike Frysinger
Cleaned up ebuild ... move most sed statements to patches. #16436 #16827
05 Mar 2003; Bartosch Pixa
set ~ppc in keywords
03 Mar 2003; Daniel Ahlberg
Version bump.
*nethack-3.4.0-r7 (26 Feb 2003)
26 Feb 2003; Mike Frysinger
Added errno patch to fix #16436 (#16267).
*nethack-3.4.0-r6 (18 Feb 2003)
18 Feb 2003; Daniel Ahlberg
Security update.
*nethack-3.4.0-r5 (22 Dec 2002)
22 Dec 2002; J.Alberto Suarez L.
Fix bug #12576
*nethack-3.4.0-r4 (16 Dec 2002)
16 Dec 2002; Mike Frysinger
Added games.eclass support and fix for #9147.
*nethack-3.4.0-r3 (23 Apr 2002)
17 jul 2002; Jose Alberto Suárez López
Added LICENSE, KEYWORDS, SLOT.
17 jul 2002; Jose Alberto Suárez López
Added LICENSE, KEYWORDS, SLOT.
23 Apr 2002; Spider
Fix qt dependency
*nethack-3.4.0-r2 (17 Apr 2002)
17 jul 2002; Jose Alberto Suárez López
Added LICENSE, KEYWORDS, SLOT.
17 Apr 2002; Spider
Here is the bulk message from Jason Ritchie
This version I wrote from scratch, but after I got stuck I got a lot of
good info from the existing nethack ebuilds. I have included a
CREDITS.gentoo.
On to the meat. This ebuild supports USE flags X, qt, and gnome. I
have also included a default .nethackrc file and a FAQ-ish thing about
why I made some decisions. It removes the need for /usr/games as this is to be avoided
from what I hear. It will emerge with qt2 or 3 installed, but it will only
use 2. I have tested tty, X, qt, and gnome window types and it seems to run very
nicely.
The whole setup process should be:
emerge nethack
cp /usr/share/nethackdir/dot.nethackrc ~/.nethackrc
nethack
This was such a fun project. Let me know if I screwed the pooch.
*nethack-3.4.0-r1 (13 Apr 2002)
17 jul 2002; Jose Alberto Suárez López
Added LICENSE, KEYWORDS, SLOT.
13 Apr 2002; Spider
Adding comment on how to get colour support thanks to Ryan Phillips
Update dodoc line
*nethack-3.4.0 (09 Apr 2002)
9 Apr 2002; Spider
Second release of nethack really, only including the 3.4.0 release though.
initial commit to cvs/portage
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
AUX 3.4.3-GNOME-support.patch 1316 RMD160 22bbef5460eded0faa3d06e7b2db45334783bf10 SHA1 b94442d65c13310e36f35e34ad48760206453c78 SHA256 7298bc971292db8ee2147a5ed04f71e21411bb51c169cc60634633dd1aecbaed
AUX 3.4.3-QT-GNOME-support.patch 1507 RMD160 3344bda39533bceb9c6a95102b4b5146aad862c6 SHA1 288568ecec759c910243adf6b8fc846413278be1 SHA256 f5d5728a7cf3a32910741d2a89b228a5fa0f0f042c6ef0918d4be06d9206ab47
AUX 3.4.3-QT-support.patch 792 RMD160 2338e103a24a2284ac1af33f22dc914f506d13e7 SHA1 d1789562e39ba5f101939c2bd3974c0b74f35398 SHA256 2e3a72bb31c8b0fe3afaa9933f64cd1858b4f32d6188273586062953b92ae97a
AUX 3.4.3-X-support.patch 920 RMD160 1cad76af263fa640097ef6f67f1298886df098ea SHA1 3fe24974e6e1df078a4a0992c9313f59e2f0c662 SHA256 e1d3a7110c97b80b1d3e3bd4204f1ea018fbbc03d2a937efdb292cc1f611f525
AUX 3.4.3-bison.patch 603 RMD160 0fd71789e69640ac8c14183edd5974938d5e6f66 SHA1 2705d64f5c2692a4f1f561c90b816dce5dbe27b0 SHA256 8b8eab414c4dfeb20ab60dc543eb023eac90da0a9e1c8a2375833fdf61baec7f
AUX 3.4.3-default-options.patch 1262 RMD160 10bdb2cbe10a7396a8f88052d6a61e62629c26d8 SHA1 678a7d263649b77b25a55290f68074042a64961a SHA256 5ba428f0c4d476c41b5ab94fb52737e39d32b7944d46755195745d97f14f38bd
AUX 3.4.3-gentoo-paths.patch 576 RMD160 84319d80353e1c029d4130a73ae65b18680f2c91 SHA1 b8cc137b8b5c04071d81c741635fd261250490b6 SHA256 09b96c2659aab5749e5f16ceedfba40597938c9aa06e6bfc05e6b5f029a2ffb1
AUX 3.4.3-macos.patch 307 RMD160 460ef1f4279e5c0e09de3cfe77b7984fbab0dede SHA1 a96ef11b97a9cbf08c9207144986d4355a27e6b1 SHA256 2df99fde20c8ff4b919da95bb4a36222b9eac564cfc2e02233da95dcbc25bb17
AUX dot.nethackrc 2717 RMD160 0e9868a1b8f017337d8c37e740399e25512bdb5b SHA1 27c973b8c336355012e2e2c4f0007bce9cce9f84 SHA256 19d692014e1b053439f5f818291e32a971942490ca7e3d2b7912b43a4563f98c
DIST nethack-343-src.tgz 3497458 RMD160 42f600d24715a0b7e631b357c135761410b3ca95 SHA1 c26537093c38152bc0fbcec20468d975b35f59fd SHA256 bb39c3d2a9ee2df4a0c8fdde708fbc63740853a7608d2f4c560b488124866fe4
EBUILD nethack-3.4.3-r1.ebuild 5030 RMD160 961a93444ddcf5d90ef1385b4abd71f4e746163f SHA1 1073009c02dca9879d2170d60183bc0fb6a31b91 SHA256 1b7587c1d373eefa224f5830e20713d44080e6de10e6417aa44684d73a78b01c
MISC ChangeLog 6634 RMD160 796ac5766a896c118e0d447fad0f3a202cfb6513 SHA1 27412205859a49d2757198e92cec110ef5c46099 SHA256 2366094311953301158ee337edd4104689c46cbf4b7b39be7d4ae584487ba947
MISC metadata.xml 158 RMD160 cbd9984bb6b426c8c9cee5022fe0a26261612fea SHA1 be5251fa1dacef5c41b74761bb1c8c54fb633b9e SHA256 1423a4fdd4a79b1728a2056d9e300f7e1074253095d82726218d9e9b953888a3
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
iEYEARECAAYFAkhIRKEACgkQkT4lNIS36YH7HwCfWFSCg7AqmjCUyRyhLTNW4t97
kZwAn3HZkaUoyVc5SCaDBI9yj5i0rUlO
=GVcj
-----END PGP SIGNATURE-----
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/games-roguelike/nethack/nethack-3.4.3-r1.ebuild,v 1.22 2008/06/05 19:55:11 wolf31o2 Exp $
inherit eutils toolchain-funcs flag-o-matic games
MY_PV=${PV//.}
DESCRIPTION="The ultimate old-school single player dungeon exploration game"
HOMEPAGE="http://www.nethack.org/"
SRC_URI="mirror://sourceforge/nethack/${PN}-${MY_PV}-src.tgz"
#SRC_URI="ftp://ftp.nethack.org/pub/nethack/nh340/src/nethack-340.tgz"
LICENSE="nethack"
SLOT="0"
KEYWORDS="amd64 ~hppa ppc sparc x86 ~x86-fbsd"
IUSE="X qt3"
RDEPEND="virtual/libc
>=sys-libs/ncurses-5.2-r5
X? (
x11-libs/libXaw
x11-libs/libXpm
x11-libs/libXt
)
qt3? ( =x11-libs/qt-3* )"
DEPEND="${RDEPEND}
X? (
x11-proto/xproto
x11-apps/bdftopcf
x11-apps/mkfontdir
)"
HACKDIR="${GAMES_DATADIR}/${PN}"
src_unpack() {
unpack ${A}
# This copies the /sys/unix Makefile.*s to their correct places for
# seding and compiling.
cd "${S}/sys/unix"
source setup.sh || die
cd "${S}"
epatch \
"${FILESDIR}"/${PV}-gentoo-paths.patch \
"${FILESDIR}"/${PV}-default-options.patch \
"${FILESDIR}"/${PV}-bison.patch \
"${FILESDIR}"/${PV}-macos.patch
sed -i \
-e "s:GENTOO_STATEDIR:${GAMES_STATEDIR}/${PN}:" include/unixconf.h \
|| die "setting statedir"
sed -i \
-e "s:GENTOO_HACKDIR:${HACKDIR}:" include/config.h \
|| die "setting hackdir"
# set the default pager from the environment bug #52122
if [[ -n "${PAGER}" ]] ; then
sed -i \
-e "115c\#define DEF_PAGER \"${PAGER}\"" \
include/unixconf.h \
|| die "setting statedir"
# bug #57410
sed -i \
-e "s/^DATNODLB =/DATNODLB = \$(DATHELP)/" Makefile \
|| die "sed Makefile failed"
fi
if use X ; then
epatch "${FILESDIR}/${PV}-X-support.patch"
if use qt3 ; then
epatch "${FILESDIR}/${PV}-QT-support.patch"
fi
fi
}
src_compile() {
local qtver=
local lflags="-L/usr/X11R6/lib"
has_version =x11-libs/qt-3* \
&& qtver=3 \
|| qtver=2
cd "${S}"/src
append-flags -I../include
emake \
QTDIR=/usr/qt/${qtver} \
CC="$(tc-getCC)" \
CFLAGS="${CFLAGS}" \
LFLAGS="${lflags}" \
../util/makedefs \
|| die "initial makedefs build failed"
emake \
QTDIR=/usr/qt/${qtver} \
CC="$(tc-getCC)" \
CFLAGS="${CFLAGS}" \
LFLAGS="${lflags}" \
|| die "main build failed"
cd "${S}"/util
emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" recover || die "util build failed"
}
src_install() {
make \
CC="$(tc-getCC)" \
CFLAGS="${CFLAGS}" \
LFLAGS="-L/usr/X11R6/lib" \
GAMEPERM=0755 \
GAMEUID="${GAMES_USER}" GAMEGRP="${GAMES_GROUP}" \
PREFIX="${D}/usr" \
GAMEDIR="${D}${HACKDIR}" \
SHELLDIR="${D}/${GAMES_BINDIR}" \
install \
|| die "make install failed"
# We keep this stuff in ${GAMES_STATEDIR} instead so tidy up.
rm -rf "${D}/usr/share/games/nethack/save"
newgamesbin util/recover recover-nethack || die "newgamesbin failed"
# The final nethack is a sh script. This fixes the hard-coded
# HACKDIR directory so it doesn't point to ${D}/usr/share/nethackdir
sed -i \
-e "s:^\(HACKDIR=\).*:\1${HACKDIR}:" \
"${D}${GAMES_BINDIR}/nethack" \
|| die "sed ${GAMES_BINDIR}/nethack failed"
doman doc/*.6
dodoc doc/*.txt
# Can be copied to ~/.nethackrc to set options
# Add this to /etc/.skel as well, thats the place for default configs
insinto "${HACKDIR}"
doins "${FILESDIR}/dot.nethackrc"
local windowtypes="tty"
use qt3 && windowtypes="${windowtypes} qt"
use X && windowtypes="${windowtypes} x11"
set -- ${windowtypes}
sed -i \
-e "s:GENTOO_WINDOWTYPES:${windowtypes}:" \
-e "s:GENTOO_DEFWINDOWTYPE:$1:" \
"${D}${HACKDIR}/dot.nethackrc" \
|| die "sed ${HACKDIR}/dot.nethackrc failed"
insinto /etc/skel
newins "${D}/${HACKDIR}/dot.nethackrc" .nethackrc
if use X ; then
# install nethack fonts
cd "${S}/win/X11"
bdftopcf -o nh10.pcf nh10.bdf || die "Converting fonts failed"
bdftopcf -o ibm.pcf ibm.bdf || die "Converting fonts failed"
insinto "${HACKDIR}/fonts"
doins *.pcf
cd "${D}/${HACKDIR}/fonts"
mkfontdir || die "The action mkfontdir ${HACKDIR}/fonts failed"
# copy nethack x application defaults
cd "${S}/win/X11"
insinto /etc/X11/app-defaults
newins NetHack.ad NetHack || die "Failed to install NetHack X app defaults"
sed -i \
-e 's:^!\(NetHack.tile_file.*\):\1:' \
"${D}/etc/X11/app-defaults/NetHack" \
|| die "sed /etc/X11/app-defaults/NetHack failed"
fi
local statedir="${GAMES_STATEDIR}/${PN}"
keepdir "${statedir}/save"
mv "${D}/${HACKDIR}/"{record,logfile,perm} "${D}/${statedir}/"
make_desktop_entry nethack "Nethack"
prepgamesdirs
chmod -R 660 "${D}/${statedir}"
chmod 770 "${D}/${statedir}" "${D}/${statedir}/save"
}
pkg_postinst() {
games_pkg_postinst
if use qt3 && has_version '=x11-libs/qt-3.1*' ; then
ewarn "the qt frontend may be a little unstable with this version of qt"
ewarn "please see Bug 32629 for more information"
fi
elog "You may want to look at /etc/skel/.nethackrc for interesting options"
}