texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[no subject]


From: Patrice Dumas
Date: Tue, 1 Oct 2024 16:38:27 -0400 (EDT)

branch: master
commit 43b9d5dcd3dcadcff47488ee3a3eb03dbeab821d
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Sun Jul 28 15:10:37 2024 +0200

    * po/Makevars (XGETTEXT_OPTIONS): add pass-perl-format flag for __p.
    
    * Makefile.am (po-check): add missing keywords.  Add an exception for
    copy-file_but_owner.c false positive where _() are commented out.
---
 ChangeLog   | 7 +++++++
 Makefile.am | 9 +++++++--
 po/Makevars | 3 ++-
 3 files changed, 16 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index f9153ba29e..9d08d97153 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2024-07-28  Patrice Dumas  <pertusus@free.fr>
+
+       * po/Makevars (XGETTEXT_OPTIONS): add pass-perl-format flag for __p.
+
+       * Makefile.am (po-check): add missing keywords.  Add an exception for
+       copy-file_but_owner.c false positive where _() are commented out.
+
 2024-07-28  Patrice Dumas  <pertusus@free.fr>
 
        * po/Makevars (XGETTEXT_OPTIONS): add c-format flag for
diff --git a/Makefile.am b/Makefile.am
index 2fe7f9ae27..92c8b456c2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -101,6 +101,10 @@ update-po:
 # Verify that all source files using _() are listed in po/POTFILES.in.
 # Run this before making pretests, as well as official releases, so that
 # translators will see changed strings.  See README-hacking.
+# Note that pgettext is not matched to avoid a false positive in
+# tp/Texinfo/Translations.pm, but it is not problematic as it appears
+# only in errors.c, which matches other function names.
+# copy-file_but_owner.c is a false positive as _() are commented out.
 po-check:
        @if test -f po/POTFILES.in; then                                \
          grep -E -v '^(#|$$)' po/POTFILES.in                           \
@@ -116,12 +120,13 @@ po-check:
              texinfo-*/*) continue;;                                   \
               tp/maintain/* ) continue;;                               \
               tp/t/results* ) continue;;                               \
-             tp/Texinfo/XS/gnulib/lib/*) continue;;                            
        \
+             tp/Texinfo/XS/copy-file_but_owner.c) continue;;           \
+             tp/Texinfo/XS/gnulib/lib/*) continue;;                    \
            esac;                                                       \
            files="$$files $$file";                                     \
          done;                                                         \
          grep -E -l                                                    \
-           
'\b(N?__?p?|gettext|line_error|line_error_ext|line_warn|command_error|command_warn|message_list_document_warn|message_list_document_error|message_list_command_warn|message_list_command_error)
 *\([^)"]*("|$$)'    \
+           
'\b(N?__?p?|ngettext|line_error|line_error_ext|line_warn|command_error|command_warn|message_list_document_warn|message_list_document_error|p?message_list_command_warn|message_list_command_error|message_list_line_error_ext)
 *\([^)"]*("|$$)'     \
            $$files | sort -u > $@-2;                                   \
          diff -u $@-1 $@-2 || exit 1;                                  \
          rm -f $@-1 $@-2;                                              \
diff --git a/po/Makevars b/po/Makevars
index 20da2dd4a2..ff0a4d4253 100644
--- a/po/Makevars
+++ b/po/Makevars
@@ -61,7 +61,8 @@ XGETTEXT_OPTIONS = \
  --flag=_command_warn:2:perl-format\
  --flag=line_error:1:perl-format\
  --flag=line_warn:1:perl-format\
- --flag=__:1:pass-perl-format
+ --flag=__:1:pass-perl-format\
+ --flag=__p:2:pass-perl-format
 
 # This is the copyright holder that gets inserted into the header of the
 # $(DOMAIN).pot file.  Set this to the copyright holder of the surrounding



reply via email to

[Prev in Thread] Current Thread [Next in Thread]