summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/qml_module.prf
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs/features/qml_module.prf')
-rw-r--r--mkspecs/features/qml_module.prf24
1 files changed, 11 insertions, 13 deletions
diff --git a/mkspecs/features/qml_module.prf b/mkspecs/features/qml_module.prf
index 4db0040dc5..bd84ce597a 100644
--- a/mkspecs/features/qml_module.prf
+++ b/mkspecs/features/qml_module.prf
@@ -23,21 +23,19 @@ for(qmlf, AUX_QML_FILES): fq_aux_qml_files += $$absolute_path($$qmlf, $$_PRO_FIL
load(qt_build_paths)
-qml1_target {
- DESTDIR = $$MODULE_BASE_OUTDIR/imports/$$TARGETPATH
- instbase = $$[QT_INSTALL_IMPORTS]
-} else {
- DESTDIR = $$MODULE_BASE_OUTDIR/qml/$$TARGETPATH
- instbase = $$[QT_INSTALL_QML]
-}
+DESTDIR = $$MODULE_BASE_OUTDIR/qml/$$TARGETPATH
-!qml1_target:static: CONFIG += builtin_resources
+static: \
+ CONFIG += builtin_resources
+else: \
+ CONFIG += install_qml_files
builtin_resources {
URITARGET = $$replace(URI, "\\.", "_")
- # Ensure the QML files are included in the resources. In static builds,
- # the QML engine reads also the qmldir file from the resources.
- $${URITARGET}.files = $$qmldir_file $$fq_qml_files
+ # In static builds, the QML engine reads also the qmldir file from the resources.
+ static: $${URITARGET}.files = $$qmldir_file
+ # Ensure the QML files are included in the resources.
+ $${URITARGET}.files += $$fq_qml_files
# qt-project.org/imports is the path used for locating imports inside the resources
$${URITARGET}.prefix = /qt-project.org/imports/$$TARGETPATH
RESOURCES += $${URITARGET}
@@ -47,8 +45,8 @@ builtin_resources {
qmldir.base = $$_PRO_FILE_PWD_
# Tools need qmldir and plugins.qmltypes always installed on the file system
qmldir.files = $$qmldir_file $$fq_aux_qml_files
-!builtin_resources: qmldir.files += $$fq_qml_files
-qmldir.path = $$instbase/$$TARGETPATH
+install_qml_files: qmldir.files += $$fq_qml_files
+qmldir.path = $$[QT_INSTALL_QML]/$$TARGETPATH
INSTALLS += qmldir
!debug_and_release|!build_all|CONFIG(release, debug|release) {