diff --git a/config.h b/config.h index 9fa466ef..7ac17fda 100644 --- a/config.h +++ b/config.h @@ -224,6 +224,12 @@ typedef unsigned int word32; typedef word64 lword; const lword LWORD_MAX = W64LIT(0xffffffffffffffff); +// Clang pretends to be VC++, too. +// See http://github.com/weidai11/cryptopp/issues/147 +#if defined(_MSC_VER) && defined(__clang__) +# error: "Unsupported configuration" +#endif + #ifdef __GNUC__ #define CRYPTOPP_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) #endif diff --git a/config.recommend b/config.recommend index 86f2812f..c9064240 100644 --- a/config.recommend +++ b/config.recommend @@ -224,6 +224,12 @@ typedef unsigned int word32; typedef word64 lword; const lword LWORD_MAX = W64LIT(0xffffffffffffffff); +// Clang pretends to be VC++, too. +// See http://github.com/weidai11/cryptopp/issues/147 +#if defined(_MSC_VER) && defined(__clang__) +# error: "Unsupported configuration" +#endif + #ifdef __GNUC__ #define CRYPTOPP_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) #endif