diff options
author | wiz <wiz@pkgsrc.org> | 2000-11-09 17:25:54 +0000 |
---|---|---|
committer | wiz <wiz@pkgsrc.org> | 2000-11-09 17:25:54 +0000 |
commit | 4a2ade2d92f01ef5a56e82e779784a180a85975b (patch) | |
tree | f1accdde7a854393761c7388d8d0d4f776527c05 /emulators/snes9x | |
parent | f0ec3c1f7e7c9364b587883a866fc8f71c75425b (diff) | |
download | pkgsrc-4a2ade2d92f01ef5a56e82e779784a180a85975b.tar.gz |
Fix package compilation to work on non-i386/ELF. Assembler only used
on i386/ELF, even though it could perhaps be made to work on i386/a.out.
DGA is also only enabled on i386 for now -- don't know of a good way
to check for DGA support.
Diffstat (limited to 'emulators/snes9x')
-rw-r--r-- | emulators/snes9x/Makefile | 14 | ||||
-rw-r--r-- | emulators/snes9x/files/patch-sum | 4 | ||||
-rw-r--r-- | emulators/snes9x/patches/patch-aa | 42 |
3 files changed, 45 insertions, 15 deletions
diff --git a/emulators/snes9x/Makefile b/emulators/snes9x/Makefile index 3e70b1e8609..f284818489a 100644 --- a/emulators/snes9x/Makefile +++ b/emulators/snes9x/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ +# $NetBSD: Makefile,v 1.2 2000/11/09 17:25:54 wiz Exp $ DISTNAME= s9xs129 PKGNAME= snes9x-1.29 @@ -12,9 +12,6 @@ HOMEPAGE= http://www.snes9x.com/ BUILD_DEPENDS+= nasm:../../devel/nasm -# for now, only builds on i386/ELF -ONLY_FOR_PLATFORM= NetBSD-1.4[A-Z]*-i386 NetBSD-1.[5-9]*-i386 - USE_X11= yes USE_GMAKE= yes @@ -33,9 +30,16 @@ do-install: .include "../../mk/bsd.pkg.mk" +.if ( ${MACHINE_ARCH} == "i386" ) .if ( ${OBJECT_FMT} == "a.out" ) MAKE_ENV+= FILEFORMAT=aoutb -MAKE_FLAGS+= _ASM_UNDERBARS=1 +MAKE_ENV+= _ASM_UNDERBARS=1 .else MAKE_ENV+= FILEFORMAT=elf +# use assembler part only for ELF, since it doesn't link on a.out +MAKE_ENV+= ZSNESFX=1 +MAKE_ENV+= ASMCPU=1 +.endif +# XXX: this check should be redone -- DGA doesn't only exist on i386 +MAKE_ENV+= NETBSD_USE_DGA=1 .endif diff --git a/emulators/snes9x/files/patch-sum b/emulators/snes9x/files/patch-sum index 2076225cc99..67e0bef1691 100644 --- a/emulators/snes9x/files/patch-sum +++ b/emulators/snes9x/files/patch-sum @@ -1,6 +1,6 @@ -$Id: patch-sum,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ +$Id: patch-sum,v 1.2 2000/11/09 17:25:55 wiz Exp $ -MD5 (patch-aa) = 506547364b5709eca8699d5715e0e90c +MD5 (patch-aa) = d15e182a98c2239da48f4015a09e7d2f MD5 (patch-ab) = 626e8bc7e260ff83708e13ef54e61cdd MD5 (patch-ac) = ad48bfa7a5b65c581c67ababd09cca99 MD5 (patch-ad) = 79cf18843562488e62fdbaf503dd50c4 diff --git a/emulators/snes9x/patches/patch-aa b/emulators/snes9x/patches/patch-aa index 394bfc03f67..c9935100145 100644 --- a/emulators/snes9x/patches/patch-aa +++ b/emulators/snes9x/patches/patch-aa @@ -1,8 +1,13 @@ -$NetBSD: patch-aa,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ +$NetBSD: patch-aa,v 1.2 2000/11/09 17:25:55 wiz Exp $ --- Makefile.orig Mon Jan 24 16:15:50 2000 +++ Makefile -@@ -4,7 +4,7 @@ +@@ -1,10 +1,10 @@ +-ZSNESFX=1 +-ASMCPU=1 ++#ZSNESFX=1 ++#ASMCPU=1 + #SPC700ASM=1 NETPLAY=1 UNZIP=1 #GLIDE=1 @@ -11,16 +16,28 @@ $NetBSD: patch-aa,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ ifdef ZSNESFX FXOBJ=i386/fxemu2b.o i386/fxemu2.o i386/fxemu2c.o i386/fxtable.o i386/sfxproc.o i386/zsnes.o -@@ -70,7 +70,7 @@ +@@ -18,7 +18,10 @@ + FXNO_DEPENDS=zsnes_fx + endif + ++ifdef NETBSD_USE_DGA + LINUXDEFINES=-DUSE_DGA_EXTENSION -DUSE_VIDMODE_EXTENSION ++DGALIBS=-lXxf86dga -lXxf86vm ++endif + + ifdef ASMCPU + ifdef SPC700ASM +@@ -70,15 +73,14 @@ CC = gcc NASM = nasm -INCLUDES=-I/usr/X11R6/include -I/usr/local/include +INCLUDES=-I${X11BASE}/include - OPTIMISE=-O6 -mpentium -fomit-frame-pointer -fno-exceptions +-OPTIMISE=-O6 -mpentium -fomit-frame-pointer -fno-exceptions ++OPTIMISE=-fomit-frame-pointer -fno-exceptions -@@ -78,7 +78,6 @@ + CCFLAGS = $(OPTIMISE) -DMITSHM \ -Ii386 \ -I. \ -Iunzip \ @@ -28,7 +45,7 @@ $NetBSD: patch-aa,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ -DZLIB \ -DNO_INLINE_SET_GET \ -DVAR_CYCLES \ -@@ -108,7 +107,7 @@ +@@ -108,7 +110,7 @@ # system using the egcs compiler get an undefined __register_frame_info # symbol error when run on a Redhat box. @@ -37,7 +54,7 @@ $NetBSD: patch-aa,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ ifdef GLIDE ifdef NETPLAY -@@ -118,9 +117,9 @@ +@@ -118,9 +120,9 @@ endif else ifdef NETPLAY @@ -49,7 +66,16 @@ $NetBSD: patch-aa,v 1.1.1.1 2000/11/09 16:43:40 wiz Exp $ endif endif -@@ -170,7 +169,7 @@ +@@ -140,7 +142,7 @@ + ./offsets >i386/offsets.h + + snes9x: $(OBJECTS) unix/x11.o +- $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/x11.o $(LDLIBS) -lXext -lX11 -lXxf86dga -lXxf86vm $(EXTRALIBS) -lz -lm ++ $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/x11.o $(LDLIBS) -lXext -lX11 $(DGALIBS) $(EXTRALIBS) -lz -lm + + ssnes9x: $(OBJECTS) unix/svga.o + $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/svga.o $(LDLIBS) -lvga -lvgagl $(EXTRALIBS) -lz -lm +@@ -170,7 +172,7 @@ $(CCC) $(INCLUDES) -c -E $(CCFLAGS) $*.S -o $@ .asm.o: |