Bug#342616: initramfs-tools: MODULES=dep doesn't work
Package: initramfs-tools
Version: 0.42
Severity: important
Tags: patch
# mkinitramfs -o /boot/initrd.img-2.6.15-rc5-swsusp2-bs-jcd
# 2.6.15-rc5-swsusp2-bs-jcd
ln: creating symbolic link `/tmp/mkinitramfs_RfGT0L/./modprobe' to
`modprobe': File exists
[...]
ln: creating symbolic link `/tmp/mkinitramfs_RfGT0L/bin/true' to
`/usr/lib/klibc/bin/true': File exists
cpio: ./modprobe: Too many levels of symbolic links
It's due to 'modprobe --show-depends' printing not only insmod command
but also install ones :
# modprobe --set-version=2.6.15-rc5-swsusp2-bs-jcd --show-depends
pci:v00008086d000024C5sv0000152Dsd00000728bc04sc01i00
WARNING: Not loading blacklisted module i810_audio
insmod
/lib/modules/2.6.15-rc5-swsusp2-bs-jcd/kernel/sound/core/snd-page-alloc.ko
insmod /lib/modules/2.6.15-rc5-swsusp2-bs-jcd/kernel/sound/soundcore.ko
install modprobe --ignore-install snd && { modprobe --quiet snd-ioctl32
; : ; }
insmod
/lib/modules/2.6.15-rc5-swsusp2-bs-jcd/kernel/sound/core/snd-timer.ko
install modprobe --ignore-install snd-pcm && { modprobe --quiet
snd-pcm-oss ; : ; }
insmod
/lib/modules/2.6.15-rc5-swsusp2-bs-jcd/kernel/sound/pci/ac97/snd-ac97-bus.ko
insmod
/lib/modules/2.6.15-rc5-swsusp2-bs-jcd/kernel/sound/pci/ac97/snd-ac97-codec.ko
install modprobe --ignore-install snd-intel8x0 &&
/lib/alsa/modprobe-post-install snd-intel8x0
In manual_add_modules() :
for mam_x in $(modprobe --set-version="${version}"
--show-depends "${1}" 2>/dev/null | awk '{ print $2 }'); do
[...]
ln -s "${mam_x}" "${DESTDIR}/$(dirname "${mam_x}")"
With mam_x = modprobe there's a problem...
Quick fix :
--- /usr/share/initramfs-tools/hook-functions.old 2005-12-08 23:39:13.000000000 +0100
+++ /usr/share/initramfs-tools/hook-functions 2005-12-08 23:36:48.000000000 +0100
@@ -40,7 +40,7 @@
manual_add_modules()
{
- for mam_x in $(modprobe --set-version="${version}" --show-depends "${1}" 2>/dev/null | awk '{ print $2 }'); do
+ for mam_x in $(modprobe --set-version="${version}" --show-depends "${1}" 2>/dev/null | awk '/^insmod/ { print $2 }'); do
# Prune duplicates
if [ -e "${DESTDIR}/${mam_x}" ]; then
continue
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (900, 'unstable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15-rc2.jcd
Locale: LANG=fr_FR@euro, LC_CTYPE=fr_FR@euro (charmap=ISO-8859-15)
Versions of packages initramfs-tools depends on:
ii busybox 1:1.01-3 Tiny utilities for small and embed
ii cpio 2.6-9 GNU cpio -- a program to manage ar
ii klibc-utils 1.1.1-4 small statically-linked utilities
ii udev 0.076-5 /dev/ and hotplug management daemo
initramfs-tools recommends no packages.
-- no debconf information
--- /usr/share/initramfs-tools/hook-functions.old 2005-12-08 23:39:13.000000000 +0100
+++ /usr/share/initramfs-tools/hook-functions 2005-12-08 23:36:48.000000000 +0100
@@ -40,7 +40,7 @@
manual_add_modules()
{
- for mam_x in $(modprobe --set-version="${version}" --show-depends "${1}" 2>/dev/null | awk '{ print $2 }'); do
+ for mam_x in $(modprobe --set-version="${version}" --show-depends "${1}" 2>/dev/null | awk '/^insmod/ { print $2 }'); do
# Prune duplicates
if [ -e "${DESTDIR}/${mam_x}" ]; then
continue
Reply to: