oops, I committed it thinking I had tested it, but it doesn't actually
build for me so I have backed out, diff against new -current is attached

errors are like this

CMake Error at src/libutils/oglapphelpers/CMakeLists.txt:34 (add_library):
  Target "oglapphelpers" links to target "OpenGL::OpenGL" but the target was

(also if possible please check if krita still works)

build log:

===>  Configuring for opencolorio-2.1.1v1
-- The CXX compiler identification is Clang 13.0.0
-- The C compiler identification is Clang 13.0.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/obj/ports/opencolorio-2.1.1/bin/c++ - 
skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/obj/ports/opencolorio-2.1.1/bin/cc - 
skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Setting C++ version to '11' as none was specified.
-- Performing Test COMPILER_SUPPORTS_CXX11
-- Performing Test COMPILER_SUPPORTS_CXX11 - Success
-- Found OpenGL: /usr/X11R6/lib/libGL.so.17.1  found components: OpenGL 
-- Could NOT find GLEW (missing: GLEW_DIR)
-- Could NOT find GLEW (missing: GLEW_DIR)
-- Found GLEW: /usr/local/include (found version "2.2.0") 
-- Found GLUT: /usr/local/lib/libglut.so.7.0  
-- GLVND supported
-- Performing Test HAVE_SSE2
-- Performing Test HAVE_SSE2 - Success
-- Setting SOVERSION to '2.1' as none was specified.
-- Could NOT find expat (missing: expat_DIR)
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.2") 
-- Found expat: /usr/lib/libexpat.so.14.0 (found suitable version "2.4.6", 
minimum required is "2.2.8") 
-- Found yaml-cpp: /usr/local/lib/libyaml-cpp.so.3.0 (found suitable version 
"0.6.3", minimum required is "0.6.3") 
-- Found pystring: /usr/local/include (Required is at least version "1.1.3") 
-- Found Imath: /usr/local/lib/libImath-3_1.so.1.0 (found suitable version 
"3.1.4", minimum required is "3.1.2") 
-- Found Python: /usr/local/bin/python3.9 (found version "3.9.10") found 
components: Interpreter Development.Module 
-- Could NOT find pybind11 (missing: pybind11_DIR)
-- Found Python: /usr/local/bin/python3.9 (found version "3.9.10") found 
components: Interpreter 
-- Using pybind11 python package (version "2.8.1", found in python "3.9.10")
-- Found pybind11: /usr/local/lib/python3.9/site-packages/pybind11/include 
(found suitable version "2.8.1", minimum required is "2.6.1") 
-- Could NOT find OpenImageIO (missing: OPENIMAGEIO_INCLUDE_DIR 
OPENIMAGEIO_LIBRARY OPENIMAGEIO_VERSION) (Required is at least version "2.1.9")
CMake Warning at tests/CMakeLists.txt:35 (message):
  Could NOT find OpenImageIO.  Skipping build of the OSL unit tests


CMake Warning at src/bindings/python/CMakeLists.txt:44 (message):
  Building PyOpenColorIO with OCIO_BUILD_DOCS disabled will result in
  incomplete Python docstrings.


-- Configuring done
CMake Error at tests/gpu/CMakeLists.txt:27 (add_executable):
  Target "test_gpu_exec" links to target "OpenGL::OpenGL" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


CMake Error at src/libutils/oglapphelpers/CMakeLists.txt:34 (add_library):
  Target "oglapphelpers" links to target "OpenGL::OpenGL" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


-- Generating done
CMake Warning:
  Manually-specified variables were not used by the project:

    PYTHON
    PYTHON_EXECUTABLE
    PYTHON_INCLUDE_DIR
    PYTHON_LIBRARY_DIRS


CMake Generate step failed.  Build files cannot be regenerated correctly.



Index: Makefile
===================================================================
RCS file: /cvs/ports/graphics/opencolorio/Makefile,v
retrieving revision 1.18
diff -u -p -r1.18 Makefile
--- Makefile    4 Mar 2022 22:33:35 -0000       1.18
+++ Makefile    4 Mar 2022 22:38:04 -0000
@@ -5,7 +5,7 @@ COMMENT =               color management library
 EPOCH =                        1
 GH_ACCOUNT =           AcademySoftwareFoundation
 GH_PROJECT =           OpenColorIO
-GH_TAGNAME =           v1.1.1
+GH_TAGNAME =           v2.1.1
 PKGNAME =              ${DISTNAME:L}
 
 SHARED_LIBS +=  OpenColorIO               1.1 # 1.1.1
@@ -20,7 +20,7 @@ MAINTAINER =          Pascal Stumpf <pascal@stum
 # several BSD-like
 PERMIT_PACKAGE =       Yes
 
-WANTLIB += m pthread ${COMPILER_LIBCXX} tinyxml yaml-cpp
+WANTLIB += ${COMPILER_LIBCXX} Imath-3_1 expat m pystring yaml-cpp
 
 COMPILER =             base-clang ports-gcc
 
@@ -28,25 +28,21 @@ MODULES =           devel/cmake \
                        lang/python
 
 BUILD_DEPENDS =                devel/boost
-LIB_DEPENDS =          textproc/tinyxml \
-                       devel/yaml-cpp
+LIB_DEPENDS =          devel/pystring \
+                       devel/yaml-cpp \
+                       math/imath
 
 CONFIGURE_ARGS +=      -DPYTHON="${MODPY_BIN}" \
-                       -DUSE_EXTERNAL_TINYXML=ON \
-                       -DUSE_EXTERNAL_YAML=ON \
-                       -DOCIO_USE_SSE=OFF \
                        -DOCIO_BUILD_STATIC=OFF \
                        -DOCIO_BUILD_APPS=OFF \
                        -DCMAKE_SHARED_LINKER_FLAGS="-L${LOCALBASE}/lib" \
                        -DCMAKE_EXE_LINKER_FLAGS="-L${LOCALBASE}/lib" \
                        -DCMAKE_MODULE_LINKER_FLAGS="-L${LOCALBASE}/lib"
 
-NO_TEST =              Yes
-
-post-install:
-       ${INSTALL_DATA_DIR} ${PREFIX}/lib/cmake/OpenColorIO
-       mv ${PREFIX}/cmake/*.cmake ${PREFIX}/OpenColorIO*.cmake \
-                ${PREFIX}/lib/cmake/OpenColorIO
-       rm -rf ${PREFIX}/cmake
+.if ${MACHINE_ARCH} == "amd64"
+CONFIGURE_ARGS +=      -DOCIO_USE_SSE=ON
+.else
+CONFIGURE_ARGS +=      -DOCIO_USE_SSE=OFF
+.endif
 
 .include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/graphics/opencolorio/distinfo,v
retrieving revision 1.6
diff -u -p -r1.6 distinfo
--- distinfo    4 Mar 2022 22:33:35 -0000       1.6
+++ distinfo    4 Mar 2022 22:38:04 -0000
@@ -1,2 +1,2 @@
-SHA256 (OpenColorIO-1.1.1.tar.gz) = 
ybW53vkH4dr7KeNzNrcC//IsxjBtRFoTsWIbinVMFMg=
-SIZE (OpenColorIO-1.1.1.tar.gz) = 13828483
+SHA256 (OpenColorIO-2.1.1.tar.gz) = 
FuvD4PIfctvpD+YEN+uGT01N6cJV744hL4N4JPybjZw=
+SIZE (OpenColorIO-2.1.1.tar.gz) = 11013141
Index: patches/patch-CMakeLists_txt
===================================================================
RCS file: patches/patch-CMakeLists_txt
diff -N patches/patch-CMakeLists_txt
--- patches/patch-CMakeLists_txt        4 Mar 2022 22:33:35 -0000       1.6
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,26 +0,0 @@
-$OpenBSD: patch-CMakeLists_txt,v 1.6 2022/03/04 22:33:35 sthen Exp $
-
-Fix macro redefined error
-
-Index: CMakeLists.txt
---- CMakeLists.txt.orig
-+++ CMakeLists.txt
-@@ -218,8 +218,7 @@ else(USE_EXTERNAL_TINYXML)
-         ## => great news when build staticaly since we do not want another 
client project have to link also with tinyxml when he want to use this project
-         ## => could be problematic if the client project use another version 
of tinyxml... In this case build tinyxml as shared lib with all projects could 
be a solution
-         ## => TODO: so maybe provide a simple cmake way to build 3rdParty as 
shared and auto install with this project ?
--        set_target_properties(TINYXML_LIB PROPERTIES COMPILE_FLAGS 
"-DTIXML_USE_STL -fPIC -fvisibility-inlines-hidden -fvisibility=hidden")
--        add_definitions(-DTIXML_USE_STL) ## needed to build correctly, and 
also need to be propagated in child projects (client projects)
-+        set_target_properties(TINYXML_LIB PROPERTIES COMPILE_FLAGS "-fPIC 
-fvisibility-inlines-hidden -fvisibility=hidden")
-         list(APPEND EXTERNAL_OBJECTS $<TARGET_OBJECTS:TINYXML_LIB>)
-     else()
-         find_package(Git REQUIRED) ## in order to apply patch (for 
crossplateform compatibility)
-@@ -384,7 +383,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)
Index: patches/patch-src_core_CMakeLists_txt
===================================================================
RCS file: patches/patch-src_core_CMakeLists_txt
diff -N patches/patch-src_core_CMakeLists_txt
--- patches/patch-src_core_CMakeLists_txt       4 Mar 2022 22:33:35 -0000       
1.3
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,16 +0,0 @@
-$OpenBSD: patch-src_core_CMakeLists_txt,v 1.3 2022/03/04 22:33:35 sthen Exp $
-
-Strip -Werror to fix sparc64 build
-
-Index: src/core/CMakeLists.txt
---- src/core/CMakeLists.txt.orig
-+++ src/core/CMakeLists.txt
-@@ -24,7 +24,7 @@ if(WIN32)
-         set(EXTERNAL_COMPILE_FLAGS "${EXTERNAL_COMPILE_FLAGS} /WX")
-     endif()
- else()
--    set(EXTERNAL_COMPILE_FLAGS "${EXTERNAL_COMPILE_FLAGS} -Werror")
-+    set(EXTERNAL_COMPILE_FLAGS "${EXTERNAL_COMPILE_FLAGS}")
- endif()
- 
- # SHARED
Index: patches/patch-src_core_Config_cpp
===================================================================
RCS file: patches/patch-src_core_Config_cpp
diff -N patches/patch-src_core_Config_cpp
--- patches/patch-src_core_Config_cpp   4 Mar 2022 22:33:35 -0000       1.6
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,15 +0,0 @@
-$OpenBSD: patch-src_core_Config_cpp,v 1.6 2022/03/04 22:33:35 sthen Exp $
-
-Upstream fix - Squashing Adsk contrib/operator rhs
-
---- src/core/Config.cpp.orig   Thu Dec  3 22:17:51 2020
-+++ src/core/Config.cpp        Thu Dec  3 22:18:10 2020
-@@ -330,7 +330,7 @@ OCIO_NAMESPACE_ENTER
-                 sanitytext_ = rhs.sanitytext_;
-                 
-                 cacheids_ = rhs.cacheids_;
--                cacheidnocontext_ = cacheidnocontext_;
-+                cacheidnocontext_ = rhs.cacheidnocontext_;
-             }
-             return *this;
-         }
Index: patches/patch-src_core_OCIOYaml_cpp
===================================================================
RCS file: patches/patch-src_core_OCIOYaml_cpp
diff -N patches/patch-src_core_OCIOYaml_cpp
--- patches/patch-src_core_OCIOYaml_cpp 4 Mar 2022 22:33:35 -0000       1.6
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,61 +0,0 @@
-$OpenBSD: patch-src_core_OCIOYaml_cpp,v 1.6 2022/03/04 22:33:35 sthen Exp $
-
-Fix the build with newer yaml-cpp.
-
-Index: src/core/OCIOYaml.cpp
---- src/core/OCIOYaml.cpp.orig Thu Dec 24 17:16:21 2020
-+++ src/core/OCIOYaml.cpp      Thu Dec 24 17:16:43 2020
-@@ -30,53 +30,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY O
- 
- #include <OpenColorIO/OpenColorIO.h>
- 
--#ifndef WIN32
--
--// fwd declare yaml-cpp visibility
--#pragma GCC visibility push(hidden)
--namespace YAML {
--    class Exception;
--    class BadDereference;
--    class RepresentationException;
--    class EmitterException;
--    class ParserException;
--    class InvalidScalar;
--    class KeyNotFound;
--    template <typename T> class TypedKeyNotFound;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::ColorSpace>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::Config>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::Exception>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::GpuShaderDesc>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::ImageDesc>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::Look>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::Processor>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::Transform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::AllocationTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::CDLTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::ColorSpaceTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::DisplayTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::ExponentTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::FileTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::GroupTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::LogTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::LookTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::MatrixTransform>;
--    template <> class TypedKeyNotFound<OCIO_NAMESPACE::TruelightTransform>;
--}
--#pragma GCC visibility pop
--
--#endif
--
--#ifdef WIN32
--#pragma warning( push )
--#pragma warning( disable: 4146 )
--#endif
--
- #include <yaml-cpp/yaml.h>
--
--#ifdef WIN32
--#pragma warning( pop )
--#endif
- 
- #include "Logging.h"
- #include "MathUtils.h"
Index: patches/patch-src_core_Platform_h
===================================================================
RCS file: patches/patch-src_core_Platform_h
diff -N patches/patch-src_core_Platform_h
--- patches/patch-src_core_Platform_h   4 Mar 2022 22:33:35 -0000       1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,12 +0,0 @@
-$OpenBSD: patch-src_core_Platform_h,v 1.4 2022/03/04 22:33:35 sthen Exp $
---- src/core/Platform.h.orig   Thu Mar 28 10:42:57 2019
-+++ src/core/Platform.h        Thu Dec  3 20:01:17 2020
-@@ -85,7 +85,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY O
- // assume linux/unix/posix
- 
- #include <stdlib.h>
--#if !defined(__FreeBSD__)
-+#if !defined(__FreeBSD__) && !defined(__OpenBSD__)
- #include <alloca.h>
- #endif
- #include <string.h>
Index: patches/patch-src_pyglue_CMakeLists_txt
===================================================================
RCS file: patches/patch-src_pyglue_CMakeLists_txt
diff -N patches/patch-src_pyglue_CMakeLists_txt
--- patches/patch-src_pyglue_CMakeLists_txt     4 Mar 2022 22:33:35 -0000       
1.3
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,16 +0,0 @@
-$OpenBSD: patch-src_pyglue_CMakeLists_txt,v 1.3 2022/03/04 22:33:35 sthen Exp $
-
-Strip -Werror to fix sparc64 build
-
-Index: src/pyglue/CMakeLists.txt
---- src/pyglue/CMakeLists.txt.orig
-+++ src/pyglue/CMakeLists.txt
-@@ -23,7 +23,7 @@ endif()
- # Process all warnings as errors
- # Unfortunately Windows still has a warning
- if(UNIX)
--    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror")
-+    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
- endif()
- 
- find_package(PythonLibs)
Index: patches/patch-src_utils_NumberUtils_h
===================================================================
RCS file: patches/patch-src_utils_NumberUtils_h
diff -N patches/patch-src_utils_NumberUtils_h
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-src_utils_NumberUtils_h       4 Mar 2022 22:38:04 -0000
@@ -0,0 +1,16 @@
+$OpenBSD: patch-src_utils_NumberUtils_h,v 1.1 2022/03/04 22:21:01 sthen Exp $
+
+Fix build failure
+
+Index: src/utils/NumberUtils.h
+--- src/utils/NumberUtils.h.orig
++++ src/utils/NumberUtils.h
+@@ -140,7 +140,7 @@ really_inline from_chars_result from_chars(const char 
+ #ifdef _WIN32
+     tempval = _strtol_l(first, &endptr, 0, loc.local);
+ #else
+-    tempval = ::strtol_l(first, &endptr, 0, loc.local);
++    tempval = ::strtoll_l(first, &endptr, 0, loc.local);
+ #endif
+ 
+     if (errno != 0)
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/graphics/opencolorio/pkg/PLIST,v
retrieving revision 1.4
diff -u -p -r1.4 PLIST
--- pkg/PLIST   4 Mar 2022 22:33:35 -0000       1.4
+++ pkg/PLIST   4 Mar 2022 22:38:04 -0000
@@ -1,15 +1,15 @@
-@comment $OpenBSD: PLIST,v 1.4 2022/03/04 22:33:35 sthen Exp $
+@comment $OpenBSD: PLIST,v 1.3 2022/03/04 22:21:01 sthen Exp $
 include/OpenColorIO/
 include/OpenColorIO/OpenColorABI.h
+include/OpenColorIO/OpenColorAppHelpers.h
 include/OpenColorIO/OpenColorIO.h
 include/OpenColorIO/OpenColorTransforms.h
 include/OpenColorIO/OpenColorTypes.h
-include/PyOpenColorIO/
-include/PyOpenColorIO/PyOpenColorIO.h
 lib/cmake/OpenColorIO/
-lib/cmake/OpenColorIO/OpenColorIO${MODCMAKE_BUILD_SUFFIX}
-lib/cmake/OpenColorIO/OpenColorIO.cmake
 lib/cmake/OpenColorIO/OpenColorIOConfig.cmake
+lib/cmake/OpenColorIO/OpenColorIOConfigVersion.cmake
+lib/cmake/OpenColorIO/OpenColorIOTargets${MODCMAKE_BUILD_SUFFIX}
+lib/cmake/OpenColorIO/OpenColorIOTargets.cmake
 @lib lib/libOpenColorIO.so.${LIBOpenColorIO_VERSION}
 lib/pkgconfig/OpenColorIO.pc
 @so lib/python${MODPY_VERSION}/site-packages/PyOpenColorIO.so

Reply via email to