Source: libcbor Version: 0.5.0+dfsg-2 Tags: patch User: [email protected] Usertags: cross-satisfiability
libcbor cannot be cross built from source, because its build depends are unsatisfiable. It also participates in dependency loops relevant to architecture bootstrap. Both are hard problems, so I rather looked into easily droppable dependencies and I have to say, that I'll not be leaving many. The first insight is that the libcbor documentation is nicely split into an arch:all package, but d/rules builds the documentation on arch-only builds as well. Indeed, the actual library build and the documentation build are fully separate. In this package, we can fully move the documentation build to -indep overrides and skip all library builds there. That allows partitioning all dependencies but debhelper to either B-D-A or B-D-I. While on it, I noticed that d/rules calls doxygen without depending on it. While the dependency is kinda implicit via python3-breathe, I think being explicit here would be better to avoid a late surprise. Finally, libcmocka-dev can be skipped via <!nocheck> as it is only used for testing. Since libcbor is normally reproducible, I went ahead and compared a full regular build without these changes to a full build, arch-only build and indep-only build with these changes (minus changelog) and they all matched exactly. Please consider applying the attached patch. Helmut
diff --minimal -Nru libcbor-0.5.0+dfsg/debian/changelog libcbor-0.5.0+dfsg/debian/changelog --- libcbor-0.5.0+dfsg/debian/changelog 2018-05-17 17:08:03.000000000 +0200 +++ libcbor-0.5.0+dfsg/debian/changelog 2021-02-02 07:03:06.000000000 +0100 @@ -1,3 +1,16 @@ +libcbor (0.5.0+dfsg-2.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Reduce Build-Depends: (Closes: #-1) + + d/rules: Move documentation build to -indep overrides. + + Enable sphinxdoc dh addon via B-D. + + Demote all sphinx dependencies to B-D-I. Be explicit about doxygen. + + d/rules: Skip cmake build in -indep overrides. + + Demote cmake and cmocka to B-D-A. + + Annotate cmocka <!nocheck>. + + -- Helmut Grohne <[email protected]> Tue, 02 Feb 2021 07:03:06 +0100 + libcbor (0.5.0+dfsg-2) unstable; urgency=medium * d/control: migrate to salsa.debian.org. diff --minimal -Nru libcbor-0.5.0+dfsg/debian/control libcbor-0.5.0+dfsg/debian/control --- libcbor-0.5.0+dfsg/debian/control 2018-05-17 17:08:03.000000000 +0200 +++ libcbor-0.5.0+dfsg/debian/control 2021-02-02 07:03:06.000000000 +0100 @@ -2,11 +2,13 @@ Priority: optional Maintainer: Vincent Bernat <[email protected]> Build-Depends: debhelper (>= 9), - cmake, - libcmocka-dev, - python3-sphinx, - python3-sphinx-rtd-theme, - python3-breathe +Build-Depends-Arch: cmake, + libcmocka-dev <!nocheck>, +Build-Depends-Indep: dh-sequence-sphinxdoc, + doxygen, + python3-sphinx, + python3-sphinx-rtd-theme, + python3-breathe Standards-Version: 4.1.2 Section: libs Homepage: https://github.com/PJK/libcbor diff --minimal -Nru libcbor-0.5.0+dfsg/debian/rules libcbor-0.5.0+dfsg/debian/rules --- libcbor-0.5.0+dfsg/debian/rules 2018-05-17 17:08:03.000000000 +0200 +++ libcbor-0.5.0+dfsg/debian/rules 2021-02-02 07:03:06.000000000 +0100 @@ -3,12 +3,15 @@ DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) %: - dh $@ --with sphinxdoc + dh $@ -override_dh_auto_build: - dh_auto_build +override_dh_auto_configure-indep: + +override_dh_auto_build-indep: mkdir -p doc/build/doxygen doxygen make -C doc html # Nothing is using MathJax find doc/build/html -type f -print0 | xargs -0 sed -i '/ajax\/libs\/mathjax/d' + +override_dh_auto_install-indep:

