diff options
author | Brad King <brad.king@kitware.com> | 2014-06-24 15:42:39 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-06-24 17:11:45 (GMT) |
commit | abebcd235c94e05a20003430981a1b46b0fb7f95 (patch) | |
tree | c2ae34e12157047ce2ab8f0e2c16dc4f5c3610d1 /Tests/RunCMake/file | |
parent | 464567a577555659610b2a26f9c1733d672583de (diff) | |
download | CMake-abebcd235c94e05a20003430981a1b46b0fb7f95.zip CMake-abebcd235c94e05a20003430981a1b46b0fb7f95.tar.gz CMake-abebcd235c94e05a20003430981a1b46b0fb7f95.tar.bz2 |
file(INSTALL): Add undocumented options to control output verbosity
Create options "MESSAGE_ALWAYS", "MESSAGE_LAZY", and "MESSAGE_NEVER" to
specify whether to print the "Installing" and "Up-to-date" messages.
Extend the RunCMake.file test with cases covering these options.
Diffstat (limited to 'Tests/RunCMake/file')
-rw-r--r-- | Tests/RunCMake/file/INSTALL-DIRECTORY-stdout.txt | 2 | ||||
-rw-r--r-- | Tests/RunCMake/file/INSTALL-DIRECTORY.cmake | 3 | ||||
-rw-r--r-- | Tests/RunCMake/file/INSTALL-MESSAGE-bad-result.txt | 1 | ||||
-rw-r--r-- | Tests/RunCMake/file/INSTALL-MESSAGE-bad-stderr.txt | 32 | ||||
-rw-r--r-- | Tests/RunCMake/file/INSTALL-MESSAGE-bad.cmake | 6 | ||||
-rw-r--r-- | Tests/RunCMake/file/RunCMakeTest.cmake | 1 |
6 files changed, 45 insertions, 0 deletions
diff --git a/Tests/RunCMake/file/INSTALL-DIRECTORY-stdout.txt b/Tests/RunCMake/file/INSTALL-DIRECTORY-stdout.txt index d2e6f4d..561a6b1 100644 --- a/Tests/RunCMake/file/INSTALL-DIRECTORY-stdout.txt +++ b/Tests/RunCMake/file/INSTALL-DIRECTORY-stdout.txt @@ -3,4 +3,6 @@ -- Installing: .*/Tests/RunCMake/file/INSTALL-DIRECTORY-build/dir/empty.txt -- Up-to-date: .*/Tests/RunCMake/file/INSTALL-DIRECTORY-build/dir -- Up-to-date: .*/Tests/RunCMake/file/INSTALL-DIRECTORY-build/dir/empty.txt +-- Up-to-date: .*/Tests/RunCMake/file/INSTALL-DIRECTORY-build/dir +-- Up-to-date: .*/Tests/RunCMake/file/INSTALL-DIRECTORY-build/dir/empty.txt -- After Installing diff --git a/Tests/RunCMake/file/INSTALL-DIRECTORY.cmake b/Tests/RunCMake/file/INSTALL-DIRECTORY.cmake index 8bcb077..0bc1d18 100644 --- a/Tests/RunCMake/file/INSTALL-DIRECTORY.cmake +++ b/Tests/RunCMake/file/INSTALL-DIRECTORY.cmake @@ -4,4 +4,7 @@ file(REMOVE RECURSE ${dst}) message(STATUS "Before Installing") file(INSTALL FILES ${src}/ DESTINATION ${dst} TYPE DIRECTORY) file(INSTALL FILES ${src}/ DESTINATION ${dst} TYPE DIRECTORY) +file(INSTALL FILES ${src}/ DESTINATION ${dst} TYPE DIRECTORY MESSAGE_NEVER) +file(INSTALL FILES ${src}/ DESTINATION ${dst} TYPE DIRECTORY MESSAGE_LAZY) +file(INSTALL FILES ${src}/ DESTINATION ${dst} TYPE DIRECTORY MESSAGE_ALWAYS) message(STATUS "After Installing") diff --git a/Tests/RunCMake/file/INSTALL-MESSAGE-bad-result.txt b/Tests/RunCMake/file/INSTALL-MESSAGE-bad-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/file/INSTALL-MESSAGE-bad-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/file/INSTALL-MESSAGE-bad-stderr.txt b/Tests/RunCMake/file/INSTALL-MESSAGE-bad-stderr.txt new file mode 100644 index 0000000..557b817 --- /dev/null +++ b/Tests/RunCMake/file/INSTALL-MESSAGE-bad-stderr.txt @@ -0,0 +1,32 @@ +CMake Error at INSTALL-MESSAGE-bad.cmake:1 \(file\): + file INSTALL options MESSAGE_ALWAYS, MESSAGE_LAZY, and MESSAGE_NEVER are + mutually exclusive. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at INSTALL-MESSAGE-bad.cmake:2 \(file\): + file INSTALL options MESSAGE_ALWAYS, MESSAGE_LAZY, and MESSAGE_NEVER are + mutually exclusive. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at INSTALL-MESSAGE-bad.cmake:3 \(file\): + file INSTALL options MESSAGE_ALWAYS, MESSAGE_LAZY, and MESSAGE_NEVER are + mutually exclusive. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at INSTALL-MESSAGE-bad.cmake:4 \(file\): + file option MESSAGE_ALWAYS may not appear after PATTERN or REGEX. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at INSTALL-MESSAGE-bad.cmake:5 \(file\): + file option MESSAGE_LAZY may not appear after PATTERN or REGEX. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) ++ +CMake Error at INSTALL-MESSAGE-bad.cmake:6 \(file\): + file option MESSAGE_NEVER may not appear after PATTERN or REGEX. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) diff --git a/Tests/RunCMake/file/INSTALL-MESSAGE-bad.cmake b/Tests/RunCMake/file/INSTALL-MESSAGE-bad.cmake new file mode 100644 index 0000000..f878c69 --- /dev/null +++ b/Tests/RunCMake/file/INSTALL-MESSAGE-bad.cmake @@ -0,0 +1,6 @@ +file(INSTALL DESTINATION dir MESSAGE_ALWAYS MESSAGE_LAZY) +file(INSTALL DESTINATION dir MESSAGE_ALWAYS MESSAGE_NEVER) +file(INSTALL DESTINATION dir MESSAGE_LAZY MESSAGE_NEVER) +file(INSTALL DESTINATION dir PATTERN *.txt MESSAGE_ALWAYS) +file(INSTALL DESTINATION dir PATTERN *.txt MESSAGE_LAZY) +file(INSTALL DESTINATION dir PATTERN *.txt MESSAGE_NEVER) diff --git a/Tests/RunCMake/file/RunCMakeTest.cmake b/Tests/RunCMake/file/RunCMakeTest.cmake index 09e3629..bf14263 100644 --- a/Tests/RunCMake/file/RunCMakeTest.cmake +++ b/Tests/RunCMake/file/RunCMakeTest.cmake @@ -1,4 +1,5 @@ include(RunCMake) run_cmake(INSTALL-DIRECTORY) +run_cmake(INSTALL-MESSAGE-bad) run_cmake(FileOpenFailRead) |