aboutsummaryrefslogtreecommitdiff
path: root/config/tls.m4
diff options
context:
space:
mode:
authorDaniel Jacobowitz <dan@codesourcery.com>2006-11-13 20:35:20 +0000
committerDaniel Jacobowitz <drow@gcc.gnu.org>2006-11-13 20:35:20 +0000
commit597c25e65d1ba0f80796c91f8b1c6318fd353caa (patch)
treeb2bf509da6cdeb68219bd470f074906b26fc5f87 /config/tls.m4
parentd296e02ef82ad43e90316bb15c4b97b9b3158bb5 (diff)
downloadgcc-597c25e65d1ba0f80796c91f8b1c6318fd353caa.zip
gcc-597c25e65d1ba0f80796c91f8b1c6318fd353caa.tar.gz
gcc-597c25e65d1ba0f80796c91f8b1c6318fd353caa.tar.bz2
* tls.m4 (GCC_CHECK_TLS): Fall back to a link test.
From-SVN: r118777
Diffstat (limited to 'config/tls.m4')
-rw-r--r--config/tls.m43
1 files changed, 2 insertions, 1 deletions
diff --git a/config/tls.m4 b/config/tls.m4
index b7a0730..b66b6d7 100644
--- a/config/tls.m4
+++ b/config/tls.m4
@@ -13,7 +13,8 @@ AC_DEFUN([GCC_CHECK_TLS], [
[have_tls=yes], [have_tls=no], [])
LDFLAGS="$save_LDFLAGS"],
[have_tls=no],
- [AC_COMPILE_IFELSE([__thread int foo;], [have_tls=yes], [have_tls=no])]
+ [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,