[packages/OpenTimelineIO] - updated to 0.18.1 - patches and build process shamelessly copied from Mageia

witekfl witekfl at pld-linux.org
Sun Nov 30 20:55:57 CET 2025


commit f76d02e0b5c2783ff9c5896d2b6f7d1fb5ffa491
Author: Witold Filipczyk <witekfl at poczta.onet.pl>
Date:   Sun Nov 30 20:53:24 2025 +0100

    - updated to 0.18.1
    - patches and build process shamelessly copied from Mageia

 0001-Use-system-rapidjson.patch | 118 ----------------------------------------
 0002-CMake-fixes.patch          |  39 ++++---------
 OpenTimelineIO.spec             |  25 +++++----
 3 files changed, 26 insertions(+), 156 deletions(-)
---
diff --git a/OpenTimelineIO.spec b/OpenTimelineIO.spec
index 2a8fe57..df85672 100644
--- a/OpenTimelineIO.spec
+++ b/OpenTimelineIO.spec
@@ -1,16 +1,18 @@
 #
 # Conditional build:
 %bcond_with	tests		# build with tests
+%define		rjcommit	24b5e7a8b27f42fa16b96fc70aade9106cf7102f
 Summary:	OpenTimelineIO
 Name:		OpenTimelineIO
-Version:	0.17.0
+Version:	0.18.1
 Release:	1
 License:	Apache v2.0
 Group:		X11/Libraries
 Source0:	https://github.com/AcademySoftwareFoundation/OpenTimelineIO/archive/refs/tags/v%{version}.tar.gz
-# Source0-md5:	efc3dff4adb57164e83afb68908018eb
-Patch0:		0001-Use-system-rapidjson.patch
-Patch1:		0002-CMake-fixes.patch
+# Source0-md5:	7b13298f151ad5bd2d4a74c0c66bfa41
+Source1:	https://github.com/Tencent/rapidjson/archive/%{rjcommit}/rapidjson-%{rjcommit}.tar.gz
+# Source1-md5:	531f76775e11b09b28422bfa1d4d59b5
+Patch0:		0002-CMake-fixes.patch
 URL:		http://opentimeline.io/
 BuildRequires:	Imath-devel
 BuildRequires:	cmake >= 3.16
@@ -42,9 +44,12 @@ Header files for %{name} development.
 Pliki nagłówkowe dla programistów używających %{name}.
 
 %prep
-%setup -q
+%setup -q -a1
 %patch -P0 -p1
-%patch -P1 -p1
+# Imath: system version used via OTIO_FIND_MATH
+# rapidjson: snapshot needed for APIs added since last release
+find src/deps/{Imath,rapidjson} -delete
+mv rapidjson-%{rjcommit} src/deps/rapidjson
 
 %build
 %cmake -B build \
@@ -73,10 +78,10 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc *.md *.pdf *.txt
-%ghost %{_libdir}/libopentime.so.0
-%attr(755,root,root) %{_libdir}/libopentime.so.*.*
-%ghost %{_libdir}/libopentimelineio.so.0
-%attr(755,root,root) %{_libdir}/libopentimelineio.so.*.*
+%ghost %{_libdir}/libopentime.so.18
+%{_libdir}/libopentime.so.*.*
+%ghost %{_libdir}/libopentimelineio.so.18
+%{_libdir}/libopentimelineio.so.*.*
 
 %files devel
 %defattr(644,root,root,755)
diff --git a/0001-Use-system-rapidjson.patch b/0001-Use-system-rapidjson.patch
deleted file mode 100644
index dd1aa93..0000000
--- a/0001-Use-system-rapidjson.patch
+++ /dev/null
@@ -1,118 +0,0 @@
-From 2bd90edfb4730780b71fcacae9e492ff15a16268 Mon Sep 17 00:00:00 2001
-From: Christophe Marin <christophe at krop.fr>
-Date: Fri, 7 Mar 2025 10:42:48 +0100
-Subject: [PATCH 1/2] Use system rapidjson
-
----
- CMakeLists.txt                    | 56 +++----------------------------
- src/opentimelineio/CMakeLists.txt |  5 ++-
- 2 files changed, 7 insertions(+), 54 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 825ad9d..0a4d0ce 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -28,7 +28,7 @@ project(OpenTimelineIO VERSION ${OTIO_VERSION} LANGUAGES C CXX)
- # Installation options
- option(OTIO_CXX_INSTALL               "Install the C++ bindings" ON)
- option(OTIO_PYTHON_INSTALL            "Install the Python bindings" OFF)
--option(OTIO_DEPENDENCIES_INSTALL      "Install OTIO's C++ header dependencies (any and nonstd)" ON)
-+option(OTIO_DEPENDENCIES_INSTALL      "Install OTIO's C++ header dependencies (any and nonstd)" OFF)
- option(OTIO_INSTALL_PYTHON_MODULES    "Install OTIO pure Python modules/files" ON)
- option(OTIO_INSTALL_COMMANDLINE_TOOLS "Install the OTIO command line tools" ON)
- option(OTIO_INSTALL_CONTRIB           "Install the opentimelineio_contrib Python package" ON)
-@@ -149,63 +149,16 @@ endif()
- set(CMAKE_CXX_STANDARD_REQUIRED ON)
- set(CMAKE_CXX_EXTENSIONS OFF)
- 
--if(OTIO_CXX_COVERAGE AND NOT MSVC)
--    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --coverage")
--    # this causes cmake to produce file.gcno instead of file.cpp.gcno
--    set(CMAKE_CXX_OUTPUT_EXTENSION_REPLACE 1)
--    message(STATUS "Building C++ with Coverage: ON")
--else()
--    message(STATUS "Building C++ with Coverage: OFF")
--endif()
- 
--if(WIN32)
--    # Windows debug builds for Python require a d in order for the module to
--    # load. This also helps ensure that debug builds in general are matched
--    # to the Microsoft debug CRT.
--    set(OTIO_DEBUG_POSTFIX "d")
--endif()
-+
-+
- 
- set_property(GLOBAL PROPERTY USE_FOLDERS ON)
- 
- #------------------------------------------------------------------------------
- # Fetch or refresh submodules if requested
- #
--if (OTIO_AUTOMATIC_SUBMODULES)
--    # make sure that git submodules are up to date when building
--    find_package(Git QUIET)
--    if (GIT_FOUND)
--        message(STATUS "Checking git repo is available:")
--        execute_process(
--            # the following command returns true if cwd is in the repo
--            COMMAND ${GIT_EXECUTABLE} rev-parse --is-inside-work-tree
--            WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
--            RESULT_VARIABLE IN_A_GIT_REPO_RETCODE
--        )
--    endif()
- 
--    if (GIT_FOUND AND IN_A_GIT_REPO_RETCODE EQUAL 0)
--        # you might want to turn this off if you're working in one of the submodules
--        # or trying it out with a different version of the submodule
--        option(GIT_UPDATE_SUBMODULES "Update submodules each build" ON)
--        if (GIT_UPDATE_SUBMODULES)
--            message(
--                STATUS "root: Updating git submodules to make sure they are up to date"
--            )
--            execute_process(
--                COMMAND ${GIT_EXECUTABLE} submodule update --init --recursive
--                WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
--                RESULT_VARIABLE GIT_UPDATE_SUBMODULES_RESULT
--            )
--            if (NOT GIT_UPDATE_SUBMODULES_RESULT EQUAL "0")
--                message(
--                    FATAL_ERROR
--                    "git submodule update --init --recursive failed with \
--                    ${GIT_UPDATE_SUBMODULES_RESULT}"
--                )
--            endif()
--        endif()
--    endif()
--endif()
- 
- #------------------------------------------------------------------------------
- # Setup tests
-@@ -245,7 +198,8 @@ else()
- endif()
- 
- # set up the internally hosted dependencies
--add_subdirectory(src/deps)
-+# add_subdirectory(src/deps)
-+find_package(RapidJSON CONFIG REQUIRED)
- 
- set (OTIO_IMATH_TARGETS
-     # For OpenEXR/Imath 3.x:
-diff --git a/src/opentimelineio/CMakeLists.txt b/src/opentimelineio/CMakeLists.txt
-index 4b08e6d..e98828b 100644
---- a/src/opentimelineio/CMakeLists.txt
-+++ b/src/opentimelineio/CMakeLists.txt
-@@ -80,9 +80,8 @@ add_library(OTIO::opentimelineio ALIAS opentimelineio)
- target_include_directories(opentimelineio
-     PRIVATE       "${IMATH_INCLUDES}"
-                   "${PROJECT_SOURCE_DIR}/src"
--                  "${PROJECT_SOURCE_DIR}/src/deps"
--                  "${PROJECT_SOURCE_DIR}/src/deps/rapidjson/include"
--                  "${IMATH_INCLUDES}")
-+                  "${IMATH_INCLUDES}"
-+                  ${RapidJSON_INCLUDE_DIRS})
- 
- target_link_libraries(opentimelineio 
-     PUBLIC opentime ${OTIO_IMATH_TARGETS})
--- 
-2.48.1
-
diff --git a/0002-CMake-fixes.patch b/0002-CMake-fixes.patch
index adbe235..026125c 100644
--- a/0002-CMake-fixes.patch
+++ b/0002-CMake-fixes.patch
@@ -13,7 +13,7 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt
 index 0a4d0ce..36f6e27 100644
 --- a/CMakeLists.txt
 +++ b/CMakeLists.txt
-@@ -20,6 +20,8 @@ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.14" CACHE STRING "Minimum OS X deployment ve
+@@ -20,6 +20,8 @@ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15"
  
  project(OpenTimelineIO VERSION ${OTIO_VERSION} LANGUAGES C CXX)
  
@@ -22,7 +22,7 @@ index 0a4d0ce..36f6e27 100644
  #------------------------------------------------------------------------------
  # Options
  # Add all options and settings here for all subprojects to aid in project
-@@ -100,7 +102,7 @@ if(OTIO_PYTHON_INSTALL)
+@@ -106,7 +108,7 @@ if(OTIO_PYTHON_INSTALL)
      endif()
  
  else()
@@ -35,16 +35,7 @@ diff --git a/src/opentime/CMakeLists.txt b/src/opentime/CMakeLists.txt
 index b7cc47c..6ad040f 100644
 --- a/src/opentime/CMakeLists.txt
 +++ b/src/opentime/CMakeLists.txt
-@@ -19,6 +19,8 @@ add_library(OTIO::opentime ALIAS opentime)
- target_include_directories(opentime PRIVATE "${PROJECT_SOURCE_DIR}/src")
- 
- set_target_properties(opentime PROPERTIES 
-+    VERSION ${OTIO_VERSION}
-+    SOVERSION 0
-     DEBUG_POSTFIX "${OTIO_DEBUG_POSTFIX}"
-     LIBRARY_OUTPUT_NAME "opentime"
-     POSITION_INDEPENDENT_CODE TRUE
-@@ -49,7 +51,7 @@ if(OTIO_CXX_INSTALL)
+@@ -73,7 +73,7 @@ if(OTIO_CXX_INSTALL)
              RUNTIME DESTINATION "${OTIO_RESOLVED_CXX_DYLIB_INSTALL_DIR}")
  
      install(EXPORT OpenTimeTargets
@@ -53,7 +44,7 @@ index b7cc47c..6ad040f 100644
              NAMESPACE OTIO:: )
  
      include(CMakePackageConfigHelpers)
-@@ -57,7 +59,7 @@ if(OTIO_CXX_INSTALL)
+@@ -81,7 +81,7 @@ if(OTIO_CXX_INSTALL)
          ${CMAKE_CURRENT_SOURCE_DIR}/OpenTimeConfig.cmake.in
          ${CMAKE_CURRENT_BINARY_DIR}/OpenTimeConfig.cmake
          INSTALL_DESTINATION
@@ -62,29 +53,20 @@ index b7cc47c..6ad040f 100644
          NO_SET_AND_CHECK_MACRO
          NO_CHECK_REQUIRED_COMPONENTS_MACRO
      )
-@@ -66,7 +68,7 @@ if(OTIO_CXX_INSTALL)
+@@ -90,7 +90,7 @@ if(OTIO_CXX_INSTALL)
          FILES
              ${CMAKE_CURRENT_BINARY_DIR}/OpenTimeConfig.cmake
          DESTINATION
 -            ${OTIO_RESOLVED_CXX_INSTALL_DIR}/share/opentime
 +            ${CMAKE_INSTALL_LIBDIR}/cmake/opentime
      )
- endif()
  
+     install(
 diff --git a/src/opentimelineio/CMakeLists.txt b/src/opentimelineio/CMakeLists.txt
 index e98828b..22828a6 100644
 --- a/src/opentimelineio/CMakeLists.txt
 +++ b/src/opentimelineio/CMakeLists.txt
-@@ -87,6 +87,8 @@ target_link_libraries(opentimelineio
-     PUBLIC opentime ${OTIO_IMATH_TARGETS})
- 
- set_target_properties(opentimelineio PROPERTIES
-+    VERSION ${OTIO_VERSION}
-+    SOVERSION 0
-     DEBUG_POSTFIX "${OTIO_DEBUG_POSTFIX}"
-     LIBRARY_OUTPUT_NAME "opentimelineio"
-     POSITION_INDEPENDENT_CODE TRUE
-@@ -123,7 +125,7 @@ if(OTIO_CXX_INSTALL)
+@@ -151,7 +151,7 @@ if(OTIO_CXX_INSTALL)
             RUNTIME DESTINATION "${OTIO_RESOLVED_CXX_DYLIB_INSTALL_DIR}")
  
      install(EXPORT OpenTimelineIOTargets
@@ -93,7 +75,7 @@ index e98828b..22828a6 100644
             NAMESPACE OTIO:: )
  
      include(CMakePackageConfigHelpers)
-@@ -131,7 +133,7 @@ if(OTIO_CXX_INSTALL)
+@@ -159,7 +159,7 @@ if(OTIO_CXX_INSTALL)
          ${CMAKE_CURRENT_SOURCE_DIR}/OpenTimelineIOConfig.cmake.in
          ${CMAKE_CURRENT_BINARY_DIR}/OpenTimelineIOConfig.cmake
          INSTALL_DESTINATION
@@ -102,14 +84,15 @@ index e98828b..22828a6 100644
          NO_SET_AND_CHECK_MACRO
          NO_CHECK_REQUIRED_COMPONENTS_MACRO
      )
-@@ -140,6 +142,6 @@ if(OTIO_CXX_INSTALL)
+@@ -168,7 +168,7 @@ if(OTIO_CXX_INSTALL)
          FILES
              ${CMAKE_CURRENT_BINARY_DIR}/OpenTimelineIOConfig.cmake
          DESTINATION
 -            ${OTIO_RESOLVED_CXX_INSTALL_DIR}/share/opentimelineio
 +            ${CMAKE_INSTALL_LIBDIR}/cmake/opentimelineio
      )
- endif()
+ 
+     install(
 -- 
 2.48.1
 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/OpenTimelineIO.git/commitdiff/f76d02e0b5c2783ff9c5896d2b6f7d1fb5ffa491




More information about the pld-cvs-commit mailing list