diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2013-10-10 12:39:01 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-10-10 14:52:56 -0700 |
commit | e3e47b34a101dfefeea67e6b4ed2ede308bfdf72 (patch) | |
tree | 096d130f278ffe7ac859e8f7870ed42e46b640d3 /subsurface-install.pri | |
parent | f5423c48b8cbc6998fbb22663e6f75cdea1ff8e1 (diff) | |
download | subsurface-e3e47b34a101dfefeea67e6b4ed2ede308bfdf72.tar.gz |
Automatically build translations
This runs lrelease against the .ts files and automatically recreates the .qm
files if any of the .ts files changes.
This also moves the .ts files into the translations directory.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-install.pri')
-rw-r--r-- | subsurface-install.pri | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/subsurface-install.pri b/subsurface-install.pri index b630b605c..ec208328c 100644 --- a/subsurface-install.pri +++ b/subsurface-install.pri @@ -113,4 +113,18 @@ XSLTDIR = $(DATADIR)/subsurface INSTALLS += target desktop icon manpage xslt doc marbledir install.target = install } +!isEmpty(TRANSLATIONS) { + isEmpty(QMAKE_LRELEASE) { + win32: QMAKE_LRELEASE = $$[QT_INSTALL_BINS]\lrelease.exe + else: QMAKE_LRELEASE = $$[QT_INSTALL_BINS]/lrelease + } + isEmpty(TS_DIR):TS_DIR = translations + TSQM.target = .translations + TSQM.name = lrelease subsurface.pro + TSQM.depends = $$TRANSLATIONS + TSQM.output = $$TS_DIR/${QMAKE_FILE_BASE}.qm + TSQM.commands = $$QMAKE_LRELEASE subsurface.pro && echo "OK" > .translations + QMAKE_EXTRA_TARGETS += TSQM + PRE_TARGETDEPS += .translations +} QMAKE_EXTRA_TARGETS += install $$install.depends |