summaryrefslogtreecommitdiff
path: root/misc.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2023-04-15 18:21:03 -0400
committerJeffrey Walton <noloader@gmail.com>2023-04-15 18:21:03 -0400
commitddb8f36e8894a3bce7daeca0815fb0137de73388 (patch)
tree2db9cb4c53c63323da064f21461b63dbcd982013 /misc.h
parentf5f63850f9a5521e45de3cc45be61309a2e71ab2 (diff)
downloadcryptopp-git-ddb8f36e8894a3bce7daeca0815fb0137de73388.tar.gz
Fix use of <x86intrin.h> for MSVC (GH #1198)
It seems Microsoft now defines GCC defines, like __BMI__
Diffstat (limited to 'misc.h')
-rw-r--r--misc.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/misc.h b/misc.h
index f81e81f4..be9fcf38 100644
--- a/misc.h
+++ b/misc.h
@@ -80,9 +80,11 @@
#endif
#if defined(__BMI__)
-# include <x86intrin.h>
+# if defined(CRYPTOPP_GCC_COMPATIBLE)
+# include <x86intrin.h>
+# endif
# include <immintrin.h>
-#endif // GCC and BMI
+#endif // BMI
// More LLVM bullshit. Apple Clang 6.0 does not define them.
// Later version of Clang defines them and results in warnings.