summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeOnly/CMakeLists.txt
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2012-02-17 17:41:39 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2012-02-17 17:41:39 (GMT)
commit9090572f5cdde7b30d2c1ad1c0bbf4ab86ddb969 (patch)
tree4069a3f908fd7d1fa0709c774ad476152f4dcd77 /Tests/CMakeOnly/CMakeLists.txt
parente2042b68d36e0881bfc00f926a275dda3d6cbc9d (diff)
downloadCMake-9090572f5cdde7b30d2c1ad1c0bbf4ab86ddb969.zip
CMake-9090572f5cdde7b30d2c1ad1c0bbf4ab86ddb969.tar.gz
CMake-9090572f5cdde7b30d2c1ad1c0bbf4ab86ddb969.tar.bz2
Add ability to include a file in a project via a cache variable.
If a variable exists called CMAKE_PROJECT_<projectName>_INCLUDE, the file pointed to by that variable will be included as the last step of the project command.
Diffstat (limited to 'Tests/CMakeOnly/CMakeLists.txt')
-rw-r--r--Tests/CMakeOnly/CMakeLists.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/Tests/CMakeOnly/CMakeLists.txt b/Tests/CMakeOnly/CMakeLists.txt
index 4407efb..629f578 100644
--- a/Tests/CMakeOnly/CMakeLists.txt
+++ b/Tests/CMakeOnly/CMakeLists.txt
@@ -22,3 +22,11 @@ add_CMakeOnly_test(CheckLanguage)
add_CMakeOnly_test(AllFindModules)
add_CMakeOnly_test(TargetScope)
+
+add_CMakeOnly_test(ProjectInclude)
+
+add_test(CMakeOnly.ProjectInclude ${CMAKE_CMAKE_COMMAND}
+ -DTEST=ProjectInclude
+ -DCMAKE_ARGS=-DCMAKE_PROJECT_ProjectInclude_INCLUDE=${CMAKE_CURRENT_SOURCE_DIR}/ProjectInclude/include.cmake
+ -P ${CMAKE_CURRENT_BINARY_DIR}/Test.cmake
+ )