You could use file(GLOB_RECURSE files *.h) or install the main directory with install(DIRECTORY ... ) and exclude every non-header file (and possibly svn..)
Andreas Am 12.07.2011 05:04, schrieb Laszlo Papp:
Hi, I have just realized this snippet in my CMakeLists.txt file: install(FILES atticamanager.h authentication.h DESTINATION ${INCLUDE_INSTALL_DIR}/gluon/player/lib COMPONENT Devel ) install(FILES archive/archive.h DESTINATION ${INCLUDE_INSTALL_DIR}/gluon/player/lib/archive COMPONENT Devel ) install(FILES models/commentitemsmodel.h models/gameitemsmodel.h models/highscoresmodel.h DESTINATION ${INCLUDE_INSTALL_DIR}/gluon/player/lib/models COMPONENT Devel ) I wonder whether it could be done smarter. In the example above, there are subfolders like archive, models. It could also contain 5-10 subfolders (even more) and we install the headers this way: one separate install section for each subfolder even if we explicitely write the subfolders all the time, like "archive/archive.h", "models/commentitemsmodel.h", et cetera. Are we doing it wrong and there is already a smarter cmake option for this ? I find it useful if there is just one section for those things, but if it is technically not possible or against the design, please let me know. Best Regards, Laszlo Papp _______________________________________________ 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
_______________________________________________ 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