]> git.saurik.com Git - wxWidgets.git/commitdiff
when testing for GCC's atomic builtins, try to link too (see bug #1844128); also...
authorVáclav Slavík <vslavik@fastmail.fm>
Tue, 4 Dec 2007 15:29:17 +0000 (15:29 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Tue, 4 Dec 2007 15:29:17 +0000 (15:29 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@50466 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

build/aclocal/atomic_builtins.m4
configure

index 45b88e90f49f8e9ffb735a380c3f7653d249981f..bf2bcd17e3c8e850cee1cdc6500d1169351083b2 100644 (file)
@@ -8,10 +8,10 @@ AC_DEFUN([WX_ATOMIC_BUILTINS],
   if test -n "$GCC"; then
     AC_MSG_CHECKING([for __sync_fetch_* builtins])
     AC_CACHE_VAL(wx_cv_cc_gcc_atomic_builtins, [
-      AC_TRY_COMPILE(
+      AC_TRY_LINK(
         [],
         [
-          int value=0;
+          unsigned int value=0;
           __sync_fetch_and_add(&value, 1);
           __sync_sub_and_fetch(&value, 1);
         ],
index c3bf79365e601fb84238593ce86f462601f8371c..56ccf8490410a8f0acdf33ccb1e2b94fe9167378 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Id: configure.in 50226 2007-11-24 19:11:19Z PC .
+# From configure.in Id: configure.in 50303 2007-11-28 06:46:25Z PC .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.61 for wxWidgets 2.9.0.
 #
@@ -24789,7 +24789,7 @@ int
 main ()
 {
 
-          int value=0;
+          unsigned int value=0;
           __sync_fetch_and_add(&value, 1);
           __sync_sub_and_fetch(&value, 1);
 
@@ -24797,14 +24797,14 @@ main ()
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -24813,7 +24813,8 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_cxx_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
   wx_cv_cc_gcc_atomic_builtins=yes
 else
   echo "$as_me: failed program was:" >&5
@@ -24822,7 +24823,8 @@ sed 's/^/| /' conftest.$ac_ext >&5
        wx_cv_cc_gcc_atomic_builtins=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
 
 fi