diff --git a/sys/sys/stdatomic.h b/sys/sys/stdatomic.h --- a/sys/sys/stdatomic.h +++ b/sys/sys/stdatomic.h @@ -33,7 +33,8 @@ #include #include -#if __has_extension(c_atomic) || __has_extension(cxx_atomic) +#if (__has_extension(c_atomic) || __has_extension(cxx_atomic)) && \ + defined(__clang__) #define __CLANG_ATOMICS #elif __GNUC_PREREQ__(4, 7) #define __GNUC_ATOMICS