summaryrefslogtreecommitdiff
path: root/emulators/pearpc
diff options
context:
space:
mode:
Diffstat (limited to 'emulators/pearpc')
-rw-r--r--emulators/pearpc/Makefile20
-rw-r--r--emulators/pearpc/PLIST6
-rw-r--r--emulators/pearpc/distinfo13
-rw-r--r--emulators/pearpc/options.mk17
-rw-r--r--emulators/pearpc/patches/patch-aa12
-rw-r--r--emulators/pearpc/patches/patch-ab31
-rw-r--r--emulators/pearpc/patches/patch-ac31
-rw-r--r--emulators/pearpc/patches/patch-ad12
8 files changed, 112 insertions, 30 deletions
diff --git a/emulators/pearpc/Makefile b/emulators/pearpc/Makefile
index 77983e1c240..b9ac12dc7ab 100644
--- a/emulators/pearpc/Makefile
+++ b/emulators/pearpc/Makefile
@@ -1,13 +1,11 @@
-# $NetBSD: Makefile,v 1.8 2005/12/11 09:40:39 wiz Exp $
-#
+# $NetBSD: Makefile,v 1.9 2005/12/22 19:27:36 ghen Exp $
-DISTNAME= pearpc-0.3.1
-PKGREVISION= 2
+DISTNAME= pearpc-0.4
CATEGORIES= emulators
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=pearpc/}
EXTRACT_SUFX= .tar.bz2
-MAINTAINER= tech-pkg@NetBSD.org
+MAINTAINER= ghen@NetBSD.org
HOMEPAGE= http://pearpc.sourceforge.net/
COMMENT= PowerPC emulator
@@ -45,17 +43,7 @@ SUBST_FILES.conf= ppccfg.example
SUBST_SED.conf= -e "s|\"nvram\"|\"/tmp/nvram\"|"
SUBST_MESSAGE.conf= "Fixing configuration file."
-PKG_OPTIONS_VAR= PKG_OPTIONS.pearpc
-PKG_SUPPORTED_OPTIONS= sdl
-
-.include "../../mk/bsd.options.mk"
-
-.if empty(PKG_OPTIONS:Msdl)
-CONFIGURE_ARGS+= --enable-ui=x11
-.else
-CONFIGURE_ARGS+= --enable-ui=sdl
-. include "../../devel/SDL/buildlink3.mk"
-.endif
+.include "options.mk"
.include "../../mk/pthread.buildlink3.mk"
.include "../../mk/x11.buildlink3.mk"
diff --git a/emulators/pearpc/PLIST b/emulators/pearpc/PLIST
index 6f86fc0fdea..ccdd27a5ea1 100644
--- a/emulators/pearpc/PLIST
+++ b/emulators/pearpc/PLIST
@@ -1,7 +1,7 @@
-@comment $NetBSD: PLIST,v 1.1.1.1 2004/06/20 19:33:19 xtraeme Exp $
+@comment $NetBSD: PLIST,v 1.2 2005/12/22 19:27:36 ghen Exp $
bin/pearpc
+share/examples/pearpc/ppccfg.example
share/pearpc/ppc
share/pearpc/video.x
-share/examples/pearpc/ppccfg.example
-@dirrm share/examples/pearpc
@dirrm share/pearpc
+@dirrm share/examples/pearpc
diff --git a/emulators/pearpc/distinfo b/emulators/pearpc/distinfo
index db5ce7a7229..5a62d71718d 100644
--- a/emulators/pearpc/distinfo
+++ b/emulators/pearpc/distinfo
@@ -1,6 +1,9 @@
-$NetBSD: distinfo,v 1.4 2005/02/23 18:49:19 agc Exp $
+$NetBSD: distinfo,v 1.5 2005/12/22 19:27:36 ghen Exp $
-SHA1 (pearpc-0.3.1.tar.bz2) = dd72099397045dfb5b2b74bc8119ca54b7bcfeba
-RMD160 (pearpc-0.3.1.tar.bz2) = 2a901d3da7086598e86af2b4bf1b549de7b48a8b
-Size (pearpc-0.3.1.tar.bz2) = 641965 bytes
-SHA1 (patch-aa) = 4f5355b989f963ef030b1ae28d4f5fce6b0f462d
+SHA1 (pearpc-0.4.tar.bz2) = 1cfa4f19f9a1de73c209a38d8fda174c0ebe6ad5
+RMD160 (pearpc-0.4.tar.bz2) = 84c831b3ede69721d0fa48d71a30ee0e7ec512fc
+Size (pearpc-0.4.tar.bz2) = 687776 bytes
+SHA1 (patch-aa) = 104fce78006613853c15573971cdb691a08c6401
+SHA1 (patch-ab) = c8724e43d99476d5ccae8d8782dc8bf9705743ae
+SHA1 (patch-ac) = e6b52cf368391fe6d09722a6ba99e5b3933c5b03
+SHA1 (patch-ad) = 5932a40320c7783c8379d2af7f6d98a42707ff1b
diff --git a/emulators/pearpc/options.mk b/emulators/pearpc/options.mk
new file mode 100644
index 00000000000..1ab21ce8d3b
--- /dev/null
+++ b/emulators/pearpc/options.mk
@@ -0,0 +1,17 @@
+# $NetBSD: options.mk,v 1.1 2005/12/22 19:27:36 ghen Exp $
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.pearpc
+PKG_OPTIONS_REQUIRED_GROUPS= ui
+PKG_OPTIONS_GROUP.ui= x11 sdl
+PKG_SUGGESTED_OPTIONS= x11
+
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mx11)
+CONFIGURE_ARGS+= --enable-ui=x11
+.endif
+
+.if !empty(PKG_OPTIONS:Msdl)
+CONFIGURE_ARGS+= --enable-ui=sdl
+.include "../../devel/SDL/buildlink3.mk"
+.endif
diff --git a/emulators/pearpc/patches/patch-aa b/emulators/pearpc/patches/patch-aa
index ceacebdf044..815cdd2b968 100644
--- a/emulators/pearpc/patches/patch-aa
+++ b/emulators/pearpc/patches/patch-aa
@@ -1,7 +1,7 @@
-$NetBSD: patch-aa,v 1.1 2004/09/30 22:59:47 xtraeme Exp $
+$NetBSD: patch-aa,v 1.2 2005/12/22 19:27:36 ghen Exp $
---- src/system/osapi/posix/systimer.cc.orig 2004-10-01 00:35:34.000000000 +0200
-+++ src/system/osapi/posix/systimer.cc 2004-10-01 00:37:26.000000000 +0200
+--- src/system/osapi/posix/systimer.cc.orig 2005-12-21 14:43:21.000000000 +0100
++++ src/system/osapi/posix/systimer.cc
@@ -31,7 +31,11 @@
static const int kTimerSignal = SYSTIMER_SIGNAL;
#ifdef USE_POSIX_REALTIME_CLOCK
@@ -12,9 +12,9 @@ $NetBSD: patch-aa,v 1.1 2004/09/30 22:59:47 xtraeme Exp $
static const int kClockRT = CLOCK_PROCESS_CPUTIME_ID;
+# endif
static const int kClock = CLOCK_REALTIME;
- #else
- # ifdef USE_POSIX_SETITIMER
-@@ -70,7 +74,11 @@
+ #elif USE_POSIX_SETITIMER
+ static void signal_handler(int signo);
+@@ -70,7 +74,11 @@ struct sys_timer_struct
#ifdef USE_POSIX_REALTIME_CLOCK
static void signal_handler(int signo, siginfo_t *extra, void *junk)
{
diff --git a/emulators/pearpc/patches/patch-ab b/emulators/pearpc/patches/patch-ab
new file mode 100644
index 00000000000..430de336463
--- /dev/null
+++ b/emulators/pearpc/patches/patch-ab
@@ -0,0 +1,31 @@
+$NetBSD: patch-ab,v 1.1 2005/12/22 19:27:36 ghen Exp $
+
+--- src/cpu/cpu_jitc_x86/ppc_vec.cc.orig 2005-12-21 15:02:51.000000000 +0100
++++ src/cpu/cpu_jitc_x86/ppc_vec.cc
+@@ -6621,7 +6621,7 @@ void ppc_opc_vrfiz()
+ PPC_OPC_ASSERT(vrA==0);
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+- gCPU.vr[vrD].f[i] = truncf(gCPU.vr[vrD].f[i]);
++ gCPU.vr[vrD].f[i] = rint(gCPU.vr[vrD].f[i]);
+ }
+ }
+ JITCFlow ppc_opc_gen_vrfiz()
+@@ -6963,7 +6963,7 @@ void ppc_opc_vctsxs()
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+ ftmp = gCPU.vr[vrB].f[i] * (float)(1 << uimm);
+- ftmp = truncf(ftmp);
++ ftmp = rint(ftmp);
+
+ tmp = (sint32)ftmp;
+
+@@ -7061,7 +7061,7 @@ void ppc_opc_vctuxs()
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+ ftmp = gCPU.vr[vrB].f[i] * (float)(1 << uimm);
+- ftmp = truncf(ftmp);
++ ftmp = rint(ftmp);
+
+ tmp = (uint32)ftmp;
+
diff --git a/emulators/pearpc/patches/patch-ac b/emulators/pearpc/patches/patch-ac
new file mode 100644
index 00000000000..e98b337cea9
--- /dev/null
+++ b/emulators/pearpc/patches/patch-ac
@@ -0,0 +1,31 @@
+$NetBSD: patch-ac,v 1.1 2005/12/22 19:27:36 ghen Exp $
+
+--- src/cpu/cpu_generic/ppc_vec.cc.orig 2005-12-21 15:41:47.000000000 +0100
++++ src/cpu/cpu_generic/ppc_vec.cc
+@@ -2594,7 +2594,7 @@ void ppc_opc_vrfiz()
+ PPC_OPC_ASSERT(vrA==0);
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+- gCPU.vr[vrD].f[i] = truncf(gCPU.vr[vrD].f[i]);
++ gCPU.vr[vrD].f[i] = rint(gCPU.vr[vrD].f[i]);
+ }
+ }
+
+@@ -2726,7 +2726,7 @@ void ppc_opc_vctsxs()
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+ ftmp = gCPU.vr[vrB].f[i] * (float)(1 << uimm);
+- ftmp = truncf(ftmp);
++ ftmp = rint(ftmp);
+
+ tmp = (sint32)ftmp;
+
+@@ -2755,7 +2755,7 @@ void ppc_opc_vctuxs()
+
+ for (int i=0; i<4; i++) { //FIXME: This might not comply with Java FP
+ ftmp = gCPU.vr[vrB].f[i] * (float)(1 << uimm);
+- ftmp = truncf(ftmp);
++ ftmp = rint(ftmp);
+
+ tmp = (uint32)ftmp;
+
diff --git a/emulators/pearpc/patches/patch-ad b/emulators/pearpc/patches/patch-ad
new file mode 100644
index 00000000000..4fb5e0cd148
--- /dev/null
+++ b/emulators/pearpc/patches/patch-ad
@@ -0,0 +1,12 @@
+$NetBSD: patch-ad,v 1.1 2005/12/22 19:27:36 ghen Exp $
+
+--- src/system/osapi/posix/sysethtun.cc.orig 2005-12-21 15:01:35.000000000 +0100
++++ src/system/osapi/posix/sysethtun.cc
+@@ -33,6 +33,7 @@
+ #include <cstring>
+ #include <unistd.h>
+ #include <sys/wait.h>
++#include <sys/select.h>
+
+ #include "system/sysethtun.h"
+ #include "tools/snprintf.h"