diff options
author | Michał Górny <mgorny@gentoo.org> | 2013-12-11 18:31:45 +0000 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2013-12-11 18:31:45 +0000 |
commit | e3d0d892bf98d9b1fc1ec0d045e3888689b8efd5 (patch) | |
tree | 97186fdb4b0abc034f68eb9c4ab6a663dac1a623 /games-emulation | |
parent | Version bump, see owncloud.org/six for the new features (diff) | |
download | historical-e3d0d892bf98d9b1fc1ec0d045e3888689b8efd5.tar.gz historical-e3d0d892bf98d9b1fc1ec0d045e3888689b8efd5.tar.bz2 historical-e3d0d892bf98d9b1fc1ec0d045e3888689b8efd5.zip |
Introduce an ebuild for pcsxr, the forked PSX emu. Bug #492936.
Package-Manager: portage-2.2.7/cvs/Linux x86_64
Manifest-Sign-Key: 0xEFB4464E!
Diffstat (limited to 'games-emulation')
-rw-r--r-- | games-emulation/pcsxr/ChangeLog | 10 | ||||
-rw-r--r-- | games-emulation/pcsxr/Manifest | 28 | ||||
-rw-r--r-- | games-emulation/pcsxr/files/pcsxr-1.9.94-disable-sdl2.patch | 28 | ||||
-rw-r--r-- | games-emulation/pcsxr/files/pcsxr-1.9.94-install-paths.patch | 223 | ||||
-rw-r--r-- | games-emulation/pcsxr/metadata.xml | 13 | ||||
-rw-r--r-- | games-emulation/pcsxr/pcsxr-1.9.94.ebuild | 99 |
6 files changed, 401 insertions, 0 deletions
diff --git a/games-emulation/pcsxr/ChangeLog b/games-emulation/pcsxr/ChangeLog new file mode 100644 index 000000000000..aec6b3f36247 --- /dev/null +++ b/games-emulation/pcsxr/ChangeLog @@ -0,0 +1,10 @@ +# ChangeLog for games-emulation/pcsxr +# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/games-emulation/pcsxr/ChangeLog,v 1.1 2013/12/11 18:31:40 mgorny Exp $ + +*pcsxr-1.9.94 (11 Dec 2013) + + 11 Dec 2013; Michał Górny <mgorny@gentoo.org> + +files/pcsxr-1.9.94-disable-sdl2.patch, + +files/pcsxr-1.9.94-install-paths.patch, +metadata.xml, +pcsxr-1.9.94.ebuild: + Introduce an ebuild for pcsxr, the forked PSX emu. Bug #492936. diff --git a/games-emulation/pcsxr/Manifest b/games-emulation/pcsxr/Manifest new file mode 100644 index 000000000000..58f5b451c48f --- /dev/null +++ b/games-emulation/pcsxr/Manifest @@ -0,0 +1,28 @@ +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + +AUX pcsxr-1.9.94-disable-sdl2.patch 1059 SHA256 7be3baa643513cee92fa908c6ae529c5f953a24f0ce7a01fc602fbba0381897e SHA512 aa010d8203a45ddd7f93fcc74d3ec9010dcdf6a79d36bb72aa434caccac650c2dee5a74e52e11e40b35356ca30d9a37a52b5e76dcacba64634988b9e57c74171 WHIRLPOOL 6cd5224095001b48ac922ffa8bcb3f3a749edb4540e8b1a4d404835b4f391a3b63c2fa1d25725c01bf83c9b919fdf78d16b2f2fc1f404c37c9d96848f6f8bfce +AUX pcsxr-1.9.94-install-paths.patch 7343 SHA256 88c95173a5798c1796e1cdad4116eb221c1ce3c47b6a5c2bc60bfc1e6e358a59 SHA512 fcff961ef5e88ba8af2dc7adc160c5b79c1908379e6bd7beb6669bfb7fa8a3e7596b88cbe8c1dde06ac320c4ea725806f19e8c10d1c1197345251c104c354916 WHIRLPOOL 71c114941128941b9980d23072334124884344b9ebc7591308cc96c15ddb4d8737ee014b755142a9ddc3544d0191f6aca787ea210dd4b09bc0590efc8b9798f7 +DIST pcsxr-1.9.94.zip 2631125 SHA256 291941eebe695d9133539783dee208fce9d7419f0042964f96bf10ce3eee9fa3 SHA512 c49471c27692fbf22da32d2f5697a1dfed3dbdbfdb86cb789b0ea6cddb2a7da4f3390e4568f4e9385bf30d6baff0f2a591a80f424cf0c640cae0035ba81dce39 WHIRLPOOL 8095fda6821cb7549574f8ff97d75d34350317f0e71ce27f9c540244ca66d3419c1aa4bdac91142cd7304daa7d56689565417f7203eb67f605c81727859a7cea +EBUILD pcsxr-1.9.94.ebuild 2281 SHA256 81bcc7cd6d73aa2bb964f7b043c5d25003eea61d0b706e38694373c17f566b9c SHA512 06e3367225392dee2077b09535a9b2c87ee18af1bf5b398c6e6850d8827972099d8cc9dc397015397fd41f65fe9534608df7e290957b196a8f522675e6b5c5af WHIRLPOOL c2481bf43fe980f633cc305d34d50db33e85cf259b3c07bff6ef828e85bba9d0d06b2b1966d9870ba8bde4f365c43211a1bc9a95ae70f5eaeea79c4fd5fed8c7 +MISC ChangeLog 482 SHA256 81b2dad0de7797aafae4199919234a16d4c32977e1e8f41196b7b9c6a1b8e4ac SHA512 03e8fae452d656cfa97668f3dc62c5f76fe6facf8f309e4279fd1c95f266374c8cf42e0a7c9e1af1fe2f3fec731e02e78e44fbcca55be724b8e34f6bf2cb0ce3 WHIRLPOOL 3d37b813d651d49bc2320cb3f7cbed49f68457593ada9e24c582766ce76684051dd0106d64fb0f17063c4a441bcecbbdb746eab11b5c0003b83b0e5fa5ac44cb +MISC metadata.xml 416 SHA256 4f7d5ac6ae0ded3af2f577e71e2d80ae55d91a106a848cdfd67a80a45671f6de SHA512 41b900eceb08da6ba79a050d0e7b96264a07ffdcaa566c78e8572d6800e1fdead411cc85b2645c6c7120cb2e356defa695d57160d7cfb6c24ac923a52294f34a WHIRLPOOL fb4e312b7da6b62db77075c17e25116e4fadb09d3dfc4e17ee12250f0fe036d28b8b324e674c8395a46f19cf61d97ac5468ea77ea6cf6199a6255002d2362ee0 +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.22 (GNU/Linux) + +iQJ8BAEBCABmBQJSqK+RXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w +ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2REJCMDdDQzRGMERBRDA2RUEwQUZFNDFC +MDdBMUFFQUVGQjQ0NjRFAAoJELB6GurvtEZOHo0QAK6qkNCM7nAneBPsSnIloa0b +LqRi0SV8W1u2ZLZmDmnDAqcoQ6BEk4QsHQzDXMMLfenIWeF2QbH5wlEmxeRD05oY +zpAXNadvVFLn/E0Hl5qZXP3R4CqozW23PG8NMlBjQAuDbw2h/3J2nDPQbrsGNDuK +HW52RjImxhIpPJiCrtb2gTPlWSeyo4rkFp8pnu7DM6+mNE9MOer4HYOK5a342rvA +oYuaui4CQyEMbf9JB5qKJiurBGALk2Hr942YjMziNz9v4Io5J7bnuYTJpIbyZqMg +PwPinNFh9yHy/mlrnHzDBUmQ7lcnZkPibhThYNeWRbFS2Odygm9Iw8GU+Vj0kFpG +OUSRj5hD/qslfGtVhv9UXEHSTXy0gekuqsIVL+3VLVZpoRNowRsbuFE+UMDd5NHl +ujx82tJFcaHRWvZx5r31aTGSrof4AsG9JYzey4gaJRER+NCf7xh3CU8sjnrifneP +lHO3bgqUvkVriX2dBFqaocMLIlsNl3r6MP/z5/U539RcRJtAlUFSUdD4gg4BWNCw +ZK50JJJFTV57eNRwzj4znMUGf86VMSfCx3hHgo1jZoMMkZOuHkhO/blFoh3Q1TSL +wjjnAto+uPlH0g7+YM+UR3jGPDbRHBwHwbOKy0be0Dw0JhR73eNLSFWuLg8CSYB2 +sV8XSlHCzBQfg85tlecz +=8blb +-----END PGP SIGNATURE----- diff --git a/games-emulation/pcsxr/files/pcsxr-1.9.94-disable-sdl2.patch b/games-emulation/pcsxr/files/pcsxr-1.9.94-disable-sdl2.patch new file mode 100644 index 000000000000..483ea56660e6 --- /dev/null +++ b/games-emulation/pcsxr/files/pcsxr-1.9.94-disable-sdl2.patch @@ -0,0 +1,28 @@ +From b7864d1b8db75eda19a7601f3e2402a885bb251d Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> +Date: Wed, 11 Dec 2013 17:19:09 +0100 +Subject: [PATCH] Disable SDL2 check for Gentoo. + +The SDL2 support seems immature at the moment, so we'd prefer pcsxr +using SDL1 even if SDL2 is installed. +--- + configure.ac | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index f79cee0..0c79cff 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -26,8 +26,7 @@ AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], ["${GETTEXT_PACKAGE}"], [gettext domain]) + PKG_CHECK_MODULES(GLIB2, glib-2.0 >= 2.20, [], AC_MSG_ERROR([*** glib2 >= 2.20 not found!])) + PKG_CHECK_MODULES(GTK3, gtk+-3.0 , [], AC_MSG_ERROR([*** libgtk3 >= 3.0 not found!])) + +-PKG_CHECK_MODULES([SDL2], [sdl2 >= 2.0.0], +- [AC_DEFINE([HAVE_SDL2], [1], [Use SDL2])], ++AS_IF([true], + [PKG_CHECK_MODULES([SDL], [sdl >= 1.2.12], + [AC_DEFINE([HAVE_SDL], [1], [Use SDL]) + ], AC_MSG_ERROR([*** SDL >= 1.2.12 not found!])) +-- +1.8.5.1 + diff --git a/games-emulation/pcsxr/files/pcsxr-1.9.94-install-paths.patch b/games-emulation/pcsxr/files/pcsxr-1.9.94-install-paths.patch new file mode 100644 index 000000000000..adf2866e1fdf --- /dev/null +++ b/games-emulation/pcsxr/files/pcsxr-1.9.94-install-paths.patch @@ -0,0 +1,223 @@ +From a5b0086e76672083f91ddb4d0350cc99c19604fb Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> +Date: Wed, 11 Dec 2013 17:12:58 +0100 +Subject: [PATCH 1/2] Fix install paths for Gentoo. + +--- + data/Makefile.am | 2 +- + gui/Makefile.am | 6 +++--- + libpcsxcore/Makefile.am | 2 +- + pixmaps/Makefile.am | 2 +- + plugins/bladesio1/Makefile.am | 6 +++--- + plugins/dfcdrom/Makefile.am | 6 +++--- + plugins/dfinput/Makefile.am | 6 +++--- + plugins/dfnet/Makefile.am | 6 +++--- + plugins/dfsound/Makefile.am | 6 +++--- + plugins/dfxvideo/Makefile.am | 6 +++--- + plugins/peopsxgl/Makefile.am | 8 ++++---- + 11 files changed, 28 insertions(+), 28 deletions(-) + +diff --git a/data/Makefile.am b/data/Makefile.am +index 8f1ce6a..9df8e87 100644 +--- a/data/Makefile.am ++++ b/data/Makefile.am +@@ -1,7 +1,7 @@ + glade_DATA = pcsxr.ui + gladedir = $(datadir)/pcsxr + +-desktopdir = $(datadir)/applications ++desktopdir = $(datarootdir)/applications + desktop_DATA = pcsxr.desktop + + EXTRA_DIST = $(glade_DATA) pcsxr.desktop +diff --git a/gui/Makefile.am b/gui/Makefile.am +index 5feb39e..6146ef0 100644 +--- a/gui/Makefile.am ++++ b/gui/Makefile.am +@@ -1,10 +1,10 @@ + AM_CPPFLAGS = -DPACKAGE_DATA_DIR=\"${datadir}/pcsxr/\" \ +- -DPIXMAPDIR=\"${datadir}/pixmaps/\" \ +- -DLOCALE_DIR=\"${datadir}/locale/\" \ ++ -DPIXMAPDIR=\"${datarootdir}/pixmaps/\" \ ++ -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + $(GTK3_CFLAGS) \ + -I$(top_srcdir)/libpcsxcore -I$(top_srcdir)/include \ + -DPSEMU_DATA_DIR=\"${datadir}/psemu\" \ +- -DDEF_PLUGIN_DIR=\"${libdir}/games/psemu\" ++ -DDEF_PLUGIN_DIR=\"${libdir}/psemu\" + + bin_PROGRAMS = pcsxr + +diff --git a/libpcsxcore/Makefile.am b/libpcsxcore/Makefile.am +index 1ae5389..9571ea3 100644 +--- a/libpcsxcore/Makefile.am ++++ b/libpcsxcore/Makefile.am +@@ -1,4 +1,4 @@ +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -I$(top_srcdir)/include + + noinst_LIBRARIES = libpcsxcore.a +diff --git a/pixmaps/Makefile.am b/pixmaps/Makefile.am +index e77fda4..f7e10da 100644 +--- a/pixmaps/Makefile.am ++++ b/pixmaps/Makefile.am +@@ -1,7 +1,7 @@ + pixmapdir = "$(datadir)/pcsxr" + pixmap_DATA = pcsxr.png iso-open.png iso-reopen.png cd.png cdr.png gpu.png memcard.png pad.png play.png sio1.png spu.png + +-icondir = "$(datadir)/pixmaps" ++icondir = "$(datarootdir)/pixmaps" + icon_DATA = pcsxr-icon.png + + EXTRA_DIST = pcsxr.png iso-open.png iso-reopen.png cd.png cdr.png gpu.png memcard.png pad.png play.png sio1.png spu.png pcsxr-icon.png +diff --git a/plugins/bladesio1/Makefile.am b/plugins/bladesio1/Makefile.am +index 5b7fee4..75d9588 100644 +--- a/plugins/bladesio1/Makefile.am ++++ b/plugins/bladesio1/Makefile.am +@@ -1,12 +1,12 @@ +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libBladeSio1.la + + libBladeSio1_la_SOURCES = cfg.c sio1.c sio1.h fifo.c fifo.h connection.c connection.h + libBladeSio1_la_LDFLAGS = -module -avoid-version + +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) \ + -I../../libpcsxcore -I../../include +diff --git a/plugins/dfcdrom/Makefile.am b/plugins/dfcdrom/Makefile.am +index b4c729f..297b4f9 100644 +--- a/plugins/dfcdrom/Makefile.am ++++ b/plugins/dfcdrom/Makefile.am +@@ -1,5 +1,5 @@ +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libDFCdrom.la + +@@ -21,7 +21,7 @@ libDFCdrom_la_CFLAGS += -DUSE_LIBCDIO=1 $(LIBCDIO_CFLAGS) + libDFCdrom_la_LIBADD += $(LIBCDIO_LIBS) + endif + +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) \ + -I../../libpcsxcore -I../../include +diff --git a/plugins/dfinput/Makefile.am b/plugins/dfinput/Makefile.am +index f270ca7..0f7f9b5 100644 +--- a/plugins/dfinput/Makefile.am ++++ b/plugins/dfinput/Makefile.am +@@ -1,5 +1,5 @@ +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libDFInput.la + +@@ -7,7 +7,7 @@ libDFInput_la_SOURCES = cfg.c pad.c pad.h sdljoy.c xkb.c analog.c util.c util.h + libDFInput_la_LDFLAGS = -module -avoid-version + libDFInput_la_LIBADD = -lpthread -lX11 $(SDL2_LIBS) $(SDL_LIBS) + +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) \ + -I../../include -I../../libpcsxcore $(SDL2_CFLAGS) $(SDL_CFLAGS) +diff --git a/plugins/dfnet/Makefile.am b/plugins/dfnet/Makefile.am +index 004df63..fff3dba 100644 +--- a/plugins/dfnet/Makefile.am ++++ b/plugins/dfnet/Makefile.am +@@ -1,12 +1,12 @@ +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libDFNet.la + + libDFNet_la_SOURCES = dfnet.c dfnet.h unix.c cfg.c + libDFNet_la_LDFLAGS = -module -avoid-version + +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) \ + -I../../libpcsxcore -I../../include +diff --git a/plugins/dfsound/Makefile.am b/plugins/dfsound/Makefile.am +index 5325555..15515b8 100644 +--- a/plugins/dfsound/Makefile.am ++++ b/plugins/dfsound/Makefile.am +@@ -1,7 +1,7 @@ + AM_CPPFLAGS = -I../../include + +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libDFSound.la + +@@ -46,7 +46,7 @@ libDFSound_la_CPPFLAGS += -DUSENULL=1 + endif + + bin_PROGRAMS = cfgDFSound +-cfgDFSound_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++cfgDFSound_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) $(AM_CPPFLAGS) + cfgDFSound_SOURCES = spucfg-0.1df/main.c +diff --git a/plugins/dfxvideo/Makefile.am b/plugins/dfxvideo/Makefile.am +index 2af76fd..0515690 100644 +--- a/plugins/dfxvideo/Makefile.am ++++ b/plugins/dfxvideo/Makefile.am +@@ -6,14 +6,14 @@ SUFFIXES = .asm + $(LIBTOOL) --tag=CC --mode=compile \ + $(STRIP_FPIC) $(NASM) -f elf -d ELF -I${srcdir}/ $< + +-AM_CPPFLAGS = -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS)\ + -I../../libpcsxcore \ + -I../../include + +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libDFXVideo.la + +diff --git a/plugins/peopsxgl/Makefile.am b/plugins/peopsxgl/Makefile.am +index 99c9554..e3af49f 100644 +--- a/plugins/peopsxgl/Makefile.am ++++ b/plugins/peopsxgl/Makefile.am +@@ -1,11 +1,11 @@ +-AM_CPPFLAGS = -DPIXMAPDIR=\"${datadir}/pixmaps/\" \ +- -DLOCALE_DIR=\"${datadir}/locale/\" \ ++AM_CPPFLAGS = -DPIXMAPDIR=\"${datarootdir}/pixmaps/\" \ ++ -DLOCALE_DIR=\"${datarootdir}/locale/\" \ + -DDATADIR=\"${datadir}/psemu/\" \ + $(GTK3_CFLAGS) \ + -I../../libpcsxcore -I../../include + +-bindir = @libdir@/games/psemu/ +-libdir = @libdir@/games/psemu/ ++bindir = @libdir@/psemu/ ++libdir = @libdir@/psemu/ + + lib_LTLIBRARIES = libpeopsxgl.la + +-- +1.8.5.1 + diff --git a/games-emulation/pcsxr/metadata.xml b/games-emulation/pcsxr/metadata.xml new file mode 100644 index 000000000000..8d5de1e77802 --- /dev/null +++ b/games-emulation/pcsxr/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>games</herd> + <maintainer> + <email>mgorny@gentoo.org</email> + <name>Michał Górny</name> + </maintainer> + <use> + <flag name='cdio'>Use libcdio for CD support</flag> + <flag name='sdl'>Use SDL sound backend (other parts of SDL are used unconditionally)</flag> + </use> +</pkgmetadata> diff --git a/games-emulation/pcsxr/pcsxr-1.9.94.ebuild b/games-emulation/pcsxr/pcsxr-1.9.94.ebuild new file mode 100644 index 000000000000..bd1e1a73903c --- /dev/null +++ b/games-emulation/pcsxr/pcsxr-1.9.94.ebuild @@ -0,0 +1,99 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-emulation/pcsxr/pcsxr-1.9.94.ebuild,v 1.1 2013/12/11 18:31:40 mgorny Exp $ + +EAPI=5 + +inherit autotools eutils games + +DESCRIPTION="PCSX-Reloaded: a fork of PCSX, the discontinued Playstation emulator" +HOMEPAGE="http://pcsxr.codeplex.com" +# codeplex doesn't support direct downloads but GPL-2 doesn't mind me +# mirroring it. +SRC_URI="http://dev.gentoo.org/~mgorny/dist/${P}.zip" + +LICENSE="GPL-2 public-domain" +SLOT="0" +KEYWORDS="~amd64" +IUSE="alsa cdio ffmpeg nls openal opengl oss pulseaudio +sdl" + +# pcsxr supports both SDL1 and SDL2 but uses the newer version installed +# since SDL is not properly slotted in Gentoo, just fix it on SDL2 + +RDEPEND="dev-libs/glib:2= + media-libs/libsdl:0=[joystick] + sys-libs/zlib:0= + x11-libs/gtk+:3= + x11-libs/libX11:0= + x11-libs/libXext:0= + x11-libs/libXtst:0= + x11-libs/libXv:0= + alsa? ( media-libs/alsa-lib:0= ) + cdio? ( dev-libs/libcdio:0= ) + ffmpeg? ( virtual/ffmpeg:0= ) + nls? ( virtual/libintl:0= ) + openal? ( media-libs/openal:0= ) + opengl? ( virtual/opengl:0= + x11-libs/libXxf86vm:0= ) + pulseaudio? ( media-sound/pulseaudio:0= ) + sdl? ( media-libs/libsdl:0=[audio] )" +DEPEND="${RDEPEND} + app-arch/unzip + dev-util/intltool + x11-proto/videoproto + nls? ( sys-devel/gettext:0 ) + x86? ( dev-lang/nasm )" + +REQUIRED_USE="?? ( alsa openal oss pulseaudio sdl )" + +# it's only the .po file check that fails :) +RESTRICT=test + +S=${WORKDIR}/${PN} + +src_prepare() { + local PATCHES=( + "${FILESDIR}"/${P}-disable-sdl2.patch + "${FILESDIR}"/${P}-install-paths.patch + ) + + epatch "${PATCHES[@]}" + epatch_user + eautoreconf +} + +src_configure() { + local sound_backend + + if use alsa; then + sound_backend=alsa + elif use oss; then + sound_backend=oss + elif use pulseaudio; then + sound_backend=pulseaudio + elif use sdl; then + sound_backend=sdl + elif use openal; then + sound_backend=openal + else + sound_backend=null + fi + + local myeconfargs=( + $(use_enable nls) + $(use_enable cdio libcdio) + $(use_enable opengl) + $(use_enable ffmpeg ccdda) + --enable-sound=${sound_backend} + ) + + egamesconf "${myeconfargs[@]}" +} + +src_install() { + default + prune_libtool_files --all + + dodoc doc/{keys,tweaks}.txt + prepgamesdirs +} |