From ceb549235df16f54d4ec6ef2a6c7c50ade751884 Mon Sep 17 00:00:00 2001 From: maximilian attems Date: Tue, 21 Apr 2009 14:50:27 +0200 Subject: update-initramfs: Don't hardcode path for lilo or elilo. elilo seems to be installed in /usr/sbin/ and thus wasn't run. (closes: #524928) Reported-by: dann frazier Signed-off-by: maximilian attems --- update-initramfs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/update-initramfs b/update-initramfs index 90a7eda..29941f3 100755 --- a/update-initramfs +++ b/update-initramfs @@ -237,7 +237,7 @@ run_bootloader() # if both lilo and grub around, figure out if lilo needs to be run if ( command -v update-grub >/dev/null 2>&1 \ || [ -e /boot/grub/menu.lst ] || [ -e /boot/grub/grub.cfg ] ) \ - && ( [ -e /etc/lilo.conf ] && [ -x /sbin/lilo ] ); then + && ( [ -e /etc/lilo.conf ] && command -v lilo >/dev/null 2>&1 ); then [ -r "${KPKGCONF}" ] && \ do_b=$(awk '/^do_bootloader/{print $3}' "${KPKGCONF}") if [ "${do_b}" = "yes" ] || [ "${do_b}" = "Yes" ] \ @@ -253,11 +253,11 @@ run_bootloader() mbr_check return 0 fi - if [ -r /etc/lilo.conf ] && [ -x /sbin/lilo ]; then + if [ -r /etc/lilo.conf ] && command -v lilo >/dev/null 2>&1; then run_lilo return 0 fi - if [ -x /sbin/elilo ]; then + if command -v elilo >/dev/null 2>&1; then elilo return 0 fi -- cgit v1.2.3