Source: libqmi
Version: 1.20.0-1.1
Tags: patch
User: [email protected]
Usertags: rebootstrap

libqmi fails to cross build from source. It requests the host
architecture python via Build-Depends, but it wants python as a build
tool. Annotating it with :any or :native fixes that. Then we get an "Exec
format error" while running some doc utility built from libqmi. Given
that the documentation is arch:any, we can skip that step in arch-only
builds. Thus the attached patch makes libqmi cross buildable. Please
consider applying it.

Helmut
diff --minimal -Nru libqmi-1.20.0/debian/changelog 
libqmi-1.20.0/debian/changelog
--- libqmi-1.20.0/debian/changelog      2018-09-22 21:05:32.000000000 +0200
+++ libqmi-1.20.0/debian/changelog      2018-11-07 06:17:30.000000000 +0100
@@ -1,3 +1,12 @@
+libqmi (1.20.0-1.2) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: (Closes: #-1)
+    + Annotate python build dependency with :any.
+    + Disable gtk-doc for arch-only builds.
+
+ -- Helmut Grohne <[email protected]>  Wed, 07 Nov 2018 06:17:30 +0100
+
 libqmi (1.20.0-1.1) unstable; urgency=medium
 
   * Non-maintainer upload.
diff --minimal -Nru libqmi-1.20.0/debian/control libqmi-1.20.0/debian/control
--- libqmi-1.20.0/debian/control        2018-03-01 15:31:56.000000000 +0100
+++ libqmi-1.20.0/debian/control        2018-11-07 06:17:30.000000000 +0100
@@ -8,7 +8,7 @@
                libglib2.0-dev (>= 2.36),
                libglib2.0-doc,
                pkg-config,
-               python,
+               python:any,
 Standards-Version: 4.1.3
 Section: libs
 Homepage: https://www.freedesktop.org/wiki/Software/libqmi
diff --minimal -Nru libqmi-1.20.0/debian/rules libqmi-1.20.0/debian/rules
--- libqmi-1.20.0/debian/rules  2018-02-24 20:33:49.000000000 +0100
+++ libqmi-1.20.0/debian/rules  2018-11-07 06:17:30.000000000 +0100
@@ -1,13 +1,20 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
 
+DOPACKAGES=$(shell dh_listpackages)
+
 %:
        dh $@
 
+ifneq (,$(filter libqmi-glib-doc,$(DOPACKAGES)))
+CONFIGURE_FLAGS = --enable-gtk-doc --enable-gtk-doc-html
+else
+CONFIGURE_FLAGS = --disable-gtk-doc --disable-gtk-doc-html
+endif
+
 override_dh_auto_configure:
        dh_auto_configure -- \
-               --enable-gtk-doc \
-               --enable-gtk-doc-html \
+               $(CONFIGURE_FLAGS) \
                --enable-firmware-update \
                --enable-gudev \
                --enable-mbim-qmux \

Reply via email to