summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2021-09-15 18:41:47 -0400
committerIonen Wolkens <ionen@gentoo.org>2021-09-15 19:20:16 -0400
commitfbcfa77b21b782c746a97a871773fd34576653bd (patch)
treed8b889319bb7ed5354bce75a7ba17c3b5631efe2 /games-action/transcend/transcend-0.3-r2.ebuild
parentdev-python/yamlpath: DISTUTILS_USE_SETUPTOOLS=bdepend (diff)
downloadgentoo-fbcfa77b21b782c746a97a871773fd34576653bd.tar.gz
gentoo-fbcfa77b21b782c746a97a871773fd34576653bd.tar.bz2
gentoo-fbcfa77b21b782c746a97a871773fd34576653bd.zip
games-action/transcend: EAPI6->8, misc cleanups
Slightly annoying to but no longer use Transcend/ in ${S} given higher level directories are also built and it makes user patching (or future need to patch) difficult. Also try to use the more "intended" way to build to drop large sed/makefile concat. Drop unused X deps and prevent from attempting to link with them. Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-action/transcend/transcend-0.3-r2.ebuild')
-rw-r--r--games-action/transcend/transcend-0.3-r2.ebuild66
1 files changed, 66 insertions, 0 deletions
diff --git a/games-action/transcend/transcend-0.3-r2.ebuild b/games-action/transcend/transcend-0.3-r2.ebuild
new file mode 100644
index 000000000000..b3f2a9b7a91c
--- /dev/null
+++ b/games-action/transcend/transcend-0.3-r2.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit desktop toolchain-funcs
+
+DESCRIPTION="Retro-style, abstract, 2D shooter"
+HOMEPAGE="http://transcend.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/Transcend_${PV}_UnixSource.tar.gz"
+S="${WORKDIR}/Transcend_${PV}_UnixSource"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="
+ media-libs/freeglut
+ media-libs/portaudio
+ virtual/glu
+ virtual/opengl"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-system-portaudio.patch
+)
+
+src_prepare() {
+ default
+
+ rm -r ${PN^}/portaudio || die
+
+ sed -e "s|\"levels\"|\"${EPREFIX}/usr/share/${PN}/levels\"|" \
+ -i ${PN^}/game/{LevelDirectoryManager,game}.cpp || die
+}
+
+src_configure() {
+ cd ${PN^} || die
+ platformSelection=1 ./configure || die
+}
+
+src_compile() {
+ tc-export PKG_CONFIG
+
+ local emakeargs=(
+ GXX="$(tc-getCXX)"
+ OPTIMIZE_FLAG="${CXXFLAGS}"
+ LINK_FLAGS="${LDFLAGS}"
+ )
+
+ emake -C ${PN^}/game "${emakeargs[@]}"
+}
+
+src_install() {
+ cd ${PN^} || die
+
+ newbin game/${PN^} ${PN}
+
+ insinto /usr/share/${PN}
+ doins -r levels
+
+ dodoc doc/{how_to_play.txt,changeLog.txt}
+
+ make_desktop_entry ${PN} ${PN^} applications-games
+}