fix behaviour on 64bit arches, based on patches from FreeBSD;

tested and ok sturm@.
This commit is contained in:
xsa 2004-06-03 07:52:30 +00:00
parent b4dd4e0130
commit b88c663474
3 changed files with 44 additions and 0 deletions

View File

@ -0,0 +1,20 @@
$OpenBSD: patch-cpubench_c,v 1.1 2004/06/03 07:52:30 xsa Exp $
--- cpubench.c.orig 2000-05-29 05:21:13.000000000 +0200
+++ cpubench.c 2004-06-03 09:40:21.000000000 +0200
@@ -25,6 +25,7 @@
#include <sys/types.h>
#include <sys/times.h>
#include <stdio.h>
+#include <stdlib.h>
#include <unistd.h>
#include <signal.h>
#include <setjmp.h>
@@ -41,7 +42,7 @@ extern char *_sys_errlist[];
#define sys_errlist _sys_errlist
#endif
-#ifdef SunOS
+#if defined(SunOS) || defined(__OpenBSD__)
extern sigjmp_buf env;
#else
extern jmp_buf env;

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-membench_c,v 1.1 2004/06/03 07:52:30 xsa Exp $
--- membench.c.orig 2000-07-31 19:23:27.000000000 +0200
+++ membench.c 2004-06-03 09:40:49.000000000 +0200
@@ -42,7 +42,7 @@ extern char *_sys_errlist[];
#define sys_errlist _sys_errlist
#endif
-#ifdef SunOS
+#if defined(SunOS) || defined(__OpenBSD__)
extern sigjmp_buf env;
#else
extern jmp_buf env;

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-signals_c,v 1.1 2004/06/03 07:52:30 xsa Exp $
--- signals.c.orig 2000-05-29 05:16:05.000000000 +0200
+++ signals.c 2004-06-03 09:41:21.000000000 +0200
@@ -22,7 +22,7 @@
#include <signal.h>
#include <setjmp.h>
-#ifdef SunOS
+#if defined(SunOS) || defined(__OpenBSD__)
sigjmp_buf env;
#else
jmp_buf env;