From 7eb506d8b2947349eeb9ce9c74be3382c02f1f9b Mon Sep 17 00:00:00 2001 From: Alexey Dokuchaev Date: Fri, 1 Dec 2023 08:56:04 +0000 Subject: [PATCH] graphics/opencoloriov1: unbreak the port's build in C++17 mode While here, expand COMMENT, drop `localbase:ldflags' from USES, tight up the `post-install' recipe (trim some useless commands, wrap overly long lines), pacify stage Q/A report. Reported by: pkg-fallout --- graphics/opencoloriov1/Makefile | 25 +++++++++++-------- .../opencoloriov1/files/patch-CMakeLists.txt | 9 +++++++ .../files/patch-src_core_CMakeLists.txt | 5 ++-- 3 files changed, 26 insertions(+), 13 deletions(-) diff --git a/graphics/opencoloriov1/Makefile b/graphics/opencoloriov1/Makefile index a3158ed40ee1e..35dd8259edad3 100644 --- a/graphics/opencoloriov1/Makefile +++ b/graphics/opencoloriov1/Makefile @@ -5,7 +5,7 @@ CATEGORIES= graphics multimedia PKGNAMESUFFIX= v1 MAINTAINER= danfe@FreeBSD.org -COMMENT= Complete color management solution v1 +COMMENT= Complete color management solution (legacy version) WWW= https://opencolorio.org/ LICENSE= BSD3CLAUSE @@ -13,7 +13,7 @@ LICENSE= BSD3CLAUSE LIB_DEPENDS= libtinyxml.so:textproc/tinyxml \ libyaml-cpp.so:devel/yaml-cpp -USES= alias cmake compiler:c++11-lang localbase:ldflags pkgconfig \ +USES= alias cmake compiler:c++11-lang pkgconfig \ python:build shebangfix USE_GITHUB= yes @@ -42,16 +42,19 @@ CMAKE_ON+= OCIO_USE_SSE CMAKE_OFF+= OCIO_USE_SSE .endif +post-patch: + @${REINPLACE_CMD} -e 's| : std::binary_function.*||' \ + ${WRKSRC}/src/core/PathUtils.h + post-install: - ${RM} -R ${STAGEDIR}/${PREFIX}/share/ocio - # add v1 suffix - ${REINPLACE_CMD} -e 's| diff --git a/graphics/opencoloriov1/files/patch-CMakeLists.txt b/graphics/opencoloriov1/files/patch-CMakeLists.txt index 8f6a7aab459af..c1a16d9e200c1 100644 --- a/graphics/opencoloriov1/files/patch-CMakeLists.txt +++ b/graphics/opencoloriov1/files/patch-CMakeLists.txt @@ -9,6 +9,15 @@ # Need to also get the boost headers here, as yaml-cpp 0.5.0+ requires them. # Don't bother doing this step if we are already including the boost headers for shared_ptr if(NOT OCIO_USE_BOOST_PTR) +@@ -384,7 +384,7 @@ else() + set(OCIO_INLINES_HIDDEN OFF) + endif() + +-set(EXTERNAL_COMPILE_FLAGS "-DTIXML_USE_STL ${YAML_CPP_COMPILE_FLAGS} ${GCC_COMPILE_FLAGS}") ++set(EXTERNAL_COMPILE_FLAGS "${YAML_CPP_COMPILE_FLAGS} ${GCC_COMPILE_FLAGS}") + + set(EXTERNAL_LINK_FLAGS "") + set(EXTERNAL_LIBRARY_DIRS ${PROJECT_BINARY_DIR}/ext/dist/lib) @@ -531,8 +531,6 @@ endif() configure_file(${CMAKE_SOURCE_DIR}/share/ocio/setup_ocio.sh.in ${CMAKE_CURRENT_BINARY_DIR}/share/ocio/setup_ocio.sh @ONLY) diff --git a/graphics/opencoloriov1/files/patch-src_core_CMakeLists.txt b/graphics/opencoloriov1/files/patch-src_core_CMakeLists.txt index 34588903eba08..047e0a79cab75 100644 --- a/graphics/opencoloriov1/files/patch-src_core_CMakeLists.txt +++ b/graphics/opencoloriov1/files/patch-src_core_CMakeLists.txt @@ -1,4 +1,4 @@ ---- src/core/CMakeLists.txt.orig 2021-12-07 20:11:03 UTC +--- src/core/CMakeLists.txt.orig 2019-03-28 05:12:57 UTC +++ src/core/CMakeLists.txt @@ -56,7 +56,7 @@ if(OCIO_BUILD_SHARED) endif() @@ -22,6 +22,7 @@ configure_file(${CMAKE_SOURCE_DIR}/export/pkgconfig/OpenColorIO.pc.in - ${CMAKE_CURRENT_BINARY_DIR}/OpenColorIO.pc @ONLY) -install(FILES ${CMAKE_CURRENT_BINARY_DIR}/OpenColorIO.pc +- DESTINATION ${CMAKE_INSTALL_EXEC_PREFIX}/lib${LIB_SUFFIX}/pkgconfig/) + ${CMAKE_CURRENT_BINARY_DIR}/OpenColorIOv1.pc @ONLY) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/OpenColorIOv1.pc - DESTINATION ${CMAKE_INSTALL_EXEC_PREFIX}/lib${LIB_SUFFIX}/pkgconfig/) ++ DESTINATION ${CMAKE_INSTALL_EXEC_PREFIX}/libdata/pkgconfig/)