Source: beav
Version: 1:1.40-18
Tags: patch
User: helm...@debian.org
Usertags: rebootstrap

beav fails to cross build from source, because it uses the build
architecture compiler. The easiest way of passing cross tools to make is
using dh_auto_build, but beav doesn't use debhelper at all. So the
attached patch implements the logic manually to make beav cross
buildable. Please consider applying it.

Helmut
diff -u beav-1.40/debian/rules beav-1.40/debian/rules
--- beav-1.40/debian/rules
+++ beav-1.40/debian/rules
@@ -2,14 +2,17 @@
 #
 # Debian rules extensively rewritten by Martin Mitchell <mar...@debian.org>
 
+DPKG_EXPORT_BUILDTOOLS=1
+include /usr/share/dpkg/architecture.mk
+-include /usr/share/dpkg/buildtools.mk
+
 CFLAGS = -O2 -g -Wall -DUNIX -DNOPROTO
 LDFLAGS = -s
-ARCH = $(shell dpkg --print-installation-architecture)
-STRIP=strip --strip-unneeded --remove-section=.note --remove-section=.comment
+STRIP=$(DEB_HOST_GNU_TYPE)-strip --strip-unneeded --remove-section=.note 
--remove-section=.comment
 
 build:
 # Builds the binary package.
-       make CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
+       make CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
        touch build
 
 clean:
diff -u beav-1.40/debian/changelog beav-1.40/debian/changelog
--- beav-1.40/debian/changelog
+++ beav-1.40/debian/changelog
@@ -1,3 +1,10 @@
+beav (1:1.40-18.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: Use host tools. (Closes: #-1)
+
+ -- Helmut Grohne <hel...@subdivi.de>  Tue, 10 Jul 2018 23:33:49 +0200
+
 beav (1:1.40-18) unstable; urgency=low
 
   * Repackaged with the original 1.40 source so that we get a proper diff.gz.

Reply via email to