]> git.proxmox.com Git - grub2.git/commitdiff
Put recheck back
authorVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Sat, 24 Dec 2011 12:37:28 +0000 (13:37 +0100)
committerVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Sat, 24 Dec 2011 12:37:28 +0000 (13:37 +0100)
util/grub-install.in

index dd31a6caf6eea68f41cad2993860c91fddd6a817..e58ed9ab3a2b4c4bf179f14c970a182acc637384 100644 (file)
@@ -51,6 +51,7 @@ modules=
 install_device=
 no_floppy=
 force_lba=
+recheck=no
 debug=no
 debug_image=
 
@@ -106,6 +107,7 @@ Install GRUB on your drive.
   --no-floppy             do not probe any floppy drive
   --allow-floppy          Make the drive also bootable as floppy 
                           (default for fdX devices). May break on some BIOSes.
+  --recheck               delete device map if it already exists
   --force                 install even if problems are detected
 EOF
 if [ "${target_cpu}-${platform}" = "i386-pc" ] ; then
@@ -217,7 +219,7 @@ do
     --no-floppy)
        no_floppy="--no-floppy" ;;
     --recheck)
-           ;;
+       recheck=yes ;;
     --removable)
        removable=yes ;;
 
@@ -415,6 +417,11 @@ fi
 # Create the GRUB directory if it is not present.
 mkdir -p "$grubdir" || exit 1
 
+# If --recheck is specified, remove the device map, if present.
+if test $recheck = yes; then
+    rm -f "$device_map"
+fi
+
 # Create the device map file if it is not present.
 if test -f "$device_map"; then
     # Make sure that there is no duplicated entry.