summaryrefslogtreecommitdiff
path: root/sys-boot/grub/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-07-10 04:26:23 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-07-10 04:26:23 +0100
commit9e8f96c1b33dc01bc5dfbed0cfb2702bb299f1e0 (patch)
tree935774930075230b45a40e5c8da1e0199bf277a5 /sys-boot/grub/files
parent796e724b5ace96ff70d918765662edf62f1d8c85 (diff)
gentoo auto-resync : 10:07:2023 - 04:26:23
Diffstat (limited to 'sys-boot/grub/files')
-rw-r--r--sys-boot/grub/files/grub-2.06-locale.patch68
1 files changed, 68 insertions, 0 deletions
diff --git a/sys-boot/grub/files/grub-2.06-locale.patch b/sys-boot/grub/files/grub-2.06-locale.patch
new file mode 100644
index 000000000000..14706cbca3a2
--- /dev/null
+++ b/sys-boot/grub/files/grub-2.06-locale.patch
@@ -0,0 +1,68 @@
+From 5983c2c6adf1c1bbb3ecd751253d1e898bdfd8a3 Mon Sep 17 00:00:00 2001
+From: Michael Chang <mchang@suse.com>
+Date: Tue, 26 Oct 2021 15:11:00 +0800
+Subject: templates: Filter out POSIX locale for translation
+
+The POSIX locale is default or native operating system's locale
+identical to the C locale, so no translation to human speaking languages
+are provided. For this reason we should filter out LANG=POSIX as well as
+LANG=C upon generating grub.cfg to avoid looking up for it's gettext's
+message catalogs that will consequently result in an unpleasant message:
+
+ error: file `/boot/grub/locale/POSIX.gmo' not found
+
+Signed-off-by: Michael Chang <mchang@suse.com>
+Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
+---
+ util/grub.d/00_header.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/util/grub.d/00_header.in b/util/grub.d/00_header.in
+index 93a9023..f74c2a4 100644
+--- a/util/grub.d/00_header.in
++++ b/util/grub.d/00_header.in
+@@ -191,7 +191,7 @@ EOF
+ EOF
+
+ # Gettext variables and module
+-if [ "x${LANG}" != "xC" ] && [ "x${LANG}" != "x" ]; then
++if [ "x${LANG}" != "xC" ] && [ "x${LANG}" != "xPOSIX" ] && [ "x${LANG}" != "x" ]; then
+ cat << EOF
+ set locale_dir=\$prefix/locale
+ set lang=${grub_lang}
+--
+cgit v1.1
+
+From f42266a8a2a4215e4ffe419b8092bdf9ced33e8e Mon Sep 17 00:00:00 2001
+From: Christian Hesse <mail@eworm.de>
+Date: Mon, 19 Sep 2022 15:31:28 +0200
+Subject: templates: Filter C.UTF-8 locale for translation
+
+In addition to C locale there is also C.UTF-8 locale now. Filter that as
+well, by using ${grub_lang}, which contains a stripped value.
+This fixes the following message and resulting boot failure:
+
+ error: file `/boot/grub/locale/C.gmo' not found.
+
+Signed-off-by: Christian Hesse <mail@eworm.de>
+Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
+---
+ util/grub.d/00_header.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/util/grub.d/00_header.in b/util/grub.d/00_header.in
+index f74c2a4..6a316a5 100644
+--- a/util/grub.d/00_header.in
++++ b/util/grub.d/00_header.in
+@@ -191,7 +191,7 @@ EOF
+ EOF
+
+ # Gettext variables and module
+-if [ "x${LANG}" != "xC" ] && [ "x${LANG}" != "xPOSIX" ] && [ "x${LANG}" != "x" ]; then
++if [ "x${grub_lang}" != "xC" ] && [ "x${LANG}" != "xPOSIX" ] && [ "x${LANG}" != "x" ]; then
+ cat << EOF
+ set locale_dir=\$prefix/locale
+ set lang=${grub_lang}
+--
+cgit v1.1
+