From: Michael Prokop Date: Fri, 3 Nov 2006 22:55:42 +0000 (+0100) Subject: improve initramfs generation code X-Git-Tag: 0.2~18 X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=commitdiff_plain;h=4afd25452f048a5a4e0608ec7b2f3dbbbe12da0f improve initramfs generation code --- diff --git a/chroot-script b/chroot-script index ea845d1..e6c95a7 100644 --- a/chroot-script +++ b/chroot-script @@ -134,13 +134,13 @@ KERNELVER=${KERNELIMG#/boot/vmlinuz-} if [ -n "$INITRD" ] ; then if [ "$RELEASE" = 'sarge' ] ; then echo "Release sarge detected, will not create an initrd." - return 0 - fi - echo "Generating initrd." - update-initramfs -c -t -k $KERNELVER - if [ -f "/boot/initrd.img-$KERNELVER" ] ; then - GRUBINITRD="initrd /boot/initrd.img-$KERNELVER" - LILOINITRD=" initrd=/boot/initrd.img-$KERNELVER" + else + echo "Generating initrd." + update-initramfs -c -t -k $KERNELVER + if [ -f "/boot/initrd.img-$KERNELVER" ] ; then + GRUBINITRD="initrd /boot/initrd.img-$KERNELVER" + LILOINITRD=" initrd=/boot/initrd.img-$KERNELVER" + fi fi fi