diff options
author | James Le Cuirot <chewi@gentoo.org> | 2024-05-19 16:47:26 +0100 |
---|---|---|
committer | James Le Cuirot <chewi@gentoo.org> | 2024-05-19 17:16:32 +0100 |
commit | 4f53cb5dc684ca1f63a571688f04b16ce071db24 (patch) | |
tree | 5c99087800d9224e3f44050ed58085437818841e /games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild | |
parent | games-action/guacamelee: Bump to 20231012, drop old 20140222, EAPI 8 (diff) | |
download | gentoo-4f53cb5dc684ca1f63a571688f04b16ce071db24.tar.gz gentoo-4f53cb5dc684ca1f63a571688f04b16ce071db24.tar.bz2 gentoo-4f53cb5dc684ca1f63a571688f04b16ce071db24.zip |
games-action/trine-enchanted-edition: libsdl2 will drop threads USE flag, EAPI 8
Signed-off-by: James Le Cuirot <chewi@gentoo.org>
Diffstat (limited to 'games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild')
-rw-r--r-- | games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild b/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild new file mode 100644 index 000000000000..4da88ca90795 --- /dev/null +++ b/games-action/trine-enchanted-edition/trine-enchanted-edition-2.12.508-r4.ebuild @@ -0,0 +1,83 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit desktop wrapper xdg + +MY_P="${PV//./_}" +MY_P="${PN//-/_}_v${MY_P%_*}_build_${MY_P##*_}" +MY_PN="Trine Enchanted Edition" + +DESCRIPTION="The original sidescrolling action platformer under the Trine 2 engine" +HOMEPAGE="https://www.frozenbyte.com/games/trine-enchanted-edition" +SRC_URI="${MY_P}_humble_linux_full.zip" +S="${WORKDIR}/linux/_enchanted_edition_" +LICENSE="all-rights-reserved" +SLOT="0" +KEYWORDS="-* ~amd64 ~x86" +IUSE="+launcher" +RESTRICT="bindist fetch splitdebug" + +QA_PREBUILT="opt/${PN}/${PN}*" + +BDEPEND="app-arch/unzip" + +# SDL 1.3 is bundled but the game appears to be statically linked +# 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] + >=sys-libs/glibc-2.15 + sys-libs/zlib[abi_x86_32] + virtual/glu[abi_x86_32] + virtual/opengl[abi_x86_32] + launcher? ( + dev-libs/glib:2[abi_x86_32] + media-libs/libpng-compat:1.2[abi_x86_32] + x11-libs/gdk-pixbuf:2[abi_x86_32] + x11-libs/gtk+:2[abi_x86_32] + x11-libs/libX11[abi_x86_32] + x11-libs/pango[abi_x86_32,X] + )" + +pkg_nofetch() { + einfo "Please buy and download ${SRC_URI} from:" + einfo " https://www.humblebundle.com/store/${PN}" + einfo "and move it to your distfiles directory." +} + +src_install() { + local dir=/opt/${PN} SDL=${EPREFIX}/usr/$(ABI=x86 get_libdir)/libSDL2-2.0.so.0 + + insinto "${dir}" + doins -r *.fbq data + + exeinto "${dir}" + newexe bin/trine1_linux_32bit ${PN} + + 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 "env SDL_DYNAMIC_API=\"${SDL}\" ./${PN}-launcher" "${dir}" + make_desktop_entry ${PN}-launcher "${MY_PN} (launcher)" + + # Launcher binary has hardcoded the game path. + dosym ../${PN} "${dir}"/bin/trine1_bin_starter.sh + fi + + newicon -s 64 trine1.png ${PN}.png + dodoc readme_changelog.txt +} |