]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
merge with mainline
authorBVK Chaitanya <bvk.groups@gmail.com>
Thu, 22 Jul 2010 21:14:22 +0000 (02:44 +0530)
committerBVK Chaitanya <bvk.groups@gmail.com>
Thu, 22 Jul 2010 21:14:22 +0000 (02:44 +0530)
1  2 
conf/common.rmk
include/grub/script_sh.h
script/function.c
script/parser.y
tests/grub_script_expansion.in
util/grub-script-check.c

diff --cc conf/common.rmk
index 1b71644aefb46d5cc80814850913ca08bd452ddf,f92e5bc4c7051a3393be4ddf1e78a8540f77763d..24d7921f5bf7cced41abd3e06f303b8bb72f6c6e
@@@ -637,19 -628,18 +628,18 @@@ keystatus_mod_CFLAGS = $(COMMON_CFLAGS
  keystatus_mod_LDFLAGS = $(COMMON_LDFLAGS)
  
  # For normal.mod.
+ ifneq (, $(FONT_SOURCE))
+ normal/charset.c_DEPENDENCIES = widthspec.h
+ endif
  normal_mod_SOURCES = normal/main.c normal/cmdline.c normal/dyncmd.c \
-       normal/auth.c normal/autofs.c normal/handler.c \
+       normal/auth.c normal/autofs.c  \
        normal/color.c normal/completion.c normal/datetime.c normal/menu.c \
-       normal/menu_entry.c normal/menu_text.c \
-       normal/misc.c normal/crypto.c normal/term.c normal/context.c
- normal_mod_CFLAGS = $(COMMON_CFLAGS)
- normal_mod_LDFLAGS = $(COMMON_LDFLAGS)
- # For sh.mod.
- sh_mod_SOURCES = script/main.c script/script.c script/argv.c script/execute.c \
+       normal/menu_entry.c normal/menu_text.c normal/charset.c \
+       normal/misc.c normal/crypto.c normal/term.c normal/context.c \
 -      script/main.c script/script.c script/execute.c unidata.c \
++      script/main.c script/script.c script/execute.c script/argv.c unidata.c \
        script/function.c script/lexer.c grub_script.tab.c grub_script.yy.c
- sh_mod_CFLAGS = $(COMMON_CFLAGS) $(POSIX_CFLAGS) $(GNULIB_CFLAGS) -Wno-error
- sh_mod_LDFLAGS = $(COMMON_LDFLAGS)
 -normal_mod_CFLAGS = $(COMMON_CFLAGS) $(POSIX_CFLAGS) -Wno-error
++normal_mod_CFLAGS = $(COMMON_CFLAGS) $(POSIX_CFLAGS) $(GNULIB_CFLAGS) -Wno-error
+ normal_mod_LDFLAGS = $(COMMON_LDFLAGS)
  
  ifneq (, $(FONT_SOURCE))
  font/font.c_DEPENDENCIES = ascii.h
index 7721edd961eb7130e25e87539f3d9313ec3db09a,7d6129243043fb22a4c91509f3354fab009cbeca..50c21bd88ca396d92d86baf1cc1c5277fce83b55
@@@ -345,9 -344,8 +350,8 @@@ grub_script_function_t grub_script_func
                                                    struct grub_script *cmd);
  void grub_script_function_remove (const char *name);
  grub_script_function_t grub_script_function_find (char *functionname);
- int grub_script_function_iterate (int (*iterate) (grub_script_function_t));
 -int grub_script_function_call (grub_script_function_t func,
 -                             int argc, char **args);
 +grub_err_t grub_script_function_call (grub_script_function_t func,
 +                                    int argc, char **args);
  
  char **
  grub_script_execute_arglist_to_argv (struct grub_script_arglist *arglist, int *count);
index 82c753bcd83b3d3db591586cd2926cddd4378534,810c652338deddd19fae613749da675a8e8ff14e..47b236652af8541a5542bb554c72e1b728f40d77
@@@ -103,15 -103,12 +103,3 @@@ grub_script_function_find (char *functi
  
    return func;
  }
--
--int
- grub_script_function_iterate (int (*iterate) (grub_script_function_t))
 -grub_script_function_call (grub_script_function_t func,
 -                         int argc __attribute__((unused)),
 -                         char **args __attribute__((unused)))
--{
-   grub_script_function_t func;
-   for (func = grub_script_function_list; func; func = func->next)
-     if (iterate (func))
-       return 1;
-   return 0;
 -  /* XXX: Arguments are not supported yet.  */
 -  return grub_script_execute (func->func);
--}
diff --cc script/parser.y
Simple merge
index 80f0a6afaf97bb0c203cff92c5ec6c4e99516a6b,0000000000000000000000000000000000000000..1ec58e3a9fca787ef3b693a262a7f48919ecff79
mode 100644,000000..100644
--- /dev/null
@@@ -1,35 -1,0 +1,35 @@@
- other=`echo echo '*' | @builddir@/grub-shell`
 +#! /bin/bash -e
 +
 +# Run GRUB script in a Qemu instance
 +# Copyright (C) 2010  Free Software Foundation, Inc.
 +#
 +# GRUB is free software: you can redistribute it and/or modify
 +# it under the terms of the GNU General Public License as published by
 +# the Free Software Foundation, either version 3 of the License, or
 +# (at your option) any later version.
 +#
 +# GRUB is distributed in the hope that it will be useful,
 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 +# GNU General Public License for more details.
 +#
 +# You should have received a copy of the GNU General Public License
 +# along with GRUB.  If not, see <http://www.gnu.org/licenses/>.
 +
 +disks=`echo ls | @builddir@/grub-shell`
++other=`echo echo \\* | @builddir@/grub-shell`
 +for d in $disks; do
 +  if ! echo "$other" | grep "$d" >/dev/null; then
 +    echo "$d missing from * expansion" >&2
 +    exit 1
 +  fi
 +done
 +
 +other=`echo echo '(*)' | @builddir@/grub-shell`
 +for d in $disks; do
 +  if ! echo "$other" | grep "$d" >/dev/null; then
 +    echo "$d missing from (*) expansion" >&2
 +    exit 1
 +  fi
 +done
 +
Simple merge