summaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorross <ross@pkgsrc.org>1999-05-10 02:17:50 +0000
committerross <ross@pkgsrc.org>1999-05-10 02:17:50 +0000
commit615998b2dda2553621f32dca28f65201706691e2 (patch)
treebf7218d93e70d33037b8853858fb4531085acae4 /emulators
parentfeb8b7fa954f6915810e026ceb68983f4c9d5597 (diff)
downloadpkgsrc-615998b2dda2553621f32dca28f65201706691e2.tar.gz
Fix compile problems. Enable on alpha.
Diffstat (limited to 'emulators')
-rw-r--r--emulators/xmame/Makefile4
-rw-r--r--emulators/xmame/patches/patch-am39
2 files changed, 40 insertions, 3 deletions
diff --git a/emulators/xmame/Makefile b/emulators/xmame/Makefile
index 2e1bfe41baf..204e1787934 100644
--- a/emulators/xmame/Makefile
+++ b/emulators/xmame/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.30 1999/04/03 21:45:16 mycroft Exp $
+# $NetBSD: Makefile,v 1.31 1999/05/10 02:17:50 ross Exp $
#
DISTNAME= xmame-0.35b8.1
@@ -12,8 +12,6 @@ HOMEPAGE= http://xmame.retrogames.com/
DEPENDS= unzip-5.40:../../archivers/unzip
DEPENDS+= xpm-3.4k:../../graphics/xpm
-NOT_FOR_ARCHS= alpha #gcc lossage
-
USE_X11BASE= yes
USE_GMAKE= yes
MAKE_ENV+= OPSYS=${OPSYS} ARCH=${ARCH} DESTDIR=${DESTDIR} \
diff --git a/emulators/xmame/patches/patch-am b/emulators/xmame/patches/patch-am
new file mode 100644
index 00000000000..b00e7f14873
--- /dev/null
+++ b/emulators/xmame/patches/patch-am
@@ -0,0 +1,39 @@
+--- src/cpuintrf.c.orig Fri Mar 26 10:03:35 1999
++++ src/cpuintrf.c Sun May 9 14:41:55 1999
+@@ -82,9 +82,34 @@
+ #define LOG(x)
+ #endif
+
+-#define CPUINFO_SIZE (5*sizeof(int)+4*sizeof(void*)+2*sizeof(double))
++/*
++ * The filler object and the CPUINFO_* defs have various problems. (1) If
++ * there is a hole at the end of the struct, the first few bytes of filler
++ * won't extend the size. This is the case if the last object isn't one with
++ * the maximum alignment restriction. (2) The calculation of CPUINFO_SIZE
++ * ignores internal holes added by the compiler for field alignment. That
++ * can be fixed by reordering fields, but then you get problem #1.
++ */
++
++typedef struct cpuinfo_test_struct
++{
++ struct cpu_interface *intf; /* pointer to the interface functions */
++ int iloops; /* number of interrupts remaining this frame */
++ int totalcycles; /* total CPU cycles executed */
++ int vblankint_countdown; /* number of vblank callbacks left until we interrupt */
++ int vblankint_multiplier; /* number of vblank callbacks per interrupt */
++ void *vblankint_timer; /* reference to elapsed time counter */
++ double vblankint_period; /* timing period of the VBLANK interrupt */
++ void *timedint_timer; /* reference to this CPU's timer */
++ double timedint_period; /* timing period of the timed interrupt */
++ int save_context; /* need to context switch this CPU? yes or no */
++ void *context; /* dynamically allocated context buffer */
++ UINT8 filler[0]; /* make the array aligned to next power of 2 */
++} cpuinfo_test;
++
+ /* How do I calculate the next power of two from CPUINFO_SIZE using a macro? */
+-#define CPUINFO_ALIGN (64-CPUINFO_SIZE)
++
++#define CPUINFO_ALIGN ((sizeof(cpuinfo_test) > 64 ? 128 : 64) - sizeof(cpuinfo_test))
+
+ struct cpuinfo
+ {