Updated to fedora-glibc-20071010T2047
[glibc.git] / nptl / sysdeps / pthread / configure
blob3cbe55e14f6cbd843141a3b06b05e54f98d840d5
1 # This file is generated from configure.in by Autoconf.  DO NOT EDIT!
3 if test "x$libc_cv_gcc___thread" != xyes; then
4   { { echo "$as_me:$LINENO: error: compiler support for __thread is required" >&5
5 echo "$as_me: error: compiler support for __thread is required" >&2;}
6    { (exit 1); exit 1; }; }
7 fi
9 if test "x${libc_cv_visibility_attribute}" != xyes ||
10    test "x${libc_cv_broken_visibility_attribute}" != xno; then
11   { { echo "$as_me:$LINENO: error: working compiler support for visibility attribute is required" >&5
12 echo "$as_me: error: working compiler support for visibility attribute is required" >&2;}
13    { (exit 1); exit 1; }; }
16 if test "x$libc_cv_asm_cfi_directives" != xyes; then
17     case "$base_machine" in
18     i386 | x86_64 | powerpc | s390)
19       { { echo "$as_me:$LINENO: error: CFI directive support in assembler is required" >&5
20 echo "$as_me: error: CFI directive support in assembler is required" >&2;}
21    { (exit 1); exit 1; }; } ;;
22     *) ;;
23   esac
27 echo "$as_me:$LINENO: checking for forced unwind support" >&5
28 echo $ECHO_N "checking for forced unwind support... $ECHO_C" >&6
29 if test "${libc_cv_forced_unwind+set}" = set; then
30   echo $ECHO_N "(cached) $ECHO_C" >&6
31 else
32   cat >conftest.$ac_ext <<_ACEOF
33 /* confdefs.h.  */
34 _ACEOF
35 cat confdefs.h >>conftest.$ac_ext
36 cat >>conftest.$ac_ext <<_ACEOF
37 /* end confdefs.h.  */
38 #include <unwind.h>
39 int
40 main ()
43 struct _Unwind_Exception exc;
44 struct _Unwind_Context *context;
45 _Unwind_GetCFA (context)
46   ;
47   return 0;
49 _ACEOF
50 rm -f conftest.$ac_objext conftest$ac_exeext
51 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
52   (eval $ac_link) 2>conftest.er1
53   ac_status=$?
54   grep -v '^ *+' conftest.er1 >conftest.err
55   rm -f conftest.er1
56   cat conftest.err >&5
57   echo "$as_me:$LINENO: \$? = $ac_status" >&5
58   (exit $ac_status); } &&
59          { ac_try='test -z "$ac_c_werror_flag"
60                          || test ! -s conftest.err'
61   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
62   (eval $ac_try) 2>&5
63   ac_status=$?
64   echo "$as_me:$LINENO: \$? = $ac_status" >&5
65   (exit $ac_status); }; } &&
66          { ac_try='test -s conftest$ac_exeext'
67   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
68   (eval $ac_try) 2>&5
69   ac_status=$?
70   echo "$as_me:$LINENO: \$? = $ac_status" >&5
71   (exit $ac_status); }; }; then
72   libc_cv_forced_unwind=yes
73 else
74   echo "$as_me: failed program was:" >&5
75 sed 's/^/| /' conftest.$ac_ext >&5
77 libc_cv_forced_unwind=no
79 rm -f conftest.err conftest.$ac_objext \
80       conftest$ac_exeext conftest.$ac_ext
82 echo "$as_me:$LINENO: result: $libc_cv_forced_unwind" >&5
83 echo "${ECHO_T}$libc_cv_forced_unwind" >&6
84 if test $libc_cv_forced_unwind = yes; then
85   cat >>confdefs.h <<\_ACEOF
86 #define HAVE_FORCED_UNWIND 1
87 _ACEOF
89   old_CFLAGS="$CFLAGS"
90   CFLAGS="$CFLAGS -Werror -fexceptions"
91   echo "$as_me:$LINENO: checking for C cleanup handling" >&5
92 echo $ECHO_N "checking for C cleanup handling... $ECHO_C" >&6
93 if test "${libc_cv_c_cleanup+set}" = set; then
94   echo $ECHO_N "(cached) $ECHO_C" >&6
95 else
96     cat >conftest.$ac_ext <<_ACEOF
97 /* confdefs.h.  */
98 _ACEOF
99 cat confdefs.h >>conftest.$ac_ext
100 cat >>conftest.$ac_ext <<_ACEOF
101 /* end confdefs.h.  */
103 #include <stdio.h>
104 void cl (void *a) { }
106 main ()
109   int a __attribute__ ((cleanup (cl)));
110   puts ("test")
111   ;
112   return 0;
114 _ACEOF
115 rm -f conftest.$ac_objext conftest$ac_exeext
116 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
117   (eval $ac_link) 2>conftest.er1
118   ac_status=$?
119   grep -v '^ *+' conftest.er1 >conftest.err
120   rm -f conftest.er1
121   cat conftest.err >&5
122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
123   (exit $ac_status); } &&
124          { ac_try='test -z "$ac_c_werror_flag"
125                          || test ! -s conftest.err'
126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
127   (eval $ac_try) 2>&5
128   ac_status=$?
129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
130   (exit $ac_status); }; } &&
131          { ac_try='test -s conftest$ac_exeext'
132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
133   (eval $ac_try) 2>&5
134   ac_status=$?
135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
136   (exit $ac_status); }; }; then
137   libc_cv_c_cleanup=yes
138 else
139   echo "$as_me: failed program was:" >&5
140 sed 's/^/| /' conftest.$ac_ext >&5
142 libc_cv_c_cleanup=no
144 rm -f conftest.err conftest.$ac_objext \
145       conftest$ac_exeext conftest.$ac_ext
147 echo "$as_me:$LINENO: result: $libc_cv_c_cleanup" >&5
148 echo "${ECHO_T}$libc_cv_c_cleanup" >&6
149   CFLAGS="$old_CFLAGS"
150   if test $libc_cv_c_cleanup = no; then
151     { { echo "$as_me:$LINENO: error: the compiler must support C cleanup handling" >&5
152 echo "$as_me: error: the compiler must support C cleanup handling" >&2;}
153    { (exit 1); exit 1; }; }
154   fi
155 else
156   { { echo "$as_me:$LINENO: error: forced unwind support is required" >&5
157 echo "$as_me: error: forced unwind support is required" >&2;}
158    { (exit 1); exit 1; }; }