From 72e7fa973e80fbc549007670b0894be00b5491c1 Mon Sep 17 00:00:00 2001 From: Julian Ste <31321934+julian-st@users.noreply.github.com> Date: Fri, 26 Nov 2021 09:38:47 +0100 Subject: [PATCH] Update module-install.cmake --- cmake/module-install.cmake | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/cmake/module-install.cmake b/cmake/module-install.cmake index 4506ea6e..44954d10 100644 --- a/cmake/module-install.cmake +++ b/cmake/module-install.cmake @@ -57,16 +57,25 @@ endforeach() ####################################################################################### -install(TARGETS ${OATPP_THIS_MODULE_TARGETS} - EXPORT "${OATPP_MODULE_NAME}Targets" - ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}/oatpp-${OATPP_MODULE_VERSION}" - LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}/oatpp-${OATPP_MODULE_VERSION}" - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}/oatpp-${OATPP_MODULE_VERSION}" - INCLUDES DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/oatpp-${OATPP_MODULE_VERSION}/${OATPP_MODULE_NAME}" +install( + TARGETS ${OATPP_THIS_MODULE_TARGETS} + EXPORT "${OATPP_MODULE_NAME}Targets" + ARCHIVE + DESTINATION "${CMAKE_INSTALL_LIBDIR}/oatpp-${OATPP_MODULE_VERSION}" + COMPONENT Devel + LIBRARY + DESTINATION "${CMAKE_INSTALL_LIBDIR}/oatpp-${OATPP_MODULE_VERSION}" + COMPONENT Library + RUNTIME + DESTINATION "${CMAKE_INSTALL_BINDIR}/oatpp-${OATPP_MODULE_VERSION}" + COMPONENT Library + INCLUDES + DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/oatpp-${OATPP_MODULE_VERSION}/${OATPP_MODULE_NAME}" ) install(DIRECTORY ${OATPP_DIRS_TO_INSTALL} DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/oatpp-${OATPP_MODULE_VERSION}/${OATPP_MODULE_NAME}" + COMPONENT Devel FILES_MATCHING PATTERN "*.hpp" ) @@ -74,6 +83,7 @@ install(EXPORT "${OATPP_MODULE_NAME}Targets" FILE "${OATPP_MODULE_NAME}Targets.cmake" NAMESPACE oatpp:: DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${OATPP_MODULE_NAME}-${OATPP_MODULE_VERSION}" + COMPONENT Devel ) include(CMakePackageConfigHelpers) @@ -104,4 +114,5 @@ install( "${CMAKE_CURRENT_BINARY_DIR}/${OATPP_MODULE_NAME}ConfigVersion.cmake" DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${OATPP_MODULE_NAME}-${OATPP_MODULE_VERSION}" -) \ No newline at end of file + COMPONENT Devel +)