diff options
author | Alfredo Tupone <tupone@gentoo.org> | 2006-08-26 20:38:33 +0000 |
---|---|---|
committer | Alfredo Tupone <tupone@gentoo.org> | 2006-08-26 20:38:33 +0000 |
commit | a099fb2b3fed15bd230c56f0353bcf461281d775 (patch) | |
tree | 1b15ec23b6f53db2015b01e5569512b4c36fd683 /games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild | |
parent | mask module-init-tools-3.2.2-r1 until we're sure baselayout 1.12 works ok, #1... (diff) | |
download | historical-a099fb2b3fed15bd230c56f0353bcf461281d775.tar.gz historical-a099fb2b3fed15bd230c56f0353bcf461281d775.tar.bz2 historical-a099fb2b3fed15bd230c56f0353bcf461281d775.zip |
Fix the bad path on the installed lgc-pg
Package-Manager: portage-2.1-r2
Diffstat (limited to 'games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild')
-rw-r--r-- | games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild | 73 |
1 files changed, 73 insertions, 0 deletions
diff --git a/games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild b/games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild new file mode 100644 index 000000000000..73f47ff4b38c --- /dev/null +++ b/games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild @@ -0,0 +1,73 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-strategy/lgeneral/lgeneral-1.2_beta12-r1.ebuild,v 1.1 2006/08/26 20:38:33 tupone Exp $ + +inherit eutils autotools games + +DATA=pg-data +MY_P="${P/_/}" +MY_P="${MY_P/beta/beta-}" +DESCRIPTION="A Panzer General clone written in SDL" +HOMEPAGE="http://lgames.sourceforge.net/index.php?project=LGeneral" +SRC_URI="mirror://sourceforge/lgeneral/${MY_P}.tar.gz + mirror://sourceforge/lgeneral/${DATA}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86" +IUSE="" + +DEPEND="media-libs/libsdl + media-libs/sdl-mixer" + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}/${P}"-gentoo-path.patch + eautoreconf + touch po/lgeneral/lgeneral.pot + # Build a temporary lgc-pg that knows about /var/tmp/portage in work/lgc-pg: + cp -pPR "${S}" "${WORKDIR}/lgc-pg" || die "cp failed." + sed -i \ + -e "s:@GENTOO_DATADIR@:${GAMES_DATADIR}:" \ + -e "s:@D@::" \ + src/misc.c \ + lgc-pg/misc.c + cd "${WORKDIR}"/lgc-pg + sed -i \ + -e "s:@GENTOO_DATADIR@:${GAMES_DATADIR}:" \ + -e "s:@D@:${D}:" \ + src/misc.c \ + lgc-pg/misc.c +} + +src_compile() { + egamesconf \ + --disable-dependency-tracking \ + || die "egamesconf failed" + emake || die "emake failed" + + # Build the temporary lgc-pg: + cd "${WORKDIR}/lgc-pg" + egamesconf --datadir="${D}/${GAMES_DATADIR}" \ + || die "lgc-gc egamesconf failed" + emake || die "lgc-gc emake failed" +} + +src_install() { + make DESTDIR=${D} install || die "make install failed." + keepdir "${GAMES_DATADIR}/${PN}/"{ai_modules,music,terrain} + + # Generate scenario data: + SDL_VIDEODRIVER=dummy "${WORKDIR}"/lgc-pg/lgc-pg/lgc-pg \ + -s "${WORKDIR}/${DATA}" \ + -d ${D}"${GAMES_DATADIR}/${PN}" \ + || die "Failed to generate scenario data." + + dodoc AUTHORS ChangeLog README.lgeneral README.lgc-pg TODO + newicon lgeneral48.png ${PN}.png + make_desktop_entry lgeneral LGeneral + prepgamesdirs +} |