summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-12-06 13:50:08 (GMT)
committerKitware Robot <kwrobot@kitware.com>2023-12-06 13:50:18 (GMT)
commit5b6f7f44fb71d16c871e6c0a9c60331a782fe696 (patch)
treed2aa8937936e769ab5ea42c854f8c4359a1cf127 /Modules
parent2e75e1550ed00bf856b991d6e98b90f4731a708b (diff)
parentef49ed0fe1034b1452bea4965f637671e68c008d (diff)
downloadCMake-5b6f7f44fb71d16c871e6c0a9c60331a782fe696.zip
CMake-5b6f7f44fb71d16c871e6c0a9c60331a782fe696.tar.gz
CMake-5b6f7f44fb71d16c871e6c0a9c60331a782fe696.tar.bz2
Merge topic 'LLVMFlang-MSVC-debug'
ef49ed0fe1 LLVMFlang: Fix MSVC ABI debug information format options Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9037
Diffstat (limited to 'Modules')
-rw-r--r--Modules/Platform/Windows-LLVMFlang-Fortran.cmake12
1 files changed, 7 insertions, 5 deletions
diff --git a/Modules/Platform/Windows-LLVMFlang-Fortran.cmake b/Modules/Platform/Windows-LLVMFlang-Fortran.cmake
index 3e22a6e..57e36c6 100644
--- a/Modules/Platform/Windows-LLVMFlang-Fortran.cmake
+++ b/Modules/Platform/Windows-LLVMFlang-Fortran.cmake
@@ -17,11 +17,13 @@ elseif("x${CMAKE_Fortran_SIMULATE_ID}" STREQUAL "xMSVC")
set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDebug "")
set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDebugDLL "")
- # FIXME(LLVMFlang): It does not provide all debug information format flags or predefines.
- # It should be given a flag to enable Embedded debug information like MSVC -Z7.
- #set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_Embedded) # not supported by LLVMFlang
- #set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_EditAndContinue) # not supported by LLVMFlang
- set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_ProgramDatabase "-g")
+ # LLVMFlang, like Clang, does not provide all debug information format flags.
+ # In order to provide easy integration with C and C++ projects that use the
+ # other debug information formats, pretend to support them, and just do not
+ # actually generate any debug information for Fortran.
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_Embedded -g)
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_ProgramDatabase "") # not supported by LLVMFlang
+ set(CMAKE_Fortran_COMPILE_OPTIONS_MSVC_DEBUG_INFORMATION_FORMAT_EditAndContinue "") # not supported by LLVMFlang
set(CMAKE_Fortran_COMPILE_OBJECT "<CMAKE_Fortran_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -o <OBJECT> -c <SOURCE>")