summaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorEdwin Groothuis <edwin@FreeBSD.org>2004-02-28 00:35:27 +0000
committerEdwin Groothuis <edwin@FreeBSD.org>2004-02-28 00:35:27 +0000
commitdefbc605c28178a7ee466afb01febd76c9c73339 (patch)
tree204ca4a3feb77617982d79799078540c903175dc /emulators
parentUpdate to OpenLDAP 2.2.6 Release: (diff)
[PATCH] ports/emulators/fmsx is outdated, update supplied
Last update of ports/emulators/fmsx occured more than 3 years ago. A few version were issued since then, recent is 2.7 that is significantly improved. Some of port patches are integrated. - Added patch to use sys/soundcard.h - Added patch to be able to select the BPP level (BPP32 didn't work on my machine, see http://www.msx.org/newspost149.html for info) PR: ports/60825 Submitted by: Eugene Grosbein <eugen@grosbein.pp.ru> Reviewed by: edwin@mavetju.org Approved by: maintainer timeout
Notes
Notes: svn path=/head/; revision=102335
Diffstat (limited to 'emulators')
-rw-r--r--emulators/fmsx/Makefile27
-rw-r--r--emulators/fmsx/distinfo2
-rw-r--r--emulators/fmsx/files/fmsx2
-rw-r--r--emulators/fmsx/files/patch-SndUnix.c11
-rw-r--r--emulators/fmsx/files/patch-aa26
-rw-r--r--emulators/fmsx/files/patch-ab21
-rw-r--r--emulators/fmsx/files/patch-ac11
-rw-r--r--emulators/fmsx/pkg-descr2
-rw-r--r--emulators/fmsx/pkg-message10
-rw-r--r--emulators/fmsx/pkg-plist7
10 files changed, 65 insertions, 54 deletions
diff --git a/emulators/fmsx/Makefile b/emulators/fmsx/Makefile
index 9bae40af1c69..b7b9f929f8a3 100644
--- a/emulators/fmsx/Makefile
+++ b/emulators/fmsx/Makefile
@@ -6,21 +6,42 @@
#
PORTNAME= fmsx
-PORTVERSION= 2.2
+PORTVERSION= 2.7
CATEGORIES= emulators
MASTER_SITES= http://fms.komkon.org/fMSX/
-DISTNAME= fMSX22
+DISTNAME= fMSX27
EXTRACT_SUFX= .tar.Z
MAINTAINER= dk@farm.org
COMMENT= The Portable MSX/MSX2/MSX2+ Emulator
+USE_REINPLACE= yes
+REINPLACE_ARGS= -i ""
+
USE_XLIB= yes
RESTRICTED= Legal status of distributed ROM images unclear
WRKSRC= ${WRKDIR}/MSX
+OPTIONS= BPP16 "With BPP16" Off \
+ BPP24 "With BPP24" Off \
+ BPP32 "With BPP32 (see pkg-message)" On
+
+.include <bsd.port.pre.mk>
+
+post-patch:
+.ifdef(WITH_BPP32)
+ ${REINPLACE_CMD} -e 's/%%BPP%%/BPP32/' ${WRKSRC}/Makefile
+.endif
+.ifdef(WITH_BPP24)
+ ${REINPLACE_CMD} -e 's/%%BPP%%/BPP24/' ${WRKSRC}/Makefile
+.endif
+.ifdef(WITH_BPP16)
+ ${REINPLACE_CMD} -e 's/%%BPP%%/BPP16/' ${WRKSRC}/Makefile
+.endif
+
do-install:
${INSTALL_SCRIPT} ${FILESDIR}/fmsx ${PREFIX}/bin
+ ${REINPLACE_CMD} "s,PREFIX,${PREFIX},g" ${PREFIX}/bin/fmsx
${INSTALL_PROGRAM} ${WRKSRC}/fmsx ${PREFIX}/bin/fmsx.bin
${INSTALL_PROGRAM} ${WRKSRC}/rddsk ${PREFIX}/bin/fmsx-rddsk
${INSTALL_PROGRAM} ${WRKSRC}/wrdsk ${PREFIX}/bin/fmsx-wrdsk
@@ -31,4 +52,4 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/*.html ${PREFIX}/share/doc/fmsx
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/emulators/fmsx/distinfo b/emulators/fmsx/distinfo
index 5c43dd4e8150..7d48239c9ed0 100644
--- a/emulators/fmsx/distinfo
+++ b/emulators/fmsx/distinfo
@@ -1 +1 @@
-MD5 (fMSX22.tar.Z) = 15f9e0d4cd28f16d9de81f75cfd63ce4
+MD5 (fMSX27.tar.Z) = 419b3b637067f83465d61b32b0b09ab7
diff --git a/emulators/fmsx/files/fmsx b/emulators/fmsx/files/fmsx
index d48efecc5fff..3edae8ae6a3c 100644
--- a/emulators/fmsx/files/fmsx
+++ b/emulators/fmsx/files/fmsx
@@ -1,3 +1,3 @@
#!/bin/sh
-exec /usr/local/bin/fmsx.bin -home /usr/local/share/fmsx "$@"
+exec PREFIX/bin/fmsx.bin -home PREFIX/share/fmsx "$@"
diff --git a/emulators/fmsx/files/patch-SndUnix.c b/emulators/fmsx/files/patch-SndUnix.c
new file mode 100644
index 000000000000..96ea70557bb6
--- /dev/null
+++ b/emulators/fmsx/files/patch-SndUnix.c
@@ -0,0 +1,11 @@
+--- SndUnix.c.orig Sat Feb 28 10:19:49 2004
++++ SndUnix.c Sat Feb 28 10:19:56 2004
+@@ -75,7 +75,7 @@
+ #else /* SUN_AUDIO */
+
+ #ifdef __FreeBSD__
+-#include <machine/soundcard.h>
++#include <sys/soundcard.h>
+ #endif
+
+ #ifdef __NetBSD__
diff --git a/emulators/fmsx/files/patch-aa b/emulators/fmsx/files/patch-aa
index b149fa52dc8f..a5b9719bddfd 100644
--- a/emulators/fmsx/files/patch-aa
+++ b/emulators/fmsx/files/patch-aa
@@ -1,26 +1,26 @@
---- Makefile.orig Fri Aug 4 02:23:33 2000
-+++ Makefile Thu Aug 17 04:50:41 2000
-@@ -43,11 +43,10 @@
+--- Makefile.orig Mon Dec 31 20:01:16 2001
++++ Makefile Sat Feb 28 11:20:12 2004
+@@ -51,10 +51,10 @@
# If you are getting linker errors about not found X11 functions,
# change the -L/usr/X11R6/lib to the directory where X11
# libraries libX11.* and libXext.* are located on your system.
-CC = gcc
-DEFINES = -DFMSX -DUNIX -DLSB_FIRST -DDEBUG -DMITSHM \
+- -DDISK -DNARROW -DSOUND -DBPP16 -DZLIB
+-CFLAGS = -O3 -Wall -I/usr/X11R6/include -L/usr/X11R6/lib ${DEFINES}
+CC ?= gcc
+DEFINES = -DFMSX -DUNIX -DLSB_FIRST -DMITSHM \
- -DDISK -DNARROW -DSOUND -DBPP16
--CFLAGS = -O3 -fomit-frame-pointer \
-- -I/usr/X11/include -L/usr/X11/lib ${DEFINES}
-+CFLAGS += -I${X11BASE}/include ${DEFINES}
- OBJECTS = fMSX.o MSX.o Z80.o AY8910.o SCC.o V9938.o Patch.o Debug.o \
- Disk.o Unix.o LibUnix.o SndUnix.o MIDI.o
-
-@@ -63,7 +62,7 @@
++ -DDISK -DNARROW -DSOUND -D%%BPP%% -DZLIB
++CFLAGS = -O3 -Wall -I${X11BASE}/include -L${X11BASE}/lib ${DEFINES}
+ OBJECTS = fMSX.o MSX.o Patch.o Debug.o Disk.o Sound.o \
+ Z80.o I8255.o AY8910.o YM2413.o SCC.o V9938.o I8251.o \
+ Unix.o LibUnix.o SndUnix.o
+@@ -71,7 +71,7 @@
# fMSX Unix/X requires X11 libraries. See note above if you are
# experiencing any problems.
fmsx: ${OBJECTS}
-- ${CC} ${CFLAGS} -o fmsx ${OBJECTS} -lXext -lX11
-+ ${CC} ${CFLAGS} -o fmsx ${OBJECTS} -lXext -lX11 -L${X11BASE}/lib
+- ${CC} ${CFLAGS} -o fmsx ${OBJECTS} -lXext -lX11 -lz
++ ${CC} ${CFLAGS} -o fmsx ${OBJECTS} -lXext -lX11 -L${X11BASE}/lib -lz
# Clean up.
clean:
diff --git a/emulators/fmsx/files/patch-ab b/emulators/fmsx/files/patch-ab
deleted file mode 100644
index 57562636345d..000000000000
--- a/emulators/fmsx/files/patch-ab
+++ /dev/null
@@ -1,21 +0,0 @@
---- Unix.c.orig Thu Aug 3 20:10:32 2000
-+++ Unix.c Wed Aug 16 16:14:50 2000
-@@ -309,12 +309,16 @@
- }
- break;
-
-- case XK_F9:
-+ case XK_F6:
- if(Control) AutoFire=!AutoFire;
- break;
-
-- case XK_F10:
-+ case XK_F9:
- if(Control) UseFont=UseFont? 0:FontBuf? 1:0;
-+ break;
-+
-+ case XK_F10:
-+ if(Control) LogSnd=!LogSnd;
- break;
-
- case XK_F12: ExitNow=1;break;
diff --git a/emulators/fmsx/files/patch-ac b/emulators/fmsx/files/patch-ac
deleted file mode 100644
index 344547b0df0f..000000000000
--- a/emulators/fmsx/files/patch-ac
+++ /dev/null
@@ -1,11 +0,0 @@
---- SndUnix.c.orig Mon Oct 13 00:19:55 2003
-+++ SndUnix.c Mon Oct 13 00:20:18 2003
-@@ -73,7 +73,7 @@
-
- #else /* SUN_AUDIO */
-
--#ifdef LINUX
-+#if defined(LINUX) || defined(__FreeBSD__)
- #include <sys/soundcard.h>
- #else
- #include <machine/soundcard.h>
diff --git a/emulators/fmsx/pkg-descr b/emulators/fmsx/pkg-descr
index ca6a60e9e7c8..abaebedf3219 100644
--- a/emulators/fmsx/pkg-descr
+++ b/emulators/fmsx/pkg-descr
@@ -1,6 +1,6 @@
******* fMSX *******
The Portable MSX/MSX2/MSX2+ Emulator
- version 2.2
+ version 2.7
by Marat Fayzullin <fms@cs.umd.edu>
WWW: http://fms.komkon.org/fMSX/
diff --git a/emulators/fmsx/pkg-message b/emulators/fmsx/pkg-message
new file mode 100644
index 000000000000..3aae9b77ace9
--- /dev/null
+++ b/emulators/fmsx/pkg-message
@@ -0,0 +1,10 @@
+*******************************************************************
+From http://www.msx.org/newspost149.html:
+
+Also a tip for X11 users: if you get 'Opening window... FAILED'
+when starting fMSX and you're using -DBPP32, try compiling with
+-DBPP24 instead
+
+For FreeBSD users: run "make clean config" and unselect BPP32 and
+select BPP16 or BPP24 as options.
+*******************************************************************
diff --git a/emulators/fmsx/pkg-plist b/emulators/fmsx/pkg-plist
index aee2eb8d11d8..fa11aec53b29 100644
--- a/emulators/fmsx/pkg-plist
+++ b/emulators/fmsx/pkg-plist
@@ -5,6 +5,7 @@ bin/fmsx-wrdsk
share/fmsx/CMOS.ROM
share/fmsx/CYRILLIC.FNT
share/fmsx/DISK.ROM
+share/fmsx/FMPAC.ROM
share/fmsx/ITALIC.FNT
share/fmsx/KANJI.ROM
share/fmsx/MSX.ROM
@@ -13,6 +14,6 @@ share/fmsx/MSX2EXT.ROM
share/fmsx/MSX2P.ROM
share/fmsx/MSX2PEXT.ROM
share/fmsx/PAINTER.ROM
-@dirrm share/fmsx
-share/doc/fmsx/fMSX.html
-@dirrm share/doc/fmsx
+%%PORTDOCS%%share/doc/fmsx/fMSX.html
+%%PORTDOCS%%@dirrm share/fmsx
+%%PORTDOCS%%@dirrm share/doc/fmsx