summaryrefslogtreecommitdiffstats
path: root/po/Makefile
diff options
context:
space:
mode:
authorLukas Fleischer <archlinux@cryptocrack.de>2014-07-27 21:54:38 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2014-07-27 21:54:38 +0200
commit35e6388fad2226d00a3c82fc63f63373f1c84fad (patch)
tree9e5b5244803b80a2b4999478e62b25a6cc81285f /po/Makefile
parent9862e533d88e1a63b407b51d1af192169e2366ab (diff)
downloadaurweb-35e6388fad2226d00a3c82fc63f63373f1c84fad.tar.xz
Auto-generate po/POTFILES
Reduce maintenance costs by auto-generating po/POTFILES in the Makefile. Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'po/Makefile')
-rw-r--r--po/Makefile7
1 files changed, 5 insertions, 2 deletions
diff --git a/po/Makefile b/po/Makefile
index 97e1822..49eab32 100644
--- a/po/Makefile
+++ b/po/Makefile
@@ -44,7 +44,10 @@ all: ${MOFILES}
lang=`echo $@ | sed -e 's/\.po-update$$//'`; \
msgmerge -U --no-location --lang="$$lang" $< aur.pot
-update-pot:
+POTFILES:
+ find ../web -type f -name '*.php' -printf '%P\n' | sort >POTFILES
+
+update-pot: POTFILES
pkgname=AUR; \
pkgver=`sed -n 's/.*"AUR_VERSION", "\(.*\)".*/\1/p' ../web/lib/version.inc.php`; \
xgettext --default-domain=aur -L php --keyword=__ --keyword=_n:1,2 \
@@ -57,7 +60,7 @@ update-po:
${MAKE} ${UPDATEPOFILES}
clean:
- rm -f *.mo *.po\~
+ rm -f *.mo *.po\~ POTFILES
install: all
for l in ${LOCALES}; do mkdir -p ${DESTDIR}${PREFIX}/$$l/LC_MESSAGES/; done