diff options
author | Brad King <brad.king@kitware.com> | 2021-07-07 13:34:42 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-07-07 13:34:48 (GMT) |
commit | 1eaef541cf72f314945ae3bff0562cd2da4614a4 (patch) | |
tree | 3a1b3918ce2d071eac88ffe701c613dc55035d83 /Modules | |
parent | d49b507bb6fb798bdab3edc738af80495efa979f (diff) | |
parent | 0602e358588690de71988b9e39dbc60c627cba0b (diff) | |
download | CMake-1eaef541cf72f314945ae3bff0562cd2da4614a4.zip CMake-1eaef541cf72f314945ae3bff0562cd2da4614a4.tar.gz CMake-1eaef541cf72f314945ae3bff0562cd2da4614a4.tar.bz2 |
Merge topic 'ifort_win32_log'
0602e35858 Intel/Fortran: Avoid recording warning 5117 lines in CMakeError.log
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6308
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/CMakeDetermineCompilerId.cmake | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake index bd1e732..fb5d773 100644 --- a/Modules/CMakeDetermineCompilerId.cmake +++ b/Modules/CMakeDetermineCompilerId.cmake @@ -722,7 +722,7 @@ Id flags: ${testflags} ${CMAKE_${lang}_COMPILER_ID_FLAGS_ALWAYS} # Check the result of compilation. if(CMAKE_${lang}_COMPILER_ID_RESULT # Intel Fortran warns and ignores preprocessor lines without /fpp - OR CMAKE_${lang}_COMPILER_ID_OUTPUT MATCHES "Bad # preprocessor line" + OR CMAKE_${lang}_COMPILER_ID_OUTPUT MATCHES "warning #5117: Bad # preprocessor line" ) # Compilation failed. set(MSG @@ -733,7 +733,10 @@ ${CMAKE_${lang}_COMPILER_ID_RESULT} ${CMAKE_${lang}_COMPILER_ID_OUTPUT} ") - file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log "${MSG}") + # Log the output unless we recognize it as a known-bad case. + if(NOT CMAKE_${lang}_COMPILER_ID_OUTPUT MATCHES "warning #5117: Bad # preprocessor line") + file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log "${MSG}") + endif() # Some languages may know the correct/desired set of flags and want to fail right away if they don't work. # This is currently only used by CUDA. |