summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--subsurface-install.pri13
1 files changed, 12 insertions, 1 deletions
diff --git a/subsurface-install.pri b/subsurface-install.pri
index c244520f5..3389dd104 100644
--- a/subsurface-install.pri
+++ b/subsurface-install.pri
@@ -3,7 +3,14 @@ xslt.files = $$XSLT_FILES
icons.files = $$ICONS_FILES
doc.files = $$DOC_FILES
translation.files = $$replace(TRANSLATIONS, .ts, .qm)
-qttranslation.files = $$join(QTTRANSLATIONS," "$$[QT_INSTALL_TRANSLATIONS]/,$$[QT_INSTALL_TRANSLATIONS]/)
+exists($$[QT_INSTALL_TRANSLATIONS]) {
+ qt_translation_dir = $$[QT_INSTALL_TRANSLATIONS]/
+} else: exists(/usr/share/qt4/translations) {
+ # On some cross-compilation environments, the translations are either missing or not
+ # where they're expected to be. In such cases, try copying from the system.
+ qt_translation_dir = /usr/share/qt4/translations
+}
+qttranslation.files = $$join(QTTRANSLATIONS," "$$qt_translation_dir/,$$qt_translation_dir/)
nltab = $$escape_expand(\\n\\t)
@@ -54,6 +61,10 @@ mac {
marbledir.path = $$WINDOWSSTAGING/data
INSTALLS += deploy marbledir target
+ translation.path = $$WINDOWSSTAGING/translations
+ qttranslation.path = $$WINDOWSSTAGING/translations
+ INSTALLS += translation qttranslation
+
qt_conf.commands = echo \'[Paths]\' > $@
qt_conf.commands += $${nltab}echo \'Prefix=.\' >> $@
qt_conf.target = $$PWD/packaging/windows/qt.conf