summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake
diff options
context:
space:
mode:
authorJean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>2018-06-01 22:43:45 (GMT)
committerBrad King <brad.king@kitware.com>2018-06-04 15:37:52 (GMT)
commit7ad5165c675d23e9d3f8c076b7cb32a2618e7e96 (patch)
treea64ea177501c2bb492a58168500cd6465b0d6f35 /Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake
parent8738eba336d0f89cd3c183fe32413283abe9140d (diff)
downloadCMake-7ad5165c675d23e9d3f8c076b7cb32a2618e7e96.zip
CMake-7ad5165c675d23e9d3f8c076b7cb32a2618e7e96.tar.gz
CMake-7ad5165c675d23e9d3f8c076b7cb32a2618e7e96.tar.bz2
ExternalProject: Fix cache generation when args end with "-NOTFOUND"
Generalize the fix in commit v3.11.0-rc4~8^2 (ExternalProject: Fix cache generation when last args ends with "-NOTFOUND", 2018-03-10) to work for any argument rather than just the last one. ExternalProject can now successfully generate the cache file when any (not only the last one) cache variable associated with either `CMAKE_CACHE_ARGS` or `CMAKE_DEFAULT_CACHE_ARGS` configure step option is set to a `<value>` ending with `-NOTFOUND`.
Diffstat (limited to 'Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake')
-rw-r--r--Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake3
1 files changed, 2 insertions, 1 deletions
diff --git a/Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake b/Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake
index d388315..6133418 100644
--- a/Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake
+++ b/Tests/RunCMake/ExternalProject/CMAKE_CACHE_DEFAULT_ARGS.cmake
@@ -9,4 +9,5 @@ ExternalProject_Add(FOO TMP_DIR "${CMAKE_CURRENT_BINARY_DIR}/tmp"
CMAKE_CACHE_DEFAULT_ARGS
"-DFOO:STRING=$<1:BAR>$<0:BAD>"
"-DTEST_LIST:STRING=A;B;C"
- "-DTEST_OPTIONAL:FILEPATH=TEST_OPTIONAL-NOTFOUND")
+ "-DTEST_OPTIONAL:FILEPATH=TEST_OPTIONAL-NOTFOUND"
+ "-DTEST_OPTIONAL_LAST:FILEPATH=TEST_OPTIONAL_LAST-NOTFOUND")