diff options
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 3cb1e5f5..ac1133d4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -264,12 +264,11 @@ HAVE_C11_ALIGNAS) # Check if we have C11 _Atomic CHECK_C_SOURCE_COMPILES( "#include <stdatomic.h> - const int _Atomic foo = ATOMIC_VAR_INIT(~0); - int _Atomic bar = ATOMIC_VAR_INIT(0); + int _Atomic foo = ATOMIC_VAR_INIT(0); int main() { - atomic_fetch_add(&bar, 2); - return atomic_load(&foo); + atomic_fetch_add(&foo, 2); + return 0; }" HAVE_C11_ATOMIC) |