Source: statsprocessor
Version: 0.11+git20160316-1
Tags: patch
User: debian-cr...@lists.debian.org
Usertags: rebootstrap

statsprocessor fails to cross build from source, because it does not
pass cross tools to make. The easiest way of fixing that - using
dh_auto_build - is insufficient here, because statsprocessor uses
help2man. Given that statsprocessor has so few dependencies, we can
simply build it twice: Once for the build architecture to run help2man
and then again for real. Please consider applying the attached patch.

Helmut
diff --minimal -Nru statsprocessor-0.11+git20160316/debian/changelog 
statsprocessor-0.11+git20160316/debian/changelog
--- statsprocessor-0.11+git20160316/debian/changelog    2018-09-03 
05:44:58.000000000 +0200
+++ statsprocessor-0.11+git20160316/debian/changelog    2019-06-06 
16:51:44.000000000 +0200
@@ -1,3 +1,11 @@
+statsprocessor (0.11+git20160316-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: Build twice. Once for help2man and once for real. (Closes:
+    #-1)
+
+ -- Helmut Grohne <hel...@subdivi.de>  Thu, 06 Jun 2019 16:51:44 +0200
+
 statsprocessor (0.11+git20160316-1) unstable; urgency=medium
 
   * Team upload.
diff --minimal -Nru statsprocessor-0.11+git20160316/debian/rules 
statsprocessor-0.11+git20160316/debian/rules
--- statsprocessor-0.11+git20160316/debian/rules        2018-09-02 
16:14:55.000000000 +0200
+++ statsprocessor-0.11+git20160316/debian/rules        2019-06-06 
16:51:44.000000000 +0200
@@ -2,6 +2,8 @@
 
 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
 
+include /usr/share/dpkg/architecture.mk
+
 %:
        dh $@
 
@@ -10,7 +12,11 @@
        rm -f sp64.1
 
 override_dh_auto_build:
-       $(MAKE) -C src
+       dpkg-architecture -f -a$(DEB_BUILD_ARCH) -c dh_auto_build 
--sourcedirectory=src
        help2man -i debian/extra-man-info.txt \
          -n 'word generator based on per-position Markov chains' \
           -N ./src/sp64 > sp64.1
+ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH))
+       rm -f src/sp64
+       dh_auto_build --sourcedirectory=src
+endif

Reply via email to