diff options
author | abs <abs> | 2000-12-07 12:58:13 +0000 |
---|---|---|
committer | abs <abs> | 2000-12-07 12:58:13 +0000 |
commit | 779170c51a0d6885fd4000730a8c0ce6385b5a13 (patch) | |
tree | f703ce6cc453ba9f889d8a544258609853a1f61f /emulators/xmame | |
parent | 992e1a24f5a19911faa34b695a74db4ddf89bbc4 (diff) | |
download | pkgsrc-779170c51a0d6885fd4000730a8c0ce6385b5a13.tar.gz |
If we are not on a CPU known by mame, determine risc or risc_lsb based on
<machine/endian.h>. Fixed xmame on arm32.
Diffstat (limited to 'emulators/xmame')
-rw-r--r-- | emulators/xmame/Makefile | 8 | ||||
-rwxr-xr-x | emulators/xmame/files/endian.sh | 4 |
2 files changed, 10 insertions, 2 deletions
diff --git a/emulators/xmame/Makefile b/emulators/xmame/Makefile index 59518a1ebe9..3b5c264928a 100644 --- a/emulators/xmame/Makefile +++ b/emulators/xmame/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.39 2000/11/05 00:43:30 mycroft Exp $ +# $NetBSD: Makefile,v 1.40 2000/12/07 12:58:13 abs Exp $ # DISTNAME= xmame-0.37b6.1 @@ -43,11 +43,15 @@ MAME_CPU= m68k MAME_CPU= alpha .elif ${MACHINE_ARCH} == "i386" MAME_CPU= i386 -.elif ${MACHINE_ARCH} == "mipsel" +.else +# Rather than enumerating all CPU types, check machine/endian.h +ENDIAN!= sh files/endian.sh +.if ${ENDIAN} == "LITTLE_ENDIAN" MAME_CPU= risc_lsb .else MAME_CPU= risc .endif +.endif post-patch: (cd ${WRKSRC}/doc && ${SED} 's|@ROMPATH@|${ROMPATH}|;s|@SPOOLDIR@|${SPOOLDIR}|' \ diff --git a/emulators/xmame/files/endian.sh b/emulators/xmame/files/endian.sh new file mode 100755 index 00000000000..0a7f33f0331 --- /dev/null +++ b/emulators/xmame/files/endian.sh @@ -0,0 +1,4 @@ +#!/bin/sh +# $Id: endian.sh,v 1.1 2000/12/07 12:58:14 abs Exp $ +# Trivial script to output BIG_ENDIAN or LITTLE_ENDIAN +printf '#include <machine/endian.h>\n#if BYTE_ORDER == BIG_ENDIAN\nORDER_BIG_ENDIAN\n#else\nORDER_LITTLE_ENDIAN\n#endif\n' | cpp -P | sed -n 's/^ORDER_//p' |