summaryrefslogtreecommitdiff
path: root/games-emulation/mupen64plus
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /games-emulation/mupen64plus
reinit the tree, so we can have metadata
Diffstat (limited to 'games-emulation/mupen64plus')
-rw-r--r--games-emulation/mupen64plus/Manifest16
-rw-r--r--games-emulation/mupen64plus/files/README.gentoo-patches-2009112355
-rw-r--r--games-emulation/mupen64plus/files/README.gentoo-patches-2010050759
-rw-r--r--games-emulation/mupen64plus/files/ftbfs-gvariant-type-conflicts.patch27
-rw-r--r--games-emulation/mupen64plus/files/mupen64plus-1.5-gcc46.patch11
-rw-r--r--games-emulation/mupen64plus/files/mupen64plus-1.5-libpng14.patch34
-rw-r--r--games-emulation/mupen64plus/files/mupen64plus-1.5-minizip.patch35
-rw-r--r--games-emulation/mupen64plus/metadata.xml24
-rw-r--r--games-emulation/mupen64plus/mupen64plus-1.5-r1.ebuild129
-rw-r--r--games-emulation/mupen64plus/mupen64plus-1.5-r2.ebuild137
-rw-r--r--games-emulation/mupen64plus/mupen64plus-2.0.ebuild22
-rw-r--r--games-emulation/mupen64plus/mupen64plus-2.5.ebuild22
12 files changed, 571 insertions, 0 deletions
diff --git a/games-emulation/mupen64plus/Manifest b/games-emulation/mupen64plus/Manifest
new file mode 100644
index 000000000000..a09efdcd99dd
--- /dev/null
+++ b/games-emulation/mupen64plus/Manifest
@@ -0,0 +1,16 @@
+AUX README.gentoo-patches-20091123 1355 SHA256 472ca36495f5cd59c66a23d4660dff19e890c7bca9c389352a54371f9aae5b2e SHA512 a8c5783a44a631acfa33d6e534baa67f542b820a0d9bf48b3696f0188326c01c9061c5cc504f08e2d25abe8923043fdd4931c3feb6931ebd8bb31c0f8a5ea1bd WHIRLPOOL 344dcc3ec5c4d859ee501b8e97e5984e3282f21fa6e550b91d31fa9d167b743481395fc8557c674ac2987a4ea76478aa3e224c4b29aaf83258866aedd2ad150b
+AUX README.gentoo-patches-20100507 1521 SHA256 c760661690d7f466bbd8640bae085b35f1e20b6c3ec882092b7547cbd32efccd SHA512 0808fb35ad32ec5747391de5e41cd49c381a0fefa0ba2d980ed6a7d786bb5b8d8bc4d51b383209d1003fa5b0f4275544f4348d5de89961a602474abc0d76f465 WHIRLPOOL cbbfbfae604c3fe86d9af8f0facea9a8e38927ec148ea45731f4d3b40bebb44c75c46724a39eeaa73c2528a2bf2ad02a4b405e486a3c557ebfbff56f0288071a
+AUX ftbfs-gvariant-type-conflicts.patch 828 SHA256 14483751e07912daeabb35b31f1b2fdae454658e00ea1a10627de29bd43881c0 SHA512 a0f559276ae3251500bdcb8c30745d089e91628b73e09b8ef0cfbe15ed29d53197f4e87b8ae8038e1b238788cdd5e60e445a60c6372c2e859175b824a1767a7f WHIRLPOOL fd73e40ff189219de65bd49a9a619c6336bcb092309515787e2bf94df78b3a2be85e3f361c02d5aaf55ad1f1ca132da13cadf7a0428f867a51b019ff21210a36
+AUX mupen64plus-1.5-gcc46.patch 335 SHA256 47eb75a963d9138f2aecaada6c4486bb9b6beff5e6acc0afcc2f364a94db540e SHA512 4a51e8aa654a1d17cbe45ebc22d80e5e43e140d98935e7d3b0b67baf500bde493a7fd3bed27afdcc36150863b78b112028b777e337f8f1a9191cfdcece4f0671 WHIRLPOOL 7be071aafd2ecdda7686031577bba5c9c589c05cc07a46170917facd2cf3483b9dc8b9be77bfeb6a85f6b4d457ccea18af9934d14bd7ba1c70be4f1c76e9af8c
+AUX mupen64plus-1.5-libpng14.patch 1404 SHA256 c0efb54eee809135dbb9429fc9869456a1d437a90929d9df09ab1102157d183f SHA512 92986174f22c8af493c2ad7d1052d6ab45e56c85fb0c2c6f8900c9061b33b21d95883225a1e1e547e7c2d648f0c81310b7b959687b519e02146d0176bc2cd5f1 WHIRLPOOL 3f5c1fbe33c3f5d7e066d55d77f30fde6b7361c3ce52c2f67c0720aa8ebaf244462cd3357d57bbc48014eff0adc48e974528bf9a6249571520c456aa1c98550d
+AUX mupen64plus-1.5-minizip.patch 806 SHA256 fb46d61b99bcc6415e3f17bcf536e6cc4591f0761aeca1757275d59de9affe76 SHA512 d2831daba45c7431cc62acbcd4e3c55a4c112a48611f739966387a41b3ba9f91d3e73fb96d14166184f084dfe37bb17ff1d0ceea454ea9d219c44dd2c5c01190 WHIRLPOOL 28d9c6f066224692418aec3a0c081a99a2123986f9f5047778d5b852e63fa9f3d71481af5e1c91a7f9a32913b26f41fc921db18dc842308b2946e856957677e2
+DIST Mupen64Plus-1-5-src.tar.gz 2348443 SHA256 58b2da6095ed8f3bcdcb5d7612bb0f1ba81cda1861ca784ef7e46991fd73cf3f SHA512 548be341e69eee543288a0a347ee117341847a032cc0a668a75ab7aaa881e876b6d143d2da9f8ec7580e4b1bbd2b36a3c8f99a0cb8c2301e4b03b593cdee5eb4 WHIRLPOOL fe5e63f07cc50676ef796a96d19e51eef38744f40e1626fd59471a65e530ac78109253ceb4f25cb9df2b4d33f4eecd47be1b9c7fa1a5d7a2304b98bdab0ef137
+DIST mupen64plus-1.5-patches-20091123.tar.bz2 25579 SHA256 b4bebb8105d7ca083b1e3d96d23dea9f2170703d53b0ea75e09b428e73e43187 SHA512 1fccfaed0d0a6d4bc3382a21b1529a173faa4fc718fd4dc6d94a850f5ad3788103041a202774c09f6db9a409b4de256a8b4a746f58860f13c8f69cc6243a9c3f WHIRLPOOL 5ed3fa14eb8a9c0b4fad71d70495125ebfe2313d23edf6155b7056fe9b583ceaeb860cf6b6df574caca315db54af786fda66871621bc1547f929f8f6e6161193
+DIST mupen64plus-1.5-patches-20100507.tar.bz2 33484 SHA256 372e437ab9d53eda23fd63cede33be38114efe527f239ef41b0c904fe208e2ce SHA512 f0265cbcc2e60bac906611a74bb7f5ea94a625d3abeee127fa105a308e9388258e2854ad91256fe14343f9b8837dfe43cb4eca16176a375f07c1259729045213 WHIRLPOOL c3fa3562bda7bd8a01fbc1644fbc7caa511bffec0efde7da479e40066bb8e31952bf98c718ab96b12211429835c458a9ab94c8fe8da540c301c83806e3bb1af1
+EBUILD mupen64plus-1.5-r1.ebuild 3239 SHA256 405cdb8c3d3a8ab5ea5437c9845b3a251bb5c771c4ad724bb3b9239c545a265c SHA512 e42a23956abcc0ad27cee2df775f9fa86c38d36cb3ea817cff384857d7181956ccab24e6abe44dbf8ed2e62456342412df3eca2c45f52a2e3e4179378b212122 WHIRLPOOL 54e05e01ca7c77c72d9d278df3980a1a19bb4b6679de4988aa9c42065145f6070dbeb35a1a67a4342b240db63b89c63c7dbb8d048fa95f5c43beb34f5a278c21
+EBUILD mupen64plus-1.5-r2.ebuild 3450 SHA256 a294b94a906bf5fc663b528de9c34d02c182e28ecb8f2da379e5c792403a7bd5 SHA512 38d236caf3e5959b788e36f36600d670529479f26bea457ac5beee44509787dd9ad120a89e1758e59e3c9891e563335ee016dec157fad1a06215f88baee211a2 WHIRLPOOL ddc7d8f4508863bb3f7327cc4ab728e2bf6865812f0c788eef825ed1d43121d38aeb7eec3055a7667e8ff09198df43d1dcad96d0431deee5655ea12d3ec9736e
+EBUILD mupen64plus-2.0.ebuild 797 SHA256 604aa5654fdd2a0f44912f0ad1c60fc085471c5cc895b65762b85a5bd19a9a2a SHA512 6e2018392dd18c315b2b98aa329206630189df1121cc837c31e65d7a47c587262fa9f688dfeb0cff13b440f6728f7128ee39582c038119b8866d31d739ccb214 WHIRLPOOL 81a299e12716232050c84617263a1148cf2144df4033ded9dbd341db28ca1e70fdb002e71ca6adc9662aa06cfafe4178e48f703e1b9424654a1c1b95892c7ff2
+EBUILD mupen64plus-2.5.ebuild 850 SHA256 4465cf865e2cb2060764a0248d9e0a567f1ce20caccf16bde25e8eb535d169eb SHA512 db172c94bc00f77f37ec07ef03b02f44185c6cd9506d989851a1a7decabe560187eaf460968f60482ec7e8a82e5e7f9ebf4aebf7fec4fdc17d3c360773d8d820 WHIRLPOOL dd0cecacb5272123197eb0e08ab59ffd8a3e2d8f25514e9cd09eb8e5b55af9a41011c4bb598670bfb6c611988c65d8eee01409aa94544bc5e8646fcf955a84e2
+MISC ChangeLog 4047 SHA256 acdc033a4a8354f292dc27a441a9d1abccbedfc5311bc0ba9ed16cf1c57c4620 SHA512 ec7bbb27ce512e260e89ec465e7c10fa6fe989c809828edc44d4a07091aa95ae073296f20330f395a323977880e5406482eab8e0d47c6b949d5447e8f55b4fc5 WHIRLPOOL 2aa08f9029f0bb87268df1801f79878bf323e7952a1a52c1f5999dc62db8682cbc263d2bb6ec9a2fb230d4a6f7825396de261c4fbc0d6f4c1e5c0150f7feaa6e
+MISC ChangeLog-2015 4880 SHA256 8f077586ed3916f5fc47a0adfd36abc4d6e4e95c26b2fe72c1c064687a86078f SHA512 5dce2f3edaa737af044ffa32ae2617d062bdfb3c025ea1bbce48a4b8af01813dc90664f013e73d6156eb4aedaa7ede2aa8d7dc45cc2a9566d06f06516bbb9bb4 WHIRLPOOL 0e7bc7141db0cdb752e35e595653ad03dcdfa271201c4b1f4687fd8628ababd6a01545297487e995e7c6ec679dbe2938fff255e5f94aabb0ba50ee4ffdc1a6c4
+MISC metadata.xml 1214 SHA256 37f55c762ab48066526f6d877b5816a52ffcc124fc268a9960e0774464a7197f SHA512 769d0957ce40eca186ef3f2ac1fa85722c0a1ed510150a6cd9f48250b2662468bf6c1280959388f79070eb28a39353c46580057f8f1fd2e5d47a58291dacd1c0 WHIRLPOOL 56b43b1d763a49fc6cfc982073f273eb16d8a8b4ee5222136f5831d805705fcf08c76f9cf4f7505ec09b82d97c5192c678e19040ac30d519d0235e95686ffd78
diff --git a/games-emulation/mupen64plus/files/README.gentoo-patches-20091123 b/games-emulation/mupen64plus/files/README.gentoo-patches-20091123
new file mode 100644
index 000000000000..96994d798b7a
--- /dev/null
+++ b/games-emulation/mupen64plus/files/README.gentoo-patches-20091123
@@ -0,0 +1,55 @@
+All patches below 500 are from the Debian git repository (Nov 23 12:35 CET 2009):
+
+http://git.debian.org/?p=collab-maint/mupen64plus.git;a=tree;f=debian/patches;hb=master
+
+Patches included:
+=================
+
+fix-desktop-file.patch
+destdir.patch
+dejavu-font.patch
+as-needed.patch
+system-libpng.patch
+system-zlib.patch
+system-libbz2.patch
+remove-gln64.patch
+remove-nondfsg-icons.patch
+glide64-noasm.patch
+rice-texturepack-crash.patch
+rice-screenflickering.patch
+static-binutils-libs.patch
+fix-7z-subfolder.patch
+ftbfs-dynarec.patch
+ftbfs-kfreebsd.patch
+ftbfs-debugger.patch
+debian-archs.patch
+ftbfs-glibc210.patch
+version-string.patch
+default-optimisations.patch
+gtk-open-filter.patch
+noexecstack.patch
+fix_readpng.patch
+jttl_fix_romclosed.patch
+rice_nodebug.patch
+interpreter_x86_fldcw.patch
+correct_fpr32_mapping.patch
+load_aidacrate.patch
+load_vistatus.patch
+fix_r0_override.patch
+resume_on_start.patch
+osd-pause-crash.patch
+system-liblzma.patch
+- system-liblzma got changed to work without the droped xdg-basedir.patch
+
+Patches excluded:
+=================
+
+plugin-searchpath.patch
+xdg-basedir.patch
+- Because Gentoo uses different locations like /usr/games/lib(64) and /usr/share/games.
+ The usage of xdg patch location standards would ne nice though.
+
+A big thanks to all the authors of the patches.
+
+Have fun
+Christian Birchinger <joker@gentoo.org>
diff --git a/games-emulation/mupen64plus/files/README.gentoo-patches-20100507 b/games-emulation/mupen64plus/files/README.gentoo-patches-20100507
new file mode 100644
index 000000000000..e6b857a07d48
--- /dev/null
+++ b/games-emulation/mupen64plus/files/README.gentoo-patches-20100507
@@ -0,0 +1,59 @@
+All patches below 500 are from the Debian git repository (May 07 2010):
+
+http://git.debian.org/?p=collab-maint/mupen64plus.git;a=tree;f=debian/patches;hb=master
+
+Patches included:
+=================
+
+fix-desktop-file.patch
+destdir.patch
+- dejavu-font.patch adjusted the font path to the font location on Gentoo systems
+as-needed.patch
+system-libpng.patch
+system-zlib.patch
+system-libbz2.patch
+remove-gln64.patch
+remove-nondfsg-icons.patch
+glide64-noasm.patch
+rice-texturepack-crash.patch
+rice-screenflickering.patch
+static-binutils-libs.patch
+fix-7z-subfolder.patch
+ftbfs-dynarec.patch
+ftbfs-kfreebsd.patch
+ftbfs-debugger.patch
+debian-archs.patch
+ftbfs-glibc210.patch
+version-string.patch
+default-optimisations.patch
+gtk-open-filter.patch
+noexecstack.patch
+fix_readpng.patch
+jttl_fix_romclosed.patch
+rice_nodebug.patch
+interpreter_x86_fldcw.patch
+correct_fpr32_mapping.patch
+load_aidacrate.patch
+load_vistatus.patch
+fix_r0_override.patch
+resume_on_start.patch
+osd-pause-crash.patch
+system-liblzma.patch
+ftbfs-gvariant-type-conflicts.path
+rsp_ucode2_reset.patch
+rsp_hle_bigendian.patch
+rice-crash-vendorstring.patch
+- system-liblzma got changed to work without the droped xdg-basedir.patch
+
+Patches excluded:
+=================
+
+plugin-searchpath.patch
+xdg-basedir.patch
+- Because Gentoo uses different locations like /usr/games/lib(64) and /usr/share/games.
+ The usage of xdg patch location standards would ne nice though.
+
+A big thanks to all the authors of the patches.
+
+Have fun
+Christian Birchinger <joker@gentoo.org>
diff --git a/games-emulation/mupen64plus/files/ftbfs-gvariant-type-conflicts.patch b/games-emulation/mupen64plus/files/ftbfs-gvariant-type-conflicts.patch
new file mode 100644
index 000000000000..e76da1707285
--- /dev/null
+++ b/games-emulation/mupen64plus/files/ftbfs-gvariant-type-conflicts.patch
@@ -0,0 +1,27 @@
+Description: Fix FTBFS due to glib gvariant type definitions
+Forwarded: not-needed
+Bug-Debian: http://bugs.debian.org/577329
+Author: Sven Eckelmann <sven.eckelmann@gmx.de>
+
+---
+diff --git a/rice_video/typedefs.h b/rice_video/typedefs.h
+index 4cded542b06445f043fa1fabf77e4d20c9d52920..b7e16e9c4ba3248f9fed9762f79349c137ee2026 100644
+--- a/rice_video/typedefs.h
++++ b/rice_video/typedefs.h
+@@ -20,10 +20,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ #ifndef _TYPEDEFS_H_
+ #define _TYPEDEFS_H_
+
+-#define uchar unsigned char
+-#define uint16 unsigned short
+-#define uint32 unsigned int
+-#define uint64 unsigned long long
++#include <stdint.h>
++
++typedef uint8_t uchar;
++typedef uint16_t uint16;
++typedef uint32_t uint32;
++typedef uint64_t uint64;
+
+ typedef unsigned char uint8;
+
diff --git a/games-emulation/mupen64plus/files/mupen64plus-1.5-gcc46.patch b/games-emulation/mupen64plus/files/mupen64plus-1.5-gcc46.patch
new file mode 100644
index 000000000000..2608fcd32a77
--- /dev/null
+++ b/games-emulation/mupen64plus/files/mupen64plus-1.5-gcc46.patch
@@ -0,0 +1,11 @@
+--- pre.mk.old 2011-04-14 20:39:21.000000000 +0200
++++ pre.mk 2011-04-14 20:39:57.000000000 +0200
+@@ -319,7 +319,7 @@
+ # tweak flags for 32-bit build on 64-bit system
+ ifeq ($(ARCH), 64BITS_32)
+ CFLAGS += -m32
+- LDFLAGS += -m32 -m elf_i386
++ LDFLAGS += -m32 -Wl,-m,elf_i386
+ endif
+ endif
+ ifeq ($(CPU_ENDIANNESS), BIG)
diff --git a/games-emulation/mupen64plus/files/mupen64plus-1.5-libpng14.patch b/games-emulation/mupen64plus/files/mupen64plus-1.5-libpng14.patch
new file mode 100644
index 000000000000..8d0b447fe96b
--- /dev/null
+++ b/games-emulation/mupen64plus/files/mupen64plus-1.5-libpng14.patch
@@ -0,0 +1,34 @@
+http://bugs.gentoo.org/show_bug.cgi?id=308753
+
+--- rice_video/liblinux/pngrw.c
++++ rice_video/liblinux/pngrw.c
+@@ -136,9 +136,9 @@
+ if (end_info != NULL)
+ png_destroy_read_struct((png_structp *) &png_ptr, (png_infop *) &info_ptr, (png_infop *) &end_info);
+ else if (info_ptr != NULL)
+- png_destroy_read_struct((png_structp *) &png_ptr, (png_infop *) &info_ptr, png_infopp_NULL);
++ png_destroy_read_struct((png_structp *) &png_ptr, (png_infop *) &info_ptr, NULL);
+ else if (png_ptr != NULL)
+- png_destroy_read_struct((png_structp *) &png_ptr, png_infopp_NULL, png_infopp_NULL);
++ png_destroy_read_struct((png_structp *) &png_ptr, NULL, NULL);
+ if (rows)
+ {
+ if (rows[0])
+@@ -162,7 +162,7 @@
+
+ /* check the signature */
+ fread( signature, 1, 8, file );
+- if ( !png_check_sig( signature, 8 ) )
++ if ( png_sig_cmp( signature, 0, 8 ) )
+ longjmp( err_jmp, (int)errUnsupportedFileFormat );
+
+ /* create a pointer to the png read structure */
+@@ -199,7 +199,7 @@
+
+ /* extract the data we need to form the HBITMAP from the PNG header */
+ png_get_IHDR( png_ptr, info_ptr, &Width, &Height, &BitDepth, &ColorType,
+- &InterlaceType, int_p_NULL, int_p_NULL);
++ &InterlaceType, (int *) NULL, (int *) NULL);
+
+ img->width = Width;
+ img->height = Height;
diff --git a/games-emulation/mupen64plus/files/mupen64plus-1.5-minizip.patch b/games-emulation/mupen64plus/files/mupen64plus-1.5-minizip.patch
new file mode 100644
index 000000000000..9ed3d7a0b256
--- /dev/null
+++ b/games-emulation/mupen64plus/files/mupen64plus-1.5-minizip.patch
@@ -0,0 +1,35 @@
+use minizip from system zlib
+
+https://bugs.gentoo.org/383845
+
+--- a/Makefile
++++ b/Makefile
+@@ -101,8 +101,6 @@
+ main/plugin.o \
+ main/rom.o \
+ main/savestates.o \
+- main/zip/ioapi.o \
+- main/zip/unzip.o \
+ main/7zip/7zAlloc.o \
+ main/7zip/7zBuffer.o \
+ main/7zip/7zCrc.o \
+@@ -229,7 +227,7 @@
+ # set primary objects and libraries for all outputs
+ ALL = mupen64plus $(PLUGINS)
+ OBJECTS = $(OBJ_CORE) $(OBJ_DYNAREC) $(OBJ_OPENGL)
+-LIBS = $(SDL_LIBS) $(LIBGL_LIBS) $(LZMA_LIBS) -lbz2
++LIBS = $(SDL_LIBS) $(LIBGL_LIBS) $(LZMA_LIBS) -lbz2 -lminizip
+ STATIC_LIBS =
+ CFLAGS+= $(LZMA_FLAGS)
+
+--- a/main/rom.c
++++ b/main/rom.c
+@@ -27,7 +27,7 @@
+ #include <limits.h>
+ #include <zlib.h>
+
+-#include "zip/unzip.h"
++#include "minizip/unzip.h"
+ #include <bzlib.h>
+ #include <lzma.h>
+ #include "7zip/7zExtract.h"
diff --git a/games-emulation/mupen64plus/metadata.xml b/games-emulation/mupen64plus/metadata.xml
new file mode 100644
index 000000000000..336e9cbb4fae
--- /dev/null
+++ b/games-emulation/mupen64plus/metadata.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>mgorny@gentoo.org</email>
+ <name>Michał Górny</name>
+ </maintainer>
+ <use>
+ <flag name="audio-sdl">Enable SDL audio plugin.</flag>
+ <flag name="input-sdl">Enable SDL input plugin.</flag>
+ <flag name="rsp-hle">Enable HLE RSP plugin.</flag>
+ <flag name="ui-console">Enable default console UI.</flag>
+ <flag name="ui-m64py">Enable PyQt4 UI using <pkg>games-emulation/m64py</pkg>.</flag>
+ <flag name="video-glide64mk2">Enable Glide64mk2 video plugin.</flag>
+ <flag name="video-rice">Enable Rice video plugin.</flag>
+ </use>
+ <longdescription>Mupen64Plus is a plugin-based N64 emulator for Linux which is capable of accurately playing many games.
+Included are four MIPS R4300 CPU emulators, with dynamic recompilers for 32-bit x86 and 64-bit amd64 systems,
+and necessary plugins for audio, graphical rendering (RDP), signal co-processor (RSP), and input.
+There are 3 OpenGL video plugins included: glN64, RiceVideoLinux, and Glide64.</longdescription>
+ <upstream>
+ <remote-id type="google-code">mupen64plus</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/games-emulation/mupen64plus/mupen64plus-1.5-r1.ebuild b/games-emulation/mupen64plus/mupen64plus-1.5-r1.ebuild
new file mode 100644
index 000000000000..39f6ad695545
--- /dev/null
+++ b/games-emulation/mupen64plus/mupen64plus-1.5-r1.ebuild
@@ -0,0 +1,129 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="2"
+
+inherit eutils flag-o-matic games
+
+MY_P="Mupen64Plus-${PV/./-}-src"
+
+PATCH_VERSION="20091123"
+
+DESCRIPTION="A fork of Mupen64 Nintendo 64 emulator"
+HOMEPAGE="http://www.mupen64plus.org/"
+SRC_URI="https://mupen64plus.googlecode.com/files/${MY_P}.tar.gz mirror://gentoo/${P}-patches-${PATCH_VERSION}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="+gtk libsamplerate lirc qt4 cpu_flags_x86_sse"
+
+# GTK+ is currently required by plugins even if no GUI support is enabled
+RDEPEND="virtual/opengl
+ media-libs/freetype:2
+ media-libs/libpng
+ media-libs/libsdl
+ media-libs/sdl-ttf
+ sys-libs/zlib
+ x11-libs/gtk+:2
+ libsamplerate? ( media-libs/libsamplerate )
+ lirc? ( app-misc/lirc )
+ qt4? ( dev-qt/qtgui:4
+ dev-qt/qtcore:4 )
+ app-arch/xz-utils"
+
+DEPEND="${RDEPEND}
+ dev-lang/yasm
+ virtual/pkgconfig"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ if ! use gtk && ! use qt4; then
+ ewarn "Building ${PN} without any GUI! To get one, enable USE=gtk or USE=qt4."
+ elif use gtk && use qt4; then
+ ewarn "Only one GUI can be built, using GTK+ one."
+ fi
+
+ games_pkg_setup
+}
+
+src_prepare() {
+ EPATCH_SOURCE="${WORKDIR}/patches" EPATCH_SUFFIX="patch" \
+ epatch
+
+ epatch "${FILESDIR}"/${P}-libpng14.patch
+
+ # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=577329
+ epatch "${FILESDIR}"/ftbfs-gvariant-type-conflicts.patch
+
+ sed -i \
+ -e "s:/usr/local/share/mupen64plus:${GAMES_DATADIR}/mupen64plus:" \
+ -e "s:%PUT_PLUGIN_PATH_HERE%:$(games_get_libdir)/${PN}/plugins/:" \
+ main/main.c || die "sed failed"
+
+ # Fix 010_all_fix-desktop-file.patch instead of using sed on the next major bump
+ sed -i \
+ -e "s:^Icon=mupen64plus-large.xpm:Icon=mupen64plus:" \
+ mupen64plus.desktop.in || die "sed failed"
+}
+
+get_opts() {
+ if use amd64 || use x86 ; then
+ echo -n "CPU=X86 ARCH=64BITS$(use x86 && echo -n _32) "
+ fi
+
+ use libsamplerate || echo -n "NO_RESAMP=1 "
+ use lirc && echo -n "LIRC=1 "
+ use cpu_flags_x86_sse || echo -n "NO_ASM=1 "
+
+ echo -n GUI=
+ if use gtk; then
+ echo -n GTK2
+ elif use qt4; then
+ echo -n QT4
+ else
+ echo -n NONE
+ fi
+}
+
+src_compile() {
+ use x86 && use cpu_flags_x86_sse && append-flags -fomit-frame-pointer
+ emake $(get_opts) DBGSYM=1 all || die "make failed"
+}
+
+src_install() {
+ # These are:
+ # 1) prefix - not used really, printed only
+ # 2) SHAREDIR
+ # 3) BINDIR
+ # 4) 'LIBDIR' - where to put plugins in
+ # 5) 'MANDIR' - exact directory to put man file in
+ # 6) APPLICATIONSDIR - where to put .desktop in
+
+ ./install.sh "${D}" \
+ "${D}${GAMES_DATADIR}/${PN}" \
+ "${D}${GAMES_BINDIR}" \
+ "${D}$(games_get_libdir)/${PN}/plugins" \
+ "${D}/usr/share/man/man1" \
+ "${D}/usr/share/applications" \
+ || or die "install.sh failed"
+
+ # Copy icon into system-wide location
+ newicon icons/mupen64plus-large.png ${PN}.png || die "newicon failed"
+
+ # 'Move' docs into correct dir
+ rm -r "${D}${GAMES_DATADIR}/${PN}/doc"
+ dodoc README RELEASE TODO doc/*.txt "${FILESDIR}/README.gentoo-patches-${PATCH_VERSION}" || die "dodoc failed"
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+
+ if use lirc; then
+ elog "For lirc configuration see:"
+ elog "https://code.google.com/p/mupen64plus/wiki/LIRC"
+ fi
+}
diff --git a/games-emulation/mupen64plus/mupen64plus-1.5-r2.ebuild b/games-emulation/mupen64plus/mupen64plus-1.5-r2.ebuild
new file mode 100644
index 000000000000..df6269c467c9
--- /dev/null
+++ b/games-emulation/mupen64plus/mupen64plus-1.5-r2.ebuild
@@ -0,0 +1,137 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="2"
+
+inherit eutils flag-o-matic games toolchain-funcs
+
+MY_P="Mupen64Plus-${PV/./-}-src"
+
+PATCH_VERSION="20100507"
+
+DESCRIPTION="A fork of Mupen64 Nintendo 64 emulator"
+HOMEPAGE="http://www.mupen64plus.org/"
+SRC_URI="https://mupen64plus.googlecode.com/files/${MY_P}.tar.gz mirror://gentoo/${P}-patches-${PATCH_VERSION}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="+gtk libsamplerate lirc qt4 cpu_flags_x86_sse"
+
+# GTK+ is currently required by plugins even if no GUI support is enabled
+RDEPEND="virtual/opengl
+ media-libs/freetype:2
+ media-libs/libpng
+ media-libs/libsdl
+ media-libs/sdl-ttf
+ media-fonts/dejavu
+ sys-libs/zlib[minizip]
+ x11-libs/gtk+:2
+ libsamplerate? ( media-libs/libsamplerate )
+ lirc? ( app-misc/lirc )
+ qt4? ( dev-qt/qtgui:4
+ dev-qt/qtcore:4 )
+ app-arch/xz-utils"
+
+DEPEND="${RDEPEND}
+ dev-lang/yasm
+ virtual/pkgconfig"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ if [[ ! $(tc-getCC) =~ gcc ]]; then
+ eerror
+ eerror "Compilers like clang and icc are not supported at this point"
+ eerror
+ die "You need gcc to build ${PN}"
+ fi
+
+ if ! use gtk && ! use qt4; then
+ ewarn "Building ${PN} without any GUI! To get one, enable USE=gtk or USE=qt4."
+ elif use gtk && use qt4; then
+ ewarn "Only one GUI can be built, using GTK+ one."
+ fi
+
+ games_pkg_setup
+}
+
+src_prepare() {
+ EPATCH_SOURCE="${WORKDIR}/patches" EPATCH_SUFFIX="patch" \
+ epatch
+
+ rm -rf main/zip
+ epatch "${FILESDIR}"/${P}-minizip.patch #383845
+
+ sed -i \
+ -e "s:/usr/local/share/mupen64plus:${GAMES_DATADIR}/mupen64plus:" \
+ -e "s:%PUT_PLUGIN_PATH_HERE%:$(games_get_libdir)/${PN}/plugins/:" \
+ main/main.c || die "sed failed"
+
+ # Fix 010_all_fix-desktop-file.patch instead of using sed on the next major bump
+ sed -i \
+ -e "s:^Icon=mupen64plus-large.xpm:Icon=mupen64plus:" \
+ mupen64plus.desktop.in || die "sed failed"
+ epatch "${FILESDIR}"/${P}-gcc46.patch
+}
+
+get_opts() {
+ if use amd64 || use x86 ; then
+ echo -n "CPU=X86 ARCH=64BITS$(use x86 && echo -n _32) "
+ fi
+
+ use libsamplerate || echo -n "NO_RESAMP=1 "
+ use lirc && echo -n "LIRC=1 "
+ use cpu_flags_x86_sse || echo -n "NO_ASM=1 "
+
+ echo -n GUI=
+ if use gtk; then
+ echo -n GTK2
+ elif use qt4; then
+ echo -n QT4
+ else
+ echo -n NONE
+ fi
+}
+
+src_compile() {
+ tc-export CC CXX
+ use x86 && use cpu_flags_x86_sse && append-flags -fomit-frame-pointer
+ emake $(get_opts) DBGSYM=1 CC="${CC}" CXX="${CXX}" LD="${CC}" all || die "make failed"
+}
+
+src_install() {
+ # These are:
+ # 1) prefix - not used really, printed only
+ # 2) SHAREDIR
+ # 3) BINDIR
+ # 4) 'LIBDIR' - where to put plugins in
+ # 5) 'MANDIR' - exact directory to put man file in
+ # 6) APPLICATIONSDIR - where to put .desktop in
+
+ ./install.sh "${D}" \
+ "${D}${GAMES_DATADIR}/${PN}" \
+ "${D}${GAMES_BINDIR}" \
+ "${D}$(games_get_libdir)/${PN}/plugins" \
+ "${D}/usr/share/man/man1" \
+ "${D}/usr/share/applications" \
+ || or die "install.sh failed"
+
+ # Copy icon into system-wide location
+ newicon icons/mupen64plus-large.png ${PN}.png || die "newicon failed"
+
+ # 'Move' docs into correct dir
+ rm -r "${D}${GAMES_DATADIR}/${PN}/doc"
+ dodoc README RELEASE TODO doc/*.txt "${FILESDIR}/README.gentoo-patches-${PATCH_VERSION}" || die "dodoc failed"
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+
+ if use lirc; then
+ elog "For lirc configuration see:"
+ elog "https://code.google.com/p/mupen64plus/wiki/LIRC"
+ fi
+}
diff --git a/games-emulation/mupen64plus/mupen64plus-2.0.ebuild b/games-emulation/mupen64plus/mupen64plus-2.0.ebuild
new file mode 100644
index 000000000000..3205e5ad74ea
--- /dev/null
+++ b/games-emulation/mupen64plus/mupen64plus-2.0.ebuild
@@ -0,0 +1,22 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+DESCRIPTION="A fork of Mupen64 Nintendo 64 emulator, meta-package"
+HOMEPAGE="http://www.mupen64plus.org/"
+SRC_URI=""
+
+LICENSE="metapackage"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+audio-sdl +input-sdl +rsp-hle +ui-console +ui-m64py +video-glide64mk2 +video-rice"
+
+RDEPEND="games-emulation/mupen64plus-core
+ audio-sdl? ( games-emulation/mupen64plus-audio-sdl )
+ input-sdl? ( games-emulation/mupen64plus-input-sdl )
+ rsp-hle? ( games-emulation/mupen64plus-rsp-hle )
+ ui-console? ( games-emulation/mupen64plus-ui-console )
+ ui-m64py? ( games-emulation/m64py )
+ video-glide64mk2? ( games-emulation/mupen64plus-video-glide64mk2 )
+ video-rice? ( games-emulation/mupen64plus-video-rice )"
diff --git a/games-emulation/mupen64plus/mupen64plus-2.5.ebuild b/games-emulation/mupen64plus/mupen64plus-2.5.ebuild
new file mode 100644
index 000000000000..f52987e83a17
--- /dev/null
+++ b/games-emulation/mupen64plus/mupen64plus-2.5.ebuild
@@ -0,0 +1,22 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+DESCRIPTION="A fork of Mupen64 Nintendo 64 emulator, meta-package"
+HOMEPAGE="http://www.mupen64plus.org/"
+SRC_URI=""
+
+LICENSE="metapackage"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+audio-sdl +input-sdl +rsp-hle +ui-console +ui-m64py +video-glide64mk2 +video-rice"
+
+RDEPEND=">=games-emulation/mupen64plus-core-2.5
+ audio-sdl? ( >=games-emulation/mupen64plus-audio-sdl-2.5 )
+ input-sdl? ( >=games-emulation/mupen64plus-input-sdl-2.5 )
+ rsp-hle? ( >=games-emulation/mupen64plus-rsp-hle-2.5 )
+ ui-console? ( >=games-emulation/mupen64plus-ui-console-2.5 )
+ ui-m64py? ( >=games-emulation/m64py-0.2.3-r1 )
+ video-glide64mk2? ( >=games-emulation/mupen64plus-video-glide64mk2-2.5 )
+ video-rice? ( >=games-emulation/mupen64plus-video-rice-2.5 )"