summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cmCPackGenerator.h
diff options
context:
space:
mode:
authorClinton Stimpson <clinton@elemtech.com>2011-03-25 16:18:59 (GMT)
committerBrad King <brad.king@kitware.com>2011-03-31 17:33:03 (GMT)
commit64a5e209998f12662a56346f855b1973cbbd0440 (patch)
tree7c4c071ee6ae358399d0ddfb7ea2b058826d20ca /Source/CPack/cmCPackGenerator.h
parent148b528f9d7d991dc01f277624df4a8aa41feccc (diff)
downloadCMake-64a5e209998f12662a56346f855b1973cbbd0440.zip
CMake-64a5e209998f12662a56346f855b1973cbbd0440.tar.gz
CMake-64a5e209998f12662a56346f855b1973cbbd0440.tar.bz2
Combine component packaging methods into an enum.
Also allow generators to override the default packaging method. Add a ONE_PER_GROUP option so that method can be specified by the user without relying on defaults.
Diffstat (limited to 'Source/CPack/cmCPackGenerator.h')
-rw-r--r--Source/CPack/cmCPackGenerator.h26
1 files changed, 19 insertions, 7 deletions
diff --git a/Source/CPack/cmCPackGenerator.h b/Source/CPack/cmCPackGenerator.h
index 9549d0b..f09c2a7 100644
--- a/Source/CPack/cmCPackGenerator.h
+++ b/Source/CPack/cmCPackGenerator.h
@@ -125,7 +125,7 @@ protected:
* CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE
* CPACK_COMPONENTS_IGNORE_GROUPS
* or
- * CPACK_COMPONENTS_GROUPING
+ * CPACK_COMPONENTS_ONE_PACKAGE_PER_GROUP
* @return 1 on success 0 on failure.
*/
virtual int PrepareGroupingKind();
@@ -237,16 +237,28 @@ protected:
*/
std::map<std::string, cmCPackComponent> Components;
std::map<std::string, cmCPackComponentGroup> ComponentGroups;
+
/**
- * If true All component will be put in a single package.
+ * If components are enabled, this enum represents the different
+ * ways of mapping components to package files.
*/
- bool allComponentInOne;
+ enum ComponentPackageMethod
+ {
+ /* one package for all components */
+ ONE_PACKAGE,
+ /* one package for each component */
+ ONE_PACKAGE_PER_COMPONENT,
+ /* one package for each group, with left over components in their own package */
+ ONE_PACKAGE_PER_GROUP,
+ UNKNOWN_COMPONENT_PACKAGE_METHOD
+ };
+
/**
- * If true component grouping will be ignored.
- * You will still get 1 package for each component unless
- * allComponentInOne is true.
+ * The component package method
+ * The default is ONE_PACKAGE_PER_GROUP, and generators may override the default
+ * before PrepareGroupingKind() is called.
*/
- bool ignoreComponentGroup;
+ ComponentPackageMethod componentPackageMethod;
cmCPackLog* Logger;
private: