Bug#558095: dpkg: please accept ":native" multiarch qualifier in build dependencies
We would like to allow people to prepare their packages for
cross-compiling. Most functionality is already in place, however we are
still lacking a way to distinguish between build dependencies that are
required as tools (e.g. debhelper) or for building a tool (e.g. zlib-dev
for building a jar archiver which is then used to build a JAR file), and
build dependencies required for linking (e.g. zlib-dev for building a
java interpreter which can then unpack the JAR file).
The multiarch specification solves this to some extent, as tools are
marked "Multi-Arch: foreign" and libraries "Multi-Arch: same", which
allows us to have reasonable defaults by requiring "foreign" packages to
be installed in working order (i.e. preferentially DEB_BUILD_ARCH, but
any working one will do) and "same" packages in the version required for
linking (i.e. DEB_HOST_ARCH).
The cases not handled by the multi-arch specification are:
- A library package (M-A: same) is to be installed for DEB_BUILD_ARCH.
- A hybrid package (M-A: allowed) is to be installed for
- A hybrid package (M-A: allowed) is to be installed for any
The last case is somewhat implied in the original specification (":any"
qualifier in Depends lines), but never explicitly allowed for
Build-Depends; the others require introducing a new qualifier that is
only meaningful in build dependencies.
In phase one, which needs to happen before the squeeze release for this
to be useful, it would therefore be good if ":any" and ":native"
qualifiers in build dependencies were accepted. As Debian itself does
not yet cross-compile packages, actually supporting the specified
resolution is optional (but would be nice to have in
A minimal implementation would accept those qualifiers in all tools that
handle Build-Depends fields, but interpret the field as if the
qualifiers were not present (thus falling back to the strictest possible
interpretation for a native build).
A full implementation would resolve the dependencies according to the
table on the specification page.