+diff -u boehm-gc/mach_dep.c boehm-gc/mach_dep.c
+--- boehm-gc/mach_dep.c Thu Jul 18 13:06:00 2002
++++ boehm-gc/mach_dep.c Tue Jan 20 17:00:36 2004
+@@ -368,9 +368,13 @@
+ # if defined(PJ)
+ {
+ register int * sp asm ("optop");
++#ifdef LINUX
++ extern ptr_t GC_linux_stack_base(void);
++ GC_push_all_stack (sp, GC_linux_stack_base());
++#elseif
+ extern int *__libc_stack_end;
+-
+ GC_push_all_stack (sp, __libc_stack_end);
++#endif
+ }
+ # endif
+
+diff -u boehm-gc/os_dep.c boehm-gc/os_dep.c
+--- boehm-gc/os_dep.c Fri Jul 19 01:54:43 2002
++++ boehm-gc/os_dep.c Tue Jan 20 16:59:10 2004
+@@ -666,8 +666,8 @@
+ # define STAT_SKIP 27 /* Number of fields preceding startstack */
+ /* field in /proc/self/stat */
+
+-# pragma weak __libc_stack_end
+- extern ptr_t __libc_stack_end;
++//# pragma weak __libc_stack_end
++// extern ptr_t __libc_stack_end;
+
+ # ifdef IA64
+ # pragma weak __libc_ia64_register_backing_store_base
+@@ -709,9 +709,11 @@
+ size_t i, buf_offset = 0;
+
+ /* First try the easy way. This should work for glibc 2.2 */
++ /*
+ if (0 != &__libc_stack_end) {
+ return __libc_stack_end;
+ }
++ */
+ f = open("/proc/self/stat", O_RDONLY);
+ if (f < 0 || STAT_READ(f, stat_buf, STAT_BUF_SIZE) < 2 * STAT_SKIP) {
+ ABORT("Couldn't read /proc/self/stat");
+