diff options
author | marino <marino@FreeBSD.org> | 2015-05-25 18:13:35 +0800 |
---|---|---|
committer | marino <marino@FreeBSD.org> | 2015-05-25 18:13:35 +0800 |
commit | 46979e8ba35f203957eb626ee53e7a416c8a6ab0 (patch) | |
tree | 79e3226e90d4cd790c09176a7676e390388a642b /emulators | |
parent | dcc966c9c0cee876b9c0afce967599288e27c815 (diff) | |
download | freebsd-ports-graphics-46979e8ba35f203957eb626ee53e7a416c8a6ab0.tar.gz freebsd-ports-graphics-46979e8ba35f203957eb626ee53e7a416c8a6ab0.tar.zst freebsd-ports-graphics-46979e8ba35f203957eb626ee53e7a416c8a6ab0.zip |
emulators/loemu: Fix runtime after mame upgrade
This port has probably be broken (at least by default) for many years.
It was trying to call sdlmame (I think) but the name was "mame" and now
for amd64, the name is "mame64". Attempt to fix this (not testing was
done, however).
While here, clean up post-patch which was doing a lot of nothing, leverage
shebangfix, and regenerate patch accordingly.
Note that RUN_DEPENDS had to be changed to deal with the morphing
executable name.
Diffstat (limited to 'emulators')
-rw-r--r-- | emulators/loemu/Makefile | 35 | ||||
-rw-r--r-- | emulators/loemu/files/patch-setup.py | 18 | ||||
-rw-r--r-- | emulators/loemu/pkg-descr | 2 |
3 files changed, 28 insertions, 27 deletions
diff --git a/emulators/loemu/Makefile b/emulators/loemu/Makefile index 452ebbe9f50..8b5cf174f0b 100644 --- a/emulators/loemu/Makefile +++ b/emulators/loemu/Makefile @@ -3,7 +3,7 @@ PORTNAME= loemu PORTVERSION= 0.3.1 -PORTREVISION= 10 +PORTREVISION= 11 CATEGORIES= emulators python MASTER_SITES= http://loemu.pegueroles.com/dists/ @@ -16,27 +16,34 @@ RUN_DEPENDS= ${PYTHON_SITELIBDIR}/gtk-2.0/gtk/__init__.py:${PORTSDIR}/x11-toolki ${PYTHON_SITELIBDIR}/libxml2.py:${PORTSDIR}/textproc/py-libxml2 \ ${PYTHON_SITELIBDIR}/libxslt.py:${PORTSDIR}/textproc/py-libxslt -USES= gettext python +USES= gettext python shebangfix USE_PYTHON= distutils NO_BUILD= yes +SHEBANG_FILES= setup.py OPTIONS_DEFINE= MAME SNES9X ZSNES OPTIONS_DEFAULT= MAME SNES9X -MAME_DESC= Install mame emulator -SNES9X_DESC= Install snes9x emulator -ZSNES_DESC= Install zsnes emulator -MAME_RUN_DEPENDS= mame:${PORTSDIR}/emulators/mame + +MAME_DESC= Install mame emulator +SNES9X_DESC= Install snes9x emulator +ZSNES_DESC= Install zsnes emulator +MAME_RUN_DEPENDS= mame>=0.154:${PORTSDIR}/emulators/mame SNES9X_RUN_DEPENDS= snes9x:${PORTSDIR}/emulators/snes9x ZSNES_RUN_DEPENDS= zsnes:${PORTSDIR}/emulators/zsnes +.include <bsd.port.options.mk> + +.if ${ARCH:Mamd64} +MAMENAME= mame64 +.else +MAMENAME= mame +.endif + post-patch: -.for DIRE in config loemu scripts - @cd ${WRKSRC}/${DIRE} && \ - ${FIND} * -type f -exec ${REINPLACE_CMD} -i '' -e \ - 's|/share/games/|/share/|g' -e \ - 's|/usr/bin/python|${PYTHON_CMD}|g' "{}" \; -.endfor - @${REINPLACE_CMD} -e 's|%%PYTHON_CMD%%|${PYTHON_CMD}|g' \ - ${WRKSRC}/setup.py + @${REINPLACE_CMD} -i '' -e 's|/usr/bin/env python|${PYTHON_CMD}|' \ + ${WRKSRC}/scripts/loemu \ + ${WRKSRC}/scripts/loemu-builder + @${REINPLACE_CMD} -i '' -e 's|sdlmame|${MAMENAME}|' \ + ${WRKSRC}/config/sdlmame.conf .include <bsd.port.mk> diff --git a/emulators/loemu/files/patch-setup.py b/emulators/loemu/files/patch-setup.py index dc09d5b6834..28556d56fbe 100644 --- a/emulators/loemu/files/patch-setup.py +++ b/emulators/loemu/files/patch-setup.py @@ -1,16 +1,9 @@ ---- setup.py Sun Aug 12 15:12:41 2007 -+++ setup.py Sun Aug 12 15:13:05 2007 -@@ -1,4 +1,4 @@ --#!/usr/bin/python -+#!%%PYTHON_CMD%% - from distutils.core import setup - from glob import glob - import os -@@ -6,21 +6,6 @@ - +--- setup.py.orig 2008-02-21 22:23:10 UTC ++++ setup.py +@@ -7,21 +7,6 @@ import sys if sys.hexversion < 0x020400f0: sys.stderr.write("python version failed: current version = %s.%s, needed version >= 2.4\n" % (sys.version_info[0],sys.version_info[1])) -- sys.exit(1) + sys.exit(1) -try: - import libxml2 -except ImportError: @@ -25,6 +18,7 @@ - import gtk.glade -except ImportError: - sys.stderr.write("dependencies failed: python glade\n") - sys.exit(1) +- sys.exit(1) # make sure that the mo files are generated and up-to-date + os.system("cd po; make update-po") diff --git a/emulators/loemu/pkg-descr b/emulators/loemu/pkg-descr index 12185923821..eed88ed7997 100644 --- a/emulators/loemu/pkg-descr +++ b/emulators/loemu/pkg-descr @@ -14,4 +14,4 @@ Features: The design of loemu allows the support of more emulators adding specific emulator configuration files. -WWW: http://loemu.pegueroles.com/ +WWW: http://loemu.pegueroles.com/ |