[metview] 03/03: Add FPIC support properly. FPIC not being picked up on CXX for i386
Alastair McKinstry
mckinstry at moszumanska.debian.org
Thu Dec 3 14:08:43 UTC 2015
This is an automated email from the git hooks/post-receive script.
mckinstry pushed a commit to branch debian/master
in repository metview.
commit 23eaaf432e0af86a3dee7f1a8620dd70dd356143
Author: Alastair McKinstry <mckinstry at debian.org>
Date: Mon Nov 9 10:38:05 2015 +0000
Add FPIC support properly. FPIC not being picked up on CXX for i386
---
debian/changelog | 6 ++++++
debian/patches/fpic.patch | 19 +++++++++++++++++++
debian/patches/series | 2 +-
debian/rules | 11 +++++------
4 files changed, 31 insertions(+), 7 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 3122df7..63c166e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+metview (4.5.7-4) unstable; urgency=medium
+
+ * Add FPIC support properly. FPIC not being picked up on CXX for i386
+
+ -- Alastair McKinstry <mckinstry at debian.org> Mon, 09 Nov 2015 10:37:35 +0000
+
metview (4.5.7-3) unstable; urgency=medium
* Next in the round of exciting metview reproducibility fixes.
diff --git a/debian/patches/fpic.patch b/debian/patches/fpic.patch
new file mode 100644
index 0000000..b3d6df1
--- /dev/null
+++ b/debian/patches/fpic.patch
@@ -0,0 +1,19 @@
+Author: Alastair McKinstry <mckinstry at debian.org>
+Description: Add FPIC support
+Last-Updated: 2015-11-09
+Forwarded: no
+
+Index: metview-4.5.7/CMakeLists.txt
+===================================================================
+--- metview-4.5.7.orig/CMakeLists.txt
++++ metview-4.5.7/CMakeLists.txt
+@@ -768,6 +768,9 @@ endif()
+ # -------------------------
+ # compiler-specific options
+ # -------------------------
++ecbuild_add_cxx_flags("${FPIC}")
++ecbuild_add_c_flags("${FPIC}")
++ecbuild_add_fortran_flags("${FPIC}")
+
+ if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" )
+ ecbuild_add_cxx_flags("-fpermissive -Wno-write-strings -Wno-deprecated")
diff --git a/debian/patches/series b/debian/patches/series
index f7694f6..bd0bade 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,5 +2,5 @@ fix-paths.patch
fix-scripts.patch
cmake-fixes.patch
mv_compress.patch
-# qt5.patch
reproducible-build.patch
+fpic.patch
diff --git a/debian/rules b/debian/rules
index c2e554d..5d64eaa 100755
--- a/debian/rules
+++ b/debian/rules
@@ -16,6 +16,7 @@ export METVIEW_DEBUG:=1
DESTDIR:=$(CURDIR)/debian/tmp/
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
+TARGET_ARCH ?= $(shell dpkg-architecture -qDEB_TARGET_ARCH_CPU)
LIBDIR:=/usr/lib/$(DEB_HOST_MULTIARCH)
PATH:=$(PATH):$(CURDIR)/scripts
AUTOGENERATED:= libmetview-dev.install metview.install
@@ -25,11 +26,8 @@ export METVIEW_BIN:=$(METVIEW_DIR_DEV)/bin
FPIC:= ''
-ifeq ($(DEB_HOST_MULTIARCH), s390x)
- FPIC:= -fpic
-endif
-ifeq ($(DEB_HOST_MULTIARCH), i386)
- FPIC:= -fpic
+ifeq ($(TARGET_ARCH), i386)
+ FPIC:= -fPIC
endif
# magic debhelper rule
@@ -58,7 +56,8 @@ override_dh_auto_configure:
-DFLEXTRA_PATH=/usr/bin/flextra \
-DENABLE_QT5=On \
-DGRIB_API_PATH=/usr/lib \
- -DDISABLE_OS_CHECK=On
+ -DDISABLE_OS_CHECK=On \
+ -DFPIC=${FPIC}
for f in ${AUTOGENERATED} ; do \
sed -e 's%@ARCH@%${DEB_HOST_MULTIARCH}%g' < debian/$$f.in > debian/$$f ; \
done
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/metview.git
More information about the debian-science-commits
mailing list