Debian Bug report logs - #703995
apt-setup: preseeding apt-setup/multiarch breaks dpkg

version graph

Package: apt-setup; Maintainer for apt-setup is Debian Install System Team <debian-boot@lists.debian.org>;

Reported by: Raphaël Hertzog <hertzog@debian.org>

Date: Tue, 26 Mar 2013 15:51:01 UTC

Severity: important

Tags: patch

Found in version 0.77

Fixed in version apt-setup/1:0.79

Done: Cyril Brulebois <kibi@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, cjwatson@debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#703995; Package apt-setup. (Tue, 26 Mar 2013 15:51:06 GMT) Full text and rfc822 format available.

Acknowledgement sent to Raphaël Hertzog <hertzog@debian.org>:
New Bug report received and forwarded. Copy sent to cjwatson@debian.org, Debian Install System Team <debian-boot@lists.debian.org>. (Tue, 26 Mar 2013 15:51:06 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Raphaël Hertzog <hertzog@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: apt-setup: preseeding apt-setup/multiarch breaks dpkg
Date: Tue, 26 Mar 2013 16:46:09 +0100
Package: apt-setup
Version: 0.77
Severity: normal
Tags: patch

I wanted to try out preseeding apt-setup/multiarch to i386 but before
doing it, I reviewed apt-setup's handling of this option and I discovered
that it actually creates the configuration file used by the early Ubuntu
implementation of multiarch (which relied on the --foreign-architecture
command line option instead of the single dpkg --add-architecture call).
This means that it actually breaks dpkg since the current version of dpkg
doesn't underestand the --foreign-architecture command-line option.

Here's an untested patch:

--- a/generators/01setup
+++ b/generators/01setup
@@ -17,8 +17,7 @@ fi
 
 db_get apt-setup/multiarch
 if [ "$RET" ]; then
-       mkdir -p $ROOT/etc/dpkg/dpkg.cfg.d
        for arch in $RET; do
-               echo "foreign-architecture $arch"
-       done >$ROOT/etc/dpkg/dpkg.cfg.d/multiarch
+               chroot $ROOT dpkg --add-architecture $arch
+       done
 fi

IMO it would be nice to have this fixed in wheezy but it's not required
either.

Cheers,

-- System Information:
Debian Release: 7.0
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.7-trunk-amd64 (SMP w/4 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#703995; Package apt-setup. (Sat, 06 Apr 2013 18:09:06 GMT) Full text and rfc822 format available.

Acknowledgement sent to Cyril Brulebois <kibi@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Sat, 06 Apr 2013 18:09:06 GMT) Full text and rfc822 format available.

Message #10 received at 703995@bugs.debian.org (full text, mbox):

From: Cyril Brulebois <kibi@debian.org>
To: Raphaël Hertzog <hertzog@debian.org>, 703995@bugs.debian.org
Subject: Re: Bug#703995: apt-setup: preseeding apt-setup/multiarch breaks dpkg
Date: Sat, 6 Apr 2013 20:07:56 +0200
[Message part 1 (text/plain, inline)]
Control: severity -1 important
Control: tag -1 pending

Raphaël Hertzog <hertzog@debian.org> (26/03/2013):
> I wanted to try out preseeding apt-setup/multiarch to i386 but
> before doing it, I reviewed apt-setup's handling of this option and
> I discovered that it actually creates the configuration file used by
> the early Ubuntu implementation of multiarch (which relied on the
> --foreign-architecture command line option instead of the single
> dpkg --add-architecture call).  This means that it actually breaks
> dpkg since the current version of dpkg doesn't underestand the
> --foreign-architecture command-line option.
> 
> IMO it would be nice to have this fixed in wheezy but it's not
> required either.

Yeah, generating non-working/crufty things, even if that's only doable
through preseeding, looks unnice (especially with such a tiny patch to
fix it). Adjusting severity accordingly.

> Here's an untested patch:
> 
> --- a/generators/01setup
> +++ b/generators/01setup
> @@ -17,8 +17,7 @@ fi
>  
>  db_get apt-setup/multiarch
>  if [ "$RET" ]; then
> -       mkdir -p $ROOT/etc/dpkg/dpkg.cfg.d
>         for arch in $RET; do
> -               echo "foreign-architecture $arch"
> -       done >$ROOT/etc/dpkg/dpkg.cfg.d/multiarch
> +               chroot $ROOT dpkg --add-architecture $arch
> +       done
>  fi

I just tested it, and that looks like it does the job. Tests:
  apt-setup/multiarch=i386
  apt-setup/multiarch="i386 armel"

Failed with this one, but due to *:powerpc package dependencies:
  apt-setup/multiarch="i386 powerpc"

Uploading in a moment, should be in rc2.

Thanks.

Mraw,
KiBi.
[signature.asc (application/pgp-signature, inline)]

Severity set to 'important' from 'normal' Request was from Cyril Brulebois <kibi@debian.org> to 703995-submit@bugs.debian.org. (Sat, 06 Apr 2013 18:09:07 GMT) Full text and rfc822 format available.

Added tag(s) pending. Request was from Cyril Brulebois <kibi@debian.org> to 703995-submit@bugs.debian.org. (Sat, 06 Apr 2013 18:09:07 GMT) Full text and rfc822 format available.

Reply sent to Cyril Brulebois <kibi@debian.org>:
You have taken responsibility. (Sat, 06 Apr 2013 18:45:28 GMT) Full text and rfc822 format available.

Notification sent to Raphaël Hertzog <hertzog@debian.org>:
Bug acknowledged by developer. (Sat, 06 Apr 2013 18:45:28 GMT) Full text and rfc822 format available.

Message #19 received at 703995-close@bugs.debian.org (full text, mbox):

From: Cyril Brulebois <kibi@debian.org>
To: 703995-close@bugs.debian.org
Subject: Bug#703995: fixed in apt-setup 1:0.79
Date: Sat, 06 Apr 2013 18:32:35 +0000
Source: apt-setup
Source-Version: 1:0.79

We believe that the bug you reported is fixed in the latest version of
apt-setup, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 703995@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Cyril Brulebois <kibi@debian.org> (supplier of updated apt-setup package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Sat, 06 Apr 2013 20:11:42 +0200
Source: apt-setup
Binary: apt-setup-udeb apt-mirror-setup apt-cdrom-setup
Architecture: source all
Version: 1:0.79
Distribution: unstable
Urgency: low
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Changed-By: Cyril Brulebois <kibi@debian.org>
Description: 
 apt-cdrom-setup - set up a CD in sources.list (udeb)
 apt-mirror-setup - set up a mirror in sources.list (udeb)
 apt-setup-udeb - Configure apt (udeb)
Closes: 703995
Changes: 
 apt-setup (1:0.79) unstable; urgency=low
 .
   * Fix support for apt-setup/multiarch preseed option: call “dpkg
     --add-architecture $arch" for each architecture, instead of
     generating dpkg.cfg (used by early multiarch implementations);
     thanks, Raphaël Hertzog! (Closes: #703995)
Checksums-Sha1: 
 6395edd3f7e888af989d827d52fa7418c465eb77 1098 apt-setup_0.79.dsc
 16f727dd37b55d1eb0abb8f92cb50a36b15c3089 299711 apt-setup_0.79.tar.gz
 4a0537e3bd5ca7aef3effcae68a31e414bb24681 65490 apt-setup-udeb_0.79_all.udeb
 dd7c86ad9940d9a2df8105961df75298d57dd0bc 72908 apt-mirror-setup_0.79_all.udeb
 610494562d3b67153c680acab3cdbdd47f72846f 95580 apt-cdrom-setup_0.79_all.udeb
Checksums-Sha256: 
 4fd3decae5ceb67fda19ce9108f400f8365687185676016c32f84a92400f740f 1098 apt-setup_0.79.dsc
 34b7359f4870994cc559c9fbc1c75ab845be04d65b5454b8c90073d114d4a33a 299711 apt-setup_0.79.tar.gz
 ee382c0a76e961b86c494331ee7068313d0b285beb4d2ac61988870da3e681f1 65490 apt-setup-udeb_0.79_all.udeb
 3eb44779efeee8d85c9eaa2fb33712bc6b3b84952871bcb76cccaf35eb8ff37b 72908 apt-mirror-setup_0.79_all.udeb
 71a7f7facde9214881cef8de59ecdacf6a18eb8f92bb0b29ba29d3b633dff58c 95580 apt-cdrom-setup_0.79_all.udeb
Files: 
 9652d5c8e8625893a36193418bf26490 1098 debian-installer extra apt-setup_0.79.dsc
 27c57a6cb65e9b2a73fcdac2758871b5 299711 debian-installer extra apt-setup_0.79.tar.gz
 fc6345a2cf236fca15a9ea6ce71c1fea 65490 debian-installer standard apt-setup-udeb_0.79_all.udeb
 92571335cd60ace877835d0309a1c447 72908 debian-installer extra apt-mirror-setup_0.79_all.udeb
 cd36bf128b7f56955f66387a5d0c009b 95580 debian-installer extra apt-cdrom-setup_0.79_all.udeb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlFgZ68ACgkQeGfVPHR5Nd1U4ACgpf6/g+Uswv1c0SmRMluCLPYN
R90AnjYVjRCj50/bWUjDGxSYzV3swgb4
=O97x
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Mon, 06 May 2013 07:33:12 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Mon Apr 21 08:02:28 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.