From 70623f3bbfa80b6e2b20eeaeb0199a6e828ba41c Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 10 Aug 2023 10:22:59 -0400 Subject: Tests: Fix RunCMake.BuildDepends Fortran case with Intel compiler on Windows The test regularly fails updating the `vc*.pdb` compiler-generated PDB file. Add the `/Z7` flag as the compiler suggests for this. --- Tests/RunCMake/BuildDepends/FortranInclude.cmake | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Tests/RunCMake/BuildDepends/FortranInclude.cmake b/Tests/RunCMake/BuildDepends/FortranInclude.cmake index fa9f399..ad5fd0a 100644 --- a/Tests/RunCMake/BuildDepends/FortranInclude.cmake +++ b/Tests/RunCMake/BuildDepends/FortranInclude.cmake @@ -1,5 +1,10 @@ enable_language(Fortran) +if("${CMAKE_Fortran_COMPILER_ID};${CMAKE_Fortran_SIMULATE_ID}" MATCHES "^Intel(LLVM)?;MSVC$") + string(APPEND CMAKE_Fortran_FLAGS_DEBUG " -Z7") + string(APPEND CMAKE_Fortran_FLAGS_RELWITHDEBINFO " -Z7") +endif() + set(check_pairs "") add_executable(preprocess FortranIncludePreprocess.F) -- cgit v0.12