diff --git a/lib/ovs-atomic.h b/lib/ovs-atomic.h index 8fdce0cf804..62ee4e06820 100644 --- a/lib/ovs-atomic.h +++ b/lib/ovs-atomic.h @@ -329,7 +329,7 @@ #if __CHECKER__ /* sparse doesn't understand some GCC extensions we use. */ #include "ovs-atomic-pthreads.h" - #elif __has_extension(c_atomic) + #elif __clang__ && __has_extension(c_atomic) #include "ovs-atomic-clang.h" #elif HAVE_ATOMIC && __cplusplus >= 201103L #include "ovs-atomic-c++.h"