Bug#774685: chdist: even if --arch is given, apt will download Packages files for all architectures

Johannes Schauer j.schauer at email.de
Tue Jan 6 08:45:37 UTC 2015


Package: devscripts
Version: 2.14.11
Severity: normal
Tags: patch

Hi,

steps to reproduce:

$ dpkg --add-architecture armhf
$ chdist --arch=amd64 create sid-amd64 http://ftp.de.debian.org/debian sid main
$ chdist --arch=amd64 apt-get sid-amd64 update
$ ls ~/.chdist/sid-amd64/var/lib/apt/lists/*armhf*
/home/josch/.chdist/sid-amd64/var/lib/apt/lists/ftp.de.debian.org_debian_dists_sid_main_binary-armhf_Packages

so even though I passed the --arch=amd64 argument, apt will download for
another architecture as well (armhf in this case which was enabled as a
foreign arch on the host chdist was running on).

This might be an apt bug because one might argue that apt should respect
the architecture given as Apt::Architectures and not ask dpkg for more.

But since the fix is simple, I'm attaching it.

Until this is applied, a workaround is to run chdist like this:

$ chdist --arch=amd64 create sid-amd64 "[arch=amd64]" http://ftp.de.debian.org/debian sid main

which happens to work because of how chdist treats its arguments for the
create subcommand (it just concatenates them with a space).

Thanks!

cheers, josch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-chdist-if-arch-is-given-make-sure-only-that-arch-is-.patch
Type: text/x-diff
Size: 827 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/devscripts-devel/attachments/20150106/c89a6070/attachment.patch>


More information about the devscripts-devel mailing list