[Pkg-phototools-commits] [SCM] openimageio branch, master, updated. debian/1.1.10+dfsg0-2-3-g9f26577
Matteo F. Vescovi
mfv.debian at gmail.com
Tue May 21 14:27:11 UTC 2013
The following commit has been merged in the master branch:
commit aa59ca6523b5d9fd59348cdb38380dc72d74ca9c
Author: Matteo F. Vescovi <mfv.debian at gmail.com>
Date: Tue May 21 15:13:13 2013 +0200
debian/: FTBFS on atomic operations fixed
- debian/control: b-dep on g++-4.7 was bumped to g++-4.8
- debian/rules: variables about g++ updated consequently
- debian/patches/0005-Fix_FTBFS_on_atomic_operations.patch:
added to adjust upstream source code using __atomic*
instead of deprecated __sync*
Closes: #708929
Thanks: Roland Stigge for the patch
diff --git a/debian/control b/debian/control
index 03f688a..5c954d4 100644
--- a/debian/control
+++ b/debian/control
@@ -6,7 +6,7 @@ Uploaders: Matteo F. Vescovi <mfv.debian at gmail.com>
Build-Depends:
cmake,
debhelper (>= 9),
- g++-4.7,
+ g++-4.8,
libboost-filesystem-dev,
libboost-regex-dev,
libboost-system-dev,
diff --git a/debian/patches/0002-Fix_IlmBase_issue.patch b/debian/patches/0002-Fix_IlmBase_issue.patch
index b0f4504..db0717f 100644
--- a/debian/patches/0002-Fix_IlmBase_issue.patch
+++ b/debian/patches/0002-Fix_IlmBase_issue.patch
@@ -9,10 +9,10 @@ even on kFreeBSD and Hurd, besides Linux.
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
-index d1fcb98..bb0e0a8 100644
+index b6f326f..a72ce9d 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
-@@ -111,7 +111,7 @@ if (CMAKE_COMPILER_IS_CLANG OR CMAKE_COMPILER_IS_GNUCC)
+@@ -113,7 +113,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})
diff --git a/debian/patches/0004-Fix_pause_issue.patch b/debian/patches/0004-Fix_pause_issue.patch
index d8580d6..a2561f0 100644
--- a/debian/patches/0004-Fix_pause_issue.patch
+++ b/debian/patches/0004-Fix_pause_issue.patch
@@ -7,10 +7,10 @@ Subject: Fix_pause_issue
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/include/thread.h b/src/include/thread.h
-index 5682f9b..51efc4e 100644
+index 28645fc..30fe1bf 100644
--- a/src/include/thread.h
+++ b/src/include/thread.h
-@@ -324,7 +324,7 @@ pause (int delay)
+@@ -336,7 +336,7 @@ pause (int delay)
{
#if USE_TBB
__TBB_Pause(delay);
diff --git a/debian/patches/0005-Fix_FTBFS_on_atomic_operations.patch b/debian/patches/0005-Fix_FTBFS_on_atomic_operations.patch
new file mode 100644
index 0000000..6efe2bc
--- /dev/null
+++ b/debian/patches/0005-Fix_FTBFS_on_atomic_operations.patch
@@ -0,0 +1,48 @@
+From: "Matteo F. Vescovi" <mfv.debian at gmail.com>
+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 30fe1bf..cc80c1e 100644
+--- a/src/include/thread.h
++++ b/src/include/thread.h
+@@ -226,7 +226,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);
+@@ -247,7 +247,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);
+@@ -278,7 +278,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;
+@@ -297,7 +297,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/debian/patches/series b/debian/patches/series
index ebbe12e..7337228 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@
0002-Fix_IlmBase_issue.patch
0003-Fix_multiarch_paths.patch
0004-Fix_pause_issue.patch
+0005-Fix_FTBFS_on_atomic_operations.patch
diff --git a/debian/rules b/debian/rules
index 55a2881..b5be8c9 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,8 +1,8 @@
#!/usr/bin/make -f
export DH_OPTIONS
export REPACK_SH=$(CURDIR)/debian/repack.sh
-export CC=gcc-4.7
-export CXX=g++-4.7
+export CC=gcc-4.8
+export CXX=g++-4.8
INSTDIR=debian/tmp
@@ -10,6 +10,8 @@ ifeq ($(DEB_HOST_ARCH_CPU),amd64)
export DEB_CXXFLAGS_MAINT_APPEND := -fPIC
endif
+export DEB_LDFLAGS_MAINT_APPEND := -latomic
+
%:
dh $@ --buildsystem=cmake \
--builddirectory=build \
--
OpenImageIO packaging
More information about the Pkg-phototools-commits
mailing list