summaryrefslogtreecommitdiffstats
path: root/Modules/Platform/Windows-MSVC.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-09-29 12:09:39 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2016-09-29 12:09:39 (GMT)
commitb53a12c29cff61d8f97997a63a00e7ca59b566ba (patch)
treed44a392e408298cd75951be0f7ae15c944485ee1 /Modules/Platform/Windows-MSVC.cmake
parent7cea3479d647ecf1957a4ed1f127a25197ac519e (diff)
parent3f300b84f312c340e92ff010c18dfebbeb4edff4 (diff)
downloadCMake-b53a12c29cff61d8f97997a63a00e7ca59b566ba.zip
CMake-b53a12c29cff61d8f97997a63a00e7ca59b566ba.tar.gz
CMake-b53a12c29cff61d8f97997a63a00e7ca59b566ba.tar.bz2
Merge topic 'vs-clang-llvm-support'
3f300b84 VS: Recognize VS/LLVM toolset names as Clang
Diffstat (limited to 'Modules/Platform/Windows-MSVC.cmake')
-rw-r--r--Modules/Platform/Windows-MSVC.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/Platform/Windows-MSVC.cmake b/Modules/Platform/Windows-MSVC.cmake
index 5055eef..d72ec66 100644
--- a/Modules/Platform/Windows-MSVC.cmake
+++ b/Modules/Platform/Windows-MSVC.cmake
@@ -182,7 +182,7 @@ else()
if(_MSVC_C_ARCHITECTURE_FAMILY STREQUAL "ARM" OR _MSVC_CXX_ARCHITECTURE_FAMILY STREQUAL "ARM")
set(CMAKE_C_STANDARD_LIBRARIES_INIT "kernel32.lib user32.lib")
elseif(MSVC_VERSION GREATER 1310)
- if(CMAKE_VS_PLATFORM_TOOLSET MATCHES "v[0-9]+_clang_.*")
+ if(CMAKE_VS_PLATFORM_TOOLSET MATCHES "(v[0-9]+_clang_.*|LLVM-vs[0-9]+.*)")
# Clang/C2 in MSVC14 Update 1 seems to not support -fsantinize (yet?)
# set(_RTC1 "-fsantinize=memory,safe-stack")
set(_FLAGS_CXX " -frtti -fexceptions")
@@ -281,7 +281,7 @@ macro(__windows_compiler_msvc lang)
if("x${lang}" STREQUAL "xC" OR
"x${lang}" STREQUAL "xCXX")
- if(CMAKE_VS_PLATFORM_TOOLSET MATCHES "v[0-9]+_clang_.*")
+ if(CMAKE_VS_PLATFORM_TOOLSET MATCHES "(v[0-9]+_clang_.*|LLVM-vs[0-9]+.*)")
# note: MSVC 14 2015 Update 1 sets -fno-ms-compatibility by default, but this does not allow one to compile many projects
# that include MS's own headers. CMake itself is affected project too.
string(APPEND CMAKE_${lang}_FLAGS_INIT " ${_PLATFORM_DEFINES}${_PLATFORM_DEFINES_${lang}} -fms-extensions -fms-compatibility -D_WINDOWS -Wall${_FLAGS_${lang}}")