diff options
author | Brad King <brad.king@kitware.com> | 2018-11-15 15:39:48 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2018-11-15 15:39:55 (GMT) |
commit | 59fc717c252fb6613b35ff3a7d2cf01e91ab6a69 (patch) | |
tree | b3904080d14f5c4760c1996c89bcbc76e2e05e77 /Tests | |
parent | 64df9ef33a2f4eb9ef0cb17a2844308d9c7f7034 (diff) | |
parent | 0f5c1b404b0f9cbe652cf306e9dca0c25c70876f (diff) | |
download | CMake-59fc717c252fb6613b35ff3a7d2cf01e91ab6a69.zip CMake-59fc717c252fb6613b35ff3a7d2cf01e91ab6a69.tar.gz CMake-59fc717c252fb6613b35ff3a7d2cf01e91ab6a69.tar.bz2 |
Merge topic 'deprecate-findqt'
0f5c1b404b find_package(): Add policy to remove the FindQt module
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: noo mook <noomook2519@gmail.com>
Merge-request: !2554
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/RunCMake/find_package/CMP0084-NEW-stderr.txt | 20 | ||||
-rw-r--r-- | Tests/RunCMake/find_package/CMP0084-NEW.cmake | 7 | ||||
-rw-r--r-- | Tests/RunCMake/find_package/CMP0084-OLD.cmake | 7 | ||||
-rw-r--r-- | Tests/RunCMake/find_package/CMP0084-WARN-stderr.txt | 8 | ||||
-rw-r--r-- | Tests/RunCMake/find_package/CMP0084-WARN.cmake | 6 | ||||
-rw-r--r-- | Tests/RunCMake/find_package/RunCMakeTest.cmake | 3 |
6 files changed, 51 insertions, 0 deletions
diff --git a/Tests/RunCMake/find_package/CMP0084-NEW-stderr.txt b/Tests/RunCMake/find_package/CMP0084-NEW-stderr.txt new file mode 100644 index 0000000..280ff8c --- /dev/null +++ b/Tests/RunCMake/find_package/CMP0084-NEW-stderr.txt @@ -0,0 +1,20 @@ +^CMake Warning at CMP0084-NEW\.cmake:[0-9]+ \(find_package\): + No "FindQt\.cmake" found in CMAKE_MODULE_PATH\. +Call Stack \(most recent call first\): + CMakeLists\.txt:3 \(include\) ++ +CMake Warning \(dev\) at CMP0084-NEW\.cmake:[0-9]+ \(find_package\): + FindQt\.cmake must either be part of this project itself, in this case + adjust CMAKE_MODULE_PATH so that it points to the correct location inside + its source tree\. + + Or it must be installed by a package which has already been found via + find_package\(\)\. In this case make sure that package has indeed been found + and adjust CMAKE_MODULE_PATH to contain the location where that package has + installed FindQt\.cmake\. This must be a location provided by that package\. + This error in general means that the buildsystem of this project is relying + on a Find-module without ensuring that it is actually available\. + +Call Stack \(most recent call first\): + CMakeLists\.txt:[0-9]+ \(include\) +This warning is for project developers\. Use -Wno-dev to suppress it\.$ diff --git a/Tests/RunCMake/find_package/CMP0084-NEW.cmake b/Tests/RunCMake/find_package/CMP0084-NEW.cmake new file mode 100644 index 0000000..68fd6cf --- /dev/null +++ b/Tests/RunCMake/find_package/CMP0084-NEW.cmake @@ -0,0 +1,7 @@ +cmake_policy(SET CMP0084 NEW) +set(_findqt_testing TRUE) +find_package(Qt MODULE) + +if(_findqt_included) + message(FATAL_ERROR "FindQt.cmake erroneously included") +endif() diff --git a/Tests/RunCMake/find_package/CMP0084-OLD.cmake b/Tests/RunCMake/find_package/CMP0084-OLD.cmake new file mode 100644 index 0000000..7bd4726 --- /dev/null +++ b/Tests/RunCMake/find_package/CMP0084-OLD.cmake @@ -0,0 +1,7 @@ +cmake_policy(SET CMP0084 OLD) +set(_findqt_testing TRUE) +find_package(Qt MODULE) + +if(NOT _findqt_included) + message(FATAL_ERROR "FindQt.cmake not included") +endif() diff --git a/Tests/RunCMake/find_package/CMP0084-WARN-stderr.txt b/Tests/RunCMake/find_package/CMP0084-WARN-stderr.txt new file mode 100644 index 0000000..9ecebd3 --- /dev/null +++ b/Tests/RunCMake/find_package/CMP0084-WARN-stderr.txt @@ -0,0 +1,8 @@ +^CMake Warning \(dev\) at CMP0084-WARN\.cmake:[0-9]+ \(find_package\): + Policy CMP0084 is not set: The FindQt module does not exist for + find_package\(\)\. Run "cmake --help-policy CMP0084" for policy details\. Use + the cmake_policy command to set the policy and suppress this warning\. + +Call Stack \(most recent call first\): + CMakeLists\.txt:[0-9]+ \(include\) +This warning is for project developers\. Use -Wno-dev to suppress it\.$ diff --git a/Tests/RunCMake/find_package/CMP0084-WARN.cmake b/Tests/RunCMake/find_package/CMP0084-WARN.cmake new file mode 100644 index 0000000..4ea22cb --- /dev/null +++ b/Tests/RunCMake/find_package/CMP0084-WARN.cmake @@ -0,0 +1,6 @@ +set(_findqt_testing TRUE) +find_package(Qt MODULE) + +if(NOT _findqt_included) + message(FATAL_ERROR "FindQt.cmake not included") +endif() diff --git a/Tests/RunCMake/find_package/RunCMakeTest.cmake b/Tests/RunCMake/find_package/RunCMakeTest.cmake index c068402..e9f3558 100644 --- a/Tests/RunCMake/find_package/RunCMakeTest.cmake +++ b/Tests/RunCMake/find_package/RunCMakeTest.cmake @@ -23,3 +23,6 @@ run_cmake(PolicyPop) run_cmake(SetFoundFALSE) run_cmake(WrongVersion) run_cmake(WrongVersionConfig) +run_cmake(CMP0084-OLD) +run_cmake(CMP0084-WARN) +run_cmake(CMP0084-NEW) |