From bbce3403531c1fd527a4ef00521e278f45d10279 Mon Sep 17 00:00:00 2001 From: Tvangeste Date: Sun, 21 Jul 2013 10:45:21 +0200 Subject: [PATCH] Fix localization files' installation on Linux/MacOS --- goldendict.pro | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/goldendict.pro b/goldendict.pro index df472511..b37f4bd7 100644 --- a/goldendict.pro +++ b/goldendict.pro @@ -431,6 +431,14 @@ win32 { win32:# Windows doesn't seem to have *-qt4 symlinks isEmpty(QMAKE_LRELEASE):QMAKE_LRELEASE = $$[QT_INSTALL_BINS]/lrelease isEmpty(QMAKE_LRELEASE):QMAKE_LRELEASE = $$[QT_INSTALL_BINS]/lrelease-qt4 + +# The *.qm files might not exist when qmake is run for the first time, +# causing the standard install rule to be ignored, and no translations +# will be installed. With this, we create the qm files during qmake run. +!win32 { + system($${QMAKE_LRELEASE} -silent $${_PRO_FILE_} 2> /dev/null) +} + updateqm.input = TRANSLATIONS updateqm.output = locale/${QMAKE_FILE_BASE}.qm updateqm.commands = $$QMAKE_LRELEASE \