From 5d7f8b804aa4c5af2972b0f762c0e297666fa5b7 Mon Sep 17 00:00:00 2001 From: Darby Johnston Date: Thu, 26 Jun 2025 09:33:49 -0700 Subject: [PATCH] Remove custom CMake FindOTIO file Signed-off-by: Darby Johnston --- CMakeLists.txt | 5 +--- cmake/FindOTIO.cmake | 64 -------------------------------------------- 2 files changed, 1 insertion(+), 68 deletions(-) delete mode 100644 cmake/FindOTIO.cmake diff --git a/CMakeLists.txt b/CMakeLists.txt index abc10b9..6ad8c36 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -67,8 +67,8 @@ find_package(OpenEXR) find_package(minizip) find_package(OpenColorIO) find_package(OpenImageIO) -find_package(OTIO) find_package(OpenFX) +find_package(OpenTimelineIO) find_package(lunasvg) find_package(dtk) @@ -85,9 +85,6 @@ add_subdirectory(tests) install( FILES cmake/FindOpenFX.cmake DESTINATION lib/cmake/toucan) -install( - FILES cmake/FindOTIO.cmake - DESTINATION lib/cmake/toucan) include(CMakePackageConfigHelpers) set(INCLUDE_INSTALL_DIR include/toucan) configure_package_config_file( diff --git a/cmake/FindOTIO.cmake b/cmake/FindOTIO.cmake deleted file mode 100644 index 6300637..0000000 --- a/cmake/FindOTIO.cmake +++ /dev/null @@ -1,64 +0,0 @@ -# Find the OpenTimelineIO library. -# -# This module defines the following variables: -# -# * OTIO_INCLUDE_DIRS -# * OTIO_LIBRARIES -# -# This module defines the following imported targets: -# -# * OTIO::opentime -# * OTIO::opentimelineio -# -# This module defines the following interfaces: -# -# * OTIO - -find_path(OTIO_INCLUDE_DIR NAMES opentimelineio/version.h) -set(OTIO_INCLUDE_DIRS ${OTIO_INCLUDE_DIR}) - -if(CMAKE_BUILD_TYPE MATCHES "^Debug$") - find_library( - opentime_LIBRARY - NAMES opentimed opentime - PATHS ${CMAKE_INSTALL_PREFIX}/python/opentimelineio) - find_library( - opentimelineio_LIBRARY - NAMES opentimelineiod opentimelineio - PATHS ${CMAKE_INSTALL_PREFIX}/python/opentimelineio) -else() - find_library( - opentime_LIBRARY - NAMES opentime - PATHS ${CMAKE_INSTALL_PREFIX}/python/opentimelineio) - find_library( - opentimelineio_LIBRARY - NAMES opentimelineio - PATHS ${CMAKE_INSTALL_PREFIX}/python/opentimelineio) -endif() -set(OTIO_LIBRARIES ${opentimelineio_LIBRARY} ${opentime_LIBRARY}) - -include(FindPackageHandleStandardArgs) -find_package_handle_standard_args( - OTIO - REQUIRED_VARS OTIO_INCLUDE_DIR opentimelineio_LIBRARY opentime_LIBRARY) -mark_as_advanced(OTIO_INCLUDE_DIR opentimelineio_LIBRARY opentime_LIBRARY) - -if(OTIO_FOUND AND NOT TARGET OTIO::opentime) - add_library(OTIO::opentime UNKNOWN IMPORTED) - set_target_properties(OTIO::opentime PROPERTIES - IMPORTED_LOCATION "${opentime_LIBRARY}" - INTERFACE_COMPILE_DEFINITIONS opentime_FOUND - INTERFACE_INCLUDE_DIRECTORIES "${opentime_INCLUDE_DIR}") -endif() -if(OTIO_FOUND AND NOT TARGET OTIO::opentimelineio) - add_library(OTIO::opentimelineio UNKNOWN IMPORTED) - set_target_properties(OTIO::opentimelineio PROPERTIES - IMPORTED_LOCATION "${opentimelineio_LIBRARY}" - INTERFACE_COMPILE_DEFINITIONS opentimelineio_FOUND - INTERFACE_INCLUDE_DIRECTORIES "${OTIO_INCLUDE_DIR}") -endif() -if(OTIO_FOUND AND NOT TARGET OTIO) - add_library(OTIO INTERFACE) - target_link_libraries(OTIO INTERFACE OTIO::opentimelineio OTIO::opentime) -endif()