Hi guys!
I've found my project doesn't compile after update from cryptopp-5.6.5 
to cryptopp-8.0.0.
This change 
<https://github.com/weidai11/cryptopp/commit/4e3a1ea962d8f8cc58b97d2dd59554479a2b2db9>
 (config.h:598) 
seems to be the reason, as it assumes that every ARM processor has Arm Neon 
architecture extension. But, as in my case, that's not true.
Fix attached solved my case.

Best regards,
Yury.

-- 
You received this message because you are subscribed to "Crypto++ Users". More 
information about Crypto++ and this group is available at 
http://www.cryptopp.com and 
http://groups.google.com/forum/#!forum/cryptopp-users.
--- 
You received this message because you are subscribed to the Google Groups 
"Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.
>From 8b1c443fa3e2f892947156093c21991c3eb59b53 Mon Sep 17 00:00:00 2001
Message-Id: <8b1c443fa3e2f892947156093c21991c3eb59b53.1553856217.git.yzhes...@iotecha.com>
From: Yury Zhesson <[email protected]>
Date: Fri, 29 Mar 2019 13:42:39 +0300
Subject: [PATCH] Arm Neon availability detection fixed

Not every ARM processor has Arm Neon architecture extension
---
 config.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/config.h b/config.h
index 8db32c6..482e6c9 100644
--- a/config.h
+++ b/config.h
@@ -630,7 +630,7 @@ NAMESPACE_END
 // Requires GCC 4.3, Clang 2.8 or Visual Studio 2012
 // Do not use APPLE_CLANG_VERSION; use __ARM_FEATURE_XXX instead.
 #if !defined(CRYPTOPP_ARM_NEON_AVAILABLE) && !defined(CRYPTOPP_DISABLE_ASM)
-# if defined(__arm__) || defined(__ARM_NEON) || defined(__ARM_FEATURE_NEON) || defined(_M_ARM)
+# if (defined(__arm__) || defined(_M_ARM)) && (defined(__ARM_NEON) || defined(__ARM_FEATURE_NEON))
 #  if (CRYPTOPP_GCC_VERSION >= 40300) || (CRYPTOPP_CLANG_VERSION >= 20800) || \
       (CRYPTOPP_MSC_VERSION >= 1700)
 #   define CRYPTOPP_ARM_NEON_AVAILABLE 1
-- 
2.11.0

Reply via email to