summaryrefslogtreecommitdiff
path: root/libguile/gen-scmconfig.c
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2011-03-29 13:21:44 +0200
committerAndy Wingo <wingo@pobox.com>2011-03-29 13:21:44 +0200
commit8cf49d836ff41838812cba1fd61bfce3fb877144 (patch)
tree18122aecc92e42ad9baab53933216210dc770e92 /libguile/gen-scmconfig.c
parentfb6df3ea137eabad25d70219da2c84282883b433 (diff)
downloadguile-8cf49d836ff41838812cba1fd61bfce3fb877144.tar.gz
fix compilation with libgc 7.0, 7.1
* configure.ac: Check for GC_pthread_exit and GC_pthread_cancel. * libguile/gen-scmconfig.c: Write HAVE_GC_PTHREAD_CANCEL and HAVE_GC_PTHREAD_EXIT into scmconfig.h. * libguile/pthread-threads.h (scm_i_pthread_exit, scm_i_pthread_cancel): Only redefine to their GC_pthread_* variants if we have those functions, which is not the case in libgc < 7.2.
Diffstat (limited to 'libguile/gen-scmconfig.c')
-rw-r--r--libguile/gen-scmconfig.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/libguile/gen-scmconfig.c b/libguile/gen-scmconfig.c
index 02633563d..97066b78e 100644
--- a/libguile/gen-scmconfig.c
+++ b/libguile/gen-scmconfig.c
@@ -318,6 +318,18 @@ main (int argc, char *argv[])
pf ("#define SCM_NEED_BRACES_ON_PTHREAD_MUTEX_INITIALIZER %d /* 0 or 1 */\n",
SCM_I_GSC_NEED_BRACES_ON_PTHREAD_MUTEX_INITIALIZER);
+#ifdef HAVE_GC_PTHREAD_CANCEL
+ pf ("#define SCM_HAVE_GC_PTHREAD_CANCEL 1 /* 0 or 1 */\n");
+#else
+ pf ("#define SCM_HAVE_GC_PTHREAD_CANCEL 0 /* 0 or 1 */\n");
+#endif
+
+#ifdef HAVE_GC_PTHREAD_EXIT
+ pf ("#define SCM_HAVE_GC_PTHREAD_EXIT 1 /* 0 or 1 */\n");
+#else
+ pf ("#define SCM_HAVE_GC_PTHREAD_EXIT 0 /* 0 or 1 */\n");
+#endif
+
pf ("\n\n/*** File system access ***/\n");
pf ("/* Define to 1 if `struct dirent64' is available. */\n");