Hello,

I have a small patch for boottool.  I took a look at the grub
source, in fact, to see exactly why the "default" command was
getting ignored.  With this fix boottool should now generate arguments
that are parsable by the current version of grub.

Please take a look at the patch and let me know if it looks reasonable.

Author: Ryan Stutsman <stutsman@google.com>
Date:   Thu Jun 21 12:11:25 2007 -0700

   Fixed boottool's grub support to fix the way it sets the default param

   Boottool was setting the default builtin in grub to some value plus
   and "comment" at the end of the line.  Grub does not support inline
   comments; it only supports comments that start with a pound at the
   beginning of the line.  This was causing the default value to be
   ignored when it was set to "saved" which is used for one-time booting.

-Ryan


Index: client/tools/boottool
===================================================================
--- client/tools/boottool	(revision 538)
+++ client/tools/boottool	(working copy)
@@ -233,7 +233,7 @@
 
     foreach my $index ( 0 .. $#config ) {
         if ( $config[$index] =~ /(^\s*default\s*\=*\s*)\d+/i ) {
-            $config[$index] = "$1$newdefault	# set by $0\n";
+            $config[$index] = "# set by $0\n$1$newdefault\n";
             last;
         }
         elsif ( $config[$index] =~ /^\s*default\s*\=*\s*saved/i ) {
