Skip to contentSkip to conversation

templates: filter C.UTF-8 locale for translation

PATCH In review Christian Hesse 2 participants 2 messages Sep 19, 2022 – Sep 22, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 templates: filter C.UTF-8 locale for translation

From: Christian Hesse <[email protected]>

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.

---
 util/grub.d/00_header.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
util/grub.d/00_header.in +1 -1
index f74c2a4c6..6a316a5ba 100644
@@ -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}
Signature · 1 line
2.37.3