[packages/OpenImageIO] - fix building with opencv 3.x - rel 5

baggins baggins at pld-linux.org
Mon Mar 21 11:13:24 CET 2016


commit 6e575f7936adf1e6002b41c849bf31ce8ced7026
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Mon Mar 21 11:13:08 2016 +0100

    - fix building with opencv 3.x
    - rel 5

 OpenImageIO.spec |  4 +++-
 opencv3.patch    | 28 ++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+), 1 deletion(-)
---
diff --git a/OpenImageIO.spec b/OpenImageIO.spec
index a6f89b0..858f003 100644
--- a/OpenImageIO.spec
+++ b/OpenImageIO.spec
@@ -17,7 +17,7 @@ Summary:	Library for reading and writing images
 Summary(pl.UTF-8):	Biblioteka do odczytu i zapisu obrazów
 Name:		OpenImageIO
 Version:	1.6.8
-Release:	4
+Release:	5
 License:	BSD
 Group:		Libraries
 Source0:	https://github.com/OpenImageIO/oiio/tarball/Release-%{version}/%{name}-%{version}.tar.gz
@@ -31,6 +31,7 @@ Patch5:		%{name}-werror.patch
 Patch6:		system-pugixml.patch
 Patch7:		fix-types.patch
 Patch8:		ffmpeg3.patch
+Patch9:		opencv3.patch
 URL:		https://sites.google.com/site/openimageio/home
 BuildRequires:	Field3D-devel
 %{?with_ocio:BuildRequires:	OpenColorIO-devel}
@@ -353,6 +354,7 @@ Wiązanie Pythona do biblioteki OpenImageIO.
 %patch6 -p1
 %patch7 -p1
 %patch8 -p1
+%patch9 -p1
 
 %{__rm} -r src/dds.imageio/squish src/ptex.imageio/ptex
 # when using system pugixml, don't use hacked headers
diff --git a/opencv3.patch b/opencv3.patch
new file mode 100644
index 0000000..7811795
--- /dev/null
+++ b/opencv3.patch
@@ -0,0 +1,28 @@
+--- OpenImageIO-oiio-4070df8/src/cmake/externalpackages.cmake~	2015-12-19 07:44:03.000000000 +0100
++++ OpenImageIO-oiio-4070df8/src/cmake/externalpackages.cmake	2016-03-21 11:06:58.754135430 +0100
+@@ -504,6 +504,14 @@
+                         /usr/local/lib
+                         /opt/local/lib
+                  )
++    find_library (OpenCV_LIBS_videoio
++                  NAMES opencv_videoio
++                  PATHS "${THIRD_PARTY_TOOLS_HOME}/lib/"
++                        "${PROJECT_SOURCE_DIR}/lib"
++                        "${OpenCV_HOME}/lib"
++                        /usr/local/lib
++                        /opt/local/lib
++                 )
+     set (OpenCV_LIBS "${OpenCV_LIBS} ${OpenCV_LIBS_highgui}")
+     if (OpenCV_INCLUDE_DIR AND OpenCV_LIBS)
+         set (OpenCV_FOUND TRUE)
+--- OpenImageIO-oiio-4070df8/src/libOpenImageIO/CMakeLists.txt~	2016-03-21 11:03:35.000000000 +0100
++++ OpenImageIO-oiio-4070df8/src/libOpenImageIO/CMakeLists.txt	2016-03-21 11:08:09.865289491 +0100
+@@ -255,7 +255,7 @@
+ # Include OpenCV if using it
+ if (OpenCV_FOUND)
+     include_directories (${OpenCV_INCLUDE_DIR})
+-    target_link_libraries (OpenImageIO opencv_core opencv_highgui)
++    target_link_libraries (OpenImageIO opencv_core opencv_highgui opencv_videoio)
+ endif ()
+ 
+ # Include OpenSSL if using it
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/OpenImageIO.git/commitdiff/6e575f7936adf1e6002b41c849bf31ce8ced7026



More information about the pld-cvs-commit mailing list