[multiple changes]
2007-02-07 Bruno Haible <bruno@clisp.org> config/ PR libgomp/28468 * config/tls.m4 (GCC_CHECK_TLS): Also check whether the libc supports TLS via __thread. 2007-02-07 Jakub Jelinek <jakub@redhat.com> {libgomp,libstdc++-v3,libmudflap,libjava}/ PR libgomp/28468 * configure: Regenerate. From-SVN: r121689
This commit is contained in:
parent
e02a048f46
commit
78e075d40b
@ -1,3 +1,9 @@
|
||||
2007-02-07 Bruno Haible <bruno@clisp.org>
|
||||
|
||||
PR libgomp/28468
|
||||
* config/tls.m4 (GCC_CHECK_TLS): Also check whether the libc supports
|
||||
TLS via __thread.
|
||||
|
||||
2007-01-31 Daniel Franke <franke.daniel@gmail.com>
|
||||
|
||||
PR libgomp/30546
|
||||
|
@ -7,16 +7,67 @@ AC_DEFUN([GCC_CHECK_TLS], [
|
||||
[dnl If the test case passed with dynamic linking, try again with
|
||||
dnl static linking, but only if static linking is supported (not
|
||||
dnl on Solaris 10). This fails with some older Red Hat releases.
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
chktls_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="-static $LDFLAGS"
|
||||
AC_LINK_IFELSE([int main() { return 0; }],
|
||||
AC_RUN_IFELSE([__thread int a; int b; int main() { return a = b; }],
|
||||
[have_tls=yes], [have_tls=no],[]),
|
||||
[have_tls=yes])
|
||||
LDFLAGS="$save_LDFLAGS"],
|
||||
LDFLAGS="$chktls_save_LDFLAGS"
|
||||
if test $have_tls = yes; then
|
||||
dnl So far, the binutils and the compiler support TLS.
|
||||
dnl Also check whether the libc supports TLS, i.e. whether a variable
|
||||
dnl with __thread linkage has a different address in different threads.
|
||||
dnl First, find the thread_CFLAGS necessary for linking a program that
|
||||
dnl calls pthread_create.
|
||||
chktls_save_CFLAGS="$CFLAGS"
|
||||
thread_CFLAGS=failed
|
||||
for flag in '' '-pthread' '-lpthread'; do
|
||||
CFLAGS="$flag $chktls_save_CFLAGS"
|
||||
AC_LINK_IFELSE(
|
||||
[AC_LANG_PROGRAM(
|
||||
[#include <pthread.h>
|
||||
void *g(void *d) { return NULL; }],
|
||||
[pthread_t t; pthread_create(&t,NULL,g,NULL);])],
|
||||
[thread_CFLAGS="$flag"])
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
|
||||
AC_RUN_IFELSE(
|
||||
[AC_LANG_PROGRAM(
|
||||
[#include <pthread.h>
|
||||
__thread int a;
|
||||
static int *a_in_other_thread;
|
||||
static void *
|
||||
thread_func (void *arg)
|
||||
{
|
||||
a_in_other_thread = &a;
|
||||
return (void *)0;
|
||||
}],
|
||||
[pthread_t thread;
|
||||
void *thread_retval;
|
||||
int *a_in_main_thread;
|
||||
if (pthread_create (&thread, (pthread_attr_t *)0,
|
||||
thread_func, (void *)0))
|
||||
return 0;
|
||||
a_in_main_thread = &a;
|
||||
if (pthread_join (thread, &thread_retval))
|
||||
return 0;
|
||||
return (a_in_other_thread == a_in_main_thread);])],
|
||||
[have_tls=yes], [have_tls=no], [])
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
fi
|
||||
fi],
|
||||
[have_tls=no],
|
||||
[AC_LINK_IFELSE([__thread int a; int b; int main() { return a = b; }],
|
||||
[have_tls=yes], [have_tls=no])]
|
||||
[dnl This is the cross-compiling case. Assume libc supports TLS if the
|
||||
dnl binutils and the compiler do.
|
||||
AC_LINK_IFELSE([__thread int a; int b; int main() { return a = b; }],
|
||||
[have_tls=yes], [have_tls=no])
|
||||
]
|
||||
)])
|
||||
if test "$enable_tls $have_tls" = "yes yes"; then
|
||||
AC_DEFINE(HAVE_TLS, 1,
|
||||
|
@ -1,5 +1,8 @@
|
||||
2007-02-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR libgomp/28486
|
||||
* configure: Regenerate.
|
||||
|
||||
PR c++/30703
|
||||
* testsuite/libgomp.c++/pr30703.C: New test.
|
||||
|
||||
|
130
libgomp/configure
vendored
130
libgomp/configure
vendored
@ -3530,6 +3530,10 @@ else
|
||||
*) gcc_cv_prog_makeinfo_modern=no;;
|
||||
esac
|
||||
|
||||
if test $gcc_cv_prog_makeinfo_modern = no; then
|
||||
MAKEINFO="${CONFIG_SHELL-/bin/sh} $ac_aux_dir/missing makeinfo"
|
||||
fi
|
||||
|
||||
fi
|
||||
echo "$as_me:$LINENO: result: $gcc_cv_prog_makeinfo_modern" >&5
|
||||
echo "${ECHO_T}$gcc_cv_prog_makeinfo_modern" >&6
|
||||
@ -8999,7 +9003,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
chktls_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="-static $LDFLAGS"
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
int main() { return 0; }
|
||||
@ -9066,7 +9070,129 @@ have_tls=yes
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LDFLAGS="$save_LDFLAGS"
|
||||
LDFLAGS="$chktls_save_LDFLAGS"
|
||||
if test $have_tls = yes; then
|
||||
chktls_save_CFLAGS="$CFLAGS"
|
||||
thread_CFLAGS=failed
|
||||
for flag in '' '-pthread' '-lpthread'; do
|
||||
CFLAGS="$flag $chktls_save_CFLAGS"
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
void *g(void *d) { return NULL; }
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t t; pthread_create(&t,NULL,g,NULL);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>conftest.er1
|
||||
ac_status=$?
|
||||
grep -v '^ *+' conftest.er1 >conftest.err
|
||||
rm -f conftest.er1
|
||||
cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } &&
|
||||
{ ac_try='test -z "$ac_c_werror_flag"
|
||||
|| test ! -s conftest.err'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; } &&
|
||||
{ ac_try='test -s conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
thread_CFLAGS="$flag"
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
|
||||
if test "$cross_compiling" = yes; then
|
||||
{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&5
|
||||
echo "$as_me: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
else
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
__thread int a;
|
||||
static int *a_in_other_thread;
|
||||
static void *
|
||||
thread_func (void *arg)
|
||||
{
|
||||
a_in_other_thread = &a;
|
||||
return (void *)0;
|
||||
}
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t thread;
|
||||
void *thread_retval;
|
||||
int *a_in_main_thread;
|
||||
if (pthread_create (&thread, (pthread_attr_t *)0,
|
||||
thread_func, (void *)0))
|
||||
return 0;
|
||||
a_in_main_thread = &a;
|
||||
if (pthread_join (thread, &thread_retval))
|
||||
return 0;
|
||||
return (a_in_other_thread == a_in_main_thread);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
have_tls=yes
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
( exit $ac_status )
|
||||
have_tls=no
|
||||
fi
|
||||
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
|
||||
fi
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
|
@ -1,3 +1,8 @@
|
||||
2007-02-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR libgomp/28468
|
||||
* configure: Regenerate.
|
||||
|
||||
2007-02-06 Andrew Haley <aph@redhat.com>
|
||||
|
||||
* scripts/makemake.tcl (emit_bc_rule): Set the source filename.
|
||||
|
131
libjava/configure
vendored
131
libjava/configure
vendored
@ -16870,7 +16870,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
chktls_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="-static $LDFLAGS"
|
||||
if test x$gcc_no_link = xyes; then
|
||||
{ { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
|
||||
@ -16942,7 +16942,134 @@ have_tls=yes
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LDFLAGS="$save_LDFLAGS"
|
||||
LDFLAGS="$chktls_save_LDFLAGS"
|
||||
if test $have_tls = yes; then
|
||||
chktls_save_CFLAGS="$CFLAGS"
|
||||
thread_CFLAGS=failed
|
||||
for flag in '' '-pthread' '-lpthread'; do
|
||||
CFLAGS="$flag $chktls_save_CFLAGS"
|
||||
if test x$gcc_no_link = xyes; then
|
||||
{ { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
|
||||
echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
fi
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
void *g(void *d) { return NULL; }
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t t; pthread_create(&t,NULL,g,NULL);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>conftest.er1
|
||||
ac_status=$?
|
||||
grep -v '^ *+' conftest.er1 >conftest.err
|
||||
rm -f conftest.er1
|
||||
cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } &&
|
||||
{ ac_try='test -z "$ac_c_werror_flag"
|
||||
|| test ! -s conftest.err'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; } &&
|
||||
{ ac_try='test -s conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
thread_CFLAGS="$flag"
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
|
||||
if test "$cross_compiling" = yes; then
|
||||
{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&5
|
||||
echo "$as_me: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
else
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
__thread int a;
|
||||
static int *a_in_other_thread;
|
||||
static void *
|
||||
thread_func (void *arg)
|
||||
{
|
||||
a_in_other_thread = &a;
|
||||
return (void *)0;
|
||||
}
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t thread;
|
||||
void *thread_retval;
|
||||
int *a_in_main_thread;
|
||||
if (pthread_create (&thread, (pthread_attr_t *)0,
|
||||
thread_func, (void *)0))
|
||||
return 0;
|
||||
a_in_main_thread = &a;
|
||||
if (pthread_join (thread, &thread_retval))
|
||||
return 0;
|
||||
return (a_in_other_thread == a_in_main_thread);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
have_tls=yes
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
( exit $ac_status )
|
||||
have_tls=no
|
||||
fi
|
||||
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
|
||||
fi
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
|
@ -1,3 +1,8 @@
|
||||
2007-02-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR libgomp/28468
|
||||
* configure: Regenerate.
|
||||
|
||||
2006-12-04 Eric Botcazou <ebotcazou@libertysurf.fr>
|
||||
|
||||
* configure: Regenerate.
|
||||
|
126
libmudflap/configure
vendored
126
libmudflap/configure
vendored
@ -7183,7 +7183,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
chktls_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="-static $LDFLAGS"
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
int main() { return 0; }
|
||||
@ -7250,7 +7250,129 @@ have_tls=yes
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LDFLAGS="$save_LDFLAGS"
|
||||
LDFLAGS="$chktls_save_LDFLAGS"
|
||||
if test $have_tls = yes; then
|
||||
chktls_save_CFLAGS="$CFLAGS"
|
||||
thread_CFLAGS=failed
|
||||
for flag in '' '-pthread' '-lpthread'; do
|
||||
CFLAGS="$flag $chktls_save_CFLAGS"
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
void *g(void *d) { return NULL; }
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t t; pthread_create(&t,NULL,g,NULL);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>conftest.er1
|
||||
ac_status=$?
|
||||
grep -v '^ *+' conftest.er1 >conftest.err
|
||||
rm -f conftest.er1
|
||||
cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } &&
|
||||
{ ac_try='test -z "$ac_c_werror_flag"
|
||||
|| test ! -s conftest.err'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; } &&
|
||||
{ ac_try='test -s conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
thread_CFLAGS="$flag"
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
|
||||
if test "$cross_compiling" = yes; then
|
||||
{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&5
|
||||
echo "$as_me: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
else
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
__thread int a;
|
||||
static int *a_in_other_thread;
|
||||
static void *
|
||||
thread_func (void *arg)
|
||||
{
|
||||
a_in_other_thread = &a;
|
||||
return (void *)0;
|
||||
}
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t thread;
|
||||
void *thread_retval;
|
||||
int *a_in_main_thread;
|
||||
if (pthread_create (&thread, (pthread_attr_t *)0,
|
||||
thread_func, (void *)0))
|
||||
return 0;
|
||||
a_in_main_thread = &a;
|
||||
if (pthread_join (thread, &thread_retval))
|
||||
return 0;
|
||||
return (a_in_other_thread == a_in_main_thread);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
have_tls=yes
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
( exit $ac_status )
|
||||
have_tls=no
|
||||
fi
|
||||
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
|
||||
fi
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
|
@ -1,3 +1,8 @@
|
||||
2007-02-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR libgomp/28468
|
||||
* configure: Regenerate.
|
||||
|
||||
2007-02-07 Hans-Peter Nilsson <hp@axis.com>
|
||||
|
||||
PR testsuite/28870
|
||||
|
131
libstdc++-v3/configure
vendored
131
libstdc++-v3/configure
vendored
@ -31620,7 +31620,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
chktls_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="-static $LDFLAGS"
|
||||
if test x$gcc_no_link = xyes; then
|
||||
{ { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
|
||||
@ -31692,7 +31692,134 @@ have_tls=yes
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LDFLAGS="$save_LDFLAGS"
|
||||
LDFLAGS="$chktls_save_LDFLAGS"
|
||||
if test $have_tls = yes; then
|
||||
chktls_save_CFLAGS="$CFLAGS"
|
||||
thread_CFLAGS=failed
|
||||
for flag in '' '-pthread' '-lpthread'; do
|
||||
CFLAGS="$flag $chktls_save_CFLAGS"
|
||||
if test x$gcc_no_link = xyes; then
|
||||
{ { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
|
||||
echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
fi
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
void *g(void *d) { return NULL; }
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t t; pthread_create(&t,NULL,g,NULL);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>conftest.er1
|
||||
ac_status=$?
|
||||
grep -v '^ *+' conftest.er1 >conftest.err
|
||||
rm -f conftest.er1
|
||||
cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } &&
|
||||
{ ac_try='test -z "$ac_c_werror_flag"
|
||||
|| test ! -s conftest.err'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; } &&
|
||||
{ ac_try='test -s conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
thread_CFLAGS="$flag"
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
if test "X$thread_CFLAGS" != Xfailed; then
|
||||
CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
|
||||
if test "$cross_compiling" = yes; then
|
||||
{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&5
|
||||
echo "$as_me: error: cannot run test program while cross compiling
|
||||
See \`config.log' for more details." >&2;}
|
||||
{ (exit 1); exit 1; }; }
|
||||
else
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <pthread.h>
|
||||
__thread int a;
|
||||
static int *a_in_other_thread;
|
||||
static void *
|
||||
thread_func (void *arg)
|
||||
{
|
||||
a_in_other_thread = &a;
|
||||
return (void *)0;
|
||||
}
|
||||
int
|
||||
main ()
|
||||
{
|
||||
pthread_t thread;
|
||||
void *thread_retval;
|
||||
int *a_in_main_thread;
|
||||
if (pthread_create (&thread, (pthread_attr_t *)0,
|
||||
thread_func, (void *)0))
|
||||
return 0;
|
||||
a_in_main_thread = &a;
|
||||
if (pthread_join (thread, &thread_retval))
|
||||
return 0;
|
||||
return (a_in_other_thread == a_in_main_thread);
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
rm -f conftest$ac_exeext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
(eval $ac_link) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
(eval $ac_try) 2>&5
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
have_tls=yes
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
( exit $ac_status )
|
||||
have_tls=no
|
||||
fi
|
||||
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
|
||||
fi
|
||||
CFLAGS="$chktls_save_CFLAGS"
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "$as_me: program exited with status $ac_status" >&5
|
||||
echo "$as_me: failed program was:" >&5
|
||||
|
Loading…
Reference in New Issue
Block a user