summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeDetermineCompilerId.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-07-31 16:45:53 (GMT)
committerBrad King <brad.king@kitware.com>2019-07-31 16:52:35 (GMT)
commit863f7eb6d7237b47a4347a2c517fd435a0edd44f (patch)
treecfcd134ff38fb57fb6774bc15577ef0a9face292 /Modules/CMakeDetermineCompilerId.cmake
parentf43a7d76c737c5bb9b903a2b1be5186c081ec21e (diff)
downloadCMake-863f7eb6d7237b47a4347a2c517fd435a0edd44f.zip
CMake-863f7eb6d7237b47a4347a2c517fd435a0edd44f.tar.gz
CMake-863f7eb6d7237b47a4347a2c517fd435a0edd44f.tar.bz2
clang: Restore support for clang-cl on non-Windows hosts
The frontend variant detection logic added by commit 53fbe23f3f (clang: introduce CMAKE_<lang>_COMPILER_FRONTEND_VARIANT, 2019-02-20, v3.15.0-rc1~41^2~8) assumes that `clang-cl` only runs on a Windows host. It is also available on non-Windows hosts. Fix the condition. Fixes: #19544
Diffstat (limited to 'Modules/CMakeDetermineCompilerId.cmake')
-rw-r--r--Modules/CMakeDetermineCompilerId.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake
index 6083358..02bc14b 100644
--- a/Modules/CMakeDetermineCompilerId.cmake
+++ b/Modules/CMakeDetermineCompilerId.cmake
@@ -138,7 +138,7 @@ function(CMAKE_DETERMINE_COMPILER_ID lang flagvar src)
set(_variant "")
if("x${CMAKE_${lang}_COMPILER_ID}" STREQUAL "xClang")
- if(CMAKE_HOST_WIN32 AND "x${CMAKE_${lang}_SIMULATE_ID}" STREQUAL "xMSVC")
+ if("x${CMAKE_${lang}_SIMULATE_ID}" STREQUAL "xMSVC")
if(CMAKE_GENERATOR MATCHES "Visual Studio")
set(CMAKE_${lang}_COMPILER_FRONTEND_VARIANT "MSVC")
else()