cmake: Fix assimp target install rule fully specifying component
This commit ensures generated install rules for the assimp target are all consistently associated with components named after LIBASSIMP_COMPONENT or LIBASSIMP-DEV_COMPONENT CMake variables. It streamlines the packaging of specific components of assimp in client projects leveraging the CPACK_INSTALL_CMAKE_PROJECTS variable. Failing to do so leads to "/path/to/assimp-build/code/cmake_install.cmake" file having install rules associated with a component called "Unspecified". See https://cmake.org/cmake/help/v3.10/command/install.html#installing-targets and https://cmake.org/cmake/help/v3.22/module/CPack.html#variable:CPACK_INSTALL_CMAKE_PROJECTSpull/4391/head
parent
510504a2c6
commit
33a48c6ca6
|
@ -1317,11 +1317,10 @@ ENDIF ()
|
|||
|
||||
INSTALL( TARGETS assimp
|
||||
EXPORT "${TARGETS_EXPORT_NAME}"
|
||||
LIBRARY DESTINATION ${ASSIMP_LIB_INSTALL_DIR}
|
||||
ARCHIVE DESTINATION ${ASSIMP_LIB_INSTALL_DIR}
|
||||
RUNTIME DESTINATION ${ASSIMP_BIN_INSTALL_DIR}
|
||||
FRAMEWORK DESTINATION ${ASSIMP_LIB_INSTALL_DIR}
|
||||
COMPONENT ${LIBASSIMP_COMPONENT}
|
||||
LIBRARY DESTINATION ${ASSIMP_LIB_INSTALL_DIR} COMPONENT ${LIBASSIMP_COMPONENT}
|
||||
ARCHIVE DESTINATION ${ASSIMP_LIB_INSTALL_DIR} COMPONENT ${LIBASSIMP-DEV_COMPONENT}
|
||||
RUNTIME DESTINATION ${ASSIMP_BIN_INSTALL_DIR} COMPONENT ${LIBASSIMP_COMPONENT}
|
||||
FRAMEWORK DESTINATION ${ASSIMP_LIB_INSTALL_DIR} COMPONENT ${LIBASSIMP_COMPONENT}
|
||||
INCLUDES DESTINATION ${ASSIMP_INCLUDE_INSTALL_DIR}
|
||||
)
|
||||
INSTALL( FILES ${PUBLIC_HEADERS} DESTINATION ${ASSIMP_INCLUDE_INSTALL_DIR}/assimp COMPONENT assimp-dev)
|
||||
|
|
Loading…
Reference in New Issue