summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/FeatureSummary/FeatureSummaryCustomRequired.cmake
diff options
context:
space:
mode:
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)