apt chooses wrong architecture if sources.list contains arch-qualified entries

Bug #1032250 reported by Wookey
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
New
Undecided
Unassigned

Bug Description

If both armel and armhf are given as arch qualifiers in sources.list, then apt tries to install the wrong architecture package:

I ask directly for an amrhf package and apt tries (but fails) to install an armel one:

$ sudo apt-get install zlib1g-dev:armhf
...
The following packages have unmet dependencies:
 zlib1g-dev:armel : Depends: zlib1g:armel (= 1:1.2.7.dfsg-13) but it is not going to be installed
                    Depends: libc6-dev:armel but it is not going to be installed or
                             libc-dev:armel

Sources.list looks like this:
deb [arch=amd64,i386] http://archive.ubuntu.com/ubuntu quantal main universe
deb [arch=armhf,armel] http://ports.ubuntu.com/ubuntu-ports quantal main universe
deb-src http://archive.ubuntu.com/ubuntu quantal main universe

There are no :armel or :armhf packages installed.

The ordering of the arch qualifiers in sources.list does not matter: this line produces the same output
deb [arch=armel,armhf] http://ports.ubuntu.com/ubuntu-ports quantal main universe

change the line to
deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports quantal main universe
and it works as expected.

The apt sources info seems to be overriding the dpkg foreign-architecture info.

Tags: multiarch
Revision history for this message
David Kalnischkies (donkult) wrote :

Smells like: http://anonscm.debian.org/loggerhead/apt/debian-sid/revision/2237
Am I right? This is in apt >= 0.9.7.2 in debian (wheezy) if you wanna test.

You haven't mentioned a version number, but i guess you are on the "newest" in ubuntu which is 0.9.7.1something.
The diff probably does not apply to apt <= 0.9.7 through as the code was moved. I am not sure, but i guess it doesn't effect earlier versions (at least on in the commandline parsing, the architecture wildcards in build-depends are a "problem" non-the-less).

Revision history for this message
Wookey (wookey) wrote :

This bug does not seem to be present in apt 0.9.7.3 in debian unstable. There it works as expected.
Similarly for apt 0.9.7.1 in debian testing. So this wqould appear to be something in the ubuntu patches.

Revision history for this message
Wookey (wookey) wrote :

sorry ubuntu version tested was 0.9.7.1ubuntu1

Revision history for this message
Wookey (wookey) wrote :

This issue is not present in precise (apt 0.8.16~exp12ubuntu10)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.