Source: usbutils Version: 1:017-3 Tags: patch User: [email protected] Usertags: cross-satisfiability
usbutils cannot be cross built from source, because its build dependency on python3 identifies a host architecture python3 and that fails to install. The dependency really is only needed for building usbutils-py, which happens to be an Arch:all package and hence it should be possible to demote the dependency to Build-Depends-Indep. I've done so and am attaching a patch for your convenience. I also verified that the arch-only, indep-only and full build produce identical binary artifacts (as in reproducible builds) and that the cross build actually works. Helmut
diff --minimal -Nru usbutils-017/debian/changelog usbutils-017/debian/changelog --- usbutils-017/debian/changelog 2024-01-04 23:03:23.000000000 +0100 +++ usbutils-017/debian/changelog 2024-02-08 11:45:39.000000000 +0100 @@ -1,3 +1,10 @@ +usbutils (1:017-3.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Demote python dependencies to Build-Depends-Indep. (Closes: #-1) + + -- Helmut Grohne <[email protected]> Thu, 08 Feb 2024 11:45:39 +0100 + usbutils (1:017-3) unstable; urgency=medium * Upload to unstable. diff --minimal -Nru usbutils-017/debian/control usbutils-017/debian/control --- usbutils-017/debian/control 2024-01-04 15:59:50.000000000 +0100 +++ usbutils-017/debian/control 2024-02-08 11:45:37.000000000 +0100 @@ -2,7 +2,8 @@ Section: utils Priority: optional Maintainer: Aurelien Jarno <[email protected]> -Build-Depends: debhelper-compat (= 13), libusb-1.0-0-dev, libudev-dev, pkg-config, python3, dh-python +Build-Depends: debhelper-compat (= 13), libusb-1.0-0-dev, libudev-dev, pkg-config +Build-Depends-Indep: dh-sequence-python3, python3 Standards-Version: 4.6.2 Rules-Requires-Root: no Homepage: https://github.com/gregkh/usbutils diff --minimal -Nru usbutils-017/debian/rules usbutils-017/debian/rules --- usbutils-017/debian/rules 2024-01-04 15:59:50.000000000 +0100 +++ usbutils-017/debian/rules 2024-02-08 11:45:39.000000000 +0100 @@ -2,13 +2,12 @@ -include /usr/share/dpkg/buildtools.mk %: - dh $@ --with python3 + dh $@ override_dh_auto_configure: dh_auto_configure -- --datadir=/usr/share/misc -override_dh_auto_build: - dh_auto_build +execute_after_dh_auto_build-arch: $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $(CURDIR)/usbreset $(CURDIR)/usbreset.c override_dh_auto_install:

