From 281084befdfbd8e8f11a38af97e85891ce033c9d Mon Sep 17 00:00:00 2001 From: wiz Date: Mon, 14 Feb 2000 02:44:31 +0000 Subject: First try at making darcnes work on non-i386-platforms --- emulators/darcnes/Makefile | 10 +++++++-- emulators/darcnes/files/patch-sum | 13 +++++++---- emulators/darcnes/patches/patch-aa | 31 ++++++++++++++++++++----- emulators/darcnes/patches/patch-ab | 6 ++--- emulators/darcnes/patches/patch-ac | 4 ++-- emulators/darcnes/patches/patch-ad | 46 ++++++++++++++++++++++++++++++++++++++ emulators/darcnes/patches/patch-ae | 11 +++++++++ emulators/darcnes/patches/patch-af | 12 ++++++++++ emulators/darcnes/patches/patch-ag | 12 ++++++++++ emulators/darcnes/patches/patch-ah | 13 +++++++++++ 10 files changed, 141 insertions(+), 17 deletions(-) create mode 100644 emulators/darcnes/patches/patch-ad create mode 100644 emulators/darcnes/patches/patch-ae create mode 100644 emulators/darcnes/patches/patch-af create mode 100644 emulators/darcnes/patches/patch-ag create mode 100644 emulators/darcnes/patches/patch-ah (limited to 'emulators/darcnes') diff --git a/emulators/darcnes/Makefile b/emulators/darcnes/Makefile index e5e718ffb21..ccc34a0cfec 100644 --- a/emulators/darcnes/Makefile +++ b/emulators/darcnes/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2000/02/14 01:42:25 wiz Exp $ +# $NetBSD: Makefile,v 1.3 2000/02/14 02:44:31 wiz Exp $ DISTNAME= dn9a0212 PKGNAME= darcnes-20000212 @@ -14,7 +14,7 @@ USE_X11= yes USE_GMAKE= yes # make dependencies -do-configure: +post-patch: cd ${WRKSRC} && ${GMAKE} do-install: @@ -27,3 +27,9 @@ do-install: .if ( ${OBJECT_FMT} == "a.out" ) MAKE_FLAGS+= ASM_FLAGS=-DASM_UNDERBARS .endif + +.if ( ${MACHINE_ARCH} == "i386" ) +MAKE_FLAGS+= MACH_TYPES=-DMACH_TYPES=\\\"types-i386.h\\\" +.else +MAKE_FLAGS+= C_ONLY=-DC_ONLY +.endif diff --git a/emulators/darcnes/files/patch-sum b/emulators/darcnes/files/patch-sum index 7707f0c1e3a..5a2b8cf5ab1 100644 --- a/emulators/darcnes/files/patch-sum +++ b/emulators/darcnes/files/patch-sum @@ -1,5 +1,10 @@ -$NetBSD: patch-sum,v 1.1.1.1 2000/02/13 23:28:06 wiz Exp $ +$NetBSD: patch-sum,v 1.2 2000/02/14 02:44:33 wiz Exp $ -MD5 (patch-aa) = 09de740fe064d8112f99bee861beb3cd -MD5 (patch-ab) = 86c37c0b40a33778df4180d135f3e9a5 -MD5 (patch-ac) = e823aec468bc2dd79f07d3552de191ec +MD5 (patch-aa) = 1ce29e1665be04dc2120b0ca10ebbab8 +MD5 (patch-ab) = 49976d407355afa04a598e981b89ecd0 +MD5 (patch-ac) = 56a4b80b41c302bfa75b287bde33e379 +MD5 (patch-ad) = 7653f1e8ecc021932392acc7fca509ec +MD5 (patch-ae) = 0c46cde110f4ae3616218068dd77cd8b +MD5 (patch-af) = caa0f3455a5309131d1e70e390a4ba35 +MD5 (patch-ag) = c437935b2db34ac9a4c950dca458f1db +MD5 (patch-ah) = 1aa5af7a684eccbdfb62f33eeb8fefec diff --git a/emulators/darcnes/patches/patch-aa b/emulators/darcnes/patches/patch-aa index e058c6a43de..a4875946250 100644 --- a/emulators/darcnes/patches/patch-aa +++ b/emulators/darcnes/patches/patch-aa @@ -1,8 +1,19 @@ -$NetBSD: patch-aa,v 1.1.1.1 2000/02/13 23:28:07 wiz Exp $ +$NetBSD: patch-aa,v 1.2 2000/02/14 02:44:33 wiz Exp $ --- ./Makefile.orig Sat Feb 12 20:04:24 2000 -+++ ./Makefile Sun Feb 13 22:26:07 2000 -@@ -20,8 +20,8 @@ ++++ ./Makefile Mon Feb 14 03:27:44 2000 +@@ -11,23 +11,23 @@ + + #C_ONLY=-DC_ONLY + +-MACH_TYPES=-DMACH_TYPES=\"types-i386.h\" ++#MACH_TYPES=-DMACH_TYPES=\"types-i386.h\" + + #BYTE_ORDER=-DMSB_FIRST +-BYTE_ORDER=-DLSB_FIRST ++#BYTE_ORDER=-DLSB_FIRST + + DEBUG=-g CDFLAGS=-DPCE_CD_SUPPORT @@ -13,15 +24,23 @@ $NetBSD: patch-aa,v 1.1.1.1 2000/02/13 23:28:07 wiz Exp $ #CD_SRC=cd_linux.c #CD_OBJ=cd_linux.o + OPTFLAGS=-O2 -fomit-frame-pointer + +-BASE_CFLAGS=-Wall $(DEBUG) $(OPTFLAGS) $(CDFLAGS) $(C_ONLY) $(BYTE_ORDER) $(MACH_TYPES) ++BASE_CFLAGS=-Wall $(DEBUG) $(OPTFLAGS) $(CDFLAGS) $(C_ONLY) $(MACH_TYPES) + BASE_SFLAGS=-Wall $(DEBUG) $(OPTFLAGS) $(CDFLAGS) + + # @@ -53,9 +53,9 @@ AS=gcc LD=gcc -LDFLAGS=-L/usr/X11R6/lib -+LDFLAGS=-L/usr/X11R6/lib -Wl,-R/usr/X11R6/lib - CFLAGS=$(BASE_CFLAGS) -I/usr/X11R6/include +-CFLAGS=$(BASE_CFLAGS) -I/usr/X11R6/include -SFLAGS=$(BASE_SFLAGS) -I/usr/X11R6/include -+SFLAGS=$(BASE_SFLAGS) -I/usr/X11R6/include ${ASM_FLAGS} ++LDFLAGS=-L${X11BASE}/lib -Wl,-R${X11BASE}/lib ++CFLAGS=$(BASE_CFLAGS) -I${X11BASE}/include ++SFLAGS=$(BASE_SFLAGS) ${ASM_FLAGS} -I${X11BASE}/include BINFILE=darcnes LIBS=-lXext -lXaw -lXmu -lXt -lX11 endif diff --git a/emulators/darcnes/patches/patch-ab b/emulators/darcnes/patches/patch-ab index 906e50f6516..6e1ede12b76 100644 --- a/emulators/darcnes/patches/patch-ab +++ b/emulators/darcnes/patches/patch-ab @@ -1,7 +1,7 @@ -$NetBSD: patch-ab,v 1.1.1.1 2000/02/13 23:28:07 wiz Exp $ +$NetBSD: patch-ab,v 1.2 2000/02/14 02:44:34 wiz Exp $ ---- ./cd_netbsd.c.orig Sun Feb 13 22:28:03 2000 -+++ ./cd_netbsd.c Sun Feb 13 22:28:32 2000 +--- ./cd_netbsd.c.orig Mon Feb 14 00:38:08 2000 ++++ ./cd_netbsd.c Mon Feb 14 00:38:08 2000 @@ -0,0 +1,93 @@ +/* + * cd_netbsd.c diff --git a/emulators/darcnes/patches/patch-ac b/emulators/darcnes/patches/patch-ac index 66519a9eda7..a9921d42248 100644 --- a/emulators/darcnes/patches/patch-ac +++ b/emulators/darcnes/patches/patch-ac @@ -1,7 +1,7 @@ -$NetBSD: patch-ac,v 1.1.1.1 2000/02/13 23:28:07 wiz Exp $ +$NetBSD: patch-ac,v 1.2 2000/02/14 02:44:35 wiz Exp $ --- ./snd_unix.c.orig Wed Jan 26 21:22:18 2000 -+++ ./snd_unix.c Sun Feb 13 22:27:06 2000 ++++ ./snd_unix.c Mon Feb 14 00:38:09 2000 @@ -8,13 +8,21 @@ /* #define SOUND_LINUX */ /* use linux sound header */ diff --git a/emulators/darcnes/patches/patch-ad b/emulators/darcnes/patches/patch-ad new file mode 100644 index 00000000000..4793e323274 --- /dev/null +++ b/emulators/darcnes/patches/patch-ad @@ -0,0 +1,46 @@ +$NetBSD: patch-ad,v 1.1 2000/02/14 02:44:36 wiz Exp $ + +--- ./endian.h.orig Mon Feb 14 03:05:25 2000 ++++ ./endian.h Mon Feb 14 02:38:38 2000 +@@ -0,0 +1,41 @@ ++#ifndef __HAD_MY_ENDIAN_H ++#define __HAD_MY_ENDIAN_H ++ ++#include ++ ++#if (defined(BSD) && (BSD >= 199306)) ++/* this should filter out NetBSD, FreeBSD and OpenBSD */ ++#include ++ ++#if BYTE_ORDER == BIG_ENDIAN ++#define MSB_FIRST 1 ++#undef LSB_FIRST ++#else ++#define LSB_FIRST 1 ++#undef MSB_FIRST ++#endif ++ ++#else ++/* for Linux, perhaps use #ifdef __linux__? */ ++#include ++ ++#if defined(__BYTE_ORDER) ++#if __BYTE_ORDER == __BIG_ENDIAN ++#define MSB_FIRST 1 ++#undef LSB_FIRST ++#else ++#define LSB_FIRST 1 ++#undef MSB_FIRST ++#endif /* __BYTE_ORDER == __BIG_ENDIAN */ ++ ++#else /* defined(__BYTE_ORDER) */ ++ ++/* not Linux, either, just set it to LSB */ ++#define LSB_FIRST 1 ++#undef MSB_FIRST ++ ++#endif /* defined(__BYTE_ORDER) */ ++ ++#endif /* defined(BSD) && (BSD >= 199306) */ ++ ++#endif /* __HAD_MY_ENDIAN_H */ diff --git a/emulators/darcnes/patches/patch-ae b/emulators/darcnes/patches/patch-ae new file mode 100644 index 00000000000..110cc069d51 --- /dev/null +++ b/emulators/darcnes/patches/patch-ae @@ -0,0 +1,11 @@ +$NetBSD: patch-ae,v 1.1 2000/02/14 02:44:39 wiz Exp $ + +--- ./mtypes.h.orig Sat Aug 7 18:19:37 1999 ++++ ./mtypes.h Mon Feb 14 02:37:16 2000 +@@ -11,4 +11,6 @@ + ++#include "endian.h" ++ + typedef unsigned char byte; + typedef unsigned short word; + typedef signed char offset; diff --git a/emulators/darcnes/patches/patch-af b/emulators/darcnes/patches/patch-af new file mode 100644 index 00000000000..ed3f830c995 --- /dev/null +++ b/emulators/darcnes/patches/patch-af @@ -0,0 +1,12 @@ +$NetBSD: patch-af,v 1.1 2000/02/14 02:44:43 wiz Exp $ + +--- ./pce_vdp.c.orig Sun Feb 6 23:28:03 2000 ++++ ./pce_vdp.c Mon Feb 14 02:36:38 2000 +@@ -13,6 +13,7 @@ + #include "video.h" + #include "blitters.h" + #include "tiledraw.h" ++#include "endian.h" + + #define PCE_VDP_RAMSIZE 0x10000 + diff --git a/emulators/darcnes/patches/patch-ag b/emulators/darcnes/patches/patch-ag new file mode 100644 index 00000000000..8435beaa20f --- /dev/null +++ b/emulators/darcnes/patches/patch-ag @@ -0,0 +1,12 @@ +$NetBSD: patch-ag,v 1.1 2000/02/14 02:44:45 wiz Exp $ + +--- ./tool.c.orig Sat Jan 1 05:12:05 2000 ++++ ./tool.c Mon Feb 14 02:36:52 2000 +@@ -19,6 +19,7 @@ + #include "video.h" + #include "tool.h" + #include "system.h" ++#include "endian.h" + + unsigned long system_flags; + diff --git a/emulators/darcnes/patches/patch-ah b/emulators/darcnes/patches/patch-ah new file mode 100644 index 00000000000..fb0e99d17c0 --- /dev/null +++ b/emulators/darcnes/patches/patch-ah @@ -0,0 +1,13 @@ +$NetBSD: patch-ah,v 1.1 2000/02/14 02:44:47 wiz Exp $ + +--- ./types.h.orig Tue Dec 7 03:01:23 1999 ++++ ./types.h Mon Feb 14 02:37:37 2000 +@@ -13,6 +13,8 @@ + #include MACH_TYPES + #endif + ++#include "endian.h" ++ + typedef unsigned char u8; + typedef signed char s8; + -- cgit v1.2.3