diff options
author | Hans Ulrich Niedermann <hun@n-dimensional.de> | 2021-12-09 11:53:04 +0100 |
---|---|---|
committer | Hans Ulrich Niedermann <hun@n-dimensional.de> | 2021-12-12 16:35:47 +0100 |
commit | 397ae74674698122b4696ac897e70de439a2d0c9 (patch) | |
tree | ca9f94e23cc1d2970c6aeb4990d1fa99610f8c03 | |
parent | d18b440a72407fc371ec17a2a983976b813e5d97 (diff) | |
download | libgphoto2-397ae74674698122b4696ac897e70de439a2d0c9.tar.gz |
Add pull-translations target
Add pull-translations target to make it easier to pull translations
from the Translation Project:
make pull-translations
-rw-r--r-- | Makefile.am | 11 | ||||
-rw-r--r-- | RELEASE-HOWTO.md | 3 | ||||
-rw-r--r-- | configure.ac | 6 |
3 files changed, 19 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am index 322491115..5071f33e6 100644 --- a/Makefile.am +++ b/Makefile.am @@ -98,6 +98,17 @@ git-checkout-po: done; \ fi +.PHONY: pull-translations +if HAVE_RSYNC +pull-translations: + $(RSYNC) -Lrtvz translationproject.org::tp/latest/libgphoto2/ $(top_srcdir)/po + $(RSYNC) -Lrtvz translationproject.org::tp/latest/libgphoto2_port/ $(top_srcdir)/libgphoto2_port/po +else +pull-translations: + echo "Error: Cannot pull translations: Could not find rsync at configure time." + exit 1 +endif + # Run "make update-po" in all po/ subdirs .PHONY: update-po update-po: diff --git a/RELEASE-HOWTO.md b/RELEASE-HOWTO.md index 5fe5bcde9..5045a16ce 100644 --- a/RELEASE-HOWTO.md +++ b/RELEASE-HOWTO.md @@ -8,7 +8,8 @@ ## sync translations from translationproject - In the toplevel directory (of which `po/` is a subdirectory) + Run `make pull-translations` or manually run in the toplevel + directory (of which `po/` is a subdirectory) rsync -Lrtvz translationproject.org::tp/latest/libgphoto2/ po rsync -Lrtvz translationproject.org::tp/latest/libgphoto2_port/ libgphoto2_port/po diff --git a/configure.ac b/configure.ac index 3a613c892..974a2938a 100644 --- a/configure.ac +++ b/configure.ac @@ -122,6 +122,12 @@ dnl compile when included into C++ source files. AM_CONDITIONAL([HAVE_CXX], [test "x$CXX" != "x" && test "x$CXX" != "xno"]) +dnl Not strictly necessary, but helps pulling translations. +AC_ARG_VAR([RSYNC], [rsync file copying command]) +AC_PATH_PROG([RSYNC], [rsync], [no]) +AM_CONDITIONAL([HAVE_RSYNC], [test "x$RSYNC" != xno]) + + dnl -------------------------------------------------------------------- dnl Determine the most pedantic compiler flags we can find for both dnl C and C++, so that we can test that the libgphoto2 headers compile |