Thread (5 messages) flat view 5 messages, 1 author, 2016-06-15
DORMANTno replies

[PATCH 2/3] Makefile: provide a --msgid-bugs-address to xgettext(1)

From: Ævar Arnfjörð Bjarmason <hidden>
Date: 2016-06-15 22:49:24
Subsystem: kernel build + files below scripts/ (unless maintained elsewhere), the rest · Maintainers: Nathan Chancellor, Nicolas Schier, Linus Torvalds

Change the invocations of xgettext to use the --msgid-bugs-address
option. This has the effect of adding a Report-Msgid-Bugs-To header to
the git.pot and the derived *.po files. Doing so is recommended by the
gettext manual.

If this isn't added the Report-Msgid-Bugs-To already in po/is.po will
be removed by msgmerge(1).

Signed-off-by: Ævar Arnfjörð Bjarmason <redacted>
---
 Makefile |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index 62d526a..155b69b 100644
--- a/Makefile
+++ b/Makefile
@@ -2008,10 +2008,11 @@ cscope:
 	$(RM) cscope*
 	$(FIND) . -name '*.[hcS]' -print | xargs cscope -b
 
+POT_BUGS = Git Mailing List <git@vger.kernel.org>
 pot:
-	$(XGETTEXT) --add-comments --keyword=_ --keyword=N_ --output=po/git.pot --language=C $(C_OBJ:o=c) t/t0200/test.c
-	$(XGETTEXT) --add-comments --join-existing --output=po/git.pot --language=Shell $(SCRIPT_SH) t/t0200/test.sh
-	$(XGETTEXT) --add-comments --join-existing --keyword=__ --output=po/git.pot --language=Perl $(SCRIPT_PERL) t/t0200/test.perl
+	$(XGETTEXT) --msgid-bugs-address="$(POT_BUGS)" --add-comments --keyword=_ --keyword=N_ --output=po/git.pot --language=C $(C_OBJ:o=c) t/t0200/test.c
+	$(XGETTEXT) --msgid-bugs-address="$(POT_BUGS)" --add-comments --join-existing --output=po/git.pot --language=Shell $(SCRIPT_SH) t/t0200/test.sh
+	$(XGETTEXT) --msgid-bugs-address="$(POT_BUGS)" --add-comments --join-existing --keyword=__ --output=po/git.pot --language=Perl $(SCRIPT_PERL) t/t0200/test.perl
 
 POFILES := $(wildcard po/*.po)
 MOFILES := $(patsubst po/%.po,share/locale/%/LC_MESSAGES/git.mo,$(POFILES))
-- 
1.7.2.2.513.g82b8
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help