]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
po: update XGETTEXT_OPTIONS
authorDmitry V. Levin <ldv@altlinux.org>
Sun, 21 Mar 2021 08:00:00 +0000 (08:00 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Mon, 26 Apr 2021 20:00:00 +0000 (20:00 +0000)
Recognize sgettext as a macro which is used for translations.

Flag _, N_, and sgettext with pass-c-format.  The effect of this
specification is that xgettext will propagate format string
requirements for _, N_, and sgettext calls to their first arguments,
and thus mark them as format strings.

Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
po/ChangeLog
po/Makevars

index 798db019554caa647a6f339abeb53f92c047d9c6..504393335049f3fc5d9b99864860c5f09e21705b 100644 (file)
@@ -1,3 +1,7 @@
+2021-03-21  Dmitry V. Levin  <ldv@altlinux.org>
+
+       * Makevars (XGETTEXT_OPTIONS): Update.
+
 2021-02-21  Piotr Drąg  <piotrdrag@gmail.com>
 
        * pl.po: Updated.
index 086de58871448bc2a9c04179277d73d5ad32f36b..692394ccc8718cc1527944da39f0278f7567dc14 100644 (file)
@@ -8,8 +8,15 @@ subdir = po
 top_builddir = ..
 
 # These options get passed to xgettext.
-XGETTEXT_OPTIONS = --keyword=_ --keyword=N_  --flag=error:3:c-format \
-                  --flag=ERROR:1:c-format --flag=argp_error:2:c-format \
+XGETTEXT_OPTIONS = --keyword=_ \
+                  --keyword=N_ \
+                  --keyword=sgettext:1g \
+                  --flag=_:1:pass-c-format \
+                  --flag=N_:1:pass-c-format \
+                  --flag=sgettext:1:pass-c-format \
+                  --flag=error:3:c-format \
+                  --flag=ERROR:1:c-format \
+                  --flag=argp_error:2:c-format \
                   --add-comments
 
 # This is the copyright holder that gets inserted into the header of the