Makefile
changeset 9539 c904e76e3834
parent 9278 3d9f77c03105
child 10003 a1217735dffb
equal deleted inserted replaced
9538:f96ee862aba0 9539:c904e76e3834
    77 test-%:
    77 test-%:
    78 	cd tests && $(PYTHON) run-tests.py $(TESTFLAGS) $@
    78 	cd tests && $(PYTHON) run-tests.py $(TESTFLAGS) $@
    79 
    79 
    80 update-pot: i18n/hg.pot
    80 update-pot: i18n/hg.pot
    81 
    81 
    82 i18n/hg.pot: $(PYTHON_FILES)
    82 i18n/hg.pot: $(PYTHON_FILES) help/*.txt
    83 	$(PYTHON) i18n/hggettext mercurial/commands.py \
    83 	$(PYTHON) i18n/hggettext mercurial/commands.py \
    84 	  hgext/*.py hgext/*/__init__.py > i18n/hg.pot
    84 	  hgext/*.py hgext/*/__init__.py help/*.txt > i18n/hg.pot
    85         # All strings marked for translation in Mercurial contain
    85         # All strings marked for translation in Mercurial contain
    86         # ASCII characters only. But some files contain string
    86         # ASCII characters only. But some files contain string
    87         # literals like this '\037\213'. xgettext thinks it has to
    87         # literals like this '\037\213'. xgettext thinks it has to
    88         # parse them even though they are not marked for translation.
    88         # parse them even though they are not marked for translation.
    89         # Extracting with an explicit encoding of ISO-8859-1 will make
    89         # Extracting with an explicit encoding of ISO-8859-1 will make
    90         # xgettext "parse" and ignore them.
    90         # xgettext "parse" and ignore them.
    91 	echo $^ | xargs \
    91 	echo $(PYTHON_FILES) | xargs \
    92 	  xgettext --package-name "Mercurial" \
    92 	  xgettext --package-name "Mercurial" \
    93 	  --msgid-bugs-address "<mercurial-devel@selenic.com>" \
    93 	  --msgid-bugs-address "<mercurial-devel@selenic.com>" \
    94 	  --copyright-holder "Matt Mackall <mpm@selenic.com> and others" \
    94 	  --copyright-holder "Matt Mackall <mpm@selenic.com> and others" \
    95 	  --from-code ISO-8859-1 --join --sort-by-file \
    95 	  --from-code ISO-8859-1 --join --sort-by-file \
    96 	  -d hg -p i18n -o hg.pot
    96 	  -d hg -p i18n -o hg.pot