[packages/OpenImageIO] - rel 3; patches from debian
arekm
arekm at pld-linux.org
Tue Nov 5 22:27:29 CET 2013
commit 05e8614ecf64ec63319642b7fe0c6cc1ec53ae0e
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Tue Nov 5 22:27:26 2013 +0100
- rel 3; patches from debian
0002-Fix_IlmBase_issue.patch | 23 +++++++++++++++
0003-Fix_multiarch_paths.patch | 39 +++++++++++++++++++++++++
0004-Fix_FTBFS_on_atomic_operations.patch | 48 +++++++++++++++++++++++++++++++
OpenImageIO.spec | 12 ++++----
no-gcc-atomics.patch | 13 ---------
5 files changed, 117 insertions(+), 18 deletions(-)
---
diff --git a/OpenImageIO.spec b/OpenImageIO.spec
index 83469b5..8f62b95 100644
--- a/OpenImageIO.spec
+++ b/OpenImageIO.spec
@@ -9,7 +9,7 @@ Summary: Library for reading and writing images
Summary(pl.UTF-8): Biblioteka do odczytu i zapisu obrazów
Name: OpenImageIO
Version: 1.2.3
-Release: 2
+Release: 3
License: BSD
Group: Libraries
Source0: https://github.com/OpenImageIO/oiio/tarball/Release-%{version}/%{name}-%{version}.tar.gz
@@ -21,8 +21,10 @@ Patch3: %{name}-system-squish.patch
Patch4: %{name}-system-ptex.patch
Patch5: %{name}-system-dpx.patch
Patch6: %{name}-system-libcineon.patch
-Patch7: no-gcc-atomics.patch
-Patch8: %{name}-werror.patch
+Patch7: %{name}-werror.patch
+Patch8: 0002-Fix_IlmBase_issue.patch
+Patch9: 0003-Fix_multiarch_paths.patch
+Patch10: 0004-Fix_FTBFS_on_atomic_operations.patch
URL: https://sites.google.com/site/openimageio/home
BuildRequires: Field3D-devel
%{?with_ocio:BuildRequires: OpenColorIO-devel}
@@ -301,10 +303,10 @@ Wiązanie Pythona do biblioteki OpenImageIO.
%patch4 -p1
%patch5 -p1
%patch6 -p1
-%ifarch i386 i486
%patch7 -p1
-%endif
%patch8 -p1
+%patch9 -p1
+%patch10 -p1
%{__rm} -r src/dds.imageio/squish src/ptex.imageio/ptex
# when using system pugixml, don't use hacked headers
diff --git a/0002-Fix_IlmBase_issue.patch b/0002-Fix_IlmBase_issue.patch
new file mode 100644
index 0000000..15f1fc4
--- /dev/null
+++ b/0002-Fix_IlmBase_issue.patch
@@ -0,0 +1,23 @@
+From: "Matteo F. Vescovi" <mfv.debian at gmail.com>
+Date: Fri, 21 Dec 2012 16:31:29 +0100
+Subject: Fix_IlmBase_issue
+
+This first patch hides the private symbols
+even on kFreeBSD and Hurd, besides Linux.
+---
+ src/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index adb380c..71f9a3e 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -130,7 +130,7 @@ if (CMAKE_COMPILER_IS_CLANG OR CMAKE_COMPILER_IS_GNUCC)
+ # Turn default symbol visibility to hidden
+ set (VISIBILITY_COMMAND "-fvisibility=hidden -fvisibility-inlines-hidden")
+ add_definitions (${VISIBILITY_COMMAND})
+- if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
++ if (CMAKE_SYSTEM_NAME MATCHES "Linux|kFreeBSD" OR CMAKE_SYSTEM_NAME STREQUAL "GNU")
+ # Linux: also hide all the symbols of dependent libraries to
+ # prevent clashes if an app using OIIO is linked against
+ # other verions of our dependencies.
diff --git a/0003-Fix_multiarch_paths.patch b/0003-Fix_multiarch_paths.patch
new file mode 100644
index 0000000..436cc6a
--- /dev/null
+++ b/0003-Fix_multiarch_paths.patch
@@ -0,0 +1,39 @@
+From: "Matteo F. Vescovi" <mfv.debian at gmail.com>
+Date: Fri, 21 Dec 2012 16:34:56 +0100
+Subject: Fix_multiarch_paths
+
+This second patch adds multiarch paths to the
+standard ones for ilm and openexr libraries.
+---
+ src/cmake/modules/FindIlmBase.cmake | 2 ++
+ src/cmake/modules/FindOpenEXR.cmake | 2 ++
+ 2 files changed, 4 insertions(+)
+
+diff --git a/src/cmake/modules/FindIlmBase.cmake b/src/cmake/modules/FindIlmBase.cmake
+index 9e2fe5b..041b470 100644
+--- a/src/cmake/modules/FindIlmBase.cmake
++++ b/src/cmake/modules/FindIlmBase.cmake
+@@ -118,7 +118,9 @@ set (IlmBase_generic_include_paths
+ /opt/local/include)
+ set (IlmBase_generic_library_paths
+ /usr/lib
++ /usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}
+ /usr/local/lib
++ /usr/local/lib/${CMAKE_LIBRARY_ARCHITECTURE}
+ /sw/lib
+ /opt/local/lib)
+
+diff --git a/src/cmake/modules/FindOpenEXR.cmake b/src/cmake/modules/FindOpenEXR.cmake
+index bd37e8a..955c025 100644
+--- a/src/cmake/modules/FindOpenEXR.cmake
++++ b/src/cmake/modules/FindOpenEXR.cmake
+@@ -114,7 +114,9 @@ set (OpenEXR_generic_include_paths
+ /opt/local/include)
+ set (OpenEXR_generic_library_paths
+ /usr/lib
++ /usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}
+ /usr/local/lib
++ /usr/local/lib/${CMAKE_LIBRARY_ARCHITECTURE}
+ /sw/lib
+ /opt/local/lib)
+
diff --git a/0004-Fix_FTBFS_on_atomic_operations.patch b/0004-Fix_FTBFS_on_atomic_operations.patch
new file mode 100644
index 0000000..9831d71
--- /dev/null
+++ b/0004-Fix_FTBFS_on_atomic_operations.patch
@@ -0,0 +1,48 @@
+From: Roland Stigge <stigge at antcom.de>
+Date: Tue, 21 May 2013 15:09:00 +0200
+Subject: Fix_FTBFS_on_atomic_operations
+
+---
+ src/include/thread.h | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/include/thread.h b/src/include/thread.h
+index e389ebb..4735796 100644
+--- a/src/include/thread.h
++++ b/src/include/thread.h
+@@ -220,7 +220,7 @@ inline int
+ atomic_exchange_and_add (volatile int *at, int x)
+ {
+ #ifdef USE_GCC_ATOMICS
+- return __sync_fetch_and_add ((int *)at, x);
++ return __atomic_fetch_add ((int *)at, x, __ATOMIC_SEQ_CST);
+ #elif USE_TBB
+ atomic<int> *a = (atomic<int> *)at;
+ return a->fetch_and_add (x);
+@@ -238,7 +238,7 @@ inline long long
+ atomic_exchange_and_add (volatile long long *at, long long x)
+ {
+ #ifdef USE_GCC_ATOMICS
+- return __sync_fetch_and_add (at, x);
++ return __atomic_fetch_add (at, x, __ATOMIC_SEQ_CST);
+ #elif USE_TBB
+ atomic<long long> *a = (atomic<long long> *)at;
+ return a->fetch_and_add (x);
+@@ -266,7 +266,7 @@ inline bool
+ atomic_compare_and_exchange (volatile int *at, int compareval, int newval)
+ {
+ #ifdef USE_GCC_ATOMICS
+- return __sync_bool_compare_and_swap (at, compareval, newval);
++ return __atomic_compare_exchange_n (at, &compareval, newval, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST);
+ #elif USE_TBB
+ atomic<int> *a = (atomic<int> *)at;
+ return a->compare_and_swap (newval, compareval) == newval;
+@@ -283,7 +283,7 @@ inline bool
+ atomic_compare_and_exchange (volatile long long *at, long long compareval, long long newval)
+ {
+ #ifdef USE_GCC_ATOMICS
+- return __sync_bool_compare_and_swap (at, compareval, newval);
++ return __atomic_compare_exchange_n (at, &compareval, newval, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST);
+ #elif USE_TBB
+ atomic<long long> *a = (atomic<long long> *)at;
+ return a->compare_and_swap (newval, compareval) == newval;
diff --git a/no-gcc-atomics.patch b/no-gcc-atomics.patch
deleted file mode 100644
index 462462e..0000000
--- a/no-gcc-atomics.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- OpenImageIO-oiio-bcdad81/src/include/thread.h~ 2013-11-01 18:03:46.000000000 +0100
-+++ OpenImageIO-oiio-bcdad81/src/include/thread.h 2013-11-05 21:54:05.234898906 +0100
-@@ -111,9 +111,7 @@
- # endif
- #endif
-
--#if defined(__GNUC__) && (defined(_GLIBCXX_ATOMIC_BUILTINS) || (__GNUC__ * 100 + __GNUC_MINOR__ >= 401))
--#define USE_GCC_ATOMICS
--#endif
-+#undef USE_GCC_ATOMICS
-
- OIIO_NAMESPACE_ENTER
- {
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/OpenImageIO.git/commitdiff/05e8614ecf64ec63319642b7fe0c6cc1ec53ae0e
More information about the pld-cvs-commit
mailing list