diff options
author | Brad King <brad.king@kitware.com> | 2022-11-10 17:51:34 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-11-10 17:57:55 (GMT) |
commit | 93ff726114cce9390728d6ff701526f491a14709 (patch) | |
tree | 4e82982af5141335f9acae5d2f9aea7adc4eb5d7 | |
parent | e242fa19caa152e7c317fde7f6eb79fb04451982 (diff) | |
download | CMake-93ff726114cce9390728d6ff701526f491a14709.zip CMake-93ff726114cce9390728d6ff701526f491a14709.tar.gz CMake-93ff726114cce9390728d6ff701526f491a14709.tar.bz2 |
Tests: Fix TryCompile bad source case for clang-cl 15 on Windows
When `pass.c bad#source.c` passes through `nmake`, the compiler gets
`pass.c bad`. The clang-cl 15 compiler now fails on `bad` with an
error that we did not previously match. Update our regex.
-rw-r--r-- | Tests/TryCompile/old_and_new_signature_tests.cmake | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Tests/TryCompile/old_and_new_signature_tests.cmake b/Tests/TryCompile/old_and_new_signature_tests.cmake index ab548f7..1373ad7 100644 --- a/Tests/TryCompile/old_and_new_signature_tests.cmake +++ b/Tests/TryCompile/old_and_new_signature_tests.cmake @@ -117,7 +117,7 @@ try_compile(SHOULD_FAIL_DUE_TO_BAD_SOURCE if(SHOULD_FAIL_DUE_TO_BAD_SOURCE AND NOT CMAKE_GENERATOR MATCHES "Watcom WMake|NMake Makefiles") string(REPLACE "\n" "\n " output " ${output}") message(SEND_ERROR "try_compile with bad#source.c did not fail:\n${output}") -elseif(NOT output MATCHES [[(bad#source\.c|bad\.c|bad')]]) +elseif(NOT output MATCHES [[(bad#source\.c|bad\.c|bad[':])]]) string(REPLACE "\n" "\n " output " ${output}") message(SEND_ERROR "try_compile with bad#source.c failed without mentioning bad source:\n${output}") else() |