summaryrefslogtreecommitdiff
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-11-09 11:23:57 -0500
committerBrad King <brad.king@kitware.com>2018-11-09 11:34:34 -0500
commitc84fb4812d99978c2608379825b78fe43cda8659 (patch)
tree91036aa5916e12d32c5fcb7d24ed185bb5fc1a71 /Modules
parent8d70ed5a10362209d265a15d993f319235aea7e5 (diff)
downloadcmake-c84fb4812d99978c2608379825b78fe43cda8659.tar.gz
ASM: Detect compiler id for Clang used as Assembler
Add missing vendor table entries for Clang and AppleClang to identify them. Previously this worked only if Clang was also enabled as a C or CXX compiler first because we used to copy the C compiler id. However, that was removed by commit v3.13.0-rc1~44^2 (ASM: Search for full path even when using C or C++ compiler, 2018-09-26). Fixes: #18575
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CMakeDetermineASMCompiler.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/Modules/CMakeDetermineASMCompiler.cmake b/Modules/CMakeDetermineASMCompiler.cmake
index 45dea8f788..dbc41c8c76 100644
--- a/Modules/CMakeDetermineASMCompiler.cmake
+++ b/Modules/CMakeDetermineASMCompiler.cmake
@@ -58,6 +58,14 @@ if(NOT CMAKE_ASM${ASM_DIALECT}_COMPILER_ID)
set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_FLAGS_GNU "--version")
set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_REGEX_GNU "(GNU assembler)|(GCC)|(Free Software Foundation)")
+ list(APPEND CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDORS Clang )
+ set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_FLAGS_Clang "--version")
+ set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_REGEX_Clang "(clang version)")
+
+ list(APPEND CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDORS AppleClang )
+ set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_FLAGS_AppleClang "--version")
+ set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_REGEX_AppleClang "(Apple LLVM version)")
+
list(APPEND CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDORS HP )
set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_FLAGS_HP "-V")
set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_REGEX_HP "HP C")