Hi Everyone,
I think the CmakeList.txt file could be improved slightly. I recently removed -DCRYPTOPP_DISABLE_ASM from ARM since that removes NEON, CRC32 and Crypto extensions provided by intrinsics. We have NEON code in the code base, and there was no technical reason to disable it.
It left an opportunity for further cleanup:
$ cat CMakeLists.txt.diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
index de53893..8106f31 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -102,9 +102,7 @@ if(MINGW OR WIN32)
endif()
if(MSVC AND NOT DISABLE_ASM)
- if(${CMAKE_GENERATOR} MATCHES ".*ARM")
- message(STATUS "Disabling ASM because ARM is specified as target platform.")
- else()
+ if(NOT ${CMAKE_GENERATOR} MATCHES ".*ARM")
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
list(APPEND cryptopp_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/x64dll.asm)
list(APPEND cryptopp_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/x64masm.asm)
I think the patch above could be further improved changing the "not matches arm" to something closer to "matches Visual Studio on X86/X64". VS alone is weaker than MSVC/VS, and that's because Clang toolchains can run in that spot, too.
Patches are welcomed.
Jeff