<p>I'm trying to find out a way to generate multiple packages from a big project. There are some patches and hack available but I'm not experienced cmake user and I can not figure out how to use them.</p><p>IMHO, an add_package command can be usefull instead of configuring cpack variables and including cpack module. </p>
<p> </p><p>For example;</p><p>I have created a library and I want to distribute it. But there is two type of distribution that I have to create. In the first distributions I include libraries, sample programs, runtime executives and documentation. In the other distribution, in addition to the components in the first distribution, I also want to include source files. </p>
<p>So a script like;</p><p>add_package(LibraryDistro COMPONENTS/GROUPS/TARGETS LibA LibB Runtime SampleA SampleB)</p><p>add_package(FullDistro COMPONENTS/GROUPS/TARGETS LibA LibB Runtime SampleA SampleB SourceFiles)</p><p>
#then we can use </p><p>set (LibraryDistro_PACKAGE_NAME "A Library")</p><p>set (LibraryDistro_PACKAGE_VENDOR "Me")</p><p> </p><p>set (FullDistro_PACKAGE_NAME "A Library + Source")</p><p>set (FullDistro_PACKAGE_VENDOR "Me")</p>
<p> </p><p>I think this can be very easy to use and maintain. This is just an sample there can be other types of commands something like add_target_to_package, add_component_to_package or add_component_group_to_package and etc with many different options.</p>
<p> </p><p> Multiple package generation can same time and effort when maintaining and deploying multiple configurations of a big project.</p><p> </p><p>Best regards,</p><p>Orçun</p>