Author: eelco
Date: Wed Jun 22 18:22:58 2011
New Revision: 27519
URL: https://svn.nixos.org/websvn/nix/?rev=27519&sc=1

Log:
* Canonicalize boot.loader.grub.device before calling grub-install to
  ensure that values such as /dev/disk/by-id/ata-WDC... work.

Modified:
   nixos/trunk/modules/system/activation/switch-to-configuration.sh

Modified: nixos/trunk/modules/system/activation/switch-to-configuration.sh
==============================================================================
--- nixos/trunk/modules/system/activation/switch-to-configuration.sh    Wed Jun 
22 17:57:32 2011        (r27518)
+++ nixos/trunk/modules/system/activation/switch-to-configuration.sh    Wed Jun 
22 18:22:58 2011        (r27519)
@@ -38,13 +38,13 @@
 
               if [ "$NIXOS_INSTALL_GRUB" = 1 -o "$oldGrubVersion" != 
"$newGrubVersion" ]; then
                   echo "installing the GRUB bootloader..."
-                  @grub@/sbin/grub-install "@grubDevice@" --no-floppy
+                  @grub@/sbin/grub-install "$(readlink -f "@grubDevice@")" 
--no-floppy
                   echo "$newGrubVersion" > /boot/grub/version
               fi
           fi
           
       else
-          echo "Warning: don't know how to make this configuration bootable; 
please set \`boot.grubDevice'." 1>&2
+          echo "Warning: don't know how to make this configuration bootable; 
please set \`boot.loader.grub.device'." 1>&2
       fi
       
     elif [ "@bootLoader@" = "generationsDir" ]; then
_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits

Reply via email to