summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sterrett <mr_bones_@gentoo.org>2009-11-04 04:33:06 +0000
committerMichael Sterrett <mr_bones_@gentoo.org>2009-11-04 04:33:06 +0000
commit1648433a20e9b39175affd954c90c8d18d70026b (patch)
treed8743c05e0a46dc79cf5312a644738d65d980494 /games-action/openastromenace/openastromenace-1.2.0.ebuild
parentWhitespace cleanup. (diff)
downloadgentoo-2-1648433a20e9b39175affd954c90c8d18d70026b.tar.gz
gentoo-2-1648433a20e9b39175affd954c90c8d18d70026b.tar.bz2
gentoo-2-1648433a20e9b39175affd954c90c8d18d70026b.zip
Actually work with LINGUAS support (bug #234729)
(Portage version: 2.1.6.13/cvs/Linux i686)
Diffstat (limited to 'games-action/openastromenace/openastromenace-1.2.0.ebuild')
-rw-r--r--games-action/openastromenace/openastromenace-1.2.0.ebuild40
1 files changed, 33 insertions, 7 deletions
diff --git a/games-action/openastromenace/openastromenace-1.2.0.ebuild b/games-action/openastromenace/openastromenace-1.2.0.ebuild
index 3ecdfc9c5739..aea87972b642 100644
--- a/games-action/openastromenace/openastromenace-1.2.0.ebuild
+++ b/games-action/openastromenace/openastromenace-1.2.0.ebuild
@@ -1,27 +1,28 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/games-action/openastromenace/openastromenace-1.2.0.ebuild,v 1.4 2009/05/27 14:23:14 nyhm Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-action/openastromenace/openastromenace-1.2.0.ebuild,v 1.5 2009/11/04 04:33:06 mr_bones_ Exp $
EAPI=2
-inherit cmake-utils eutils games
+inherit flag-o-matic cmake-utils eutils games
DESCRIPTION="Modern 3D space shooter with spaceship upgrade possibilities"
HOMEPAGE="http://sourceforge.net/projects/openastromenace/"
SRC_URI="mirror://sourceforge/${PN}/openamenace-src-${PV}.tar.bz2
mirror://sourceforge/${PN}/oamenace-data-${PV}.tar.bz2
- mirror://sourceforge/${PN}/oamenace-lang-en-${PV}.tar.bz2
+ linguas_en? ( mirror://sourceforge/${PN}/oamenace-lang-en-${PV}.tar.bz2 )
linguas_de? ( mirror://sourceforge/${PN}/oamenace-lang-de-${PV}.tar.bz2 )
linguas_ru? ( mirror://sourceforge/${PN}/oamenace-lang-ru-${PV}.tar.bz2 )
+ !linguas_en? ( !linguas_de? ( !linguas_ru? ( mirror://sourceforge/${PN}/oamenace-lang-en-${PV}.tar.bz2 ) ) )
mirror://gentoo/${PN}.png"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE="linguas_de linguas_ru"
+IUSE="linguas_en linguas_de linguas_ru"
DEPEND="virtual/opengl
virtual/glu
- media-libs/libsdl[joystick]
+ media-libs/libsdl[joystick,video]
media-libs/openal
media-libs/freealut
media-libs/libogg
@@ -32,10 +33,35 @@ S=${WORKDIR}/OpenAstroMenaceSVN
src_prepare() {
epatch "${FILESDIR}"/${P}-cmake.patch
+ if use linguas_en ; then
+ einfo "Picking en for language set"
+ mv ../gamelang_en.vfs ../gamelang.vfs
+ elif use linguas_de ; then
+ einfo "Picking de for language set"
+ sed -i \
+ -e '/^#define EN/s:^://:' \
+ -e '/#define DE/s://::' \
+ AstroMenaceSource/Defines.h \
+ || die "sed failed"
+ mv ../gamelang_de.vfs ../gamelang.vfs
+ elif use linguas_ru ; then
+ einfo "Picking ru for language set"
+ sed -i \
+ -e '/^#define EN/s:^://:' \
+ -e '/#define RU/s://::' \
+ AstroMenaceSource/Defines.h \
+ || die "sed failed"
+ mv ../gamelang_ru.vfs ../gamelang.vfs
+ else
+ einfo "Picking en for language set"
+ mv ../gamelang_en.vfs ../gamelang.vfs
+ fi
+ rm -f ../gamelang_*
}
src_configure() {
local mycmakeargs="-DDATADIR=${GAMES_DATADIR}/${PN}"
+
cmake-utils_src_configure
}
@@ -44,10 +70,10 @@ src_compile() {
}
src_install() {
- newgamesbin "${CMAKE_BUILD_DIR}"/AstroMenace ${PN} || die "newgamesbin failed"
+ newgamesbin "${CMAKE_BUILD_DIR}"/AstroMenace ${PN} \
+ || die "newgamesbin failed"
insinto "${GAMES_DATADIR}"/${PN}
doins -r ../DATA ../*.vfs || die "doins failed"
- dosym gamelang_en.vfs "${GAMES_DATADIR}"/${PN}/gamelang.vfs
doicon "${DISTDIR}"/${PN}.png
make_desktop_entry ${PN} OpenAstroMenace
dodoc ReadMe.txt