[Simple-cdd-devel] Bug#632331: .udebs or .packages files which are empty or all commented out cause install to fail

Enrico Zini enrico at debian.org
Fri Jul 1 14:03:20 UTC 2011


Package: simple-cdd
Version: 0.3.14
Severity: minor

Hello,

I commented out all udebs from my .udebs file and got a big red screen
saying: "loading simple-cdd-profiles failed for unknown reasons.
Aborting".

Investigating the issue I traced it down to simple-cdd-profiles'
postinst:

  [...]
  set -e
  [...]
        echo "Queuing udebs for profile: $p"
        wanted_packages="$(egrep -v ^# $p.udebs)"
	anna-install $wanted_packages || true
  [...]
        echo "Queuing packages for profile: $p"
        wanted_packages="$(egrep -v ^# $p.packages)"
  [...]

Egrep exits with 1 in case no lines are found, and since it's running
under set -e, this terminates the script.

A possible fix is to switch to sed instead of grep:

	wanted_packages="$(sed -n '/^[^#]/p')"
	test -z "$wanted_packages" || anna-install $wanted_packages || true

Ciao,

Enrico

-- System Information:
Debian Release: wheezy/sid
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'testing')
Architecture: amd64 (x86_64)

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

Versions of packages simple-cdd depends on:
ii  apt-utils                     0.8.14.1   APT utility programs
ii  dctrl-tools                   2.18       Command-line tools to process Debi
ii  debian-cd                     3.1.6      Tools for building (Official) Debi
ii  debootstrap                   1.0.32     Bootstrap a basic Debian system
ii  lsb-release                   3.2-27     Linux Standard Base version report
ii  python                        2.6.6-14   interactive high-level object-orie
ii  reprepro                      4.6.0-1    Debian package repository producer
ii  rsync                         3.0.8-1    fast remote file copy program (lik
ii  wget                          1.12-3.1   retrieves files from the web

Versions of packages simple-cdd recommends:
ii  edos-debcheck                1.0-9       Check package dependencies (transi
ii  edos-distcheck [edos-debchec 1.4.2-12+b1 Checks whether dependencies of pac

Versions of packages simple-cdd suggests:
ii  qemu-kvm                   0.14.1+dfsg-1 Full virtualization on x86 hardwar

-- no debconf information





More information about the Simple-cdd-devel mailing list