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

Bug#748936: apt doesnt understand architecture wildcards



Package: apt
Version: 1.0.1
Severity: normal

Hi,

Debian policy 11.1.1 [1] and the associated footnote [2] allow
architecture wildcards of the form os-any and any-cpu. Apt seems to
equal "cpu" with "debian architecture" which is not correct. Here is an
example of correct matching:

dpkg-architecture -aarmhf -iany-arm && echo "any-arm matches armhf"

Apt would instead only match the deprecated "arm" architecture with
"any-arm". This doesnt seem to be a problem in practice though because:

 1) apt does not check whether a source package can be compiled on the
    current host architecture (it ignores the Architecture field of
    source packages)
 2) all packages that have any-arm in their build dependency
    architecture restrictions also include any-armel, any-armeb and
    any-armhf

Nevertheless, apt behaviour should reflect dpkg behaviour and naturally
policy. The correct behaviour is encoded in dpkg scripts/Dpkg/Arch.pm
and needs the files /usr/share/dpkg/triplettable and
/usr/share/dpkg/cputable to work correctly.

cheers, josch


[1] https://www.debian.org/doc/debian-policy/ch-customized-programs.html#s-arch-wildcard-spec
[2] https://www.debian.org/doc/debian-policy/footnotes.html#f99


Reply to: