Source: unzip
Version: 6.0-20
Tags: patch
User: helm...@debian.org
Usertags: rebootstrap

unzip fails to cross build from source, because it uses the build
architecture compiler. Simply setting up CC correctly fixes the build.
The attached patch does just that.

Helmut
diff --minimal -Nru unzip-6.0/debian/changelog unzip-6.0/debian/changelog
--- unzip-6.0/debian/changelog  2015-11-09 22:15:44.000000000 +0100
+++ unzip-6.0/debian/changelog  2016-08-30 12:12:23.000000000 +0200
@@ -1,3 +1,10 @@
+unzip (6.0-20.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: pass correct CC to Makefile. Closes: #-1.
+
+ -- Helmut Grohne <hel...@subdivi.de>  Tue, 30 Aug 2016 12:12:01 +0200
+
 unzip (6.0-20) unstable; urgency=high
 
   * Update debian/patches/16-fix-integer-underflow-csiz-decrypted to fix
diff --minimal -Nru unzip-6.0/debian/rules unzip-6.0/debian/rules
--- unzip-6.0/debian/rules      2015-10-22 11:00:00.000000000 +0200
+++ unzip-6.0/debian/rules      2016-08-30 12:11:59.000000000 +0200
@@ -1,6 +1,9 @@
 #!/usr/bin/make -f
 
-CC = gcc
+include /usr/share/dpkg/architecture.mk
+ifeq ($(origin CC),default)
+CC = $(DEB_HOST_GNU_TYPE)-gcc
+endif
 export DEB_BUILD_MAINT_OPTIONS=hardening=-format
 CFLAGS := `dpkg-buildflags --get CFLAGS` -Wall
 ifeq ($(DEB_HOST_ARCH),armhf)

Reply via email to