From 1eba9d9c7424235b1a6dcd866fcd06d12e08a7f3 Mon Sep 17 00:00:00 2001 From: "jieluo@google.com" Date: Mon, 25 Aug 2014 20:17:53 +0000 Subject: merge tags/2.6.0 into trunk --- src/google/protobuf/stubs/platform_macros.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/google/protobuf/stubs/platform_macros.h') diff --git a/src/google/protobuf/stubs/platform_macros.h b/src/google/protobuf/stubs/platform_macros.h index 30604782..1705b416 100644 --- a/src/google/protobuf/stubs/platform_macros.h +++ b/src/google/protobuf/stubs/platform_macros.h @@ -65,6 +65,14 @@ #elif defined(__ppc__) #define GOOGLE_PROTOBUF_ARCH_PPC 1 #define GOOGLE_PROTOBUF_ARCH_32_BIT 1 +#elif defined(__GNUC__) && \ + (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 7)) || (__GNUC__ > 4)) +// We fallback to the generic GCC >= 4.7 implementation in atomicops.h +# if __LP64__ +# define GOOGLE_PROTOBUF_ARCH_64_BIT 1 +# else +# define GOOGLE_PROTOBUF_ARCH_32_BIT 1 +# endif #else #error Host architecture was not detected as supported by protobuf #endif -- cgit v1.2.3