Source: horizon-eda
Version: 1.1.0-1
Tags: patch
User: debian-cr...@lists.debian.org
Usertags: ftcbfs

horizon-eda fails to cross build from source, because it uses the build
architecture pkg-config. The upstream Makefile actually makes pkg-config
substitutable, but it uses the non-standard variable PKGCONFIG whereas
dh_auto_build substitutes PKG_CONFIG. Beyond that, make install also
needs to know about cross tools to avoid rebuilding things. Please
consider applying the attached patch to make horizon-eda cross
buildable.

Helmut
diff --minimal -Nru horizon-eda-1.1.0/debian/changelog 
horizon-eda-1.1.0/debian/changelog
--- horizon-eda-1.1.0/debian/changelog  2020-04-30 07:53:01.000000000 +0200
+++ horizon-eda-1.1.0/debian/changelog  2020-05-04 12:26:06.000000000 +0200
@@ -1,3 +1,12 @@
+horizon-eda (1.1.0-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: (Closes: #-1)
+    + Pass pkg-config as PKGCONFIG.
+    + Also pass cross tools to make install.
+
+ -- Helmut Grohne <hel...@subdivi.de>  Mon, 04 May 2020 12:26:06 +0200
+
 horizon-eda (1.1.0-1) unstable; urgency=medium
 
   * New upstream version
diff --minimal -Nru horizon-eda-1.1.0/debian/rules 
horizon-eda-1.1.0/debian/rules
--- horizon-eda-1.1.0/debian/rules      2020-01-17 14:12:27.000000000 +0100
+++ horizon-eda-1.1.0/debian/rules      2020-05-04 12:26:06.000000000 +0200
@@ -2,6 +2,7 @@
 # output every command that modifies files on the build system.
 export DH_VERBOSE = 1
 
+-include /usr/share/dpkg/buildtools.mk
 
 # see FEATURE AREAS in dpkg-buildflags(1)
 #export DEB_BUILD_MAINT_OPTIONS = hardening=+all
@@ -12,6 +13,7 @@
 # package maintainers to append LDFLAGS
 export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
 export PREFIX=/usr
+PKG_CONFIG ?= pkg-config
 
 %:
        dh $@
@@ -19,7 +21,10 @@
 
 override_dh_auto_build:
        doxygen doxygen.config
-       dh_auto_build
+       dh_auto_build -- 'PKGCONFIG=$(PKG_CONFIG)'
+
+override_dh_auto_install:
+       dh_auto_install -- 'CXX=$(CXX)' 'PKGCONFIG=$(PKG_CONFIG)'
 
 override_dh_clean:
        -rm -r docs

Reply via email to