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

Bug#380351: new patch (includes fix for /etc/kernel-img.conf)



Hi!

Please use this new patch instead.  It includes fix for update-grub entries in
/etc/kernel-img.conf as well.

As of 10.051, kernel-package now supports relative paths in kernel-img.conf.

-- 
Robert Millan

My spam trap is honeypot@aybabtu.com.  Note: this address is only intended for
spam harvesters.  Writing to it will get you added to my black list.
diff -ur grub-installer-1.17.old/grub-installer grub-installer-1.17/grub-installer
--- grub-installer-1.17.old/grub-installer	2006-06-06 00:53:14.000000000 +0200
+++ grub-installer-1.17/grub-installer	2006-08-06 09:13:40.000000000 +0200
@@ -173,7 +173,7 @@
 
 # Run update-grub in $ROOT.
 update_grub () {
-	if ! log-output -t grub-installer $chroot $ROOT /sbin/update-grub -y ; then
+	if ! log-output -t grub-installer $chroot $ROOT update-grub -y ; then
 		error "Running 'update-grub -y' failed." 1>&2
 		db_input critical grub-installer/update-grub-failed || [ $? -eq 30 ]
 		db_go || true
@@ -338,7 +338,7 @@
 update_mtab
 
 if ! is_floppy "$bootdev"; then
-	if $chroot $ROOT /sbin/grub-install -h 2>&1 | grep -q no-floppy; then
+	if $chroot $ROOT grub-install -h 2>&1 | grep -q no-floppy; then
 		info "grub-install supports --no-floppy"
 		floppyparam="--no-floppy"
 	else
@@ -346,8 +346,8 @@
 	fi
 fi
 
-info "Running $chroot $ROOT /sbin/grub-install --recheck $floppyparam \"$bootdev\""
-if log-output -t grub-installer $chroot $ROOT /sbin/grub-install --recheck $floppyparam "$bootdev"; then
+info "Running $chroot $ROOT grub-install --recheck $floppyparam \"$bootdev\""
+if log-output -t grub-installer $chroot $ROOT grub-install --recheck $floppyparam "$bootdev"; then
 	info "grub-install ran successfully"
 else
 	error "Running 'grub-install --recheck $floppyparam \"$bootdev\"' failed."
@@ -554,8 +554,8 @@
 sed -e 's/do_bootloader = yes/do_bootloader = no/' < $ROOT/etc/kernel-img.conf > $ROOT/etc/kernel-img.conf.$$
 if [ -z "`grep update-grub $ROOT/etc/kernel-img.conf.$$`" ]; then
 	(
-		echo "postinst_hook = /sbin/update-grub"
-		echo "postrm_hook   = /sbin/update-grub"
+		echo "postinst_hook = update-grub"
+		echo "postrm_hook   = update-grub"
 	) >> $ROOT/etc/kernel-img.conf.$$
 fi
 mv $ROOT/etc/kernel-img.conf.$$ $ROOT/etc/kernel-img.conf
diff -ur grub-installer-1.17.old/rescue.d/80grub-reinstall grub-installer-1.17/rescue.d/80grub-reinstall
--- grub-installer-1.17.old/rescue.d/80grub-reinstall	2006-01-17 00:04:04.000000000 +0100
+++ grub-installer-1.17/rescue.d/80grub-reinstall	2006-08-06 09:13:18.000000000 +0200
@@ -30,12 +30,12 @@
 update_mtab
 
 if ! is_floppy "$bootdev"; then
-	if chroot /target /sbin/grub-install -h 2>&1 | grep -q no-floppy; then
+	if chroot /target grub-install -h 2>&1 | grep -q no-floppy; then
 		floppyparam="--no-floppy"
 	fi
 fi
 
-if ! log-output -t grub-installer chroot /target /sbin/grub-install --recheck $floppyparam "$bootdev"; then
+if ! log-output -t grub-installer chroot /target grub-install --recheck $floppyparam "$bootdev"; then
 	db_subst grub-installer/grub-install-failed BOOTDEV "$bootdev"
 	db_input critical grub-installer/grub-install-failed BOOTDEV "$bootdev"
 	db_go || true

Reply to: