[Glibc-bsd-commits] r1585 - in trunk/web/patches: . debian-only
upstream-only
Petr Salinger
ps-guest at costa.debian.org
Wed Jun 7 16:09:41 UTC 2006
Author: ps-guest
Date: 2006-06-07 16:09:39 +0000 (Wed, 07 Jun 2006)
New Revision: 1585
Added:
trunk/web/patches/debian-only/libgc_6.7.diff
Removed:
trunk/web/patches/gcc-3.4.java.diff
trunk/web/patches/libgc_6.3-1.diff
trunk/web/patches/libgc_6.7.diff
Modified:
trunk/web/patches/upstream-only/gcc.java_kfreebsd-gnu.diff
Log:
* boehm-gc (java) status update
Copied: trunk/web/patches/debian-only/libgc_6.7.diff (from rev 1583, trunk/web/patches/libgc_6.7.diff)
===================================================================
--- trunk/web/patches/libgc_6.7.diff 2006-06-06 16:15:14 UTC (rev 1583)
+++ trunk/web/patches/debian-only/libgc_6.7.diff 2006-06-07 16:09:39 UTC (rev 1585)
@@ -0,0 +1,149 @@
+
+
+
+Status: in BTS #366864, rerun of autoconf is needed; accepted by upstream for gc 6.8
+
+
+Note: applies almost cleanly also against gc 6.6 and boehm-gc in gcc-4.1
+
+
+diff -ur gc6.7/configure.in gc6.7/configure.in
+--- gc6.7/configure.in 2006-02-17 05:07:50.000000000 +0100
++++ gc6.7/configure.in 2006-05-11 18:58:59.000000000 +0200
+@@ -110,6 +110,17 @@
+ INCLUDES="$INCLUDES -pthread"
+ THREADDLLIBS=-pthread
+ ;;
++ *-*-kfreebsd*-gnu)
++ AC_DEFINE(GC_FREEBSD_THREADS)
++ INCLUDES="$INCLUDES -pthread"
++ THREADDLLIBS=-pthread
++ AC_DEFINE(_REENTRANT)
++ if test "${enable_parallel_mark}" = yes; then
++ AC_DEFINE(PARALLEL_MARK)
++ fi
++ AC_DEFINE(THREAD_LOCAL_ALLOC)
++ AC_DEFINE(USE_COMPILER_TLS)
++ ;;
+ *-*-netbsd*)
+ AC_MSG_WARN("Only on NetBSD 2.0 or later.")
+ AC_DEFINE(GC_NETBSD_THREADS)
+diff -ur gc6.7/dyn_load.c gc6.7/dyn_load.c
+--- gc6.7/dyn_load.c 2006-02-16 22:13:55.000000000 +0100
++++ gc6.7/dyn_load.c 2006-05-11 18:29:02.000000000 +0200
+@@ -26,7 +26,7 @@
+ * None of this is safe with dlclose and incremental collection.
+ * But then not much of anything is safe in the presence of dlclose.
+ */
+-#if defined(__linux__) && !defined(_GNU_SOURCE)
++#if (defined(__linux__) || defined(__GLIBC__)) && !defined(_GNU_SOURCE)
+ /* Can't test LINUX, since this must be define before other includes */
+ # define _GNU_SOURCE
+ #endif
+@@ -381,7 +381,7 @@
+ /* For glibc 2.2.4+. Unfortunately, it doesn't work for older */
+ /* versions. Thanks to Jakub Jelinek for most of the code. */
+
+-# if defined(LINUX) /* Are others OK here, too? */ \
++# if (defined(LINUX) || defined (__GLIBC__)) /* Are others OK here, too? */ \
+ && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \
+ || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG)))
+
+diff -ur gc6.7/include/gc.h gc6.7/include/gc.h
+--- gc6.7/include/gc.h 2006-02-18 02:03:40.000000000 +0100
++++ gc6.7/include/gc.h 2006-05-11 18:29:02.000000000 +0200
+@@ -469,7 +469,7 @@
+ # define GC_RETURN_ADDR (GC_word)__return_address
+ #endif
+
+-#ifdef __linux__
++#if defined(__linux__) || defined(__GLIBC__)
+ # include <features.h>
+ # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
+ && !defined(__ia64__)
+diff -ur gc6.7/include/private/gcconfig.h gc6.7/include/private/gcconfig.h
+--- gc6.7/include/private/gcconfig.h 2006-02-17 05:34:18.000000000 +0100
++++ gc6.7/include/private/gcconfig.h 2006-05-11 18:37:53.000000000 +0200
+@@ -55,7 +55,7 @@
+ # endif
+
+ /* And one for FreeBSD: */
+-# if defined(__FreeBSD__) && !defined(FREEBSD)
++# if (defined(__FreeBSD__) || defined(__FreeBSD_kernel__)) && !defined(FREEBSD)
+ # define FREEBSD
+ # endif
+
+@@ -1249,8 +1249,15 @@
+ # ifndef GC_FREEBSD_THREADS
+ # define MPROTECT_VDB
+ # endif
+-# define SIG_SUSPEND SIGUSR1
+-# define SIG_THR_RESTART SIGUSR2
++# ifdef __GLIBC__
++# define SIG_SUSPEND (32+6)
++# define SIG_THR_RESTART (32+5)
++ extern int _end[];
++# define DATAEND (_end)
++# else
++# define SIG_SUSPEND SIGUSR1
++# define SIG_THR_RESTART SIGUSR2
++# endif
+ # define FREEBSD_STACKBOTTOM
+ # ifdef __ELF__
+ # define DYNAMIC_LOADING
+@@ -1993,6 +2000,28 @@
+ # define PREFETCH_FOR_WRITE(x) __builtin_prefetch((x), 1)
+ # endif
+ # endif
++# ifdef FREEBSD
++# define OS_TYPE "FREEBSD"
++# ifndef GC_FREEBSD_THREADS
++# define MPROTECT_VDB
++# endif
++# ifdef __GLIBC__
++# define SIG_SUSPEND (32+6)
++# define SIG_THR_RESTART (32+5)
++ extern int _end[];
++# define DATAEND (_end)
++# else
++# define SIG_SUSPEND SIGUSR1
++# define SIG_THR_RESTART SIGUSR2
++# endif
++# define FREEBSD_STACKBOTTOM
++# ifdef __ELF__
++# define DYNAMIC_LOADING
++# endif
++ extern char etext[];
++ extern char * GC_FreeBSDGetDataStart();
++# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
++# endif
+ # ifdef NETBSD
+ # define OS_TYPE "NETBSD"
+ # ifdef __ELF__
+@@ -2064,7 +2093,7 @@
+ # define SUNOS5SIGS
+ # endif
+
+-# if defined(FREEBSD) && (__FreeBSD__ >= 4)
++# if defined(FREEBSD) && ((__FreeBSD__ >= 4) || (__FreeBSD_kernel__ >= 4))
+ # define SUNOS5SIGS
+ # endif
+
+@@ -2132,7 +2161,7 @@
+ # define CACHE_LINE_SIZE 32 /* Wild guess */
+ # endif
+
+-# ifdef LINUX
++# if defined(LINUX) || defined(__GLIBC__)
+ # define REGISTER_LIBRARIES_EARLY
+ /* We sometimes use dl_iterate_phdr, which may acquire an internal */
+ /* lock. This isn't safe after the world has stopped. So we must */
+@@ -2216,7 +2245,7 @@
+ #if defined(SPARC)
+ # define CAN_SAVE_CALL_ARGS
+ #endif
+-#if (defined(I386) || defined(X86_64)) && defined(LINUX)
++#if (defined(I386) || defined(X86_64)) && (defined(LINUX) || defined(__GLIBC__))
+ /* SAVE_CALL_CHAIN is supported if the code is compiled to save */
+ /* frame pointers by default, i.e. no -fomit-frame-pointer flag. */
+ # define CAN_SAVE_CALL_ARGS
Deleted: trunk/web/patches/gcc-3.4.java.diff
===================================================================
--- trunk/web/patches/gcc-3.4.java.diff 2006-06-06 20:14:56 UTC (rev 1584)
+++ trunk/web/patches/gcc-3.4.java.diff 2006-06-07 16:09:39 UTC (rev 1585)
@@ -1,341 +0,0 @@
-diff -u gcc-3.4.4/boehm-gc/configure gcc-3.4.4/boehm-gc/configure
---- gcc-3.4.4/boehm-gc/configure 2005-06-23 16:09:42.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/configure 2005-06-23 16:09:42.000000000 +0200
-@@ -2764,6 +2764,16 @@
- EOF
-
- ;;
-+ *-*-kfreebsd*)
-+ cat >> confdefs.h <<\EOF
-+#define GC_LINUX_THREADS_FIXME 1
-+EOF
-+
-+ cat >> confdefs.h <<\EOF
-+#define _REENTRANT 1
-+EOF
-+
-+ ;;
- *-*-aix*)
- cat >> confdefs.h <<\EOF
- #define GC_AIX_THREADS 1
-diff -u gcc-3.4.4/libjava/configure gcc-3.4.4/libjava/configure
---- gcc-3.4.4/libjava/configure 2005-06-23 16:09:41.000000000 +0200
-+++ gcc-3.4.4/libjava/configure 2005-06-23 16:09:41.000000000 +0200
-@@ -4451,7 +4451,7 @@
- posix | pthreads)
- THREADS=posix
- case "$host" in
-- *-*-linux*)
-+ *-*-linux* | *-*-kfreebsd*)
- cat >> confdefs.h <<\EOF
- #define LINUX_THREADS 1
- EOF
-@@ -5243,7 +5243,7 @@
-
- else
- case $host in
-- *-linux*)
-+ *-linux* | *-kfreebsd*)
- cat >> confdefs.h <<\EOF
- #define HAVE_PROC_SELF_EXE 1
- EOF
---- gcc-3.4.4.old/boehm-gc/configure.in 2005-02-22 20:00:37.000000000 +0100
-+++ gcc-3.4.4/boehm-gc/configure.in 2005-06-23 16:09:42.000000000 +0200
-@@ -86,6 +86,10 @@
- AC_DEFINE(GC_LINUX_THREADS)
- AC_DEFINE(_REENTRANT)
- ;;
-+ *-*-kfreebsd*)
-+ AC_DEFINE(GC_LINUX_THREADS)
-+ AC_DEFINE(_REENTRANT)
-+ ;;
- *-*-aix*)
- AC_DEFINE(GC_AIX_THREADS)
- AC_DEFINE(_REENTRANT)
---- gcc-3.4.4.old/boehm-gc/dbg_mlc.c 2003-07-28 06:18:20.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/dbg_mlc.c 2005-06-23 16:09:40.000000000 +0200
-@@ -59,7 +59,7 @@
-
- # include <stdlib.h>
-
--# if defined(LINUX) || defined(SUNOS4) || defined(SUNOS5) \
-+# if defined(LINUX) || defined(GLIBC) || defined(SUNOS4) || defined(SUNOS5) \
- || defined(HPUX) || defined(IRIX5) || defined(OSF1)
- # define RANDOM() random()
- # else
---- gcc-3.4.4.old/boehm-gc/dyn_load.c 2003-07-30 19:42:28.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/dyn_load.c 2005-06-23 16:09:40.000000000 +0200
-@@ -26,7 +26,8 @@
- * None of this is safe with dlclose and incremental collection.
- * But then not much of anything is safe in the presence of dlclose.
- */
--#if defined(__linux__) && !defined(_GNU_SOURCE)
-+#if (defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)) \
-+ && !defined(_GNU_SOURCE)
- /* Can't test LINUX, since this must be define before other includes */
- # define _GNU_SOURCE
- #endif
-@@ -56,7 +57,7 @@
- !(defined(ALPHA) && defined(OSF1)) && \
- !defined(HPUX) && !(defined(LINUX) && defined(__ELF__)) && \
- !defined(RS6000) && !defined(SCO_ELF) && !defined(DGUX) && \
-- !(defined(FREEBSD) && defined(__ELF__)) && \
-+ !(defined(KFREEBSD) && defined(__ELF__)) && \
- !(defined(NETBSD) && defined(__ELF__)) && !defined(HURD) && \
- !defined(DARWIN)
- --> We only know how to find data segments of dynamic libraries for the
-@@ -81,7 +82,7 @@
- #endif
-
- #if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
-- (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
-+ (defined(KFREEBSD) && defined(__ELF__)) || defined(DGUX) || \
- (defined(NETBSD) && defined(__ELF__)) || defined(HURD)
- # include <stddef.h>
- # include <elf.h>
-@@ -265,7 +266,7 @@
- # endif /* SUNOS */
-
- #if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
-- (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
-+ (defined(KFREEBSD) && defined(__ELF__)) || defined(DGUX) || \
- (defined(NETBSD) && defined(__ELF__)) || defined(HURD)
-
-
-@@ -360,7 +361,7 @@
- /* For glibc 2.2.4+. Unfortunately, it doesn't work for older */
- /* versions. Thanks to Jakub Jelinek for most of the code. */
-
--# if defined(LINUX) /* Are others OK here, too? */ \
-+# if defined(GLIBC) \
- && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \
- || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG)))
-
-@@ -434,7 +435,7 @@
-
- #define HAVE_REGISTER_MAIN_STATIC_DATA
-
--# else /* !LINUX || version(glibc) < 2.2.4 */
-+# else /* !GLIBC || version(glibc) < 2.2.4 */
-
- /* Dynamic loading code for Linux running ELF. Somewhat tested on
- * Linux/x86, untested but hopefully should work on Linux/Alpha.
---- gcc-3.4.4.old/boehm-gc/include/gc.h 2003-07-31 06:52:36.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/include/gc.h 2005-06-23 16:09:40.000000000 +0200
-@@ -466,7 +466,7 @@
- # define GC_RETURN_ADDR (GC_word)__return_address
- #endif
-
--#ifdef __linux__
-+#if defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
- # include <features.h>
- # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
- && !defined(__ia64__)
-@@ -490,7 +490,8 @@
- /* This may also be desirable if it is possible but expensive to */
- /* retrieve the call chain. */
- #if (defined(__linux__) || defined(__NetBSD__) || defined(__OpenBSD__) \
-- || defined(__FreeBSD__)) & !defined(GC_CAN_SAVE_CALL_STACKS)
-+ || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) \
-+ ) & !defined(GC_CAN_SAVE_CALL_STACKS)
- # define GC_ADD_CALLER
- # if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
- /* gcc knows how to retrieve return address, but we don't know */
---- gcc-3.4.4.old/boehm-gc/include/private/gcconfig.h 2005-04-19 00:23:46.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/include/private/gcconfig.h 2005-06-23 16:09:40.000000000 +0200
-@@ -44,6 +44,14 @@
- # endif
- # endif
-
-+/* And one for Glibc: */
-+#if defined(LINUX) || defined(__GNU__) || defined(__GLIBC__)
-+# include <features.h>
-+#endif
-+#ifdef __GLIBC__
-+# define GLIBC
-+#endif
-+
- /* And one for NetBSD: */
- # if defined(__NetBSD__)
- # define NETBSD
-@@ -58,6 +66,9 @@
- # if defined(__FreeBSD__)
- # define FREEBSD
- # endif
-+# if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
-+# define KFREEBSD
-+# endif
-
- /* Determine the machine type: */
- # if defined(__arm__) || defined(__thumb__)
-@@ -299,7 +310,7 @@
- # define OPENBSD
- # define mach_type_known
- # endif
--# if defined(FREEBSD) && (defined(i386) || defined(__i386__))
-+# if defined(KFREEBSD) && (defined(i386) || defined(__i386__))
- # define I386
- # define mach_type_known
- # endif
-@@ -1160,13 +1171,25 @@
- # endif
- # define SIG_SUSPEND SIGUSR1
- # define SIG_THR_RESTART SIGUSR2
-+ extern char etext[];
-+ extern char * GC_FreeBSDGetDataStart();
-+# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
-+# endif
-+# if defined(GLIBC) && defined(KFREEBSD)
-+# define OS_TYPE "GNU/kFreeBSD"
-+# if !defined(GC_LINUX_THREADS) && !defined(REDIRECT_MALLOC)
-+# define MPROTECT_VDB
-+# endif
-+# define SIG_SUSPEND 57 /* arbitrary signal number <= 128 */
-+# define SIG_THR_RESTART 58 /* arbitrary signal number <= 128 */
-+# define SEARCH_FOR_DATA_START
-+# define DATAEND (sbrk (0))
-+# endif
-+# ifdef KFREEBSD
- # define FREEBSD_STACKBOTTOM
- # ifdef __ELF__
- # define DYNAMIC_LOADING
- # endif
-- extern char etext[];
-- extern char * GC_FreeBSDGetDataStart();
--# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
- # endif
- # ifdef NETBSD
- # define OS_TYPE "NETBSD"
---- gcc-3.4.4.old/boehm-gc/os_dep.c 2005-04-19 00:23:45.000000000 +0200
-+++ gcc-3.4.4/boehm-gc/os_dep.c 2005-06-23 16:09:40.000000000 +0200
-@@ -80,7 +80,7 @@
- # define NEED_FIND_LIMIT
- # endif
-
--#if defined(FREEBSD) && defined(I386)
-+#if defined(KFREEBSD) && defined(I386)
- # include <machine/trap.h>
- # if !defined(PCR)
- # define NEED_FIND_LIMIT
-@@ -121,7 +121,7 @@
- # include <fcntl.h>
- #endif
-
--#if defined(SUNOS5SIGS) || defined (HURD) || defined(LINUX)
-+#if defined(SUNOS5SIGS) || defined(LINUX) || defined(GLIBC)
- # ifdef SUNOS5SIGS
- # include <sys/siginfo.h>
- # endif
-@@ -311,7 +311,7 @@
- /* for recent Linux versions. This seems to be the easiest way to */
- /* cover all versions. */
-
--# ifdef LINUX
-+# if defined(LINUX) || defined(GLIBC)
- /* Some Linux distributions arrange to define __data_start. Some */
- /* define data_start as a weak symbol. The latter is technically */
- /* broken, since the user program may define data_start, in which */
-@@ -321,7 +321,7 @@
- extern int __data_start[];
- # pragma weak data_start
- extern int data_start[];
--# endif /* LINUX */
-+# endif /* LINUX || GLIBC */
- extern int _end[];
-
- ptr_t GC_data_start;
-@@ -330,7 +330,7 @@
- {
- extern ptr_t GC_find_limit();
-
--# ifdef LINUX
-+# if defined(LINUX) || defined(GLIBC)
- /* Try the easy approaches first: */
- if ((ptr_t)__data_start != 0) {
- GC_data_start = (ptr_t)(__data_start);
-@@ -340,7 +340,7 @@
- GC_data_start = (ptr_t)(data_start);
- return;
- }
--# endif /* LINUX */
-+# endif /* LINUX || GLIBC */
- GC_data_start = GC_find_limit((ptr_t)(_end), FALSE);
- }
- #endif
-@@ -2184,13 +2184,13 @@
- #endif /* SUNOS4 || FREEBSD */
-
- #if defined(SUNOS5SIGS) || defined(OSF1) || defined(LINUX) \
-- || defined(HURD)
-+ || defined(GLIBC)
- # ifdef __STDC__
- typedef void (* SIG_PF)(int);
- # else
- typedef void (* SIG_PF)();
- # endif
--#endif /* SUNOS5SIGS || OSF1 || LINUX || HURD */
-+#endif /* SUNOS5SIGS || OSF1 || LINUX || GLIBC */
-
- #if defined(MSWIN32)
- typedef LPTOP_LEVEL_EXCEPTION_FILTER SIG_PF;
-@@ -2310,7 +2310,7 @@
-
- /*ARGSUSED*/
- #if !defined(DARWIN)
--# if defined (SUNOS4) || defined(FREEBSD)
-+# if defined (SUNOS4) || defined(KFREEBSD)
- void GC_write_fault_handler(sig, code, scp, addr)
- int sig, code;
- struct sigcontext *scp;
-@@ -2321,11 +2321,11 @@
- || (FC_CODE(code) == FC_OBJERR \
- && FC_ERRNO(code) == FC_PROT))
- # endif
--# ifdef FREEBSD
-+# ifdef KFREEBSD
- # define SIG_OK (sig == SIGBUS)
- # define CODE_OK (code == BUS_PAGE_FAULT)
- # endif
--# endif /* SUNOS4 || FREEBSD */
-+# endif /* SUNOS4 || KFREEBSD */
-
- # if defined(IRIX5) || defined(OSF1) || defined(HURD)
- # include <errno.h>
-@@ -3842,7 +3842,7 @@
- /* I suspect the following works for most X86 *nix variants, so */
- /* long as the frame pointer is explicitly stored. In the case of gcc, */
- /* compiler flags (e.g. -fomit-frame-pointer) determine whether it is. */
--#if defined(I386) && defined(LINUX) && defined(SAVE_CALL_CHAIN)
-+#if defined(I386) && (defined(LINUX) || defined(GLIBC)) && defined(SAVE_CALL_CHAIN)
- # include <features.h>
-
- struct frame {
-@@ -3853,7 +3853,7 @@
- #endif
-
- #if defined(SPARC)
--# if defined(LINUX)
-+# if defined(LINUX) || defined(GLIBC)
- # include <features.h>
-
- struct frame {
---- gcc-3.4.4.old/libjava/configure.in 2004-01-23 18:39:12.000000000 +0100
-+++ gcc-3.4.4/libjava/configure.in 2005-06-23 16:09:41.000000000 +0200
-@@ -482,7 +482,7 @@
- posix | pthreads)
- THREADS=posix
- case "$host" in
-- *-*-linux*)
-+ *-*-linux* | *-*-kfreebsd*)
- AC_DEFINE(LINUX_THREADS, 1, [Define if using POSIX threads on Linux.])
- ;;
- esac
-@@ -679,7 +679,7 @@
- AC_DEFINE(HAVE_PROC_SELF_EXE, 1, [Define if you have /proc/self/exe])])
- else
- case $host in
-- *-linux*)
-+ *-linux* | *-kfreebsd*)
- AC_DEFINE(HAVE_PROC_SELF_EXE, 1, [Define if you have /proc/self/exe])
- ;;
- esac
Deleted: trunk/web/patches/libgc_6.3-1.diff
===================================================================
--- trunk/web/patches/libgc_6.3-1.diff 2006-06-06 20:14:56 UTC (rev 1584)
+++ trunk/web/patches/libgc_6.3-1.diff 2006-06-07 16:09:39 UTC (rev 1585)
@@ -1,300 +0,0 @@
-
-Status: Submitted to upstream (Hans Boehm). Waiting for him to approve it
-before submuitting to gcc.
-
-diff -ur libgc-6.3.old/configure libgc-6.3/configure
---- libgc-6.3.old/configure 2004-07-20 01:51:50.000000000 +0200
-+++ libgc-6.3/configure 2004-07-20 02:00:20.000000000 +0200
-@@ -3953,6 +3953,12 @@
- _ACEOF
-
- ;;
-+ *-*-gnu* | *-*-k*bsd*-gnu)
-+ cat >>confdefs.h <<\_ACEOF
-+#define _REENTRANT 1
-+_ACEOF
-+
-+ ;;
- *-*-aix*)
- cat >>confdefs.h <<\_ACEOF
- #define GC_AIX_THREADS 1
-diff -ur libgc-6.3.old/configure.in libgc-6.3/configure.in
---- libgc-6.3.old/configure.in 2004-07-20 01:51:50.000000000 +0200
-+++ libgc-6.3/configure.in 2004-07-20 01:54:03.000000000 +0200
-@@ -89,6 +89,9 @@
- AC_DEFINE(GC_LINUX_THREADS)
- AC_DEFINE(_REENTRANT)
- ;;
-+ *-*-gnu* | *-*-k*bsd*-gnu)
-+ AC_DEFINE(_REENTRANT)
-+ ;;
- *-*-aix*)
- AC_DEFINE(GC_AIX_THREADS)
- AC_DEFINE(_REENTRANT)
-diff -ur libgc-6.3.old/dbg_mlc.c libgc-6.3/dbg_mlc.c
---- libgc-6.3.old/dbg_mlc.c 2004-04-23 01:51:56.000000000 +0200
-+++ libgc-6.3/dbg_mlc.c 2004-07-20 01:54:03.000000000 +0200
-@@ -59,7 +59,7 @@
-
- # include <stdlib.h>
-
--# if defined(LINUX) || defined(SUNOS4) || defined(SUNOS5) \
-+# if defined(LINUX) || defined(GLIBC) || defined(SUNOS4) || defined(SUNOS5) \
- || defined(HPUX) || defined(IRIX5) || defined(OSF1)
- # define RANDOM() random()
- # else
-diff -ur libgc-6.3.old/dyn_load.c libgc-6.3/dyn_load.c
---- libgc-6.3.old/dyn_load.c 2004-05-06 01:03:06.000000000 +0200
-+++ libgc-6.3/dyn_load.c 2004-07-20 01:54:03.000000000 +0200
-@@ -26,7 +26,8 @@
- * None of this is safe with dlclose and incremental collection.
- * But then not much of anything is safe in the presence of dlclose.
- */
--#if defined(__linux__) && !defined(_GNU_SOURCE)
-+#if (defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)) \
-+ && !defined(_GNU_SOURCE)
- /* Can't test LINUX, since this must be define before other includes */
- # define _GNU_SOURCE
- #endif
-@@ -56,7 +57,7 @@
- !(defined(ALPHA) && defined(OSF1)) && \
- !defined(HPUX) && !(defined(LINUX) && defined(__ELF__)) && \
- !defined(RS6000) && !defined(SCO_ELF) && !defined(DGUX) && \
-- !(defined(FREEBSD) && defined(__ELF__)) && \
-+ !(defined(KFREEBSD) && defined(__ELF__)) && \
- !(defined(NETBSD) && defined(__ELF__)) && !defined(HURD) && \
- !defined(DARWIN)
- --> We only know how to find data segments of dynamic libraries for the
-@@ -81,7 +82,7 @@
- #endif
-
- #if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
-- (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
-+ (defined(KFREEBSD) && defined(__ELF__)) || defined(DGUX) || \
- (defined(NETBSD) && defined(__ELF__)) || defined(HURD)
- # include <stddef.h>
- # include <elf.h>
-@@ -273,7 +274,7 @@
- # endif /* SUNOS */
-
- #if defined(LINUX) && defined(__ELF__) || defined(SCO_ELF) || \
-- (defined(FREEBSD) && defined(__ELF__)) || defined(DGUX) || \
-+ (defined(KFREEBSD) && defined(__ELF__)) || defined(DGUX) || \
- (defined(NETBSD) && defined(__ELF__)) || defined(HURD)
-
-
-@@ -368,7 +369,7 @@
- /* For glibc 2.2.4+. Unfortunately, it doesn't work for older */
- /* versions. Thanks to Jakub Jelinek for most of the code. */
-
--# if defined(LINUX) /* Are others OK here, too? */ \
-+# if defined(GLIBC) \
- && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \
- || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG)))
-
-@@ -442,7 +443,7 @@
-
- #define HAVE_REGISTER_MAIN_STATIC_DATA
-
--# else /* !LINUX || version(glibc) < 2.2.4 */
-+# else /* !GLIBC || version(glibc) < 2.2.4 */
-
- /* Dynamic loading code for Linux running ELF. Somewhat tested on
- * Linux/x86, untested but hopefully should work on Linux/Alpha.
-diff -ur libgc-6.3.old/include/gc.h libgc-6.3/include/gc.h
---- libgc-6.3.old/include/gc.h 2004-05-10 23:58:03.000000000 +0200
-+++ libgc-6.3/include/gc.h 2004-07-20 01:54:03.000000000 +0200
-@@ -465,7 +465,7 @@
- # define GC_RETURN_ADDR (GC_word)__return_address
- #endif
-
--#ifdef __linux__
-+#if defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
- # include <features.h>
- # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
- && !defined(__ia64__)
-@@ -494,7 +494,8 @@
- /* This may also be desirable if it is possible but expensive to */
- /* retrieve the call chain. */
- #if (defined(__linux__) || defined(__NetBSD__) || defined(__OpenBSD__) \
-- || defined(__FreeBSD__)) & !defined(GC_CAN_SAVE_CALL_STACKS)
-+ || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) \
-+ ) & !defined(GC_CAN_SAVE_CALL_STACKS)
- # define GC_ADD_CALLER
- # if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
- /* gcc knows how to retrieve return address, but we don't know */
-diff -ur libgc-6.3.old/include/private/gcconfig.h libgc-6.3/include/private/gcconfig.h
---- libgc-6.3.old/include/private/gcconfig.h 2004-05-06 01:10:54.000000000 +0200
-+++ libgc-6.3/include/private/gcconfig.h 2004-07-20 01:54:04.000000000 +0200
-@@ -44,6 +44,14 @@
- # endif
- # endif
-
-+/* And one for Glibc: */
-+#if defined(LINUX) || defined(__GNU__) || defined(__GLIBC__)
-+# include <features.h>
-+#endif
-+#ifdef __GLIBC__
-+# define GLIBC
-+#endif
-+
- /* And one for NetBSD: */
- # if defined(__NetBSD__)
- # define NETBSD
-@@ -58,6 +66,9 @@
- # if defined(__FreeBSD__)
- # define FREEBSD
- # endif
-+# if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
-+# define KFREEBSD
-+# endif
-
- /* Determine the machine type: */
- # if defined(__arm__) || defined(__thumb__)
-@@ -302,7 +313,7 @@
- # define OPENBSD
- # define mach_type_known
- # endif
--# if defined(FREEBSD) && (defined(i386) || defined(__i386__))
-+# if defined(KFREEBSD) && (defined(i386) || defined(__i386__))
- # define I386
- # define mach_type_known
- # endif
-@@ -1188,13 +1199,25 @@
- # endif
- # define SIG_SUSPEND SIGUSR1
- # define SIG_THR_RESTART SIGUSR2
-+ extern char etext[];
-+ extern char * GC_FreeBSDGetDataStart();
-+# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
-+# endif
-+# if defined(GLIBC) && defined(KFREEBSD)
-+# define OS_TYPE "GNU/kFreeBSD"
-+# if !defined(GC_LINUX_THREADS) && !defined(REDIRECT_MALLOC)
-+# define MPROTECT_VDB
-+# endif
-+# define SIG_SUSPEND 57 /* arbitrary signal number <= 128 */
-+# define SIG_THR_RESTART 58 /* arbitrary signal number <= 128 */
-+# define SEARCH_FOR_DATA_START
-+# define DATAEND (sbrk (0))
-+# endif
-+# ifdef KFREEBSD
- # define FREEBSD_STACKBOTTOM
- # ifdef __ELF__
- # define DYNAMIC_LOADING
- # endif
-- extern char etext[];
-- extern char * GC_FreeBSDGetDataStart();
--# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
- # endif
- # ifdef NETBSD
- # define OS_TYPE "NETBSD"
-diff -ur libgc-6.3.old/os_dep.c libgc-6.3/os_dep.c
---- libgc-6.3.old/os_dep.c 2004-07-07 21:16:28.000000000 +0200
-+++ libgc-6.3/os_dep.c 2004-07-20 01:56:20.000000000 +0200
-@@ -80,7 +80,7 @@
- # define NEED_FIND_LIMIT
- # endif
-
--#if defined(FREEBSD) && defined(I386)
-+#if defined(KFREEBSD) && defined(I386)
- # include <machine/trap.h>
- # if !defined(PCR)
- # define NEED_FIND_LIMIT
-@@ -129,7 +129,7 @@
-
- #ifdef UNIX_LIKE
- # include <fcntl.h>
--# if defined(SUNOS5SIGS) && !defined(FREEBSD)
-+# if defined(SUNOS5SIGS) && !defined(KFREEBSD)
- # include <sys/siginfo.h>
- # endif
- /* Define SETJMP and friends to be the version that restores */
-@@ -318,7 +318,7 @@
- /* for recent Linux versions. This seems to be the easiest way to */
- /* cover all versions. */
-
--# ifdef LINUX
-+# if defined(LINUX) || defined(GLIBC)
- /* Some Linux distributions arrange to define __data_start. Some */
- /* define data_start as a weak symbol. The latter is technically */
- /* broken, since the user program may define data_start, in which */
-@@ -328,7 +328,7 @@
- extern int __data_start[];
- # pragma weak data_start
- extern int data_start[];
--# endif /* LINUX */
-+# endif /* LINUX || GLIBC */
- extern int _end[];
-
- ptr_t GC_data_start;
-@@ -337,7 +337,7 @@
- {
- extern ptr_t GC_find_limit();
-
--# ifdef LINUX
-+# if defined(LINUX) || defined(GLIBC)
- /* Try the easy approaches first: */
- if ((ptr_t)__data_start != 0) {
- GC_data_start = (ptr_t)(__data_start);
-@@ -347,7 +347,7 @@
- GC_data_start = (ptr_t)(data_start);
- return;
- }
--# endif /* LINUX */
-+# endif /* LINUX || GLIBC */
- GC_data_start = GC_find_limit((ptr_t)(_end), FALSE);
- }
- #endif
-@@ -2230,13 +2230,13 @@
- #endif /* SUNOS4 || (FREEBSD && !SUNOS5SIGS) */
-
- #if defined(SUNOS5SIGS) || defined(OSF1) || defined(LINUX) \
-- || defined(HURD)
-+ || defined(GLIBC)
- # ifdef __STDC__
- typedef void (* SIG_PF)(int);
- # else
- typedef void (* SIG_PF)();
- # endif
--#endif /* SUNOS5SIGS || OSF1 || LINUX || HURD */
-+#endif /* SUNOS5SIGS || OSF1 || LINUX || GLIBC */
-
- #if defined(MSWIN32)
- typedef LPTOP_LEVEL_EXCEPTION_FILTER SIG_PF;
-@@ -2359,7 +2359,7 @@
-
- /*ARGSUSED*/
- #if !defined(DARWIN)
--# if defined (SUNOS4) || (defined(FREEBSD) && !defined(SUNOS5SIGS))
-+# if defined (SUNOS4) || (defined(KFREEBSD) && !defined(SUNOS5SIGS))
- void GC_write_fault_handler(sig, code, scp, addr)
- int sig, code;
- struct sigcontext *scp;
-@@ -2370,7 +2370,7 @@
- || (FC_CODE(code) == FC_OBJERR \
- && FC_ERRNO(code) == FC_PROT))
- # endif
--# ifdef FREEBSD
-+# ifdef KFREEBSD
- # define SIG_OK (sig == SIGBUS)
- # define CODE_OK (code == BUS_PAGE_FAULT)
- # endif
-@@ -3908,7 +3908,7 @@
- /* I suspect the following works for most X86 *nix variants, so */
- /* long as the frame pointer is explicitly stored. In the case of gcc, */
- /* compiler flags (e.g. -fomit-frame-pointer) determine whether it is. */
--#if defined(I386) && defined(LINUX) && defined(SAVE_CALL_CHAIN)
-+#if defined(I386) && (defined(LINUX) || defined(GLIBC)) && defined(SAVE_CALL_CHAIN)
- # include <features.h>
-
- struct frame {
-@@ -3919,7 +3919,7 @@
- #endif
-
- #if defined(SPARC)
--# if defined(LINUX)
-+# if defined(LINUX) || defined(GLIBC)
- # include <features.h>
-
- struct frame {
Deleted: trunk/web/patches/libgc_6.7.diff
===================================================================
--- trunk/web/patches/libgc_6.7.diff 2006-06-06 20:14:56 UTC (rev 1584)
+++ trunk/web/patches/libgc_6.7.diff 2006-06-07 16:09:39 UTC (rev 1585)
@@ -1,146 +0,0 @@
-
-Status: in BTS #366864, rerun of autoconf is needed
-
-Note: applies almost cleanly also against gc 6.6 and boehm-gc in gcc-4.1
-
-
-diff -ur gc6.7/configure.in gc6.7/configure.in
---- gc6.7/configure.in 2006-02-17 05:07:50.000000000 +0100
-+++ gc6.7/configure.in 2006-05-11 18:58:59.000000000 +0200
-@@ -110,6 +110,17 @@
- INCLUDES="$INCLUDES -pthread"
- THREADDLLIBS=-pthread
- ;;
-+ *-*-kfreebsd*-gnu)
-+ AC_DEFINE(GC_FREEBSD_THREADS)
-+ INCLUDES="$INCLUDES -pthread"
-+ THREADDLLIBS=-pthread
-+ AC_DEFINE(_REENTRANT)
-+ if test "${enable_parallel_mark}" = yes; then
-+ AC_DEFINE(PARALLEL_MARK)
-+ fi
-+ AC_DEFINE(THREAD_LOCAL_ALLOC)
-+ AC_DEFINE(USE_COMPILER_TLS)
-+ ;;
- *-*-netbsd*)
- AC_MSG_WARN("Only on NetBSD 2.0 or later.")
- AC_DEFINE(GC_NETBSD_THREADS)
-diff -ur gc6.7/dyn_load.c gc6.7/dyn_load.c
---- gc6.7/dyn_load.c 2006-02-16 22:13:55.000000000 +0100
-+++ gc6.7/dyn_load.c 2006-05-11 18:29:02.000000000 +0200
-@@ -26,7 +26,7 @@
- * None of this is safe with dlclose and incremental collection.
- * But then not much of anything is safe in the presence of dlclose.
- */
--#if defined(__linux__) && !defined(_GNU_SOURCE)
-+#if (defined(__linux__) || defined(__GLIBC__)) && !defined(_GNU_SOURCE)
- /* Can't test LINUX, since this must be define before other includes */
- # define _GNU_SOURCE
- #endif
-@@ -381,7 +381,7 @@
- /* For glibc 2.2.4+. Unfortunately, it doesn't work for older */
- /* versions. Thanks to Jakub Jelinek for most of the code. */
-
--# if defined(LINUX) /* Are others OK here, too? */ \
-+# if (defined(LINUX) || defined (__GLIBC__)) /* Are others OK here, too? */ \
- && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \
- || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG)))
-
-diff -ur gc6.7/include/gc.h gc6.7/include/gc.h
---- gc6.7/include/gc.h 2006-02-18 02:03:40.000000000 +0100
-+++ gc6.7/include/gc.h 2006-05-11 18:29:02.000000000 +0200
-@@ -469,7 +469,7 @@
- # define GC_RETURN_ADDR (GC_word)__return_address
- #endif
-
--#ifdef __linux__
-+#if defined(__linux__) || defined(__GLIBC__)
- # include <features.h>
- # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
- && !defined(__ia64__)
-diff -ur gc6.7/include/private/gcconfig.h gc6.7/include/private/gcconfig.h
---- gc6.7/include/private/gcconfig.h 2006-02-17 05:34:18.000000000 +0100
-+++ gc6.7/include/private/gcconfig.h 2006-05-11 18:37:53.000000000 +0200
-@@ -55,7 +55,7 @@
- # endif
-
- /* And one for FreeBSD: */
--# if defined(__FreeBSD__) && !defined(FREEBSD)
-+# if (defined(__FreeBSD__) || defined(__FreeBSD_kernel__)) && !defined(FREEBSD)
- # define FREEBSD
- # endif
-
-@@ -1249,8 +1249,15 @@
- # ifndef GC_FREEBSD_THREADS
- # define MPROTECT_VDB
- # endif
--# define SIG_SUSPEND SIGUSR1
--# define SIG_THR_RESTART SIGUSR2
-+# ifdef __GLIBC__
-+# define SIG_SUSPEND (32+6)
-+# define SIG_THR_RESTART (32+5)
-+ extern int _end[];
-+# define DATAEND (_end)
-+# else
-+# define SIG_SUSPEND SIGUSR1
-+# define SIG_THR_RESTART SIGUSR2
-+# endif
- # define FREEBSD_STACKBOTTOM
- # ifdef __ELF__
- # define DYNAMIC_LOADING
-@@ -1993,6 +2000,28 @@
- # define PREFETCH_FOR_WRITE(x) __builtin_prefetch((x), 1)
- # endif
- # endif
-+# ifdef FREEBSD
-+# define OS_TYPE "FREEBSD"
-+# ifndef GC_FREEBSD_THREADS
-+# define MPROTECT_VDB
-+# endif
-+# ifdef __GLIBC__
-+# define SIG_SUSPEND (32+6)
-+# define SIG_THR_RESTART (32+5)
-+ extern int _end[];
-+# define DATAEND (_end)
-+# else
-+# define SIG_SUSPEND SIGUSR1
-+# define SIG_THR_RESTART SIGUSR2
-+# endif
-+# define FREEBSD_STACKBOTTOM
-+# ifdef __ELF__
-+# define DYNAMIC_LOADING
-+# endif
-+ extern char etext[];
-+ extern char * GC_FreeBSDGetDataStart();
-+# define DATASTART GC_FreeBSDGetDataStart(0x1000, &etext)
-+# endif
- # ifdef NETBSD
- # define OS_TYPE "NETBSD"
- # ifdef __ELF__
-@@ -2064,7 +2093,7 @@
- # define SUNOS5SIGS
- # endif
-
--# if defined(FREEBSD) && (__FreeBSD__ >= 4)
-+# if defined(FREEBSD) && ((__FreeBSD__ >= 4) || (__FreeBSD_kernel__ >= 4))
- # define SUNOS5SIGS
- # endif
-
-@@ -2132,7 +2161,7 @@
- # define CACHE_LINE_SIZE 32 /* Wild guess */
- # endif
-
--# ifdef LINUX
-+# if defined(LINUX) || defined(__GLIBC__)
- # define REGISTER_LIBRARIES_EARLY
- /* We sometimes use dl_iterate_phdr, which may acquire an internal */
- /* lock. This isn't safe after the world has stopped. So we must */
-@@ -2216,7 +2245,7 @@
- #if defined(SPARC)
- # define CAN_SAVE_CALL_ARGS
- #endif
--#if (defined(I386) || defined(X86_64)) && defined(LINUX)
-+#if (defined(I386) || defined(X86_64)) && (defined(LINUX) || defined(__GLIBC__))
- /* SAVE_CALL_CHAIN is supported if the code is compiled to save */
- /* frame pointers by default, i.e. no -fomit-frame-pointer flag. */
- # define CAN_SAVE_CALL_ARGS
Modified: trunk/web/patches/upstream-only/gcc.java_kfreebsd-gnu.diff
===================================================================
--- trunk/web/patches/upstream-only/gcc.java_kfreebsd-gnu.diff 2006-06-06 20:14:56 UTC (rev 1584)
+++ trunk/web/patches/upstream-only/gcc.java_kfreebsd-gnu.diff 2006-06-07 16:09:39 UTC (rev 1585)
@@ -1,7 +1,8 @@
-
shlibs changes submitted to http://gcc.gnu.org/ml/java-patches/2006-q2/msg00193.html
-boehm-gc changes submitted to http://www.hpl.hp.com/hosted/linux/mail-archives/gc/2006-May/001308.html
+boehm-gc changes submitted to http://www.hpl.hp.com/hosted/linux/mail-archives/gc/2006-May/001308.html, accepted
+boehm-gc changes submitted to http://gcc.gnu.org/ml/java-patches/2006-q2/msg00320.html
+
More information about the Glibc-bsd-commits
mailing list