summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Heaven <nyhm@gentoo.org>2007-03-13 14:33:58 +0000
committerTristan Heaven <nyhm@gentoo.org>2007-03-13 14:33:58 +0000
commit75bbb853b7a03170afdefb216d8e5371b587c814 (patch)
treec55c19fb7b2ade865ff81be423892dfa116de518 /games-action/battalion/battalion-1.4b.ebuild
parentx86 stable (diff)
downloadgentoo-2-75bbb853b7a03170afdefb216d8e5371b587c814.tar.gz
gentoo-2-75bbb853b7a03170afdefb216d8e5371b587c814.tar.bz2
gentoo-2-75bbb853b7a03170afdefb216d8e5371b587c814.zip
use doins
(Portage version: 2.1.2.2)
Diffstat (limited to 'games-action/battalion/battalion-1.4b.ebuild')
-rw-r--r--games-action/battalion/battalion-1.4b.ebuild28
1 files changed, 13 insertions, 15 deletions
diff --git a/games-action/battalion/battalion-1.4b.ebuild b/games-action/battalion/battalion-1.4b.ebuild
index 05585e957289..7497786de7b9 100644
--- a/games-action/battalion/battalion-1.4b.ebuild
+++ b/games-action/battalion/battalion-1.4b.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/games-action/battalion/battalion-1.4b.ebuild,v 1.12 2007/03/12 13:13:57 genone Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-action/battalion/battalion-1.4b.ebuild,v 1.13 2007/03/13 14:33:58 nyhm Exp $
inherit games
@@ -13,11 +13,10 @@ SLOT="0"
KEYWORDS="ppc x86"
IUSE=""
-RDEPEND="x11-libs/libXext
- virtual/opengl"
+DEPEND="virtual/opengl
+ virtual/glu"
-S="${WORKDIR}/${PN}${PV}"
-dir="${GAMES_DATADIR}/${PN}"
+S=${WORKDIR}/${PN}${PV}
src_unpack() {
unpack ${A}
@@ -25,15 +24,15 @@ src_unpack() {
# Modify data paths
sed -i \
- -e "s:SOUNDS/:${dir}/SOUNDS/:" \
- -e "s:MUSIC/:${dir}/MUSIC/:" \
+ -e "s:SOUNDS/:${GAMES_DATADIR}/${PN}/SOUNDS/:" \
+ -e "s:MUSIC/:${GAMES_DATADIR}/${PN}/MUSIC/:" \
audio.c || die "sed audio.c failed"
sed -i \
- -e "s:DATA/:${dir}/DATA/:" \
+ -e "s:DATA/:${GAMES_DATADIR}/${PN}/DATA/:" \
-e "s:/usr/tmp:${GAMES_STATEDIR}:" \
battalion.c || die "sed battalion.c failed"
sed -i \
- -e "s:TEXTURES/:${dir}/TEXTURES/:" \
+ -e "s:TEXTURES/:${GAMES_DATADIR}/${PN}/TEXTURES/:" \
graphics.c || die "sed graphics.c failed"
# Modify Makefile and add CFLAGS
@@ -41,25 +40,24 @@ src_unpack() {
-e "s:-O2:${CFLAGS}:" \
Makefile || die "sed Makefile failed"
# Only .raw sound files are used on Linux. The .au files are not needed.
- rm {SOUNDS,MUSIC}/*.au
+ rm -f {SOUNDS,MUSIC}/*.au
}
src_install() {
dogamesbin battalion || die "dogamesbin failed"
- dodir "${dir}"
- cp -r DATA MUSIC SOUNDS TEXTURES "${D}${dir}" || die "cp failed"
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r DATA MUSIC SOUNDS TEXTURES || die "doins failed"
dodoc README
dodir "${GAMES_STATEDIR}"
- touch "${D}${GAMES_STATEDIR}/battalion_hiscore"
- fperms 660 "${GAMES_STATEDIR}/battalion_hiscore"
+ touch "${D}${GAMES_STATEDIR}"/battalion_hiscore
+ fperms 660 "${GAMES_STATEDIR}"/battalion_hiscore
prepgamesdirs
}
pkg_postinst() {
games_pkg_postinst
- echo
elog "Sound and music are not enabled by default."
elog "Use the S and M keys to enable them in-game, or start the game with"
elog "the -s and -m switches: battalion -s -m"