[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#595264: assumes libdevmapper1.02.1 (optional in Squeeze) is installed; breaks update-initramfs

Package: live-boot-initramfs-tools
Version: 2.0.1-1
Severity: important
File: /usr/share/initramfs-tools/hooks/live

When installing live-boot and a kernel into a pretty minimalist
bootstrap chroot, update-initramfs fails with

    cp: cannot stat `/lib/libdevmapper*': No such file or directory

This is because live-boot currently assumes libdevmapper1.02.1 is
installed, instead of checking for it.

This was a reasonable assumption in Lenny, but in Squeeze its priority
is downgraded:

    $ curl -s http://cdn.debian.net/debian/dists/stable/main/binary-amd64/Packages.bz2 |
      bzcat | grep-dctrl -PsPriority libdevmapper1.02.1
    > Priority: required
    $ curl -s http://cdn.debian.net/debian/dists/testing/main/binary-amd64/Packages.bz2 |
      bzcat | grep-dctrl -PsPriority libdevmapper1.02.1
    > Priority: optional

A simple patch along these lines should suffice (untested):

    diff -ud /usr/share/initramfs-tools/hooks/live /tmp/buffer-content-1839QrW
    --- /usr/share/initramfs-tools/hooks/live	2010-09-02 02:27:57.000000000 +1000
    +++ /tmp/buffer-content-1839QrW	2010-09-03 01:35:15.115969801 +1000
    @@ -61,7 +61,7 @@
     # klibc dependencies
     for FILE in /lib/libacl* /lib/libblkid* /lib/libuuid* /lib/libdevmapper* /lib/libattr*
    -	if [ ! -e "${DESTDIR}"/"${FILE}" ]
    +	if [ -e "$FILE" -a ! -e "${DESTDIR}"/"${FILE}" ]
                    cp -a "${FILE}" "${DESTDIR}"/"${FILE}"

    Diff finished.  Fri Sep  3 01:35:15 2010

A temporary workaround is simply to run "touch t/lib/libdevmapper*"
prior to installing live-boot into the bootstrap environment t/, which
results in an useless but harmless literal "libdevmapper*" file being
copied into the ramdisk.

PS: I'm surprised that live-boot needs to pull in klibc dependencies
at all -- I'd have thought either klibc or initramfs-tools would've
handled that automagically elsewhere.  Go figure.

-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.35 (SMP w/2 CPU cores)
Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages live-boot-initramfs-tools depends on:
ii  busybox                       1:1.17.1-4 Tiny utilities for small and embed
ii  initramfs-tools               0.98.1     tools for generating an initramfs
ii  udev                          161-1      /dev/ and hotplug management daemo

live-boot-initramfs-tools recommends no packages.

live-boot-initramfs-tools suggests no packages.

-- no debconf information

Reply to: