diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt index a3398084f..934870261 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt @@ -242,10 +242,10 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Config.cmake DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME} ) -# install(EXPORT ${PROJECT_NAME} -# DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME} -# FILE ${PROJECT_NAME}Targets.cmake -# NAMESPACE ${PROJECT_NAME}:: -# EXPORT_LINK_INTERFACE_LIBRARIES -# ) +install(EXPORT ${PROJECT_NAME} + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME} + FILE ${PROJECT_NAME}Targets.cmake + NAMESPACE ${PROJECT_NAME}:: + EXPORT_LINK_INTERFACE_LIBRARIES +) endif() diff --git a/cmake/OpenEXRSetup.cmake b/cmake/OpenEXRSetup.cmake index 9134ebf07..42b3e702c 100644 --- a/cmake/OpenEXRSetup.cmake +++ b/cmake/OpenEXRSetup.cmake @@ -307,11 +307,15 @@ message(STATUS "Fetching OpenJPH") include(FetchContent) FetchContent_Declare( openjph - GIT_REPOSITORY https://github.com/aous72/OpenJPH - GIT_TAG 0.18.2 + GIT_REPOSITORY https://github.com/palemieux/OpenJPH + GIT_TAG feature/install-fix-openexr ) FetchContent_MakeAvailable(openjph) +install( + TARGETS openjph + EXPORT OpenEXR +) set_property(DIRECTORY ${openjph_SOURCE_DIR} PROPERTY OJPH_ENABLE_TIFF_SUPPORT OFF) set_property(DIRECTORY ${openjph_SOURCE_DIR} PROPERTY OJPH_BUILD_TESTS OFF) set_property(DIRECTORY ${openjph_SOURCE_DIR} PROPERTY OJPH_BUILD_EXECUTABLES OFF)