2012/6/15 Doug <[email protected]>: > Oddly, I was just doing that last night. Here's an example: > https://github.com/shadowmint/cmake-multi-install > > If you run: > mkdir build > cd build > cmake .. > cmake -G DEB > > It'll build two debian packages. > If you want RPMs I suspect you'll have to add: > > set(CPACK_RPM_COMPONENT_INSTALL ON) > > ...but you get the idea. > No idea why this isn't in the wiki. It keeps turning up as a question...
It is in the wiki: http://www.cmake.org/Wiki/CMake:Component_Install_With_CPack#CPack_Generator_specific_behavior but you are right it keeps popping-up :-] > Also, it doesn't work on all the pack builders. This is explained in the Wiki as well, some CPack generator are component-aware other are not. If you want to have a look at "COMPONENT" related CPack variable you can try: cpack --help-variable-list | grep -i COMPONENT in particular: $ cpack --help-variable "CPACK_<GENNAME>_COMPONENT_INSTALL" CPACK_<GENNAME>_COMPONENT_INSTALL Enable/Disable component install for CPack generator <GENNAME>. Each CPack Generator (RPM, DEB, ARCHIVE, NSIS, DMG, etc...) has a legacy default behavior. e.g. RPM builds monolithic whereas NSIS builds component. One can change the default behavior by setting this variable to 0/1 or OFF/ON. The current documentation does not say which generators supports COMPONENT install. The doc may be fixed, as usual patch are welcomed, and documentation patches may sometimes be more than welcomed. -- Erk Le gouvernement représentatif n'est pas la démocratie -- http://www.le-message.org -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
