diff options
author | Hans Ulrich Niedermann <hun@n-dimensional.de> | 2019-11-01 00:05:22 +0100 |
---|---|---|
committer | Hans Ulrich Niedermann <hun@n-dimensional.de> | 2020-01-20 06:23:50 +0100 |
commit | de98b151bce6b0aa70157d6c0ebb7f59b4da3792 (patch) | |
tree | 2ad88c62b4b2708f6236c91a9e12fcf84d51a3c6 | |
parent | 684fc9e83078c1f17e8932fa6718d9f791dfd7bc (diff) | |
download | libgphoto2-de98b151bce6b0aa70157d6c0ebb7f59b4da3792.tar.gz |
Convenience make targets for dealing with *.po files
Add convenience make targets for helping deal with *.po files:
git-checkout-po
Run "git checkout *.po" in all po/ subdirs.
This can be useful after "make dist".
update-po
Run "make update-po" in all po/ subdirs.
-rw-r--r-- | Makefile.am | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am index b33481468..9940e1021 100644 --- a/Makefile.am +++ b/Makefile.am @@ -80,6 +80,31 @@ install-camlibs: ######################################################################## +# Convenience shortcuts to update the *.po translation files in both +# po/ subdirs at once and to reset the *.po translation files to "git +# HEAD" in both po/ subdirs at once. + +PO_SUBDIRS = +PO_SUBDIRS += libgphoto2_port/po +PO_SUBDIRS += po + +# Run "git checkout *.po" in all po/ subdirs +# which is quite useful after "make dist" to clean up "git status". +.PHONY: git-checkout-po +git-checkout-po: + set -e; cd "$(top_srcdir)" && if test -d .git; then \ + for d in $(PO_SUBDIRS); do \ + (cd "$$d" && git checkout *.po); \ + done; \ + fi + +# Run "make update-po" in all po/ subdirs +.PHONY: update-po +update-po: + @for d in $(PO_SUBDIRS); do (cd "$$d" && $(MAKE) $(AM_MAKEFLAGS) update-po) || exit 1; done + + +######################################################################## # The following default options for aclocal and automake # are required in the top level Makefile.am for the automatic # re-building of the build system files. |