diff options
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index ab2c83a96..1770b229f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -45,7 +45,12 @@ function (die msg) message(FATAL_ERROR "${BoldRed}${msg}${ColourReset}") endfunction () -if (NOT ${ARCH} STREQUAL "") +if ("${ARCH}" STREQUAL "" OR "${ARCH}" STREQUAL "native") + set(ARCH ${CMAKE_SYSTEM_PROCESSOR}) + message(STATUS "Building natively on ${ARCH}") +endif() + +if (NOT "${ARCH}" STREQUAL "") string(SUBSTRING ${ARCH} 0 3 IS_ARM) string(TOLOWER ${IS_ARM} IS_ARM) |