diff options
author | crees <crees@FreeBSD.org> | 2011-08-14 01:04:38 +0800 |
---|---|---|
committer | crees <crees@FreeBSD.org> | 2011-08-14 01:04:38 +0800 |
commit | de03444b0b5dd7c992beac5b359b8ee00ac25434 (patch) | |
tree | e22feff3a161893f9c5eb64d0dfa0d8f3d381c7d | |
parent | 8c9728c00a23c1a533b00d3e1c0ac1b2b822ac75 (diff) | |
download | freebsd-ports-gnome-de03444b0b5dd7c992beac5b359b8ee00ac25434.tar.gz freebsd-ports-gnome-de03444b0b5dd7c992beac5b359b8ee00ac25434.tar.zst freebsd-ports-gnome-de03444b0b5dd7c992beac5b359b8ee00ac25434.zip |
- Update to 0.143p2 ('borrowing' obrien's cool patchlevel code from editors/vim)
- Add missing fontconfig dependency
- Use PORTDOCS/PORTEXAMPLES
- Use PATCHDIR (not FILESDIR)
- Use COPYTREE_SHARE (not cp -R)
Mostly based on:
PR: ports/153645
Submitted by: Emmanuel Vadot <elbarto@arcadebsd.org> (maintainer), acm
Approved by: maintainer timeout (8 weeks)
-rw-r--r-- | emulators/mame/Makefile | 52 | ||||
-rw-r--r-- | emulators/mame/distinfo | 8 | ||||
-rw-r--r-- | emulators/mame/files/patch-debugcpu.c | 13 | ||||
-rw-r--r-- | emulators/mame/files/sdl.mak.patch | 24 | ||||
-rw-r--r-- | emulators/mame/pkg-plist | 10 |
5 files changed, 63 insertions, 44 deletions
diff --git a/emulators/mame/Makefile b/emulators/mame/Makefile index 4ba7ba9bb4a1..6787d07549fc 100644 --- a/emulators/mame/Makefile +++ b/emulators/mame/Makefile @@ -6,15 +6,25 @@ # PORTNAME= mame -PORTVERSION= 0.139 +PATCHLEVEL= 2 +PORTVERSION= 0.143${PATCHSUFFIX} CATEGORIES= emulators -MASTER_SITES= http://www.aarongiles.com/mirror/releases/ \ - ftp://ftp.arcadebsd.org/pub/ArcadeBSD/ports/distfiles/ -DISTNAME= ${PORTNAME}${PORTVERSION:S/.//}s +MASTER_SITES= http://mame.mirrors.zippykid.com/releases/:src \ + http://emumovies.com/aarongiles/releases/:src \ + http://mamedev.mameworld.info/releases/:src \ + http://mamedev.thiswebhost.com/releases/:src \ + ftp://ftp.arcadebsd.org/pub/ArcadeBSD/ports/distfiles/:src \ + http://mamedev.org/updates/:patchsets +DISTFILES= \ + ${PORTNAME}${PORTVERSION:S/.//:C/\.p[0-9]*$//}s${EXTRACT_SUFX}:src \ + ${UPDATE_PATCHES:C/$/.zip:patchsets/} +DIST_SUBDIR= ${PORTNAME} MAINTAINER= elbarto@ArcadeBSD.org COMMENT= The popular MAME (Multi Arcade Machine Emulator) +LIB_DEPENDS= fontconfig.1:${PORTSDIR}/x11-fonts/fontconfig + USE_ZIP= yes NO_WRKSUBDIR= yes USE_XORG= xext xrender xinerama xi @@ -22,12 +32,22 @@ USE_GL= gl USE_GNOME?= gtk20 gconf2 USE_GMAKE= yes MAKE_ENV= PTHREAD_LIBS="${PTHREAD_LIBS}" -USE_SDL= sdl +USE_SDL= sdl ttf USE_GCC= 4.2+ MAKEFILE= makefile ONLY_FOR_ARCHS= i386 amd64 SUB_FILES= pkg-message -USE_DOS2UNIX= makefile sdl.mak debugcpu.c +USE_DOS2UNIX= makefile sdl.mak debugcpu.c *.c *.h + +PORTDOCS= * +PORTEXAMPLES= * + +.if defined(PATCHLEVEL) && ${PATCHLEVEL} +PATCHSUFFIX= .p${PATCHLEVEL} +UPDATE_PATCHES!= /usr/bin/jot -s " " \ + -w ${PORTVERSION:S/.//:C/\.p[0-9]*$//}u%d_diff \ + ${PATCHLEVEL} 1 ${PATCHLEVEL} +.endif OPTIONS= DEBUG "Build mame debugger" off @@ -35,7 +55,7 @@ OPTIONS= DEBUG "Build mame debugger" off .if !defined(WITH_DEBUG) USE_GNOME= # -EXTRA_PATCHES+= ${FILESDIR}/sdl.mak.patch +EXTRA_PATCHES+= ${PATCHDIR}/sdl.mak.patch .endif MAKE_JOBS_SAFE= yes @@ -50,9 +70,19 @@ BROKEN= Does not compile on sparc64 post-extract: @${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${WRKDIR}/mame.zip ${EXTRACT_AFTER_ARGS} @${RM} -f ${WRKDIR}/mame.zip +# Use post-extract target to get in before dos2unix-isation +.if defined(UPDATE_PATCHES) +. for patch in ${UPDATE_PATCHES:S/_/./} + @${ECHO_MSG} -n "===> Applying upstream development patch ${patch}... " + @${PATCH} ${PATCH_ARGS} < ${WRKSRC}/${patch} + @${ECHO_MSG} "[DONE]" +. endfor +.endif post-patch: @${REINPLACE_CMD} -e "s|ui.bdf|${DATADIR}/ui.bdf|g" ${WRKSRC}/src/emu/ui.c + @${REINPLACE_CMD} -e "s|int getc()|int getcf()|g" ${WRKSRC}/src/emu/fileio.h + @${REINPLACE_CMD} -e "s|::getc()|::getcf()|g" ${WRKSRC}/src/emu/fileio.c do-install: ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin/ @@ -67,12 +97,14 @@ do-install: .if !defined(NOPORTDOCS) ${MKDIR} ${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/*.txt ${DOCSDIR} - ${CP} -R ${WRKSRC}/docs ${DOCSDIR} + (cd ${WRKSRC}/ && ${COPYTREE_SHARE} docs ${DOCSDIR}) .endif ${MKDIR} ${DATADIR} - ${CP} -R ${WRKSRC}/src/osd/sdl/keymaps ${DATADIR}/ + (cd ${WRKSRC}/src/osd/sdl/ && ${COPYTREE_SHARE} keymaps ${DATADIR}) +.if !defined(NOPORTEXAMPLES) ${MKDIR} ${EXAMPLESDIR} - ${CP} ${FILESDIR}/mame.ini ${EXAMPLESDIR} + ${INSTALL_DATA} ${FILESDIR}/mame.ini ${EXAMPLESDIR} +.endif post-install: @${ECHO_CMD} diff --git a/emulators/mame/distinfo b/emulators/mame/distinfo index d965712baa87..58d30daf85c4 100644 --- a/emulators/mame/distinfo +++ b/emulators/mame/distinfo @@ -1,2 +1,6 @@ -SHA256 (mame0139s.zip) = e9dc268530b9a2b6fe17330af96dc5680dadba1b5e444bf7ef8fa1f15de7f3d6 -SIZE (mame0139s.zip) = 16706970 +SHA256 (mame/mame0143s.zip) = 677f04756ed7bc00e1adc6e68bbb174f89845887758dc287c7244a58e6ac266f +SIZE (mame/mame0143s.zip) = 17902802 +SHA256 (mame/0143u1_diff.zip) = 307172c6956f58251590a5c30c454c99fbdf02ae554d0e3aaa0133fc9989eee8 +SIZE (mame/0143u1_diff.zip) = 250465 +SHA256 (mame/0143u2_diff.zip) = 4f6fa5961fe9fe99dfd6d315daf5280b2516ac96213b2a2c0fcf849c284db086 +SIZE (mame/0143u2_diff.zip) = 679992 diff --git a/emulators/mame/files/patch-debugcpu.c b/emulators/mame/files/patch-debugcpu.c deleted file mode 100644 index 5cb69d9216c4..000000000000 --- a/emulators/mame/files/patch-debugcpu.c +++ /dev/null @@ -1,13 +0,0 @@ ---- src/emu/debug/debugcpu.c.orig 2010-07-30 10:55:52.000000000 +0200 -+++ src/emu/debug/debugcpu.c 2010-07-30 10:56:13.000000000 +0200 -@@ -49,7 +49,9 @@ - #include "debugint/debugint.h" - #include "uiinput.h" - #include <ctype.h> -- -+#ifdef __FreeBSD__ -+#undef tolower -+#endif - - - /*************************************************************************** diff --git a/emulators/mame/files/sdl.mak.patch b/emulators/mame/files/sdl.mak.patch index 4ebbccccf877..7de85e19b832 100644 --- a/emulators/mame/files/sdl.mak.patch +++ b/emulators/mame/files/sdl.mak.patch @@ -1,15 +1,19 @@ ---- src/osd/sdl/sdl.mak.orig 2010-02-14 04:47:30.000000000 +0100 -+++ src/osd/sdl/sdl.mak 2010-07-30 12:05:33.000000000 +0200 +$FreeBSD$ + +This is applied if WITH_DEBUG is unset. + +--- src/osd/sdl/sdl.mak 2011-06-21 19:58:18.000000000 -0500 ++++ src/osd/sdl/sdl.mak 2011-06-21 20:01:07.000000000 -0500 @@ -139,7 +139,7 @@ ifeq ($(TARGETOS),freebsd) BASE_TARGETOS = unix SYNC_IMPLEMENTATION = tc -DEFS += -DNO_AFFINITY_NP +DEFS += -DNO_AFFINITY_NP -DNO_DEBUGGER + LIBS += -lutil # /usr/local/include is not considered a system include directory # on FreeBSD. GL.h resides there and throws warnings - CCOMFLAGS += -isystem /usr/local/include -@@ -205,7 +205,7 @@ +@@ -213,7 +213,7 @@ ifndef GTK_INSTALL_ROOT NO_DEBUGGER = 1 else @@ -17,8 +21,8 @@ +DEBUGOBJS = $(SDLOBJ)/debugwin.o LIBS += -lgtk-win32-2.0 -lgdk-win32-2.0 -lgmodule-2.0 -lglib-2.0 -lgobject-2.0 \ -lpango-1.0 -latk-1.0 -lgdk_pixbuf-2.0 - CCOMFLAGS += -mms-bitfields \ -@@ -304,7 +304,7 @@ + CCOMFLAGS += -mms-bitfields +@@ -315,7 +315,7 @@ ifeq ($(BASE_TARGETOS),unix) DEFS += -DSDLMAME_UNIX @@ -27,13 +31,15 @@ LIBGL = -lGL ifeq ($(NO_X11),1) NO_DEBUGGER = 1 -@@ -454,8 +454,8 @@ +@@ -484,9 +484,9 @@ # the new debugger relies on GTK+ in addition to the base SDLMAME needs # Non-X11 builds can not use the debugger --CCOMFLAGS += `pkg-config --cflags gtk+-2.0` `pkg-config --cflags gconf-2.0` +-INCPATH += `pkg-config --cflags-only-I gtk+-2.0` `pkg-config --cflags-only-I gconf-2.0` +-CCOMFLAGS += `pkg-config --cflags-only-other gtk+-2.0` `pkg-config --cflags-only-other gconf-2.0` -LIBS += `pkg-config --libs gtk+-2.0` `pkg-config --libs gconf-2.0` -+#CCOMFLAGS += `pkg-config --cflags gtk+-2.0` `pkg-config --cflags gconf-2.0` ++#INCPATH += `pkg-config --cflags-only-I gtk+-2.0` `pkg-config --cflags-only-I gconf-2.0` ++#CCOMFLAGS += `pkg-config --cflags-only-other gtk+-2.0` `pkg-config --cflags-only-other gconf-2.0` +#LIBS += `pkg-config --libs gtk+-2.0` `pkg-config --libs gconf-2.0` #CCOMFLAGS += -DGTK_DISABLE_DEPRECATED diff --git a/emulators/mame/pkg-plist b/emulators/mame/pkg-plist index b50c4e6757ec..4b60f7d9a902 100644 --- a/emulators/mame/pkg-plist +++ b/emulators/mame/pkg-plist @@ -5,22 +5,12 @@ libexec/mame/ldverify libexec/mame/romcmp libexec/mame/testkeys libexec/mame/unidasm -%%PORTDOCS%%%%DOCSDIR%%/docs/license.txt -%%PORTDOCS%%%%DOCSDIR%%/docs/mame.txt -%%PORTDOCS%%%%DOCSDIR%%/docs/newvideo.txt -%%PORTDOCS%%%%DOCSDIR%%/docs/windows.txt -%%PORTDOCS%%%%DOCSDIR%%/docs/config.txt -%%PORTDOCS%%%%DOCSDIR%%/whatsnew.txt %%DATADIR%%/keymaps/km-be.txt %%DATADIR%%/keymaps/km-ch.txt %%DATADIR%%/keymaps/km-de.txt %%DATADIR%%/keymaps/km-fr-OSX.txt %%DATADIR%%/keymaps/km-fr.txt %%DATADIR%%/keymaps/km_it.txt -%%EXAMPLESDIR%%/mame.ini @dirrm %%DATADIR%%/keymaps/ @dirrm %%DATADIR%%/ @dirrm libexec/mame -%%PORTDOCS%%@dirrm %%DOCSDIR%%/docs -%%PORTDOCS%%@dirrm %%DOCSDIR%% -@dirrm %%EXAMPLESDIR%% |