ports/167655: [PATCH] emulators/bsnes: update to 0.87, take maintainership
Naram Qashat
cyberbotx at cyberbotx.com
Sun May 6 21:50:05 UTC 2012
>Number: 167655
>Category: ports
>Synopsis: [PATCH] emulators/bsnes: update to 0.87, take maintainership
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Sun May 06 21:50:05 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator: Naram Qashat
>Release: FreeBSD 8.2-RELEASE amd64
>Organization:
>Environment:
System: FreeBSD kirby.cyberbotx.com 8.2-RELEASE FreeBSD 8.2-RELEASE #3: Sun Feb 27 08:58:31 EST 2011
>Description:
- Update to 0.87
- Take maintainership
Added file(s):
- files/patch-nall-file.hpp
- files/patch-target-ui-Makefile
Removed file(s):
- files/patch-qt-Makefile
- files/patch-serialization.cpp
NOTE: I am unsure if having USE_GNOME=gtk20 is correct regardless of the GUI
selected, but from some Tinderbox builds it appears to be added
regardless. Also, it seems that USE_XORG+=xv is needed on the inclusion
of SDL, I think this is a problem with bsnes and not SDL, however.
Generated with FreeBSD Port Tools 0.99_6 (mode: update, diff: ports)
>How-To-Repeat:
>Fix:
--- bsnes-0.87.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/Makefile ./Makefile
--- /usr/ports/emulators/bsnes/Makefile 2012-02-27 02:20:28.000000000 -0500
+++ ./Makefile 2012-05-06 16:45:16.000000000 -0400
@@ -5,33 +5,28 @@
# $FreeBSD: ports/emulators/bsnes/Makefile,v 1.15 2012/02/18 10:17:26 mva Exp $
PORTNAME= bsnes
-PORTVERSION= 0.70
-PORTREVISION= 1
+PORTVERSION= 0.87
CATEGORIES= emulators
MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE}
-DISTNAME= ${PORTNAME}_v${PORTVERSION:S/.//}
+DISTNAME= ${PORTNAME}_v${PORTVERSION:S/.//}-source
-MAINTAINER= ports at FreeBSD.org
+MAINTAINER= cyberbotx at cyberbotx.com
COMMENT= Super Nintendo/Super Famicom emulator
-BROKEN= does not compile
-
USE_BZIP2= yes
USE_GMAKE= yes
-USE_XORG= videoproto xv x11
-USE_QT_VER= 4
-QT_COMPONENTS= qmake_build uic_build moc_build rcc_build gui
-USE_GCC= 4.4+
+USE_GNOME= gtk20
+USE_GCC= 4.6
ONLY_FOR_ARCHS= i386 amd64
-WRKSRC= ${WRKDIR}/
-MAKE_ENV+= moc=moc-qt4 c="${CC} -std=gnu99" cpp="${CXX} -std=gnu++0x"
+MAKE_ENV+= c="${CC} -std=gnu99" cpp="${CXX} -std=gnu++0x" profile="performance"
USE_LDCONFIG= yes
-OPTIONS= VIDEO_GLX "Build GLX Video Driver" on \
+OPTIONS= GUI_GTK "Build with GTK+ GUI" on \
+ GUI_QT4 "Build with QT4 GUI" off \
+ VIDEO_GLX "Build GLX Video Driver" on \
VIDEO_XV "Build Xv Video Driver" on \
VIDEO_SDL "Build SDL Video Driver" on \
- VIDEO_QT "Build QtImage Video Driver" off \
SOUND_OPENAL "Build OpenAL Sound Driver" off \
SOUND_OSS "Build OSS Sound Driver" on \
SOUND_PULSE "Build Pulseaudio Sound Driver" off \
@@ -39,7 +34,15 @@
INPUT_X "Build X Input Driver" on \
INPUT_SDL "Build SDL Input Driver" on
-.include <bsd.port.pre.mk>
+.include <bsd.port.options.mk>
+
+.if defined(WITH_GUI_GTK)
+MAKE_ENV+= phoenix="gtk"
+.else
+USE_QT_VER= 4
+QT_COMPONENTS= corelib gui
+MAKE_ENV+= phoenix="qt"
+.endif
.if defined(WITH_VIDEO_GLX)
USE_GL+= gl
@@ -47,18 +50,16 @@
.endif
.if defined(WITH_VIDEO_XV)
+USE_XORG+= xv
VIDEO_DRIVER+= video.xv
.endif
.if defined(WITH_VIDEO_SDL)
+USE_XORG+= xv
USE_SDL+= sdl
VIDEO_DRIVER+= video.sdl
.endif
-.if defined(WITH_VIDEO_QT)
-VIDEO_DRIVER+= video.qtimage
-.endif
-
.if defined(WITH_SOUND_OPENAL)
USE_OPENAL= al
AUDIO_DRIVER+= audio.openal
@@ -87,37 +88,38 @@
INPUT_DRIVER+= input.sdl
.endif
+.if !defined(WITH_GUI_GTK) && !defined(WITH_GUI_QT4)
+IGNORE= you have to choose a GUI
+.endif
+.if defined(WITH_GUI_GTK) && defined(WITH_GUI_QT4)
+IGNORE= you may only choose one GUI
+.endif
+
.if !defined(VIDEO_DRIVER)
-IGNORE= you have to choose at least a video driver first
+IGNORE= you have to choose at least one video driver
.endif
.if !defined(AUDIO_DRIVER)
-IGNORE= you have to choose at least a audio driver first
+IGNORE= you have to choose at least one audio driver
.endif
.if !defined(INPUT_DRIVER)
-IGNORE= you have to choose at least an input driver first
+IGNORE= you have to choose at least one input driver
.endif
post-patch:
- ${REINPLACE_CMD} -e 's|VIDEO|${VIDEO_DRIVER}|' ${WRKSRC}/bsnes/ui-qt/Makefile
- ${REINPLACE_CMD} -e 's|AUDIO|${AUDIO_DRIVER}|' ${WRKSRC}/bsnes/ui-qt/Makefile
- ${REINPLACE_CMD} -e 's|INPUT|${INPUT_DRIVER}|' ${WRKSRC}/bsnes/ui-qt/Makefile
+ ${REINPLACE_CMD} -e 's|VIDEO|${VIDEO_DRIVER}|' ${WRKSRC}/bsnes/target-ui/Makefile
+ ${REINPLACE_CMD} -e 's|AUDIO|${AUDIO_DRIVER}|' ${WRKSRC}/bsnes/target-ui/Makefile
+ ${REINPLACE_CMD} -e 's|INPUT|${INPUT_DRIVER}|' ${WRKSRC}/bsnes/target-ui/Makefile
do-build:
(cd ${WRKSRC}/bsnes && ${GMAKE} ${MAKE_ENV})
- (cd ${WRKSRC}/snesreader && ${GMAKE} ${MAKE_ENV})
- (cd ${WRKSRC}/snesfilter && ${GMAKE} ${MAKE_ENV})
- (cd ${WRKSRC}/supergameboy && ${GMAKE} ${MAKE_ENV})
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/bsnes/out/bsnes ${PREFIX}/bin/
${MKDIR} ${PREFIX}/share/pixmaps
- ${INSTALL_DATA} ${WRKSRC}/bsnes/ui-qt/data/bsnes.png ${PREFIX}/share/pixmaps/
+ ${INSTALL_DATA} ${WRKSRC}/bsnes/data/bsnes.png ${PREFIX}/share/pixmaps/
${MKDIR} ${PREFIX}/share/applications
- ${INSTALL_DATA} ${WRKSRC}/bsnes/ui-qt/data/bsnes.desktop ${PREFIX}/share/applications/
- ${INSTALL_DATA} ${WRKSRC}/snesreader/libsnesreader.so ${PREFIX}/lib/
- ${INSTALL_DATA} ${WRKSRC}/snesfilter/libsnesfilter.so ${PREFIX}/lib/
- ${INSTALL_DATA} ${WRKSRC}/supergameboy/libsupergameboy.so ${PREFIX}/lib/
+ ${INSTALL_DATA} ${WRKSRC}/bsnes/data/bsnes.desktop ${PREFIX}/share/applications/
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/distinfo ./distinfo
--- /usr/ports/emulators/bsnes/distinfo 2011-07-03 20:45:57.000000000 -0400
+++ ./distinfo 2012-04-16 23:24:56.000000000 -0400
@@ -1,2 +1,2 @@
-SHA256 (bsnes_v070.tar.bz2) = 843fe06200488863510dd4c2923eaef6744977f8d1926cdb0806bb6d470c4b79
-SIZE (bsnes_v070.tar.bz2) = 1020720
+SHA256 (bsnes_v087-source.tar.bz2) = a8ef86ad318396c56cbbb2723487a63afd003ec54737baeb027a340b24123e60
+SIZE (bsnes_v087-source.tar.bz2) = 1173031
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/files/patch-Makefile ./files/patch-Makefile
--- /usr/ports/emulators/bsnes/files/patch-Makefile 2010-10-02 07:14:50.000000000 -0400
+++ ./files/patch-Makefile 2012-04-16 23:27:11.000000000 -0400
@@ -1,6 +1,6 @@
---- bsnes/Makefile.orig 2010-09-27 03:24:08.000000000 +0200
-+++ bsnes/Makefile 2010-09-27 03:24:26.000000000 +0200
-@@ -19,7 +19,7 @@
+--- bsnes/Makefile.orig 2012-03-06 14:59:41.000000000 -0500
++++ bsnes/Makefile 2012-04-16 23:26:48.000000000 -0400
+@@ -28,7 +28,7 @@
# platform
ifeq ($(platform),x)
@@ -8,4 +8,4 @@
+ link += -s -lX11 -lXext
else ifeq ($(platform),osx)
else ifeq ($(platform),win)
- link += -mwindows
+ link += $(if $(findstring console,$(options)),-mconsole,-mwindows)
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/files/patch-nall-file.hpp ./files/patch-nall-file.hpp
--- /usr/ports/emulators/bsnes/files/patch-nall-file.hpp 1969-12-31 19:00:00.000000000 -0500
+++ ./files/patch-nall-file.hpp 2012-04-16 23:42:58.000000000 -0400
@@ -0,0 +1,35 @@
+--- bsnes/nall/file.hpp.orig 2012-03-06 14:03:53.000000000 -0500
++++ bsnes/nall/file.hpp 2012-04-16 23:42:33.000000000 -0400
+@@ -160,8 +160,8 @@
+
+ static bool exists(const string &filename) {
+ #if !defined(_WIN32)
+- struct stat64 data;
+- return stat64(filename, &data) == 0;
++ struct stat data;
++ return stat(filename, &data) == 0;
+ #else
+ struct __stat64 data;
+ return _wstat64(utf16_t(filename), &data) == 0;
+@@ -170,8 +170,8 @@
+
+ static uintmax_t size(const string &filename) {
+ #if !defined(_WIN32)
+- struct stat64 data;
+- stat64(filename, &data);
++ struct stat data;
++ stat(filename, &data);
+ #else
+ struct __stat64 data;
+ _wstat64(utf16_t(filename), &data);
+@@ -181,8 +181,8 @@
+
+ static time_t timestamp(const string &filename, file::time mode = file::time::create) {
+ #if !defined(_WIN32)
+- struct stat64 data;
+- stat64(filename, &data);
++ struct stat data;
++ stat(filename, &data);
+ #else
+ struct __stat64 data;
+ _wstat64(utf16_t(filename), &data);
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/files/patch-qt-Makefile ./files/patch-qt-Makefile
--- /usr/ports/emulators/bsnes/files/patch-qt-Makefile 2010-10-02 07:14:50.000000000 -0400
+++ ./files/patch-qt-Makefile 1969-12-31 19:00:00.000000000 -0500
@@ -1,15 +0,0 @@
---- bsnes/ui-qt/Makefile.orig 2010-09-27 03:25:04.000000000 +0200
-+++ bsnes/ui-qt/Makefile 2010-09-27 03:25:16.000000000 +0200
-@@ -13,9 +13,9 @@
-
- # platform
- ifeq ($(platform),x)
-- ruby := video.glx video.xv video.qtraster video.sdl
-- ruby += audio.alsa audio.openal audio.oss audio.pulseaudio audio.pulseaudiosimple audio.ao
-- ruby += input.sdl input.x
-+ ruby := VIDEO
-+ ruby += AUDIO
-+ ruby += INPUT
-
- link += $(if $(findstring audio.openal,$(ruby)),-lopenal)
- else ifeq ($(platform),osx)
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/files/patch-serialization.cpp ./files/patch-serialization.cpp
--- /usr/ports/emulators/bsnes/files/patch-serialization.cpp 2010-09-04 05:31:08.000000000 -0400
+++ ./files/patch-serialization.cpp 1969-12-31 19:00:00.000000000 -0500
@@ -1,11 +0,0 @@
---- bsnes/snes/system/serialization.cpp.orig 2010-09-02 13:16:20.000000000 +0200
-+++ bsnes/snes/system/serialization.cpp 2010-09-02 13:23:12.000000000 +0200
-@@ -7,7 +7,7 @@
- char profile[16], description[512];
- memset(&profile, 0, sizeof profile);
- memset(&description, 0, sizeof description);
-- strlcpy(profile, Info::Profile, sizeof profile);
-+ nall::strlcpy(profile, Info::Profile, sizeof profile);
-
- s.integer(signature);
- s.integer(version);
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/files/patch-target-ui-Makefile ./files/patch-target-ui-Makefile
--- /usr/ports/emulators/bsnes/files/patch-target-ui-Makefile 1969-12-31 19:00:00.000000000 -0500
+++ ./files/patch-target-ui-Makefile 2012-04-16 23:29:16.000000000 -0400
@@ -0,0 +1,15 @@
+--- bsnes/target-ui/Makefile.orig 2012-02-05 20:04:19.000000000 -0500
++++ bsnes/target-ui/Makefile 2012-04-16 23:28:28.000000000 -0400
+@@ -10,9 +10,9 @@
+
+ # platform
+ ifeq ($(platform),x)
+- ruby := video.glx video.xv video.sdl
+- ruby += audio.alsa audio.openal audio.oss audio.pulseaudio audio.pulseaudiosimple audio.ao
+- ruby += input.sdl input.x
++ ruby := VIDEO
++ ruby += AUDIO
++ ruby += INPUT
+ else ifeq ($(platform),osx)
+ ruby :=
+ ruby += audio.openal
diff -ruN --exclude=CVS /usr/ports/emulators/bsnes/pkg-plist ./pkg-plist
--- /usr/ports/emulators/bsnes/pkg-plist 2010-07-12 07:37:31.000000000 -0400
+++ ./pkg-plist 2012-05-06 17:44:48.000000000 -0400
@@ -1,7 +1,4 @@
bin/bsnes
-lib/libsnesfilter.so
-lib/libsnesreader.so
-lib/libsupergameboy.so
share/applications/bsnes.desktop
share/pixmaps/bsnes.png
@dirrmtry share/applications
--- bsnes-0.87.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list