diff options
author | Christian Birchinger <joker@gentoo.org> | 2007-03-28 00:58:24 +0000 |
---|---|---|
committer | Christian Birchinger <joker@gentoo.org> | 2007-03-28 00:58:24 +0000 |
commit | 121c27dbab1fdbba02cd92ce2529443c256b956c (patch) | |
tree | deb436faadc94d2fca5b7578af1f2f7d45b61750 /games-emulation/mupen64 | |
parent | gnome 2.18.0 (diff) | |
download | gentoo-2-121c27dbab1fdbba02cd92ce2529443c256b956c.tar.gz gentoo-2-121c27dbab1fdbba02cd92ce2529443c256b956c.tar.bz2 gentoo-2-121c27dbab1fdbba02cd92ce2529443c256b956c.zip |
New revision with some patches from the standalone glN64 ebuild. Infos taken from Bug #170763 and thanks to Sal Gonzalez <ghostx@optonline.net>.
(Portage version: 2.1.2.2)
Diffstat (limited to 'games-emulation/mupen64')
-rw-r--r-- | games-emulation/mupen64/ChangeLog | 10 | ||||
-rw-r--r-- | games-emulation/mupen64/files/digest-mupen64-0.5-r4 | 3 | ||||
-rw-r--r-- | games-emulation/mupen64/files/mupen64-glN64-noasmfix.patch | 11 | ||||
-rw-r--r-- | games-emulation/mupen64/files/mupen64-glN64-ucode.patch | 121 | ||||
-rw-r--r-- | games-emulation/mupen64/mupen64-0.5-r4.ebuild | 91 |
5 files changed, 235 insertions, 1 deletions
diff --git a/games-emulation/mupen64/ChangeLog b/games-emulation/mupen64/ChangeLog index fd89841f5ad2..afcdf90fe58f 100644 --- a/games-emulation/mupen64/ChangeLog +++ b/games-emulation/mupen64/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for games-emulation/mupen64 # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/games-emulation/mupen64/ChangeLog,v 1.24 2007/03/27 15:17:01 joker Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-emulation/mupen64/ChangeLog,v 1.25 2007/03/28 00:58:24 joker Exp $ + +*mupen64-0.5-r4 (28 Mar 2007) + + 28 Mar 2007; Christian Birchinger <joker@gentoo.org> + +files/mupen64-glN64-noasmfix.patch, +files/mupen64-glN64-ucode.patch, + +mupen64-0.5-r4.ebuild: + New revision with some patches from the standalone glN64 ebuild. Infos taken + from Bug #170763 and thanks to Sal Gonzalez <ghostx@optonline.net>. *mupen64-0.5-r3 (27 Mar 2007) diff --git a/games-emulation/mupen64/files/digest-mupen64-0.5-r4 b/games-emulation/mupen64/files/digest-mupen64-0.5-r4 new file mode 100644 index 000000000000..f5e4ac023a01 --- /dev/null +++ b/games-emulation/mupen64/files/digest-mupen64-0.5-r4 @@ -0,0 +1,3 @@ +MD5 11f994bed40e00fad5b82333b553e421 mupen64_src-0.5.tar.bz2 1981046 +RMD160 da916bc77f2f06ed92630332545dc3ee5ae1ff51 mupen64_src-0.5.tar.bz2 1981046 +SHA256 1b8e4188ab7a94d8125b77aed8725ee348c24818622b881adfe16be510487dfd mupen64_src-0.5.tar.bz2 1981046 diff --git a/games-emulation/mupen64/files/mupen64-glN64-noasmfix.patch b/games-emulation/mupen64/files/mupen64-glN64-noasmfix.patch new file mode 100644 index 000000000000..5aee4032eedd --- /dev/null +++ b/games-emulation/mupen64/files/mupen64-glN64-noasmfix.patch @@ -0,0 +1,11 @@ +--- glN64/convert.h.old 2005-04-23 16:32:44.000000000 -0700 ++++ glN64/convert.h 2005-04-23 16:40:43.000000000 -0700 +@@ -442,7 +442,7 @@ + while (numDWords--) + { + u32 dword = *(u32 *)src; +- __asm__ volatile( "bswapl %0\n\t" : "=q"(dword) : "0"(dword) ); ++ dword = ((dword<<24)|((dword<<8)&0x00FF0000)|((dword>>8)&0x0000FF00)|(dword>>24)); + *(u32 *)dest = dword; + dest = (void *)((int)dest+4); + src = (void *)((int)src +4); diff --git a/games-emulation/mupen64/files/mupen64-glN64-ucode.patch b/games-emulation/mupen64/files/mupen64-glN64-ucode.patch new file mode 100644 index 000000000000..8dc9aab0a647 --- /dev/null +++ b/games-emulation/mupen64/files/mupen64-glN64-ucode.patch @@ -0,0 +1,121 @@ +diff -g glN64-old/GBI.cpp glN64/GBI.cpp +*** glN64-old/GBI.cpp 2003-10-15 16:01:07.000000000 -0700 +--- glN64/GBI.cpp 2005-02-02 23:42:30.000000000 -0800 +*************** +*** 37,43 **** + { F3DDKR, FALSE, 0x8d91244f, "Diddy Kong Racing" }, + { F3DDKR, FALSE, 0x6e6fc893, "Diddy Kong Racing" }, + { F3DDKR, FALSE, 0xbde9d1fb, "Jet Force Gemini" }, +! { F3DPD, FALSE, 0x1c4f7869, "Perfect Dark" } + }; + + u32 G_RDPHALF_1, G_RDPHALF_2, G_RDPHALF_CONT; +--- 37,44 ---- + { F3DDKR, FALSE, 0x8d91244f, "Diddy Kong Racing" }, + { F3DDKR, FALSE, 0x6e6fc893, "Diddy Kong Racing" }, + { F3DDKR, FALSE, 0xbde9d1fb, "Jet Force Gemini" }, +! { F3DPD, FALSE, 0x1c4f7869, "Perfect Dark" }, +! { F3DEX, FALSE, 0x0ace4c3f, "Mario Kart" } + }; + + u32 G_RDPHALF_1, G_RDPHALF_2, G_RDPHALF_CONT; +*************** +*** 264,274 **** + + while (selectedMicrocode == -1) + { +! // if( gtk_main_iteration() ) +! // break; + usleep( 10000 ); + } + gdk_threads_leave(); + return selectedMicrocode; + } + #endif // __LINUX__ +--- 265,276 ---- + + while (selectedMicrocode == -1) + { +! if( gtk_main_iteration() ) +! break; + usleep( 10000 ); + } + gdk_threads_leave(); ++ + return selectedMicrocode; + } + #endif // __LINUX__ +*************** +*** 435,441 **** + current->type = DialogBox( hInstance, MAKEINTRESOURCE( IDD_MICROCODEDLG ), hWnd, MicrocodeDlgProc ); + #else // !__LINUX__ + printf( "glN64: Warning - unknown ucode!!!\n" ); +! current->type = MicrocodeDialog(); + #endif // __LINUX__ + return current; + } +--- 437,447 ---- + current->type = DialogBox( hInstance, MAKEINTRESOURCE( IDD_MICROCODEDLG ), hWnd, MicrocodeDlgProc ); + #else // !__LINUX__ + printf( "glN64: Warning - unknown ucode!!!\n" ); +! if(last_good_ucode != -1) { +! current->type=last_good_ucode; +! } else { +! current->type = MicrocodeDialog(); +! } + #endif // __LINUX__ + return current; + } +diff -g glN64-old/GBI.h glN64/GBI.h +*** glN64-old/GBI.h 2003-10-15 16:01:07.000000000 -0700 +--- glN64/GBI.h 2005-02-02 23:37:36.000000000 -0800 +*************** +*** 736,741 **** +--- 736,742 ---- + + void GBI_MakeCurrent( MicrocodeInfo *current ); + MicrocodeInfo *GBI_DetectMicrocode( u32 uc_start, u32 uc_dstart, u16 uc_dsize ); ++ extern u32 last_good_ucode; + void GBI_Init(); + void GBI_Destroy(); + +diff -g glN64-old/glN64.cpp glN64/glN64.cpp +*** glN64-old/glN64.cpp 2003-10-15 16:09:00.000000000 -0700 +--- glN64/glN64.cpp 2005-02-02 23:36:47.000000000 -0800 +*************** +*** 29,35 **** + + char pluginName[] = "glN64 v0.4.1-rc2"; + char *screenDirectory; +! + void (*CheckInterrupts)( void ); + + #ifndef __LINUX__ +--- 29,35 ---- + + char pluginName[] = "glN64 v0.4.1-rc2"; + char *screenDirectory; +! u32 last_good_ucode = -1; + void (*CheckInterrupts)( void ); + + #ifndef __LINUX__ +diff -g glN64-old/gSP.cpp glN64/gSP.cpp +*** glN64-old/gSP.cpp 2003-10-15 16:01:07.000000000 -0700 +--- glN64/gSP.cpp 2005-02-02 23:41:58.000000000 -0800 +*************** +*** 60,66 **** + } + + MicrocodeInfo *ucode = GBI_DetectMicrocode( uc_start, uc_dstart, uc_dsize ); +! + if (ucode->type != NONE) + GBI_MakeCurrent( ucode ); + else +--- 60,66 ---- + } + + MicrocodeInfo *ucode = GBI_DetectMicrocode( uc_start, uc_dstart, uc_dsize ); +! if (ucode->type != -1) last_good_ucode = ucode->type; + if (ucode->type != NONE) + GBI_MakeCurrent( ucode ); + else diff --git a/games-emulation/mupen64/mupen64-0.5-r4.ebuild b/games-emulation/mupen64/mupen64-0.5-r4.ebuild new file mode 100644 index 000000000000..b355f75bd999 --- /dev/null +++ b/games-emulation/mupen64/mupen64-0.5-r4.ebuild @@ -0,0 +1,91 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-emulation/mupen64/mupen64-0.5-r4.ebuild,v 1.1 2007/03/28 00:58:24 joker Exp $ + +inherit eutils multilib games + +MY_P=${PN}_src-${PV} +DESCRIPTION="A Nintendo 64 (N64) emulator" +HOMEPAGE="http://mupen64.emulation64.com/" +SRC_URI="http://mupen64.emulation64.com/files/${PV}/${MY_P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="-* ~amd64 ~x86" +IUSE="" + +RDEPEND="virtual/opengl + >=x11-libs/gtk+-2 + media-libs/libsdl + media-libs/sdl-ttf + amd64? ( + app-emulation/emul-linux-x86-gtklibs + >=app-emulation/emul-linux-x86-sdl-10.0 + )" +DEPEND="${RDEPEND} + dev-util/pkgconfig + !games-emulation/mupen64-blight-input + !games-emulation/mupen64-glN64 + !games-emulation/mupen64-jttl_sound" + +S=${WORKDIR}/${MY_P} + +pkg_setup() { + has_multilib_profile && multilib_toolchain_setup x86 +} + +src_unpack() { + unpack ${A} + cd "${S}" + rm -f plugins/empty blight_input/SDL_ttf* + + epatch \ + "${FILESDIR}"/${P}-anisotropic.patch \ + "${FILESDIR}"/${P}-gentoo3.patch \ + "${FILESDIR}"/${PN}-glN64-ucode.patch \ + "${FILESDIR}"/${PN}-glN64-noasmfix.patch + + sed -i \ + -e "s:#undef WITH_HOME:#define WITH_HOME \"$(games_get_libdir)/\":" \ + -e "s:#undef SHARE:#define SHARE \"$(games_get_libdir)/${PN}/\":" \ + config.h \ + || die "sed failed" +} + +src_compile() { + local t + for t in \ + mupen64 \ + mupen64_nogui \ + plugins/mupen64_input.so \ + plugins/blight_input.so \ + plugins/mupen64_hle_rsp_azimer.so \ + plugins/dummyaudio.so \ + plugins/mupen64_audio.so \ + plugins/jttl_audio.so \ + plugins/mupen64_soft_gfx.so \ + plugins/glN64.so + do + emake ${t} || die "emake ${t} failed" + done +} + +src_install() { + dogamesbin mupen64 mupen64_nogui || die "dogamesbin failed" + + insinto "$(games_get_libdir)/${PN}" + doins -r mupen64.ini jttl_audio.conf lang roms plugins || die "doins failed" + + dodoc *.txt doc/readme.pdf + prepgamesdirs +} + +pkg_postinst() { + games_pkg_postinst + echo + ewarn "If you are upgrading from a previous version of mupen64," + ewarn "backup your saved games then run rm -rf on your" + ewarn ".mupen64 directory. After launching the new version, copy" + ewarn "your saved games to their original place." + echo +} |