From aa41c492ff2b3259e5e1cc6d6c2055d913cf9b9d Mon Sep 17 00:00:00 2001 From: Jakub Bogusz Date: Sun, 14 Jul 2013 20:07:04 +0200 Subject: [PATCH] - updated to 1.2.0 (note: new soname) - updated link,hdf patches - added werror patch (fixes warnings which causes build with -Werror to fail) --- OpenImageIO-hdf.patch | 12 ++++++------ OpenImageIO-link.patch | 18 +++++++++--------- OpenImageIO-werror.patch | 24 ++++++++++++++++++++++++ OpenImageIO.spec | 18 +++++++++--------- 4 files changed, 48 insertions(+), 24 deletions(-) create mode 100644 OpenImageIO-werror.patch diff --git a/OpenImageIO-hdf.patch b/OpenImageIO-hdf.patch index 1d3c14a..39f760e 100644 --- a/OpenImageIO-hdf.patch +++ b/OpenImageIO-hdf.patch @@ -1,12 +1,12 @@ Field3D uses only C interface of hdf5 ---- OpenImageIO-oiio-7d98ca6/src/cmake/externalpackages.cmake.orig 2011-11-05 08:35:00.000000000 +0100 -+++ OpenImageIO-oiio-7d98ca6/src/cmake/externalpackages.cmake 2011-11-18 20:57:50.883126299 +0100 -@@ -195,7 +195,7 @@ +--- OpenImageIO-oiio-f4d79c0/src/cmake/externalpackages.cmake.orig 2013-07-14 17:08:40.729538530 +0200 ++++ OpenImageIO-oiio-f4d79c0/src/cmake/externalpackages.cmake 2013-07-14 17:09:33.429536318 +0200 +@@ -284,7 +284,7 @@ + # N.B. For a custom version, the caller had better set up the # variables HDF5_INCLUDE_DIRS and HDF5_LIBRARIES. else () - message (STATUS "Looking for system HDF5") - find_package (HDF5 COMPONENTS CXX) + find_package (HDF5) endif () - message (STATUS "HDF5_FOUND=${HDF5_FOUND}") - message (STATUS "HDF5_INCLUDE_DIRS=${HDF5_INCLUDE_DIRS}") + if (VERBOSE) + message (STATUS "HDF5_FOUND=${HDF5_FOUND}") diff --git a/OpenImageIO-link.patch b/OpenImageIO-link.patch index 967f2a0..6f52fae 100644 --- a/OpenImageIO-link.patch +++ b/OpenImageIO-link.patch @@ -1,11 +1,11 @@ ---- OpenImageIO-oiio-0cae52b/src/libOpenImageIO/CMakeLists.txt.orig 2012-07-09 08:28:46.000000000 +0200 -+++ OpenImageIO-oiio-0cae52b/src/libOpenImageIO/CMakeLists.txt 2012-07-11 20:20:34.235460584 +0200 -@@ -197,7 +197,7 @@ - else () - add_library (OpenImageIO SHARED ${libOpenImageIO_srcs}) +--- OpenImageIO-oiio-f4d79c0/src/libOpenImageIO/CMakeLists.txt.orig 2013-07-14 16:40:55.296275085 +0200 ++++ OpenImageIO-oiio-f4d79c0/src/libOpenImageIO/CMakeLists.txt 2013-07-14 17:08:13.526206338 +0200 +@@ -210,7 +210,7 @@ endif () --target_link_libraries (OpenImageIO ${Boost_LIBRARIES}) -+target_link_libraries (OpenImageIO ${Boost_LIBRARIES} ${CMAKE_DL_LIBS}) - - + target_link_libraries (OpenImageIO + ${VISIBILITY_COMMAND} ${VISIBILITY_MAP_COMMAND} +- ${Boost_LIBRARIES}) ++ ${Boost_LIBRARIES} ${CMAKE_DL_LIBS}) + # Link against system TBB library if specified + if (USE_TBB AND USE_EXTERNAL_TBB) diff --git a/OpenImageIO-werror.patch b/OpenImageIO-werror.patch new file mode 100644 index 0000000..e67153f --- /dev/null +++ b/OpenImageIO-werror.patch @@ -0,0 +1,24 @@ +--- OpenImageIO-oiio-f4d79c0/src/libOpenImageIO/fmath_test.cpp.orig 2013-07-08 21:47:25.000000000 +0200 ++++ OpenImageIO-oiio-f4d79c0/src/libOpenImageIO/fmath_test.cpp 2013-07-14 17:32:19.946145637 +0200 +@@ -72,8 +72,8 @@ + OIIO_CHECK_EQUAL ((bit_range_convert<2,20>(3)), 1048575); + OIIO_CHECK_EQUAL ((bit_range_convert<20,2>(1048575)), 3); + OIIO_CHECK_EQUAL ((bit_range_convert<20,21>(1048575)), 2097151); +- OIIO_CHECK_EQUAL ((bit_range_convert<32,32>(4294967295)), 4294967295); +- OIIO_CHECK_EQUAL ((bit_range_convert<32,16>(4294967295)), 65535); ++ OIIO_CHECK_EQUAL ((bit_range_convert<32,32>(4294967295U)), 4294967295U); ++ OIIO_CHECK_EQUAL ((bit_range_convert<32,16>(4294967295U)), 65535); + // These are not expected to work, since bit_range_convert only takes a + // regular 'unsigned int' as parameter. If we need >32 bit conversion, + // we need to add a uint64_t version of bit_range_convert. +--- OpenImageIO-oiio-f4d79c0/src/dpx.imageio/dpxinput.cpp.orig 2013-07-14 17:33:27.426142801 +0200 ++++ OpenImageIO-oiio-f4d79c0/src/dpx.imageio/dpxinput.cpp 2013-07-14 18:10:42.519382338 +0200 +@@ -467,7 +467,7 @@ + m_spec.attribute ("dpx:FilmEdgeCode", buf); + + tmpstr.clear (); +- switch (m_dpx.header.Signal ()) { ++ switch ((int)m_dpx.header.Signal ()) { + case dpx::kUndefined: + tmpstr = "Undefined"; + break; diff --git a/OpenImageIO.spec b/OpenImageIO.spec index d4290e2..3c65dcd 100644 --- a/OpenImageIO.spec +++ b/OpenImageIO.spec @@ -8,12 +8,12 @@ Summary: Library for reading and writing images Summary(pl.UTF-8): Biblioteka do odczytu i zapisu obrazów Name: OpenImageIO -Version: 1.0.9 -Release: 5 +Version: 1.2.0 +Release: 1 License: BSD Group: Libraries Source0: https://github.com/OpenImageIO/oiio/tarball/Release-%{version}/%{name}-%{version}.tar.gz -# Source0-md5: fad47ccfe619c203e5395afc1ebed4e2 +# Source0-md5: 8738dd9b24fc4f0cb3eebb094347104a Patch0: %{name}-link.patch Patch2: %{name}-hdf.patch Patch3: %{name}-system-squish.patch @@ -21,6 +21,7 @@ Patch4: %{name}-system-ptex.patch Patch5: %{name}-system-dpx.patch Patch6: %{name}-system-libcineon.patch Patch7: no-gcc-atomics.patch +Patch8: %{name}-werror.patch URL: https://sites.google.com/site/openimageio/home BuildRequires: Field3D-devel %{?with_ocio:BuildRequires: OpenColorIO-devel} @@ -291,16 +292,17 @@ Python binding for OpenImageIO library. Wiązanie Pythona do biblioteki OpenImageIO. %prep -%setup -q -n OpenImageIO-oiio-0b78dec +%setup -q -n OpenImageIO-oiio-f4d79c0 %patch0 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 -%ifarch i486 +%ifarch i386 i486 %patch7 -p1 %endif +%patch8 -p1 %{__rm} -r src/dds.imageio/squish src/ptex.imageio/ptex # when using system pugixml, don't use hacked headers @@ -342,16 +344,15 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(644,root,root,755) -%doc CHANGES CREDITS LICENSE README +%doc CHANGES CREDITS LICENSE README.rst %attr(755,root,root) %{_bindir}/iconvert %attr(755,root,root) %{_bindir}/idiff %attr(755,root,root) %{_bindir}/igrep %attr(755,root,root) %{_bindir}/iinfo -%attr(755,root,root) %{_bindir}/iprocess %attr(755,root,root) %{_bindir}/maketx %attr(755,root,root) %{_bindir}/oiiotool %attr(755,root,root) %{_libdir}/libOpenImageIO.so.*.*.* -%attr(755,root,root) %ghost %{_libdir}/libOpenImageIO.so.1.0 +%attr(755,root,root) %ghost %{_libdir}/libOpenImageIO.so.1.2 %attr(755,root,root) %{_libdir}/bmp.imageio.so %attr(755,root,root) %{_libdir}/fits.imageio.so %attr(755,root,root) %{_libdir}/hdr.imageio.so @@ -367,7 +368,6 @@ rm -rf $RPM_BUILD_ROOT %{_mandir}/man1/idiff.1* %{_mandir}/man1/igrep.1* %{_mandir}/man1/iinfo.1* -%{_mandir}/man1/iprocess.1* %{_mandir}/man1/maketx.1* %{_mandir}/man1/oiiotool.1* -- 2.44.0