Skip to content

Instantly share code, notes, and snippets.

@mdcallag
Created January 16, 2023 20:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mdcallag/5881a0a810d67316fba8c29ebfc6c172 to your computer and use it in GitHub Desktop.
Save mdcallag/5881a0a810d67316fba8c29ebfc6c172 to your computer and use it in GitHub Desktop.
--- configure.cmake.orig 2023-01-16 20:48:09.530421192 +0000
+++ configure.cmake 2023-01-14 18:38:25.424809439 +0000
@@ -738,7 +738,9 @@
IF (NOT HAVE_ARMV8_CRC32)
CMAKE_PUSH_CHECK_STATE(RESET)
- set(CMAKE_REQUIRED_FLAGS "-march=armv8-a+crc")
+ #set(CMAKE_REQUIRED_FLAGS "-march=armv8-a+crc")
+ #set(CMAKE_REQUIRED_FLAGS "-mcpu=native")
+ set(CMAKE_REQUIRED_FLAGS "-mtune=native")
CHECK_CXX_SOURCE_COMPILES(
"
#include <arm_acle.h>
@@ -750,7 +752,9 @@
HAVE_ARMV8_CRC32_WITH_ARCH_EXTN)
CMAKE_POP_CHECK_STATE()
if (HAVE_ARMV8_CRC32_WITH_ARCH_EXTN)
- STRING_APPEND(CMAKE_CXX_FLAGS " -march=armv8-a+crc")
+ #STRING_APPEND(CMAKE_CXX_FLAGS " -march=armv8-a+crc")
+ #STRING_APPEND(CMAKE_CXX_FLAGS " -mcpu=native")
+ STRING_APPEND(CMAKE_CXX_FLAGS " -mtune=native")
ENDIF()
ENDIF()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment