diff options
Diffstat (limited to 'cmake/Platform/Emscripten.cmake')
-rw-r--r-- | cmake/Platform/Emscripten.cmake | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/cmake/Platform/Emscripten.cmake b/cmake/Platform/Emscripten.cmake index e050d8a6..fde45b3e 100644 --- a/cmake/Platform/Emscripten.cmake +++ b/cmake/Platform/Emscripten.cmake @@ -16,12 +16,12 @@ set(CMAKE_SYSTEM_NAME Emscripten) set(CMAKE_SYSTEM_VERSION 1) -if ("$ENV{EMSCRIPTEN}" STREQUAL "") - message(ERROR "Environment variable EMSCRIPTEN has not been set! Please point it to Emscripten root directory!") +if ("${EMSCRIPTEN_ROOT_PATH}" STREQUAL "") + set(CMAKE_FIND_ROOT_PATH "$ENV{EMSCRIPTEN}") +else() + set(CMAKE_FIND_ROOT_PATH "${EMSCRIPTEN_ROOT_PATH}") endif() -set(CMAKE_FIND_ROOT_PATH $ENV{EMSCRIPTEN}) - # Specify the compilers to use for C and C++ if ("${CMAKE_C_COMPILER}" STREQUAL "") set(CMAKE_C_COMPILER "emcc") |