]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
po: Fix replacement of %m in sed programs
authorMike Gilbert <floppym@gentoo.org>
Mon, 2 Mar 2020 20:03:32 +0000 (15:03 -0500)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 10 Mar 2020 20:32:09 +0000 (21:32 +0100)
When running make dist, I hit this error:

  rm -f en@arabic.gmo && /usr/bin/gmsgfmt -c --statistics --verbose -o en@arabic.gmo en@arabic.po
  en@arabic.po:5312: 'msgstr' is not a valid C format string, unlike 'msgid'.
  Reason: The character that terminates the directive number 3 is not a valid conversion specifier.
  /usr/bin/gmsgfmt: found 1 fatal error

This was caused by "%m" being replaced with foreign Unicode characters.
For example:

  msgid "cannot rename the file %s to %s: %m"
  msgstr "ﺹﺎﻨﻧﻮﺗ ﺮﻌﻧﺎﻤﻋ ﺖﻬﻋ ﻒִﻴﻠﻋ %s ﺕﻭ %s: %ﻡ"

Mimic the workaround used for "%s" by reversing the replacement of "%m" at
the end of the sed programs.

Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
po/arabic.sed
po/cyrillic.sed
po/greek.sed
po/hebrew.sed

index b5b5db661205f84793e56ef6dec32543815ff428..21dc8b6db227c5c7e387c54301332c5b599e939d 100644 (file)
@@ -73,6 +73,7 @@ s,%\([0-9]*\)لد,%\1ld,g
 s,%\([0-9]*\)للد,%\1lld,g
 
 s,%\([0-9\.\*]*\)س,%\1s,g
+s,%\([0-9\.\*]*\)م,%\1m,g
 s,%\([0-9]*\)لو,%\1lu,g
 s,%\([0-9]*\)و,%\1u,g
 s,%\([0-9]*\)للو,%\1llu,g
index ffad0ed8c5131c147cb943c20e054cee3e977474..2e3e6655d6a4c6bc32cf347e838d031c753795ef 100644 (file)
@@ -96,6 +96,7 @@ s,%\([0-9]*\)лд,%\1ld,g
 s,%\([0-9]*\)ллд,%\1lld,g
 
 s,%\([0-9\.\*]*\)с,%\1s,g
+s,%\([0-9\.\*]*\)м,%\1m,g
 s,%\([0-9]*\)лу,%\1lu,g
 s,%\([0-9]*\)у,%\1u,g
 s,%\([0-9]*\)ллу,%\1llu,g
index 93556c38650436cc298329c8ea879ebd44da0b9c..3543f6aac36b7704d4a1699790a6524d90f24abc 100644 (file)
@@ -98,6 +98,7 @@ s,%\([0-9]*\)λδ,%\1ld,g
 s,%\([0-9]*\)λλδ,%\1lld,g
 
 s,%\([0-9\.\*]*\)σ,%\1s,g
+s,%\([0-9\.\*]*\)μ,%\1m,g
 s,%\([0-9]*\)λυ,%\1lu,g
 s,%\([0-9]*\)υ,%\1u,g
 s,%\([0-9]*\)λλυ,%\1llu,g
index a47bc6a281bdd6bf34301e62a0ae6d3a4934935b..9210014bc3b059bfb1b06bcb20891d311789f96d 100644 (file)
@@ -81,6 +81,7 @@ s,%\([0-9]*\)לד,%\1ld,g
 s,%\([0-9]*\)ללד,%\1lld,g
 
 s,%\([0-9\.\*]*\)ש,%\1s,g
+s,%\([0-9\.\*]*\)מ,%\1m,g
 s,%\([0-9]*\)לוּ,%\1lu,g
 s,%\([0-9]*\)וּ,%\1u,g
 s,%\([0-9]*\)ללוּ,%\1llu,g