summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Le Cuirot <chewi@gentoo.org>2018-10-31 21:35:57 +0000
committerJames Le Cuirot <chewi@gentoo.org>2018-10-31 21:53:11 +0000
commitbc136377c77f0ea077c87592f911b4683da94331 (patch)
tree83d689893102f88de2e7c417212a1fb92b70babc /games-action/trine-enchanted-edition
parentmedia-libs/libsdl2: Drop old 2.0.8-r1 (diff)
downloadgentoo-bc136377c77f0ea077c87592f911b4683da94331.tar.gz
gentoo-bc136377c77f0ea077c87592f911b4683da94331.tar.bz2
gentoo-bc136377c77f0ea077c87592f911b4683da94331.zip
games-action/trine-enchanted-edition: Use our SDL with SDL_DYNAMIC_API
This is a magic environment variable that allows us to bypass the static version of SDL 2 that the game was built with. Signed-off-by: James Le Cuirot <chewi@gentoo.org> Package-Manager: Portage-2.3.51, Repoman-2.3.11
Diffstat (limited to 'games-action/trine-enchanted-edition')
-rw-r--r--games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r1.ebuild (renamed from games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508.ebuild)14
1 files changed, 7 insertions, 7 deletions
diff --git a/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508.ebuild b/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r1.ebuild
index fcff32bee8f5..d15a55db5f78 100644
--- a/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508.ebuild
+++ b/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -23,14 +23,15 @@ QA_PREBUILT="opt/${PN}/${PN}*"
DEPEND="app-arch/unzip"
# SDL 1.3 is bundled but the game appears to be statically linked
-# against SDL 2.0.3. This is unfortunate as there are bugs. For example,
-# it doesn't respect the DISPLAY variable under Zaphod mode.
+# against SDL 2.0.3. We can bypass this and use our own SDL 2 by setting
+# the SDL_DYNAMIC_API environment variable.
RDEPEND="
media-gfx/nvidia-cg-toolkit[abi_x86_32]
media-libs/alsa-lib[abi_x86_32]
media-libs/freetype:2[abi_x86_32]
media-libs/libogg[abi_x86_32]
+ >=media-libs/libsdl2-2.0.3[abi_x86_32,joystick,opengl,sound,threads,video]
>=media-libs/libvorbis-1.3[abi_x86_32]
>=media-libs/openal-1.15[abi_x86_32]
>=sys-devel/gcc-4.6[cxx]
@@ -56,7 +57,7 @@ pkg_nofetch() {
}
src_install() {
- local dir=/opt/${PN}
+ local dir=/opt/${PN} SDL=${EPREFIX}/usr/$(ABI=x86 get_libdir)/libSDL2-2.0.so.0
insinto "${dir}"
doins -r *.fbq data
@@ -64,14 +65,14 @@ src_install() {
exeinto "${dir}"
newexe bin/trine1_linux_32bit ${PN}
- make_wrapper ${PN} ./${PN} "${dir}"
+ make_wrapper ${PN} "env SDL_DYNAMIC_API=\"${SDL}\" ./${PN}" "${dir}"
make_desktop_entry ${PN} "${MY_PN}"
if use launcher ; then
exeinto "${dir}"
newexe bin/trine1_linux_launcher_32bit ${PN}-launcher
- make_wrapper ${PN}-launcher ./${PN}-launcher "${dir}"
+ make_wrapper ${PN}-launcher "env SDL_DYNAMIC_API=\"${SDL}\" ./${PN}-launcher" "${dir}"
make_desktop_entry ${PN}-launcher "${MY_PN} (launcher)"
# Launcher binary has hardcoded the game path.
@@ -82,6 +83,5 @@ src_install() {
dodoc readme_changelog.txt
}
-pkg_preinst() { gnome2_icon_savelist; }
pkg_postinst() { gnome2_icon_cache_update; }
pkg_postrm() { gnome2_icon_cache_update; }