aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2019-03-05 12:40:06 +0200
committerRiccardo Spagni <ric@spagni.net>2019-03-05 12:40:06 +0200
commit39d7d3113bfe3655e721fa08b132d3b7fbcfb9b3 (patch)
tree01313a7ac6efed723a88e4063478539323fd556b /CMakeLists.txt
parentMerge pull request #5101 (diff)
parentCryptonightR: define out i386/x86_64 specific code on other archs (diff)
downloadmonero-39d7d3113bfe3655e721fa08b132d3b7fbcfb9b3.tar.xz
Merge pull request #5231
108c625b CryptonightR: define out i386/x86_64 specific code on other archs (moneromooo-monero) 1b8757dd slow-hash: fix build on arm (moneromooo-monero) 5057eb11 cmake: ARCH_ID fixes for cross compilation (TheCharlatan)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 90b16cab8..191cc8966 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -115,6 +115,9 @@ string(TOLOWER ${CMAKE_BUILD_TYPE} CMAKE_BUILD_TYPE_LOWER)
# to identify the target architecture, to direct logic in this cmake script.
# Since ARCH is a cached variable, it will not be set on first cmake invocation.
if (NOT ARCH OR ARCH STREQUAL "" OR ARCH STREQUAL "native" OR ARCH STREQUAL "default")
+ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "")
+ set(CMAKE_SYSTEM_PROCESSOR ${CMAKE_HOST_SYSTEM_PROCESSOR})
+ endif()
set(ARCH_ID "${CMAKE_SYSTEM_PROCESSOR}")
else()
set(ARCH_ID "${ARCH}")