summaryrefslogtreecommitdiff
path: root/config_misc.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2021-04-20 04:07:15 -0400
committerJeffrey Walton <noloader@gmail.com>2021-04-20 04:07:15 -0400
commit21799b1fba6d9d3148cb56003a21f42f6fd086ed (patch)
tree6ea6052cbcae5e00d31d70131509f185948c4342 /config_misc.h
parentfee14910eaabfa098b1a7e1b05326a8831ee5e41 (diff)
downloadcryptopp-git-21799b1fba6d9d3148cb56003a21f42f6fd086ed.tar.gz
Fix build error when -DCRYPTOPP_DISABLE_ASM
Diffstat (limited to 'config_misc.h')
-rw-r--r--config_misc.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/config_misc.h b/config_misc.h
index c84577e2..9e8bfb7e 100644
--- a/config_misc.h
+++ b/config_misc.h
@@ -197,12 +197,14 @@
// Not available on Apple and Solaris platforms. Also see
// https://sourceware.org/glibc/wiki/GNU_IFUNC and
// https://gcc.gnu.org/onlinedocs/gcc/Function-Multiversioning.html.
-#if defined(__i386__) || defined(__i686__) || defined(__amd64__)
-# if defined(__linux__) && (CRYPTOPP_GCC_VERSION >= 40800)
-# include <x86intrin.h>
-# define CRYPTOPP_HAVE_ATTRIBUTE_TARGET 1
-# define CRYPTOPP_TARGET_DEFAULT __attribute__ ((target ("default")))
-# define CRYPTOPP_TARGET_SSSE3 __attribute__ ((target ("ssse3")))
+#if !defined(CRYPTOPP_DISABLE_ASM)
+# if defined(__i386__) || defined(__i686__) || defined(__amd64__)
+# if defined(__linux__) && (CRYPTOPP_GCC_VERSION >= 40800)
+# include <x86intrin.h>
+# define CRYPTOPP_HAVE_ATTRIBUTE_TARGET 1
+# define CRYPTOPP_TARGET_DEFAULT __attribute__ ((target ("default")))
+# define CRYPTOPP_TARGET_SSSE3 __attribute__ ((target ("ssse3")))
+# endif
# endif
#endif