[m-dev.] diff: Fix for boehm_gc using glibc 2.1

Peter Ross petdr at cs.mu.OZ.AU
Tue Jun 15 17:31:23 AEST 1999


Hi,


===================================================================


Estimated hours taken: 0.5

Fix a bug with glibc 2.1 on linux machines.

boehm_gc/os_dep.c:
    Make sure the correct sigcontext.h gets included depending on
    which version of glibc we are using.


Index: os_dep.c
===================================================================
RCS file: /home/staff/zs/imp/mercury/boehm_gc/os_dep.c,v
retrieving revision 1.20
diff -u -b -r1.20 os_dep.c
--- os_dep.c	1998/10/02 05:35:36	1.20
+++ os_dep.c	1999/06/15 07:27:43
@@ -34,7 +34,12 @@
       /* make sure the former gets defined to be the latter if appropriate. */
 #     include <features.h>
 #     if 2 <= __GLIBC__
-#       include <sigcontext.h>
+#       if 0 == __GLIBC_MINOR__
+#         include <sigcontext.h>
+#       else
+			/* It appears to have disappeared again in glibc 2.1 */
+#         include <asm/sigcontext.h>
+#       endif
 #     else /* not 2 <= __GLIBC__ */
         /* libc5 doesn't have <sigcontext.h>: go directly with the kernel   */
         /* one.  Check LINUX_VERSION_CODE to see which we should reference. */

----
 +----------------------------------------------------------------------+
 | Peter Ross      M Sci/Eng Melbourne Uni                              |
 | petdr at cs.mu.oz.au  WWW: www.cs.mu.oz.au/~petdr/ ph: +61 3 9344 9158  |
 +----------------------------------------------------------------------+
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list