Source: authbind
Version: 2.1.1+nmu1
Tags: patch
User: [email protected]
Usertags: rebootstrap
authbind fails to cross build from source, because it generally uses the
build architecture toolchain. The attached patch converts it to use
triplet-prefixed build tools and thus makes cross builds succeed. Please
consider applying it.
Helmut
diff --minimal -Nru authbind-2.1.1+nmu1/Makefile authbind-2.1.1+nmu2/Makefile
--- authbind-2.1.1+nmu1/Makefile 2012-06-03 02:45:04.000000000 +0200
+++ authbind-2.1.1+nmu2/Makefile 2017-01-12 23:23:43.000000000 +0100
@@ -82,7 +82,7 @@
helper.o authbind.o: authbind.h
$(LIBTARGET): libauthbind.o
- ld -shared -soname $(LIBCANON) -o $@ $< $(LIBS)
+ $(LD) -shared -soname $(LIBCANON) -o $@ $< $(LIBS)
clean distclean:
rm -f $(TARGETS) *.o *~ ./#*# *.bak *.new core
diff --minimal -Nru authbind-2.1.1+nmu1/debian/changelog
authbind-2.1.1+nmu2/debian/changelog
--- authbind-2.1.1+nmu1/debian/changelog 2015-07-26 11:23:38.000000000
+0200
+++ authbind-2.1.1+nmu2/debian/changelog 2017-01-12 23:23:43.000000000
+0100
@@ -1,3 +1,10 @@
+authbind (2.1.1+nmu2) UNRELEASED; urgency=medium
+
+ * Non-maintainer upload.
+ * Fix FTCBFS: Use triplet-prefixed build tools (Closes: #-1)
+
+ -- Helmut Grohne <[email protected]> Thu, 12 Jan 2017 23:23:43 +0100
+
authbind (2.1.1+nmu1) unstable; urgency=medium
* Non-maintainer upload.
diff --minimal -Nru authbind-2.1.1+nmu1/debian/rules
authbind-2.1.1+nmu2/debian/rules
--- authbind-2.1.1+nmu1/debian/rules 2015-07-26 11:18:57.000000000 +0200
+++ authbind-2.1.1+nmu2/debian/rules 2017-01-12 23:23:43.000000000 +0100
@@ -20,7 +20,13 @@
#
# $Id$
-CC= gcc
+-include /usr/share/dpkg/architecture.mk
+ifneq ($(DEB_HOST_GNU_TYPE),)
+TOOL_PREFIX=$(DEB_HOST_GNU_TYPE)-
+endif
+ifeq ($(origin CC),default)
+CC=$(TOOL_PREFIX)gcc
+endif
SHELL=/bin/bash
package=authbind
@@ -45,8 +51,8 @@
LDFLAGS += -g
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
-INSTALL_PROGRAM += -s
-STRIP=strip
+STRIP=$(TOOL_PREFIX)strip
+INSTALL_PROGRAM += -s --strip-program=$(STRIP)
else
STRIP=:
endif
@@ -62,7 +68,7 @@
build:
- $(MAKE) prefix=/usr
+ $(MAKE) prefix=/usr CC='$(CC)' LD='$(TOOL_PREFIX)ld'
clean:
$(MAKE) distclean