[Python-modules-team] Bug#888142: mark python-docutils binary packages Multi-Arch: foreign

Helmut Grohne helmut at subdivi.de
Tue Jan 23 16:36:36 UTC 2018


Source: python-docutils
Version: 0.14+dfsg-2
Tags: patch
User: helmutg at debian.org
Usertags: rebootstrap

Please mark all binary packages built from python-docutils Multi-Arch:
foreign.

Rationale
---------
Whenever a source package Build-Depends on an Architecture: all package,
that dependency is only cross-satisfiable if the dependee is marked
Multi-Arch: foreign. In other words, everything that Build-Depends on
python-docutils or python3-docutils cannot presently satisfy cross
Build-Depends.

Correctness
-----------
The question whether Multi-Arch: foreign is correct is an important one.
Architecture-specific interfaces mainly come from three sources:
 * content
 * dependencies
 * maintainer scripts

For all binary packages, the content is architecture-independent by
virtue of them being Architecture: all rather than Architecture: any.

As for dependencies, docutils-doc has none. docutils-common Depends on
sgml-base and xml-core, both of which are marked Multi-Arch: foreign.
python-docutils Depends on docutils-common, python:any and python-roman.
The :any annotation is as good as being marked M-A:foreign and
python-roman got marked such in the last upload. The situation for
python3-docutils is likewise, so if docutils-common can be M-A:foreign,
dependencies won't be a problem for python{,3}-docutils.

This leaves maintainer scripts. Again docutils-doc has none.
docutils-common has the xml catalog scripts, which are ok for
M-A:foreign. And the python modules perform byte compilation. The output
of this byte compilation is architecture-dependent, so in principle
that'd render M-A:foreign incorrect. However we gave up on embedded
interpreter use cases an generally have only one python (for whatever
architecture) and the byte compilation will happen for whatever python
happens to be installed. Thus we proceeded and marked python-six and
lots of others and now also python-roman. This seems to be good enough
as long as we never encounter any python extensions in dependencies, a
fortunate case we have here.

So I think we should go ahead. Here is the patch.

Helmut
-------------- next part --------------
diff --minimal -Nru python-docutils-0.14+dfsg/debian/changelog python-docutils-0.14+dfsg/debian/changelog
--- python-docutils-0.14+dfsg/debian/changelog	2018-01-05 21:00:57.000000000 +0100
+++ python-docutils-0.14+dfsg/debian/changelog	2018-01-23 17:25:13.000000000 +0100
@@ -1,3 +1,10 @@
+python-docutils (0.14+dfsg-2.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Mark all binary packages Multi-Arch: foreign. (Closes: #-1)
+
+ -- Helmut Grohne <helmut at subdivi.de>  Tue, 23 Jan 2018 17:25:13 +0100
+
 python-docutils (0.14+dfsg-2) unstable; urgency=medium
 
   * Add python3-lib2to3 to dependencies of python3-docutils autopkgtest.
diff --minimal -Nru python-docutils-0.14+dfsg/debian/control python-docutils-0.14+dfsg/debian/control
--- python-docutils-0.14+dfsg/debian/control	2018-01-05 21:00:57.000000000 +0100
+++ python-docutils-0.14+dfsg/debian/control	2018-01-23 17:25:11.000000000 +0100
@@ -21,6 +21,7 @@
 Package: python-docutils
 Provides: docutils
 Architecture: all
+Multi-Arch: foreign
 Depends: docutils-common (= ${source:Version}),
          python-roman,
          ${misc:Depends},
@@ -48,6 +49,7 @@
 Package: python3-docutils
 Provides: docutils
 Architecture: all
+Multi-Arch: foreign
 Depends: docutils-common (= ${source:Version}),
          python3-roman,
          ${misc:Depends},
@@ -72,6 +74,7 @@
 
 Package: docutils-common
 Architecture: all
+Multi-Arch: foreign
 Depends: ${misc:Depends}
 Recommends: python-docutils | python3-docutils
 Description: text processing system for reStructuredText - common data
@@ -89,6 +92,7 @@
 Package: docutils-doc
 Section: doc
 Architecture: all
+Multi-Arch: foreign
 Depends: ${misc:Depends}
 Description: text processing system for reStructuredText - documentation
  reStructuredText is an easy-to-read, what-you-see-is-what-you-get plaintext


More information about the Python-modules-team mailing list