[CMake] install component shared library

David Ojeda david.ojeda at gmail.com
Fri Jun 4 10:14:17 EDT 2010


Hello all,

I have a problem using the COMPONENT property of the install command. My
CMakeLists.txt has several install commands:

# some files...
install(FILES ${some_var} DESTINATION include/xxx COMPONENT headers)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/somefile.txt"
    DESTINATION share/txt
    COMPONENT extras)
# a shared library created with add_library(mylib SHARED ${somefiles})
install(TARGETS mylib
    RUNTIME DESTINATION bin
    LIBRARY DESTINATION lib
    ARCHIVE DESTINATION lib/static
    COMPONENT libraries)

When I do
make list_install_components
I get:
Available install components are: "Unspecified" "extras" "headers"

My question is: why I don't have a "libraries" component? Does the COMPONENT
property works with shared libraries?

Thank you for your help

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100604/96cf12a2/attachment-0001.htm>


More information about the CMake mailing list