diff --git a/AUTHORS b/AUTHORS index 8f75808e6e747..e547f5442e7d6 100644 --- a/AUTHORS +++ b/AUTHORS @@ -470,3 +470,4 @@ a license to everyone to use it as detailed in LICENSE.) * rssqian * Shachar Langbeheim * David Carlier +* Paul Du (copyright owned by ARSKAN) diff --git a/cmake/Modules/Platform/Emscripten.cmake b/cmake/Modules/Platform/Emscripten.cmake index 8cb3df5f68370..e2b6e9f0421ce 100644 --- a/cmake/Modules/Platform/Emscripten.cmake +++ b/cmake/Modules/Platform/Emscripten.cmake @@ -100,6 +100,19 @@ if ("${CMAKE_RANLIB}" STREQUAL "") set(CMAKE_RANLIB "${EMSCRIPTEN_ROOT_PATH}/emranlib${EMCC_SUFFIX}" CACHE FILEPATH "Emscripten ranlib") endif() +if ("${CMAKE_C_COMPILER_AR}" STREQUAL "") + set(CMAKE_C_COMPILER_AR "${CMAKE_AR}" CACHE FILEPATH) +endif() +if ("${CMAKE_CXX_COMPILER_AR}" STREQUAL "") + set(CMAKE_CXX_COMPILER_AR "${CMAKE_AR}" CACHE FILEPATH) +endif() +if ("${CMAKE_C_COMPILER_RANLIB}" STREQUAL "") + set(CMAKE_C_COMPILER_RANLIB "${CMAKE_RANLIB}" CACHE FILEPATH) +endif() +if ("${CMAKE_CXX_COMPILER_RANLIB}" STREQUAL "") + set(CMAKE_CXX_COMPILER_RANLIB "${CMAKE_RANLIB}" CACHE FILEPATH) +endif() + # Don't allow CMake to autodetect the compiler, since it does not understand # Emscripten. # Pass -DEMSCRIPTEN_FORCE_COMPILERS=OFF to disable (sensible mostly only for