From owner-freebsd-ports Mon Mar 29 2:40:20 1999 Delivered-To: freebsd-ports@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id A305A15839 for ; Mon, 29 Mar 1999 02:40:19 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.2/8.9.2) id CAA48499; Mon, 29 Mar 1999 02:40:02 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: by hub.freebsd.org (Postfix, from userid 32767) id 37B651583E; Mon, 29 Mar 1999 02:39:26 -0800 (PST) Message-Id: <19990329103926.37B651583E@hub.freebsd.org> Date: Mon, 29 Mar 1999 02:39:26 -0800 (PST) From: nakai@internetsolutions.co.jp To: freebsd-gnats-submit@freebsd.org X-Send-Pr-Version: www-1.0 Subject: ports/10852: Fixed port: snes9x Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 10852 >Category: ports >Synopsis: Fixed port: snes9x >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Mar 29 02:40:01 PST 1999 >Closed-Date: >Last-Modified: >Originator: Yukihiro Nakai >Release: 3.1R >Organization: Internet Solutions, Inc >Environment: 3.1R with latest /usr/ports >Description: I have fixed the snes9x port to follow its latest version. Now it comes with sound! ( It was my mistake the previous port doesn't support sound... ) I disabled the joystick, but it seems FreeBSD support that. Could anyone hack? Also, I don't test the s9xserver, because don't know what game really use that. Yukihiro Nakai -------------- diff -ruN snes9x.orig/Makefile snes9x/Makefile --- snes9x.orig/Makefile Sat Mar 27 16:40:03 1999 +++ snes9x/Makefile Sat Mar 27 16:33:44 1999 @@ -1,13 +1,13 @@ # New ports collection makefile for: snes9x -# Version required: 116a +# Version required: 118e # Date created: 20 July 1997 # Whom: Yukihiro Nakai # # $Id: Makefile,v 1.7 1999/02/03 11:11:42 asami Exp $ # -DISTNAME= snes116a -PKGNAME= snes9x-116a +DISTNAME= snes118e +PKGNAME= snes9x-118e CATEGORIES= emulators MASTER_SITES= http://www.snes9x.com/zips/ EXTRACT_SUFX= .zip @@ -23,6 +23,7 @@ USE_GMAKE= YES USE_X_PREFIX= YES MAKEFILE= Makefile.linux +ALL_TARGET= snes9x s9xserver EXTRACT_CMD= unzip EXTRACT_BEFORE_ARGS= # empty diff -ruN snes9x.orig/files/md5 snes9x/files/md5 --- snes9x.orig/files/md5 Sat Mar 27 16:40:03 1999 +++ snes9x/files/md5 Thu Mar 25 23:29:30 1999 @@ -1 +1 @@ -MD5 (snes116a.zip) = 76487bcdd362065bdf6877413f895243 +MD5 (snes118e.zip) = 676e4509c80031e8dd9938cd6e68f5d1 diff -ruN snes9x.orig/patches/patch-aa snes9x/patches/patch-aa --- snes9x.orig/patches/patch-aa Sat Mar 27 16:40:03 1999 +++ snes9x/patches/patch-aa Sat Mar 27 16:24:01 1999 @@ -1,16 +1,23 @@ ---- Makefile.linux.orig Mon Dec 21 14:40:08 1998 -+++ Makefile.linux Sun Jan 10 10:32:23 1999 -@@ -1,8 +1,8 @@ --ZSNESFX=1 -+#ZSNESFX=1 - ASMCPU=1 - #SPC700ASM=1 - NETPLAY=1 --UNZIP=1 -+#UNZIP=1 +--- Makefile.linux.orig Sat Mar 27 15:19:07 1999 ++++ Makefile.linux Sat Mar 27 15:31:11 1999 +@@ -5,7 +5,7 @@ + UNZIP=1 ifdef ZSNESFX - FXOBJ=i386/zsnes.o +-FXOBJ=i386/zsnes.o ++FXOBJ=i386/zsnes.o fxinst.o fxemu.o fxdbg.o + FXDEFINES=-DZSNES_FX -DEXECUTE_SUPERFX_PER_LINE + FXDEPENDS=zsnes_fx + FXNO_DEPENDS=c_fx +@@ -16,7 +16,7 @@ + FXNO_DEPENDS=zsnes_fx + endif + +-LINUXDEFINES=-DUSE_DGA_EXTENSION -DUSE_VIDMODE_EXTENSION ++LINUXDEFINES=-DUSE_DGA_EXTENSION -DUSE_VIDMODE_EXTENSION -D__linux + + ifdef ASMCPU + ifdef SPC700ASM @@ -47,8 +47,8 @@ UNZIPDEFINES=-DUNZIP_SUPPORT endif @@ -22,37 +29,11 @@ NASM = nasm INCLUDES=-I/usr/X11R6/include -I/usr/local/include -@@ -58,7 +58,7 @@ +@@ -59,7 +59,6 @@ -Ii386 \ -I. \ -Iunzip \ --DJOYSTICK_SUPPORT \ -+#-DJOYSTICK_SUPPORT \ -DZLIB \ -DNO_INLINE_SET_GET \ -DVAR_CYCLES \ -@@ -84,9 +84,9 @@ - LDLIBS = -L/usr/X11R6/lib - - ifdef NETPLAY --all: offsets snes9x ssnes9x s9xserver -+all: offsets snes9x s9xserver - else --all: offsets snes9x ssnes9x -+all: offsets snes9x - endif - - #ggisnes9x -@@ -101,10 +101,10 @@ - ./offsets >i386/offsets.h - - snes9x: $(OBJECTS) unix/x11.o -- $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/x11.o $(LDLIBS) -lXext -lX11 -lXxf86dga -lXxf86vm -lgz -lm -+ $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/x11.o $(LDLIBS) -lXext -lX11 -lXxf86dga -lXxf86vm -lz -lm - - xf86snes9x: $(OBJECTS) unix/xf86.o -- $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/xf86.o $(LDLIBS) -lXext -lX11 -lXxf86dga -lXxf86vm -lgz -lm -+ $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/xf86.o $(LDLIBS) -lXext -lX11 -lXxf86dga -lXxf86vm -lz -lm - /bin/chmod u+s xf86snes9x - - ssnes9x: $(OBJECTS) unix/svga.o diff -ruN snes9x.orig/patches/patch-ab snes9x/patches/patch-ab --- snes9x.orig/patches/patch-ab Sat Mar 27 16:40:03 1999 +++ snes9x/patches/patch-ab Sat Mar 27 16:24:58 1999 @@ -1,40 +1,11 @@ ---- unix/unix.cpp.orig Mon Dec 21 15:09:16 1998 -+++ unix/unix.cpp Sun Jan 10 10:28:58 1999 -@@ -71,6 +71,10 @@ - #if defined(__sun) && defined(__GNUC__) - typedef void (*SIG_PF)(); +--- port.h.orig Sat Mar 27 15:23:53 1999 ++++ port.h Sat Mar 27 16:24:39 1999 +@@ -125,7 +125,7 @@ + #define SLASH_CHAR '/' #endif -+#if defined (__FreeBSD__) -+typedef void (*SIG_PF)(); -+#endif -+ - #include "snes9x.h" - #include "memmap.h" -@@ -302,7 +306,7 @@ - Settings.SoundBufferSize = 0; - Settings.SPCTo65c816Ratio = 2; - Settings.DisableSoundEcho = FALSE; -- Settings.APUEnabled = TRUE; -+ Settings.APUEnabled = FALSE; - Settings.H_Max = (100 * SNES_CYCLES_PER_SCANLINE) / 100; - Settings.SkipFrames = AUTO_FRAMERATE; - Settings.Shutdown = TRUE; -@@ -983,7 +987,7 @@ - #if defined(__linux) - sa.sa_handler = (SIG_PF) SoundTrigger; - #else -- sa.sa_handler = (SIG_PF) SoundTrigger; -+ sa.sa_handler = (void*) SoundTrigger; +-#ifdef __linux ++#if defined(__linux) || defined(__FreeBSD__) + typedef void (*SignalHandler)(int); + #define SIG_PF SignalHandler #endif - - #if defined (SA_RESTART) -@@ -1615,7 +1619,7 @@ - stretch = get_config_int("Graphics", "Scale", 0); - _vsync = get_config_int("Graphics", "VSync", 0); - -- Settings.APUEnabled = get_config_int("Sound", "APUEnabled", TRUE); -+ Settings.APUEnabled = get_config_int("Sound", "APUEnabled", FALSE); - Settings.SoundPlaybackRate = get_config_int("Sound", "SoundPlaybackRate", 4); - Settings.Stereo = get_config_int("Sound", "Stereo", TRUE); - Settings.SoundBufferSize = get_config_int("Sound", "SoundBufferSize", 256); diff -ruN snes9x.orig/patches/patch-ac snes9x/patches/patch-ac --- snes9x.orig/patches/patch-ac Sat Mar 27 16:40:03 1999 +++ snes9x/patches/patch-ac Sat Mar 27 16:25:15 1999 @@ -1,12 +1,17 @@ ---- soundux.cpp.orig Sun Jan 10 10:18:25 1999 -+++ soundux.cpp Sun Jan 10 10:19:17 1999 -@@ -1202,7 +1202,9 @@ - return (1); +--- ppu.cpp.orig Sat Mar 27 15:26:53 1999 ++++ ppu.cpp Sat Mar 27 15:28:24 1999 +@@ -2293,6 +2293,7 @@ + } + + #ifndef ZSNES_FX ++#if 0 + void S9xSuperFXExec () + { + #ifdef EXECUTE_SUPERFX_PER_LINE +@@ -2463,5 +2464,6 @@ + } + #endif + } ++#endif + #endif - S9xSetSoundMute (TRUE); -+/* - if (!S9xOpenSoundDevice (mode, stereo, buffer_size)) -+*/ - { - S9xMessage (S9X_ERROR, S9X_SOUND_DEVICE_OPEN_FAILED, - "Sound device open failed"); diff -ruN snes9x.orig/patches/patch-ad snes9x/patches/patch-ad --- snes9x.orig/patches/patch-ad Thu Jan 1 09:00:00 1970 +++ snes9x/patches/patch-ad Sat Mar 27 16:25:41 1999 @@ -0,0 +1,11 @@ +--- unix/unix.cpp.orig Sat Mar 27 15:20:06 1999 ++++ unix/unix.cpp Sat Mar 27 15:20:14 1999 +@@ -57,7 +57,7 @@ + #endif + + #ifdef __linux +-#include ++#include + #endif + + #ifdef __sun >How-To-Repeat: >Fix: >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message