summaryrefslogtreecommitdiffstats
path: root/Tests/MSVCRuntimeLibrary
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-10-04 15:18:21 (GMT)
committerKitware Robot <kwrobot@kitware.com>2023-10-04 15:18:40 (GMT)
commit1f00b0e2300299802bd01ba24271e901a428605d (patch)
tree529ec9f4558101e3f7528014fda6fa290750d4bb /Tests/MSVCRuntimeLibrary
parentbbba1879ffce1eda178950a3d06a2b185039c50e (diff)
parent26bf32cdc67271547ca0b0d38872f8f23a90d191 (diff)
downloadCMake-1f00b0e2300299802bd01ba24271e901a428605d.zip
CMake-1f00b0e2300299802bd01ba24271e901a428605d.tar.gz
CMake-1f00b0e2300299802bd01ba24271e901a428605d.tar.bz2
Merge topic 'LLVMFlang-MSVC' into release-3.28
26bf32cdc6 LLVMFlang: Add support for targeting MSVC ABI on Windows e9af7b9687 LLVMFlang: Add support for CMAKE_Fortran_COMPILER_TARGET 26fa048ffe Tests: Enable CMP0091/CMP0141 for MSVC settings in FortranOnly test 9d060b8682 Fortran: Save CMAKE_LINKER variable persistently for MSVC ABI 7571e653f4 CMakeDetermineCompilerABI: Add option to skip implicit link info parsing 12733d0d8d CMakeParseImplicitLinkInfo: Detect link lines using link.exe and lld-link Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8852
Diffstat (limited to 'Tests/MSVCRuntimeLibrary')
-rw-r--r--Tests/MSVCRuntimeLibrary/Fortran/CMakeLists.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/Tests/MSVCRuntimeLibrary/Fortran/CMakeLists.txt b/Tests/MSVCRuntimeLibrary/Fortran/CMakeLists.txt
index 41bd6f5..2a8a152 100644
--- a/Tests/MSVCRuntimeLibrary/Fortran/CMakeLists.txt
+++ b/Tests/MSVCRuntimeLibrary/Fortran/CMakeLists.txt
@@ -21,6 +21,13 @@ foreach(t MultiThreaded SingleThreaded)
endforeach()
endforeach()
endforeach()
+if(CMAKE_Fortran_COMPILER_ID STREQUAL "LLVMFlang")
+ # LLVMFlang does not actually define these, so inject them
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreaded "-D_MT")
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDLL "-D_MT;-D_DLL")
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDebug "-D_MT;-D_DEBUG")
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDebugDLL "-D_MT;-D_DEBUG;-D_DLL")
+endif()
string(APPEND CMAKE_Fortran_FLAGS " -w")
function(verify_combinations threads lang src)