Avoid calling update-initrd in lb_chroot_hacks if the target system has no initrd, thanks to Hector Oron <zumbi@debian.org>.

This commit is contained in:
Daniel Baumann 2012-03-07 18:12:26 +01:00
parent 98192da0b9
commit 8fa786ba89
1 changed files with 4 additions and 1 deletions
scripts/build

View File

@ -174,7 +174,10 @@ case "${LB_INITRAMFS}" in
;;
esac
Chroot chroot "${UPDATE_INITRAMFS_OPTIONS} update-initramfs -k all -t -u"
if [ "${LB_INITRAMFS}" != "none" ]
then
Chroot chroot "${UPDATE_INITRAMFS_OPTIONS} update-initramfs -k all -t -u"
fi
# We probably ought to use COMPRESS= in a temporary file in
# /etc/initramfs-tools/conf.d/ instead, but it's hard to pass options that