SHA256
1
0
forked from pool/grub2

Accepting request 147213 from Base:System

- add support for chainloading another UEFI bootloader to
  30_os-prober (bnc#775610) (forwarded request 147192 from arvidjaar)

OBS-URL: https://build.opensuse.org/request/show/147213
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/grub2?expand=0&rev=53
This commit is contained in:
Stephan Kulow 2013-01-07 14:17:20 +00:00 committed by Git OBS Bridge
parent 7127299ebe
commit 65ab51d514
3 changed files with 44 additions and 0 deletions

View File

@ -0,0 +1,36 @@
From: Andrey Borzenkov <arvidjaar@gmail.com>
Date: Fri Jan 4 09:46:56 UTC 2013
Subject: properly quote translated strings in grub.cfg
References: bnc#775610
Patch-Mainline: no
Add support for chainloading another bootloader on UEFI systems.
This requires additional os-prober support to be actually useful.
Index: grub-2.00/util/grub.d/30_os-prober.in
===================================================================
--- grub-2.00.orig/util/grub.d/30_os-prober.in
+++ grub-2.00/util/grub.d/30_os-prober.in
@@ -144,6 +144,22 @@ EOF
}
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)
LINUXPROBED="`linux-boot-prober ${DEVICE} 2> /dev/null | tr ' ' '^' | paste -s -d ' '`"
prepare_boot_cache=

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Fri Jan 4 10:29:58 UTC 2013 - arvidjaar@gmail.com
- add support for chainloading another UEFI bootloader to
30_os-prober (bnc#775610)
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Nov 26 08:26:10 UTC 2012 - mchang@suse.com Mon Nov 26 08:26:10 UTC 2012 - mchang@suse.com

View File

@ -131,6 +131,7 @@ Patch21: grub2-secureboot-add-linuxefi.patch
Patch22: grub2-secureboot-use-linuxefi-on-uefi.patch Patch22: grub2-secureboot-use-linuxefi-on-uefi.patch
Patch23: grub2-secureboot-no-insmod-on-sb.patch Patch23: grub2-secureboot-no-insmod-on-sb.patch
Patch24: grub2-secureboot-provide-linuxefi-config.patch Patch24: grub2-secureboot-provide-linuxefi-config.patch
Patch25: 30_os-prober_UEFI_support.patch
PreReq: perl-Bootloader PreReq: perl-Bootloader
Requires: gettext-runtime Requires: gettext-runtime
%if 0%{?suse_version} >= 1140 %if 0%{?suse_version} >= 1140
@ -242,6 +243,7 @@ mv docs/grub.texi docs/grub2.texi
%patch22 -p1 %patch22 -p1
%patch23 -p1 %patch23 -p1
%patch24 -p1 %patch24 -p1
%patch25 -p1
cd .. cd ..
# README.openSUSE # README.openSUSE