Merge topic 'clang-imsvc'

2fc5e5dba9 Clang: Use -imsvc for system include only with MSVC-like front-end

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Thomas Bernard <thomas@famillebernardgouriou.fr>
Merge-request: !5792
This commit is contained in:
Brad King
2021-02-10 12:45:53 +00:00
committed by Kitware Robot
2 changed files with 1 additions and 1 deletions

View File

@@ -19,7 +19,6 @@ if("x${CMAKE_C_SIMULATE_ID}" STREQUAL "xMSVC"
OR "x${CMAKE_CXX_SIMULATE_ID}" STREQUAL "xMSVC"
OR "x${CMAKE_Fortran_SIMULATE_ID}" STREQUAL "xMSVC")
macro(__compiler_clang lang)
set(CMAKE_INCLUDE_SYSTEM_FLAG_${lang} "-imsvc ")
endmacro()
else()
include(Compiler/GNU)

View File

@@ -174,6 +174,7 @@ if("x${CMAKE_C_SIMULATE_ID}" STREQUAL "xMSVC"
macro(__windows_compiler_clang_base lang)
set(_COMPILE_${lang} "${_COMPILE_${lang}_MSVC}")
__windows_compiler_msvc(${lang})
set(CMAKE_INCLUDE_SYSTEM_FLAG_${lang} "-imsvc ")
endmacro()
else()
cmake_policy(GET CMP0091 __WINDOWS_CLANG_CMP0091)