Source: qtchooser
Version: 58-gfab25f1-1
Tags: patch
User: helm...@debian.org
Usertags: rebootstrap

qtchooser fails to cross build from source, because it uses the build
architecture compiler and then dh_strip fails to strip the generated elf
executable with the host architecture tools. The attached patch passes a
triplet-prefixed CXX to make and thus makes the cross build succeed.

Helmut
diff --minimal -Nru qtchooser-58-gfab25f1/debian/changelog 
qtchooser-58-gfab25f1/debian/changelog
--- qtchooser-58-gfab25f1/debian/changelog      2016-05-22 16:49:07.000000000 
+0200
+++ qtchooser-58-gfab25f1/debian/changelog      2016-09-03 13:40:28.000000000 
+0200
@@ -1,3 +1,10 @@
+qtchooser (58-gfab25f1-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: Pass triplet-prefixed CXX to make (Closes: #-1).
+
+ -- Helmut Grohne <hel...@subdivi.de>  Sat, 03 Sep 2016 13:40:09 +0200
+
 qtchooser (58-gfab25f1-1) unstable; urgency=medium
 
   [ Dmitry Shachnev ]
diff --minimal -Nru qtchooser-58-gfab25f1/debian/rules 
qtchooser-58-gfab25f1/debian/rules
--- qtchooser-58-gfab25f1/debian/rules  2016-05-22 16:34:28.000000000 +0200
+++ qtchooser-58-gfab25f1/debian/rules  2016-09-03 13:40:07.000000000 +0200
@@ -3,13 +3,16 @@
 export DEB_CXXFLAGS_MAINT_APPEND := $(shell dpkg-buildflags --get CPPFLAGS)
 export LFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
 
-DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
+include /usr/share/dpkg/architecture.mk
+ifeq ($(origin CXX),default)
+       CXX = $(DEB_HOST_GNU_TYPE)-g++
+endif
 
 %:
        dh $@ 
 
 override_dh_auto_build:
-       make 
QTCHOOSER_GLOBAL_DIR=/usr/share:/usr/lib/$(DEB_HOST_MULTIARCH):/usr/lib/$(DEB_HOST_MULTIARCH)/qt-default
+       make 
QTCHOOSER_GLOBAL_DIR=/usr/share:/usr/lib/$(DEB_HOST_MULTIARCH):/usr/lib/$(DEB_HOST_MULTIARCH)/qt-default
 CXX=$(CXX)
 
 override_dh_auto_install:
        make install INSTALL_ROOT=$(CURDIR)/debian/qtchooser

Reply via email to