Home My Page Projects Dose: library and tools
Summary Activity Tracker Lists SCM Files

[#15098] wrong implementation of --defaultedMAforeign

2012-11-18 00:14
Submitted by:
Johannes Schauer (josch)
Assigned to:
Pietro Abate (abate)
wrong implementation of --defaultedMAforeign

Detailed description
for cross building, dpkg in Ubuntu treats architecture:all packages as

Commit d8f178ab is supposed to accommodate for this different behavior
in Ubuntu but what it actually does is to make all architecture:all
packages Multi-Arch:foreign. Instead, architecture:all packages are only
treated as Multi-Arch:foreign when they are used to satisfy cross build
dependencies ant NOT for any other dependency resolution.
Message  ↓
Date: 2015-03-27 16:25
Sender: Johannes Schauer

There are two sides to this. One is to allow dose3 to emulate Ubuntu apt behaviour. It still doesn't do that but instead does what is described in the original report.

The other side is whether this mangling of arch:all packages during cross building is the right solution. This is discussed in Debian bug #666772 and in the last message I give two examples (dh-ocaml and haskell-devscripts) where doing this mangling would be outright wrong and lead to wrong results. So once cross compiling becomes more popular this patch might even be removed from apt in Debian.

Any thing else you want to know?

Date: 2015-03-27 15:31
Sender: Pietro Abate

Do you have any updates on this one ?

Date: 2014-05-28 06:36
Sender: Johannes Schauer

As far as I can see, applications/deb-buildcheck.ml still just makes all arch:all packages m-a:foreign which is wrong. See below for an explanation for what actually would have to be done to replicate Ubuntu behavior.

Date: 2014-05-26 07:18
Sender: Pietro Abate

Is this problem still present in HEAD or we can close this bug ?

Date: 2012-11-27 08:40
Sender: Johannes Schauer

The behaviour should be triggered for cross building - one of the other patches I submitted implements the ~cross argument when host<>build.

Your conclusion is correct. I assumed that implementing it would be very messy which is why I didnt attach a patch for this :)

But wookey also didnt yet run into any problems with the current dose behaviour when --defaultedMAforeign is set. So maybe you should wait for a complaint first?

It also strange that the assumption that all arch:all packages can satisfy foreign cross build dependencies on it seems to hold but on the other hand the assumption that all arch:all packages can also satisfy all other foreign dependencies on it does not seem to hold.

There is not (yet) much discussion in debian about this "feature" except for this bug report:


Date: 2012-11-26 18:09
Sender: Pietro Abate

Would be sufficient to enable this encoding on if the host option is set ? I guess in this case we can safely assume that the user is trying to cross build.

Or you are suggesting to have some kind of mixed encoding where a package
arch:all satisfy build (cross) dependencies as multi-arch foreign, but at the same time satisfy other dependency as multi-arch none ? This would be kind messy as a package arch all should behave differently w.r.t. the package that is using it to satisfy its dependencies...

Field Old Value Date By
assigned_tonone2012-11-26 16:13abate