when testing for GCC's atomic builtins, try to link too (see bug #1844128); also more closely mirror wx's use by using unsigned int and not int for tests
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@50466 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -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);
|
||||
],
|
||||
|
Reference in New Issue
Block a user