2003-03-16 03:22:41 +00:00
|
|
|
dnl configure fragment for new libpthread implementation.
|
|
|
|
GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
|
|
|
|
|
|
|
|
if test "x$libc_cv_gcc___thread" != xyes; then
|
|
|
|
AC_MSG_ERROR(compiler support for __thread is required)
|
|
|
|
fi
|
2003-04-12 00:58:26 +00:00
|
|
|
|
2003-07-03 21:08:05 +00:00
|
|
|
if test "x$libc_cv_asm_cfi_directives" != xyes; then
|
|
|
|
AC_MSG_ERROR(CFI directive support in assembler is required)
|
|
|
|
fi
|
|
|
|
|
2003-04-12 00:58:26 +00:00
|
|
|
dnl Iff <unwind.h> is available, make sure it is the right one and it
|
|
|
|
dnl contains struct _Unwind_Exception.
|
|
|
|
AC_CACHE_CHECK(dnl
|
|
|
|
for forced unwind support, libc_cv_forced_unwind, [dnl
|
|
|
|
AC_TRY_LINK([#include <unwind.h>], [
|
|
|
|
struct _Unwind_Exception exc;
|
|
|
|
struct _Unwind_Context *context;
|
|
|
|
_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)
|
2003-06-29 23:01:49 +00:00
|
|
|
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
|
2003-04-12 00:58:26 +00:00
|
|
|
fi
|