summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-06-09 15:08:44 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-06-11 13:52:41 (GMT)
commit5717e44d47bf5f6be59a59844223ce71b094b08e (patch)
tree6fa8406ee04bf7b3808e1747b9437bb88e5073a2
parentdfb61e59f0a1c2113cc01c99c3fd052efa2b6c8e (diff)
downloadQt-5717e44d47bf5f6be59a59844223ce71b094b08e.zip
Qt-5717e44d47bf5f6be59a59844223ce71b094b08e.tar.gz
Qt-5717e44d47bf5f6be59a59844223ce71b094b08e.tar.bz2
turn qm generation into a build time target
consequently, remove the qm files from the repository this uses some really black magic to convince qmake to do the right thing. this will be fixed properly in a later version. Reviewed-by: mariusSO
-rw-r--r--projects.pro5
-rw-r--r--translations/assistant_adp_de.qmbin23139 -> 0 bytes
-rw-r--r--translations/assistant_adp_ja.qmbin18357 -> 0 bytes
-rw-r--r--translations/assistant_adp_pl.qmbin22726 -> 0 bytes
-rw-r--r--translations/assistant_adp_zh_CN.qmbin16631 -> 0 bytes
-rw-r--r--translations/assistant_adp_zh_TW.qmbin16555 -> 0 bytes
-rw-r--r--translations/assistant_de.qmbin18688 -> 0 bytes
-rw-r--r--translations/assistant_pl.qmbin18457 -> 0 bytes
-rw-r--r--translations/assistant_zh_CN.qmbin15595 -> 0 bytes
-rw-r--r--translations/assistant_zh_TW.qmbin15567 -> 0 bytes
-rw-r--r--translations/designer_de.qmbin151189 -> 0 bytes
-rw-r--r--translations/designer_ja.qmbin105573 -> 0 bytes
-rw-r--r--translations/designer_pl.qmbin150544 -> 0 bytes
-rw-r--r--translations/designer_zh_CN.qmbin113745 -> 0 bytes
-rw-r--r--translations/designer_zh_TW.qmbin113449 -> 0 bytes
-rw-r--r--translations/linguist_de.qmbin45915 -> 0 bytes
-rw-r--r--translations/linguist_ja.qmbin30494 -> 0 bytes
-rw-r--r--translations/linguist_pl.qmbin50952 -> 0 bytes
-rw-r--r--translations/linguist_zh_CN.qmbin33492 -> 0 bytes
-rw-r--r--translations/linguist_zh_TW.qmbin33735 -> 0 bytes
-rw-r--r--translations/qt_ar.qmbin58499 -> 0 bytes
-rw-r--r--translations/qt_de.qmbin181348 -> 0 bytes
-rw-r--r--translations/qt_es.qmbin117693 -> 0 bytes
-rw-r--r--translations/qt_fr.qmbin148544 -> 0 bytes
-rw-r--r--translations/qt_help_de.qmbin9583 -> 0 bytes
-rw-r--r--translations/qt_help_pl.qmbin9058 -> 0 bytes
-rw-r--r--translations/qt_help_zh_CN.qmbin6434 -> 0 bytes
-rw-r--r--translations/qt_help_zh_TW.qmbin6384 -> 0 bytes
-rw-r--r--translations/qt_iw.qmbin55269 -> 0 bytes
-rw-r--r--translations/qt_ja_JP.qmbin64337 -> 0 bytes
-rw-r--r--translations/qt_pl.qmbin143971 -> 0 bytes
-rw-r--r--translations/qt_pt.qmbin78828 -> 0 bytes
-rw-r--r--translations/qt_ru.qmbin60815 -> 0 bytes
-rw-r--r--translations/qt_sk.qmbin79787 -> 0 bytes
-rw-r--r--translations/qt_sv.qmbin73493 -> 0 bytes
-rw-r--r--translations/qt_uk.qmbin81429 -> 0 bytes
-rw-r--r--translations/qt_zh_CN.qmbin118981 -> 0 bytes
-rw-r--r--translations/qt_zh_TW.qmbin118967 -> 0 bytes
-rw-r--r--translations/qtconfig_pl.qmbin17940 -> 0 bytes
-rw-r--r--translations/qtconfig_zh_CN.qmbin21688 -> 0 bytes
-rw-r--r--translations/qtconfig_zh_TW.qmbin20262 -> 0 bytes
-rw-r--r--translations/qvfb_pl.qmbin4742 -> 0 bytes
-rw-r--r--translations/qvfb_zh_CN.qmbin4853 -> 0 bytes
-rw-r--r--translations/qvfb_zh_TW.qmbin4853 -> 0 bytes
-rw-r--r--translations/translations.pri38
-rw-r--r--translations/translations.pro41
46 files changed, 48 insertions, 36 deletions
diff --git a/projects.pro b/projects.pro
index 2596c0a..03ce098 100644
--- a/projects.pro
+++ b/projects.pro
@@ -37,7 +37,10 @@ for(PROJECT, $$list($$lower($$unique(QT_BUILD_PARTS)))) {
} else:isEqual(PROJECT, docs) {
contains(QT_BUILD_PARTS, tools):include(doc/doc.pri)
} else:isEqual(PROJECT, translations) {
- contains(QT_BUILD_PARTS, tools):include(translations/translations.pri)
+ contains(QT_BUILD_PARTS, tools) {
+ include(translations/translations.pri) # ts targets
+ SUBDIRS += translations # qm build step
+ }
} else:isEqual(PROJECT, qmake) {
# SUBDIRS += qmake
} else {
diff --git a/translations/assistant_adp_de.qm b/translations/assistant_adp_de.qm
deleted file mode 100644
index 15ef713..0000000
--- a/translations/assistant_adp_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_adp_ja.qm b/translations/assistant_adp_ja.qm
deleted file mode 100644
index a3b4383..0000000
--- a/translations/assistant_adp_ja.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_adp_pl.qm b/translations/assistant_adp_pl.qm
deleted file mode 100644
index 1b144e1..0000000
--- a/translations/assistant_adp_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_adp_zh_CN.qm b/translations/assistant_adp_zh_CN.qm
deleted file mode 100644
index 1685e47..0000000
--- a/translations/assistant_adp_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_adp_zh_TW.qm b/translations/assistant_adp_zh_TW.qm
deleted file mode 100644
index 8e055c4..0000000
--- a/translations/assistant_adp_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_de.qm b/translations/assistant_de.qm
deleted file mode 100644
index 5b31aea..0000000
--- a/translations/assistant_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_pl.qm b/translations/assistant_pl.qm
deleted file mode 100644
index 14560b3..0000000
--- a/translations/assistant_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_zh_CN.qm b/translations/assistant_zh_CN.qm
deleted file mode 100644
index 22a770d..0000000
--- a/translations/assistant_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/assistant_zh_TW.qm b/translations/assistant_zh_TW.qm
deleted file mode 100644
index 41f320e..0000000
--- a/translations/assistant_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/designer_de.qm b/translations/designer_de.qm
deleted file mode 100644
index f9b0a03..0000000
--- a/translations/designer_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/designer_ja.qm b/translations/designer_ja.qm
deleted file mode 100644
index 6cf5f89..0000000
--- a/translations/designer_ja.qm
+++ /dev/null
Binary files differ
diff --git a/translations/designer_pl.qm b/translations/designer_pl.qm
deleted file mode 100644
index bf8d5f7..0000000
--- a/translations/designer_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/designer_zh_CN.qm b/translations/designer_zh_CN.qm
deleted file mode 100644
index 9267123..0000000
--- a/translations/designer_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/designer_zh_TW.qm b/translations/designer_zh_TW.qm
deleted file mode 100644
index fd6460d..0000000
--- a/translations/designer_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/linguist_de.qm b/translations/linguist_de.qm
deleted file mode 100644
index a39c3bf..0000000
--- a/translations/linguist_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/linguist_ja.qm b/translations/linguist_ja.qm
deleted file mode 100644
index cdb7c1c..0000000
--- a/translations/linguist_ja.qm
+++ /dev/null
Binary files differ
diff --git a/translations/linguist_pl.qm b/translations/linguist_pl.qm
deleted file mode 100644
index 2604ffe..0000000
--- a/translations/linguist_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/linguist_zh_CN.qm b/translations/linguist_zh_CN.qm
deleted file mode 100644
index d8081c5..0000000
--- a/translations/linguist_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/linguist_zh_TW.qm b/translations/linguist_zh_TW.qm
deleted file mode 100644
index 9477e56..0000000
--- a/translations/linguist_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_ar.qm b/translations/qt_ar.qm
deleted file mode 100644
index 3d55bf4..0000000
--- a/translations/qt_ar.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_de.qm b/translations/qt_de.qm
deleted file mode 100644
index 9ea09a7..0000000
--- a/translations/qt_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_es.qm b/translations/qt_es.qm
deleted file mode 100644
index 0fa1226..0000000
--- a/translations/qt_es.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_fr.qm b/translations/qt_fr.qm
deleted file mode 100644
index 5553086..0000000
--- a/translations/qt_fr.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_help_de.qm b/translations/qt_help_de.qm
deleted file mode 100644
index e3d8d87..0000000
--- a/translations/qt_help_de.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_help_pl.qm b/translations/qt_help_pl.qm
deleted file mode 100644
index bf7fd10..0000000
--- a/translations/qt_help_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_help_zh_CN.qm b/translations/qt_help_zh_CN.qm
deleted file mode 100644
index 11748b7..0000000
--- a/translations/qt_help_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_help_zh_TW.qm b/translations/qt_help_zh_TW.qm
deleted file mode 100644
index b97aae4..0000000
--- a/translations/qt_help_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_iw.qm b/translations/qt_iw.qm
deleted file mode 100644
index 59c1c7e..0000000
--- a/translations/qt_iw.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_ja_JP.qm b/translations/qt_ja_JP.qm
deleted file mode 100644
index b695c97..0000000
--- a/translations/qt_ja_JP.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_pl.qm b/translations/qt_pl.qm
deleted file mode 100644
index f6847d0..0000000
--- a/translations/qt_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_pt.qm b/translations/qt_pt.qm
deleted file mode 100644
index 253a007..0000000
--- a/translations/qt_pt.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_ru.qm b/translations/qt_ru.qm
deleted file mode 100644
index 63b7b8b..0000000
--- a/translations/qt_ru.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_sk.qm b/translations/qt_sk.qm
deleted file mode 100644
index a73ddc6..0000000
--- a/translations/qt_sk.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_sv.qm b/translations/qt_sv.qm
deleted file mode 100644
index 6b1e9cf..0000000
--- a/translations/qt_sv.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_uk.qm b/translations/qt_uk.qm
deleted file mode 100644
index 7cd604a..0000000
--- a/translations/qt_uk.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_zh_CN.qm b/translations/qt_zh_CN.qm
deleted file mode 100644
index e73b0cd..0000000
--- a/translations/qt_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qt_zh_TW.qm b/translations/qt_zh_TW.qm
deleted file mode 100644
index 699bd5c..0000000
--- a/translations/qt_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qtconfig_pl.qm b/translations/qtconfig_pl.qm
deleted file mode 100644
index 1a2faa3..0000000
--- a/translations/qtconfig_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qtconfig_zh_CN.qm b/translations/qtconfig_zh_CN.qm
deleted file mode 100644
index 9998e81..0000000
--- a/translations/qtconfig_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qtconfig_zh_TW.qm b/translations/qtconfig_zh_TW.qm
deleted file mode 100644
index 3d36679..0000000
--- a/translations/qtconfig_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qvfb_pl.qm b/translations/qvfb_pl.qm
deleted file mode 100644
index 7230cb6..0000000
--- a/translations/qvfb_pl.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qvfb_zh_CN.qm b/translations/qvfb_zh_CN.qm
deleted file mode 100644
index 5592f07..0000000
--- a/translations/qvfb_zh_CN.qm
+++ /dev/null
Binary files differ
diff --git a/translations/qvfb_zh_TW.qm b/translations/qvfb_zh_TW.qm
deleted file mode 100644
index b378ad8..0000000
--- a/translations/qvfb_zh_TW.qm
+++ /dev/null
Binary files differ
diff --git a/translations/translations.pri b/translations/translations.pri
index 0c5c1ee..c143043 100644
--- a/translations/translations.pri
+++ b/translations/translations.pri
@@ -8,16 +8,8 @@ defineReplace(prependAll) {
return ($$result)
}
-defineReplace(fixPath) {
-WIN {
- return ($$replace($$1, /, \))
-} ELSE {
- return ($$1)
-}
-}
-
-LUPDATE = $$fixPath($$QT_BUILD_TREE/bin/lupdate) -locations relative -no-ui-lines
-LRELEASE = $$fixPath($$QT_BUILD_TREE/bin/lrelease)
+LUPDATE = $$QT_BUILD_TREE/bin/lupdate -locations relative -no-ui-lines
+win32:LUPDATE ~= s|/|\|g
###### Qt Libraries
@@ -41,27 +33,18 @@ ts-qt.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
-ts $$prependAll($$[QT_INSTALL_TRANSLATIONS]/qt_,$$QT_TS,.ts))
ts-qt.depends = sub-tools
-qm-qt.commands = $$LRELEASE $$prependAll($$[QT_INSTALL_TRANSLATIONS]/qt_,$$QT_TS,.ts)
-qm-qt.depends = sub-tools
-
###### Designer
ts-designer.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
../tools/designer/translations/translations.pro)
ts-designer.depends = sub-tools
-qm-designer.commands = $$LRELEASE $$QT_SOURCE_TREE/tools/designer/translations/translations.pro
-qm-designer.depends = sub-tools
-
###### Linguist
ts-linguist.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
../tools/linguist/linguist/linguist.pro)
ts-linguist.depends = sub-tools
-qm-linguist.commands = $$LRELEASE $$QT_SOURCE_TREE/tools/linguist/linguist/linguist.pro
-qm-linguist.depends = sub-tools
-
###### Assistant
ts-assistant.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
@@ -72,36 +55,21 @@ ts-assistant.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
../tools/assistant/translations/translations_adp.pro)
ts-assistant.depends = sub-tools
-qm-assistant.commands = ($$LRELEASE $$QT_SOURCE_TREE/tools/assistant/translations/translations.pro \
- && $$LRELEASE \
- $$QT_SOURCE_TREE/tools/assistant/translations/qt_help.pro \
- && $$LRELEASE \
- $$QT_SOURCE_TREE/tools/assistant/translations/translations_adp.pro)
-qm-assistant.depends = sub-tools
-
###### Qtconfig
ts-qtconfig.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
../tools/qtconfig/translations/translations.pro)
ts-qtconfig.depends = sub-tools
-qm-qtconfig.commands = $$LRELEASE $$QT_SOURCE_TREE/tools/qtconfig/translations/translations.pro
-qm-qtconfig.depends = sub-tools
-
###### Qvfp
ts-qvfb.commands = (cd $$QT_SOURCE_TREE/src && $$LUPDATE \
../tools/qvfb/translations/translations.pro)
ts-qvfb.depends = sub-tools
-qm-qvfb.commands = $$LRELEASE $$QT_SOURCE_TREE/tools/qvfb/translations/translations.pro
-qm-qvfb.depends = sub-tools
-
###### Overall Rules
ts.depends = ts-qt ts-designer ts-linguist ts-assistant ts-qtconfig ts-qvfb
-qm.depends = qm-qt qm-designer qm-linguist qm-assistant qm-qtconfig qm-qvfb
QMAKE_EXTRA_TARGETS += ts-qt ts-designer ts-linguist ts-assistant ts-qtconfig ts-qvfb \
- qm-qt qm-designer qm-linguist qm-assistant qm-qtconfig qm-qvfb \
- ts qm
+ ts
diff --git a/translations/translations.pro b/translations/translations.pro
new file mode 100644
index 0000000..d1962fe
--- /dev/null
+++ b/translations/translations.pro
@@ -0,0 +1,41 @@
+TRANSLATIONS = $$files(*.ts)
+
+LRELEASE = $$QT_BUILD_TREE/bin/lrelease
+win32:LRELEASE ~= s|/|\|g
+
+contains(TEMPLATE_PREFIX, vc):vcproj = 1
+
+TEMPLATE = app
+TARGET = qm_phony_target
+CONFIG -= qt separate_debug_info
+QT =
+LIBS =
+
+updateqm.input = TRANSLATIONS
+updateqm.output = ${QMAKE_FILE_BASE}.qm
+isEmpty(vcproj):updateqm.variable_out = PRE_TARGETDEPS
+updateqm.commands = $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT}
+updateqm.name = LRELEASE ${QMAKE_FILE_IN}
+updateqm.CONFIG += no_link
+QMAKE_EXTRA_COMPILERS += updateqm
+
+isEmpty(vcproj) {
+ QMAKE_LINK = @: IGNORE THIS LINE
+ OBJECTS_DIR =
+ win32:CONFIG -= embed_manifest_exe
+} else {
+ CONFIG += console
+ PHONY_DEPS = .
+ phony_src.input = PHONY_DEPS
+ phony_src.output = phony.c
+ phony_src.variable_out = GENERATED_SOURCES
+ phony_src.commands = echo int main() { return 0; } > phony.c
+ phony_src.name = CREATE phony.c
+ phony_src.CONFIG += combine
+ QMAKE_EXTRA_COMPILERS += phony_src
+}
+
+translations.path = $$[QT_INSTALL_TRANSLATIONS]
+translations.files = $$TRANSLATIONS
+translations.files ~= s,\\.ts$,.qm,g
+INSTALLS += translations