summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmake/detect-arch.cmake4
1 files changed, 3 insertions, 1 deletions
diff --git a/cmake/detect-arch.cmake b/cmake/detect-arch.cmake
index ac798c67fb..991fe18296 100644
--- a/cmake/detect-arch.cmake
+++ b/cmake/detect-arch.cmake
@@ -8,7 +8,9 @@ elseif(MSVC)
set(ARCH ${MSVC_C_ARCHITECTURE_ID})
elseif(EMSCRIPTEN)
set(ARCH "wasm32")
-else()
+endif()
+
+if(NOT ARCH OR ARCH STREQUAL "")
# Compile detect-arch.c and read the architecture name from the binary
try_compile(
COMPILE_RESULT