diff options
author | Ulrich Drepper <drepper@redhat.com> | 2003-06-29 23:01:49 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2003-06-29 23:01:49 +0000 |
commit | e479cc8e4c2297c6d1f190192bd8038b1b7e99d2 (patch) | |
tree | 81d6c0a114ebbaa390559c3247bd9c1dce8a0015 /nptl/sysdeps/pthread/configure.in | |
parent | 5245d8a1fe962ee93d81e305e8fa249ee8a6b354 (diff) | |
download | glibc-e479cc8e4c2297c6d1f190192bd8038b1b7e99d2.tar.gz |
Update.
2003-06-29 Ulrich Drepper <drepper@redhat.com>
* sysdeps/pthread/configure.in: Check for C cleanup handling in gcc.
Diffstat (limited to 'nptl/sysdeps/pthread/configure.in')
-rw-r--r-- | nptl/sysdeps/pthread/configure.in | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/nptl/sysdeps/pthread/configure.in b/nptl/sysdeps/pthread/configure.in index e4ea6830d6..922741e723 100644 --- a/nptl/sysdeps/pthread/configure.in +++ b/nptl/sysdeps/pthread/configure.in @@ -16,4 +16,19 @@ _Unwind_GetCFA (context)], libc_cv_forced_unwind=yes, libc_cv_forced_unwind=no)]) if test $libc_cv_forced_unwind = yes; then AC_DEFINE(HAVE_FORCED_UNWIND) +dnl Check for C cleanup handling. + old_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Werror -fexceptions" + AC_CACHE_CHECK([for C cleanup handling], libc_cv_c_cleanup, [dnl + AC_TRY_LINK([ +#include <stdio.h> +void cl (void *a) { } +extern c (void);], [ + int a __attribute__ ((cleanup (cl))); + puts ("test")], +libc_cv_c_cleanup=yes, libc_cv_c_cleanup=no)]) + CFLAGS="$old_CFLAGS" + if test $libc_cv_c_cleanup = no; then + AC_MSG_ERROR([the compiler must support C cleanup handling]) + fi fi |