Fix compile under Debian Hurd (i386)

Debian Hurd defines __MACH__, and it was picking up "#define CRYPTOPP_SECTION_INIT __attribute__((section (__DATA,__data)))" intended for Apple linkers
pull/339/head
Jeffrey Walton 2016-10-28 00:33:43 -04:00
parent 69de0d591b
commit 84b602cc7d
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
2 changed files with 4 additions and 4 deletions

View File

@ -364,9 +364,9 @@ NAMESPACE_END
#endif #endif
// The section attribute attempts to initialize CPU flags to avoid Valgrind findings above -O1 // The section attribute attempts to initialize CPU flags to avoid Valgrind findings above -O1
#if ((__MACH__ >= 1) && ((CRYPTOPP_LLVM_CLANG_VERSION >= 30600) || (CRYPTOPP_APPLE_CLANG_VERSION >= 70100) || (CRYPTOPP_GCC_VERSION >= 40300))) #if ((defined(__MACH__) && defined(__APPLE__)) && ((CRYPTOPP_LLVM_CLANG_VERSION >= 30600) || (CRYPTOPP_APPLE_CLANG_VERSION >= 70100) || (CRYPTOPP_GCC_VERSION >= 40300)))
#define CRYPTOPP_SECTION_INIT __attribute__((section ("__DATA,__data"))) #define CRYPTOPP_SECTION_INIT __attribute__((section ("__DATA,__data")))
#elif ((__ELF__ >= 1) && (CRYPTOPP_GCC_VERSION >= 40300)) #elif (defined(__ELF__) && (CRYPTOPP_GCC_VERSION >= 40300))
#define CRYPTOPP_SECTION_INIT __attribute__((section ("nocommon"))) #define CRYPTOPP_SECTION_INIT __attribute__((section ("nocommon")))
#else #else
#define CRYPTOPP_SECTION_INIT #define CRYPTOPP_SECTION_INIT

View File

@ -364,9 +364,9 @@ NAMESPACE_END
#endif #endif
// The section attribute attempts to initialize CPU flags to avoid Valgrind findings above -O1 // The section attribute attempts to initialize CPU flags to avoid Valgrind findings above -O1
#if ((__MACH__ >= 1) && ((CRYPTOPP_LLVM_CLANG_VERSION >= 30600) || (CRYPTOPP_APPLE_CLANG_VERSION >= 70100) || (CRYPTOPP_GCC_VERSION >= 40300))) #if ((defined(__MACH__) && defined(__APPLE__)) && ((CRYPTOPP_LLVM_CLANG_VERSION >= 30600) || (CRYPTOPP_APPLE_CLANG_VERSION >= 70100) || (CRYPTOPP_GCC_VERSION >= 40300)))
#define CRYPTOPP_SECTION_INIT __attribute__((section ("__DATA,__data"))) #define CRYPTOPP_SECTION_INIT __attribute__((section ("__DATA,__data")))
#elif ((__ELF__ >= 1) && (CRYPTOPP_GCC_VERSION >= 40300)) #elif (defined(__ELF__) && (CRYPTOPP_GCC_VERSION >= 40300))
#define CRYPTOPP_SECTION_INIT __attribute__((section ("nocommon"))) #define CRYPTOPP_SECTION_INIT __attribute__((section ("nocommon")))
#else #else
#define CRYPTOPP_SECTION_INIT #define CRYPTOPP_SECTION_INIT