summaryrefslogtreecommitdiffhomepage
path: root/patches
diff options
context:
space:
mode:
authorLucio Andrés Illanes Albornoz <lucio@lucioillanes.de>2020-07-06 19:46:20 +0100
committerLucio Andrés Illanes Albornoz <lucio@lucioillanes.de>2020-07-06 19:46:20 +0100
commit61f3f43be97e5046f8dcd582452b8c6dde4d891c (patch)
treee005804ae0fdaf5732fb7e4428bff434376bcbd9 /patches
parente22af77276eae62eebc5f6b7faf4ff6c835311d2 (diff)
downloadmidipix_build-61f3f43be97e5046f8dcd582452b8c6dde4d891c.tar.bz2
midipix_build-61f3f43be97e5046f8dcd582452b8c6dde4d891c.tar.xz
patches/bdwgc.local.patch: updated (via Redfoxmoon.)
Diffstat (limited to 'patches')
-rw-r--r--patches/bdwgc.local.patch82
1 files changed, 35 insertions, 47 deletions
diff --git a/patches/bdwgc.local.patch b/patches/bdwgc.local.patch
index 62b52c87..ede786e7 100644
--- a/patches/bdwgc.local.patch
+++ b/patches/bdwgc.local.patch
@@ -1,18 +1,30 @@
-diff -ru bdwgc.orig/include/private/gcconfig.h bdwgc/include/private/gcconfig.h
---- bdwgc.orig/include/private/gcconfig.h 2019-04-25 16:08:37.996677359 +0200
-+++ bdwgc/include/private/gcconfig.h 2019-04-25 16:22:53.456682549 +0200
-@@ -109,6 +109,10 @@
+diff --git a/include/private/gcconfig.h b/include/private/gcconfig.h
+index b342883..174dd88 100644
+--- a/include/private/gcconfig.h
++++ b/include/private/gcconfig.h
+@@ -109,6 +109,21 @@ EXTERN_C_BEGIN
# define LINUX
# endif
+# if defined(__midipix__)
+# define MIDIPIX
++
++# include <fcntl.h>
++# include <sys/select.h>
++
++# include <psxtypes/psxtypes.h>
++# include <pemagine/pemagine.h>
++# include <ntapi/nt_thread.h>
++
++ int __gc_data_start_mark__[1];
++ int __gc_data_end_mark__[1];
++
+# endif
+
/* And one for NetBSD: */
# if defined(__NetBSD__)
# define NETBSD
-@@ -345,6 +349,16 @@
+@@ -350,6 +359,16 @@ EXTERN_C_BEGIN
# define X86_64
# define mach_type_known
# endif
@@ -29,64 +41,40 @@ diff -ru bdwgc.orig/include/private/gcconfig.h bdwgc/include/private/gcconfig.h
# if defined(LINUX) && (defined(i386) || defined(__i386__))
# define I386
# define mach_type_known
-@@ -1538,6 +1552,12 @@
+@@ -1542,6 +1561,13 @@ EXTERN_C_BEGIN
EXTERN_C_BEGIN
# endif
# endif
+# ifdef MIDIPIX
+# define OS_TYPE "MIDIPIX"
-+# define DATASTART (ptr_t)NULL /* Wrong */
-+# define DATAEND (ptr_t)NULL /* Wrong */
-+# define STACKBOTTOM (ptr_t)0x000000 /* Not sure if we should be using STACKBOTTOM or LINUX_STACK... */
++# define DATASTART ((ptr_t)__gc_data_start_mark__)
++# define DATAEND ((ptr_t)__gc_data_end_mark__)
++# define STACKBOTTOM (ptr_t)(((nt_tib *)pe_get_teb_address())->stack_base)
++# define USE_MMAP_ANON
+# endif
# ifdef CYGWIN32
# define OS_TYPE "CYGWIN32"
- # define DATASTART ((ptr_t)GC_DATASTART) /* From gc.h */
-@@ -2656,6 +2676,12 @@
+ # define WOW64_THREAD_CONTEXT_WORKAROUND
+@@ -2706,6 +2732,13 @@ EXTERN_C_BEGIN
EXTERN_C_BEGIN
# endif
# endif
+# ifdef MIDIPIX
+# define OS_TYPE "MIDIPIX"
-+# define DATASTART (ptr_t)NULL /* Wrong */
-+# define DATAEND (ptr_t)NULL /* Wrong */
-+# define STACKBOTTOM (ptr_t)0x000000 /* Not sure if we should be using STACKBOTTOM or LINUX_STACK... */
++# define DATASTART ((ptr_t)__gc_data_start_mark__)
++# define DATAEND ((ptr_t)__gc_data_end_mark__)
++# define STACKBOTTOM (ptr_t)(((nt_tib *)pe_get_teb_address())->stack_base)
++# define USE_MMAP_ANON
+# endif
# ifdef DARWIN
# define OS_TYPE "DARWIN"
# define DARWIN_DONT_PARSE_STACK 1
-@@ -3259,7 +3285,7 @@
- # if defined(GC_IRIX_THREADS) && !defined(IRIX5)
- # error Inconsistent configuration
- # endif
--# if defined(GC_LINUX_THREADS) && !defined(LINUX) && !defined(NACL)
-+# if defined(GC_LINUX_THREADS) && !defined(LINUX) && !defined(NACL) && !defined(MIDIPIX)
- # error Inconsistent configuration
- # endif
- # if defined(GC_NETBSD_THREADS) && !defined(NETBSD)
-diff -ru bdwgc.orig/os_dep.c bdwgc/os_dep.c
---- bdwgc.orig/os_dep.c 2019-04-25 16:08:38.000677359 +0200
-+++ bdwgc/os_dep.c 2019-04-25 16:11:21.272678349 +0200
-@@ -33,7 +33,7 @@
+@@ -3111,7 +3144,7 @@ EXTERN_C_BEGIN
+ #if defined(SVR4) || defined(LINUX) || defined(IRIX5) || defined(HPUX) \
+ || defined(OPENBSD) || defined(NETBSD) || defined(FREEBSD) \
+ || defined(DGUX) || defined(BSD) || defined(HAIKU) || defined(HURD) \
+- || defined(AIX) || defined(DARWIN) || defined(OSF1)
++ || defined(AIX) || defined(DARWIN) || defined(OSF1) || defined(MIDIPIX)
+ # define UNIX_LIKE /* Basic Unix-like system calls work. */
#endif
- #if defined(UNIX_LIKE) || defined(CYGWIN32) || defined(NACL) \
-- || defined(SYMBIAN)
-+ || defined(SYMBIAN) || defined(MIDIPIX)
- # include <fcntl.h>
- #endif
-
-diff -ru bdwgc.orig/pthread_stop_world.c bdwgc/pthread_stop_world.c
---- bdwgc.orig/pthread_stop_world.c 2019-04-25 16:08:38.000677359 +0200
-+++ bdwgc/pthread_stop_world.c 2019-04-25 16:23:19.820682709 +0200
-@@ -21,6 +21,10 @@
- !defined(GC_DARWIN_THREADS) && !defined(SN_TARGET_ORBIS) \
- && !defined(SN_TARGET_PSP2)
-
-+#ifdef MIDIPIX
-+# include <sys/select.h>
-+#endif
-+
- #ifdef NACL
-
- # include <unistd.h>