[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1003522: fonttools: Please review the (build-)dependencies



On Tue, 11 Jan 2022 10:34:41 +0100 Laurent Bigonville <bigon@debian.org> wrote:

> Hello,
>
> It seems that the fonttools has too much (build-)dependencies defined.
>
> For exemple it build-depends on python3-defcon, this BD seems useless
> (not defined in the requirements.txt file) and creates a dependency loop
> with it.
>
> Could you please drop python3-defcon and maybe also review the other
> (build-)dependencies, for example it's noted in the requirements.txt
> that ufoLib2 is required only for tests (that should maybe be indicated
> using the nocheck build profile)
>
> It also could be a good idea to move the build-dependencies needed to
> build the doc to the Build-Depends-Indep and mark them with nodoc, that
> would speedup/make it easier to build the package on the different
> ports.
>

I've made the following patch to fix the build-dependencies and some other cleanup.

The resulting .deb file is identical

I didn't look at the runtime dependencies
diff -Nru fonttools-4.28.5/debian/control fonttools-4.28.5/debian/control
--- fonttools-4.28.5/debian/control	2021-12-26 16:11:28.000000000 +0100
+++ fonttools-4.28.5/debian/control	2022-01-11 11:26:08.000000000 +0100
@@ -11,18 +11,19 @@
  python3-all,
  python3-all-dev,
  cython3 (>= 0.28.5),
- python3-defcon (>= 0.6.0),
  python3-brotli (>= 1.0.9),
  python3-pytest,
- python3-scipy (>= 1.7.1) | python3-munkres (>= 1.1.4),
+ python3-scipy (>= 1.7.1) <!nocheck> | python3-munkres (>= 1.1.4) <!nocheck>,
  python3-setuptools,
- python3-sympy,
  python3-fs (>= 2.4.11),
- python3-lxml (>= 4.5.0),
- python3-lz4 (>= 1.7.4.2),
- python3-sphinx,
- python3-sphinx-rtd-theme,
+ python3-lxml (>= 4.5.0) <!nocheck>,
+ python3-ufolib2 (>= 0.12.1) <!nocheck>,
+ sphinx-common,
  unicode-data (>= 14.0.0),
+Build-Depends-Indep: 
+ python3-sphinx <!nodoc>,
+ python3-sphinx-rtd-theme <!nodoc>,
+ python3-matplotlib <!nodoc>,
 Standards-Version: 4.5.1
 Homepage: https://github.com/fonttools/fonttools
 Vcs-Git: https://salsa.debian.org/fonts-team/fonttools.git
@@ -63,6 +64,7 @@
  ${misc:Depends}
 Replaces: fonttools (<< 3.15.1-1)
 Breaks: fonttools (<< 3.15.1-1)
+Build-Profiles: <!nodoc>
 Description: Converts OpenType and TrueType fonts to and from XML (Documentation)
  FontTools/TTX is a library to manipulate font files from Python.
  It supports reading and writing of TrueType/OpenType fonts, reading
diff -Nru fonttools-4.28.5/debian/rules fonttools-4.28.5/debian/rules
--- fonttools-4.28.5/debian/rules	2021-12-26 16:11:28.000000000 +0100
+++ fonttools-4.28.5/debian/rules	2022-01-11 11:26:08.000000000 +0100
@@ -2,6 +2,8 @@
 
 export LC_ALL=C.UTF-8
 
+binaries := $(shell dh_listpackages)
+
 %:
 	dh $@ --with python3,sphinxdoc --buildsystem=pybuild
 
@@ -15,11 +17,8 @@
 	PYTHONPATH="./Lib" python3 MetaTools/buildTableList.py
 	dh_auto_build
 
+ifneq ($(filter python-fonttools-doc,$(binaries)),)
 override_dh_sphinxdoc:
 	sphinx-build $(CURDIR)/Doc/source $(CURDIR)/debian/python-fonttools-doc/usr/share/doc/fonttools/html/
 	dh_sphinxdoc
-
-override_dh_auto_test:
-ifeq ($(filter nocheck,$(DEB_BUILD_PROFILES)),)
-	dh_auto_test
 endif

Reply to: