svn commit: r387374 - in head/emulators/loemu: . files
John Marino
marino at FreeBSD.org
Mon May 25 10:13:36 UTC 2015
Author: marino
Date: Mon May 25 10:13:35 2015
New Revision: 387374
URL: https://svnweb.freebsd.org/changeset/ports/387374
Log:
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.
Modified:
head/emulators/loemu/Makefile
head/emulators/loemu/files/patch-setup.py
head/emulators/loemu/pkg-descr
Modified: head/emulators/loemu/Makefile
==============================================================================
--- head/emulators/loemu/Makefile Mon May 25 09:51:14 2015 (r387373)
+++ head/emulators/loemu/Makefile Mon May 25 10:13:35 2015 (r387374)
@@ -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.
${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>
Modified: head/emulators/loemu/files/patch-setup.py
==============================================================================
--- head/emulators/loemu/files/patch-setup.py Mon May 25 09:51:14 2015 (r387373)
+++ head/emulators/loemu/files/patch-setup.py Mon May 25 10:13:35 2015 (r387374)
@@ -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")
Modified: head/emulators/loemu/pkg-descr
==============================================================================
--- head/emulators/loemu/pkg-descr Mon May 25 09:51:14 2015 (r387373)
+++ head/emulators/loemu/pkg-descr Mon May 25 10:13:35 2015 (r387374)
@@ -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/
More information about the svn-ports-all
mailing list