summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-01-30 13:43:23 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2017-01-30 13:43:23 (GMT)
commit8df12fc9d4b52cdd18d4fa9408325be7d0c28ed2 (patch)
tree8162de8c02229d0d5a2e7824fed6e67031d7af48 /Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake
parent5c6c766da1b30f2d886ba369a4c407e575ee1ccf (diff)
parent560574b0c03f2cd8f34cf4a90f6f41648b08a1e9 (diff)
downloadCMake-8df12fc9d4b52cdd18d4fa9408325be7d0c28ed2.zip
CMake-8df12fc9d4b52cdd18d4fa9408325be7d0c28ed2.tar.gz
CMake-8df12fc9d4b52cdd18d4fa9408325be7d0c28ed2.tar.bz2
Merge topic 'FeatureSummary_enhancement'
560574b0 FeatureSummary: Update release notes 3cfde818 FeatureSummary: Refactor to use global properties for package types f0165eb6 FeatureSummary: Allow lists of dependencies in ADD_FEATURE_INFO 9da7bf08 FeatureSummary: Add QUIET_ON_EMPTY option to feature_summary 4cf4aceb FeatureSummary: Add unit tests 614a97a5 FeatureSummary: Do not force OPTIONAL type in SET_PACKAGE_PROPERTIES 65a0bfd8 FeatureSummary: Add deprecation warnings to deprecated commands 4da3cae9 FeatureSummary: Clean printed output
Diffstat (limited to 'Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake')
-rw-r--r--Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake16
1 files changed, 16 insertions, 0 deletions
diff --git a/Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake b/Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake
new file mode 100644
index 0000000..11cf04c
--- /dev/null
+++ b/Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake
@@ -0,0 +1,16 @@
+include(FeatureSummary)
+
+list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR})
+
+set_property(GLOBAL PROPERTY FeatureSummary_PKG_TYPES TYPE1 TYPE2 TYPE3)
+set_property(GLOBAL PROPERTY FeatureSummary_REQUIRED_PKG_TYPES TYPE3)
+set_property(GLOBAL PROPERTY FeatureSummary_DEFAULT_PKG_TYPE TYPE2)
+
+find_package(Foo)
+find_package(Bar)
+
+set_package_properties(Foo PROPERTIES TYPE TYPE3)
+feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
+
+set_package_properties(Bar PROPERTIES TYPE TYPE3)
+feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)