Merge mainline into arm
This commit is contained in:
commit
ae27e4d323
111 changed files with 5383 additions and 3002 deletions
|
@ -350,7 +350,9 @@ if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = "i386-pc" ] || [ "$
|
|||
if test -f "$1"; then
|
||||
:
|
||||
else
|
||||
echo "$1: Not found." 1>&2
|
||||
# TRANSLATORS: This message is shown when required executable `%s'
|
||||
# isn't found
|
||||
gettext_printf "%s: Not found.\n" "$1" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
@ -359,7 +361,9 @@ set "$grub_mkimage" dummy
|
|||
if test -f "$1"; then
|
||||
:
|
||||
else
|
||||
echo "$1: Not found." 1>&2
|
||||
# TRANSLATORS: This message is shown when required executable `%s'
|
||||
# isn't found
|
||||
gettext_printf "%s: Not found.\n" "$1" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
@ -703,14 +707,18 @@ elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = "i386-ieee1275" ]
|
|||
if test -f "$1"; then
|
||||
:
|
||||
else
|
||||
echo "$1: Not found." 1>&2
|
||||
# TRANSLATORS: This message is shown when required executable `%s'
|
||||
# isn't found
|
||||
gettext_printf "%s: Not found.\n" "$1" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
set "$nvsetenv" dummy
|
||||
if test -f "$1"; then
|
||||
:
|
||||
else
|
||||
echo "$1: Not found." 1>&2
|
||||
# TRANSLATORS: This message is shown when required executable `%s'
|
||||
# isn't found
|
||||
gettext_printf "%s: Not found.\n" "$1" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" != "powerpc-ieee1275" ] \
|
||||
|
|
|
@ -784,24 +784,38 @@ write_font_ascii_bitmap (struct grub_font_info *font_info, char *output_file)
|
|||
grub_util_error (_("cannot write to `%s': %s"), output_file,
|
||||
strerror (errno));
|
||||
|
||||
int correct_size;
|
||||
for (glyph = font_info->glyphs_sorted, num = 0; num < font_info->num_glyphs;
|
||||
glyph++, num++)
|
||||
{
|
||||
correct_size = 1;
|
||||
if (glyph->width != 8 || glyph->height != 16)
|
||||
{
|
||||
/* printf ("Width or height from glyph U+%04x not supported, skipping.\n", glyph->char_code); */
|
||||
correct_size = 0;
|
||||
}
|
||||
int row;
|
||||
for (row = 0; row < glyph->height; row++)
|
||||
{
|
||||
if (correct_size)
|
||||
fwrite (&glyph->bitmap[row], sizeof(glyph->bitmap[row]), 1, file);
|
||||
else
|
||||
fwrite (&correct_size, 1, 1, file);
|
||||
}
|
||||
if (glyph->width == 8 && glyph->height == 16
|
||||
&& glyph->x_ofs == 0 && glyph->y_ofs == 0)
|
||||
fwrite (glyph->bitmap, 16, 1, file);
|
||||
else
|
||||
{
|
||||
grub_uint8_t glph[16];
|
||||
int p = 0, mask = 0x80;
|
||||
int row, col;
|
||||
int dy = 12 - glyph->height - glyph->y_ofs;
|
||||
for (row = 0; row < 16; row++)
|
||||
glph[row] = 0;
|
||||
for (row = 0; row < glyph->height; row++)
|
||||
for (col = 0; col < glyph->width; col++)
|
||||
{
|
||||
int val = glyph->bitmap[p] & mask;
|
||||
mask >>= 1;
|
||||
if (mask == 0)
|
||||
{
|
||||
mask = 0x80;
|
||||
p++;
|
||||
}
|
||||
if (val && dy + row >= 0
|
||||
&& dy + row < 16
|
||||
&& glyph->x_ofs + col >= 0
|
||||
&& glyph->x_ofs + col < 8)
|
||||
glph[dy + row] |= 1 << (7 - (glyph->x_ofs + col));
|
||||
}
|
||||
fwrite (glph, 16, 1, file);
|
||||
}
|
||||
}
|
||||
fclose (file);
|
||||
}
|
||||
|
|
|
@ -1450,15 +1450,16 @@ generate_image (const char *dir, const char *prefix,
|
|||
/* fwstart.img is the only part which can't be tested by using *-elf
|
||||
target. Check it against the checksum. */
|
||||
const grub_uint8_t yeeloong_fwstart_good_hash[512 / 8] =
|
||||
{
|
||||
0x11, 0x7f, 0xfd, 0x7e, 0xd9, 0xbb, 0x82, 0xe7,
|
||||
0x5f, 0xcc, 0xbf, 0x09, 0x1d, 0xfe, 0xfa, 0xd5,
|
||||
0x97, 0xfb, 0xbb, 0xd8, 0x76, 0x4b, 0xfc, 0x0a,
|
||||
0x4e, 0x3c, 0x91, 0x06, 0x98, 0xa0, 0xe0, 0xda,
|
||||
0x4f, 0x74, 0x17, 0x6f, 0x95, 0xd2, 0xec, 0x1b,
|
||||
0x7f, 0x12, 0x80, 0x23, 0xcb, 0xa0, 0x2d, 0x59,
|
||||
0x15, 0x82, 0x70, 0x3d, 0x23, 0xbf, 0xee, 0x93,
|
||||
0x5e, 0x5c, 0xbd, 0x1c, 0x51, 0x0b, 0x0b, 0x45 };
|
||||
{
|
||||
0x5f, 0x67, 0x46, 0x57, 0x31, 0x30, 0xc5, 0x0a,
|
||||
0xe9, 0x98, 0x18, 0xc9, 0xf3, 0xca, 0x45, 0xa5,
|
||||
0x75, 0x64, 0x6b, 0xbb, 0x24, 0xcd, 0xb4, 0xbc,
|
||||
0xf2, 0x3e, 0x23, 0xf9, 0xc2, 0x6a, 0x8c, 0xde,
|
||||
0x3b, 0x94, 0x9c, 0xcc, 0xa5, 0xa7, 0x58, 0xb1,
|
||||
0xbe, 0x8b, 0x3d, 0x73, 0x98, 0x18, 0x7e, 0x68,
|
||||
0x5e, 0x5f, 0x23, 0x7d, 0x7a, 0xe8, 0x51, 0xf7,
|
||||
0x1a, 0xaf, 0x2f, 0x54, 0x11, 0x2e, 0x5c, 0x25
|
||||
};
|
||||
const grub_uint8_t fuloong2f_fwstart_good_hash[512 / 8] =
|
||||
{
|
||||
0x76, 0x9b, 0xad, 0x6e, 0xa2, 0x39, 0x47, 0x62,
|
||||
|
|
|
@ -37,7 +37,6 @@ itanium_dir="${libdir}/@PACKAGE@/ia64-efi"
|
|||
# Print the usage.
|
||||
usage () {
|
||||
gettext_printf "Usage: %s [OPTION]\n" "$self"
|
||||
gettext; echo "Install GRUB on your drive."; echo
|
||||
echo
|
||||
print_option_help "-h, --help" "$(gettext "print this message and exit")"
|
||||
grub_print_install_files_help
|
||||
|
|
|
@ -51,7 +51,11 @@ usage () {
|
|||
dirmsg="$(gettext_printf "expect GRUB images under the directory DIR/%s instead of the %s directory" "@grubdirname@" "$grubdir")"
|
||||
print_option_help "--boot-directory=$(gettext "DIR")" "$dirmsg"
|
||||
echo
|
||||
gettext "MENU_ENTRY is a number, a menu item title or a menu item identifier."; echo
|
||||
gettext "MENU_ENTRY is a number, a menu item title or a menu item identifier. Please note that menu items in
|
||||
submenus or sub-submenus require specifying the submenu components and then the
|
||||
menu item component. The titles should be separated using the greater-than
|
||||
character (>) with no extra spaces. Depending on your shell some characters including > may need escpaing. More information about this is available
|
||||
in the GRUB Manual in the section about the 'default' command. "; echo
|
||||
echo
|
||||
gettext "Report bugs to <bug-grub@gnu.org>."; echo
|
||||
}
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <grub/term.h>
|
||||
#include <grub/font.h>
|
||||
#include <grub/gfxmenu_view.h>
|
||||
#include <grub/color.h>
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
|
||||
|
|
|
@ -143,7 +143,7 @@ main (int argc, char *argv[])
|
|||
.file = 0
|
||||
};
|
||||
char *input;
|
||||
int found_input = 0;
|
||||
int found_input = 0, found_cmd = 0;
|
||||
struct grub_script *script = NULL;
|
||||
|
||||
set_program_name (argv[0]);
|
||||
|
@ -188,6 +188,8 @@ main (int argc, char *argv[])
|
|||
script = grub_script_parse (input, get_config_line, &ctx);
|
||||
if (script)
|
||||
{
|
||||
if (script->cmd)
|
||||
found_cmd = 1;
|
||||
grub_script_execute (script);
|
||||
grub_script_free (script);
|
||||
}
|
||||
|
@ -202,6 +204,12 @@ main (int argc, char *argv[])
|
|||
fprintf (stderr, _("Syntax error at line %u\n"), ctx.lineno);
|
||||
return 1;
|
||||
}
|
||||
if (! found_cmd)
|
||||
{
|
||||
fprintf (stderr, _("Script contains no commands and will do nothing\n"),
|
||||
ctx.arguments.filename);
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -147,6 +147,22 @@ EOF
|
|||
cat <<EOF
|
||||
chainloader +1
|
||||
}
|
||||
EOF
|
||||
;;
|
||||
efi)
|
||||
|
||||
EFIPATH=${DEVICE#*@}
|
||||
DEVICE=${DEVICE%@*}
|
||||
onstr="$(gettext_printf "(on %s)" "${DEVICE}")"
|
||||
cat << EOF
|
||||
menuentry '$(echo "${LONGNAME} $onstr" | grub_quote)' --class windows --class os \$menuentry_id_option 'osprober-efi-$(grub_get_device_id "${DEVICE}")' {
|
||||
EOF
|
||||
save_default_entry | sed -e "s/^/\t/"
|
||||
prepare_grub_to_access_device ${DEVICE} | sed -e "s/^/\t/"
|
||||
|
||||
cat <<EOF
|
||||
chainloader ${EFIPATH}
|
||||
}
|
||||
EOF
|
||||
;;
|
||||
linux)
|
||||
|
|
|
@ -473,7 +473,17 @@ for cipher_file in cipher_files:
|
|||
cryptolist.close ()
|
||||
|
||||
for src in sorted (os.listdir (os.path.join (indir, "src"))):
|
||||
if src == "versioninfo.rc.in":
|
||||
if src == "versioninfo.rc.in" or src == "ath.c" or src == "ChangeLog-2011" \
|
||||
or src == "dumpsexp.c" or src == "fips.c" or src == "gcrypt.h.in" \
|
||||
or src == "gcryptrnd.c"or src == "getrandom.c" \
|
||||
or src == "global.c" or src == "hmac256.c" \
|
||||
or src == "hwfeatures.c" or src == "libgcrypt-config.in" \
|
||||
or src == "libgcrypt.def" or src == "libgcrypt.m4" \
|
||||
or src == "libgcrypt.vers" or src == "Makefile.am" \
|
||||
or src == "Manifest" or src == "misc.c" \
|
||||
or src == "missing-string.c" or src == "module.c" \
|
||||
or src == "secmem.c" or src == "sexp.c" \
|
||||
or src == "stdmem.c" or src == "visibility.c":
|
||||
continue
|
||||
outfile = os.path.join (basedir, "src", src)
|
||||
infile = os.path.join (indir, "src", src)
|
||||
|
@ -499,6 +509,10 @@ for src in sorted (os.listdir (os.path.join (indir, "src"))):
|
|||
fw.close ()
|
||||
|
||||
for src in sorted (os.listdir (os.path.join (indir, "mpi"))):
|
||||
if src == "config.links" or src == "ChangeLog-2011" \
|
||||
or src == "mpi-scan.c" or src == "Manifest" \
|
||||
or src == "Makefile.am":
|
||||
continue
|
||||
infile = os.path.join (indir, "mpi", src)
|
||||
outfile = os.path.join (basedir, "mpi", src)
|
||||
if os.path.isdir (infile):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue