aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJake Petroules <jake.petroules@qt.io>2017-11-01 15:50:15 -0700
committerJake Petroules <jake.petroules@qt.io>2017-11-02 15:16:31 +0000
commit81c92bf00f2e1dad3e319d0bbc5ae466e2a047c6 (patch)
tree2a0caac96b85f8163c4aa70d41b393e3d4033fcc
parente7bb51e497cd5836472f4414d254f560ceab2663 (diff)
Allow fully overriding the QML type info build and install paths
Amends 6cb626668a Change-Id: I876f4b72a5d6ee20721b3746861f615e750c9be1 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
-rw-r--r--qbs-resources/modules/qbsbuildconfig/qbsbuildconfig.qbs4
-rw-r--r--share/share.qbs2
-rw-r--r--static-res.pro17
3 files changed, 13 insertions, 10 deletions
diff --git a/qbs-resources/modules/qbsbuildconfig/qbsbuildconfig.qbs b/qbs-resources/modules/qbsbuildconfig/qbsbuildconfig.qbs
index 74613021d..ee28da55a 100644
--- a/qbs-resources/modules/qbsbuildconfig/qbsbuildconfig.qbs
+++ b/qbs-resources/modules/qbsbuildconfig/qbsbuildconfig.qbs
@@ -1,4 +1,5 @@
import qbs
+import qbs.FileInfo
Module {
property bool enableUnitTests: false
@@ -28,5 +29,6 @@ Module {
}
property string resourcesInstallDir: ""
property string pluginsInstallDir: libDirName
- property string qmlTypeDescriptionsInstallDir: "share/qbs/qml-type-descriptions"
+ property string qmlTypeDescriptionsInstallDir: FileInfo.joinPaths(resourcesInstallDir,
+ "share/qbs/qml-type-descriptions")
}
diff --git a/share/share.qbs b/share/share.qbs
index c9966c791..18185927f 100644
--- a/share/share.qbs
+++ b/share/share.qbs
@@ -80,7 +80,6 @@ Product {
Artifact {
filePath: FileInfo.joinPaths(
project.buildDirectory,
- product.qbsbuildconfig.resourcesInstallDir,
product.qbsbuildconfig.qmlTypeDescriptionsInstallDir, "qbs.qmltypes")
fileTags: ["qbs qml type descriptions"]
}
@@ -108,7 +107,6 @@ Product {
Artifact {
filePath: FileInfo.joinPaths(
project.buildDirectory,
- product.qbsbuildconfig.resourcesInstallDir,
product.qbsbuildconfig.qmlTypeDescriptionsInstallDir, "qbs-bundle.json")
fileTags: ["qbs qml type bundle"]
}
diff --git a/static-res.pro b/static-res.pro
index 6ceae11cb..f65c82353 100644
--- a/static-res.pro
+++ b/static-res.pro
@@ -1,13 +1,14 @@
TEMPLATE = aux
!isEmpty(QBS_APPS_DESTDIR): qbsbindir = $${QBS_APPS_DESTDIR}
-else: qbsbindir = ../../../bin
-qbsbindir = $$clean_path(src/app/qbs/$$qbsbindir)
+else: qbsbindir = bin
builddirname = qbsres
typedescdir = share/qbs/qml-type-descriptions
typedescdir_src = $$builddirname/default/install-root/$$typedescdir
-!isEmpty(QBS_RESOURCES_BUILD_DIR): \
+!isEmpty(QBS_QML_TYPE_DESCRIPTIONS_BUILD_DIR): \
+ typedescdir_dst = $$QBS_QML_TYPE_DESCRIPTIONS_BUILD_DIR
+else:!isEmpty(QBS_RESOURCES_BUILD_DIR): \
typedescdir_dst = $$QBS_RESOURCES_BUILD_DIR/$$typedescdir
else: \
typedescdir_dst = $$typedescdir
@@ -51,9 +52,11 @@ PRE_TARGETDEPS += $$qbsqmltypes.target $$qbsbundle.target
include(src/install_prefix.pri)
qbstypedescfiles.files = $$qbsqmltypes.target $$qbsbundle.target
-!isEmpty(QBS_RESOURCES_INSTALL_DIR): \
- installPrefix = $${QBS_RESOURCES_INSTALL_DIR}
+!isEmpty(QBS_QML_TYPE_DESCRIPTIONS_INSTALL_DIR): \
+ installPrefix = $${QBS_QML_TYPE_DESCRIPTIONS_INSTALL_DIR}
+else:!isEmpty(QBS_RESOURCES_INSTALL_DIR): \
+ installPrefix = $${QBS_RESOURCES_INSTALL_DIR}/$$typedescdir
else: \
- installPrefix = $${QBS_INSTALL_PREFIX}
-qbstypedescfiles.path = $${installPrefix}/$$typedescdir
+ installPrefix = $${QBS_INSTALL_PREFIX}/$$typedescdir
+qbstypedescfiles.path = $${installPrefix}
INSTALLS += qbstypedescfiles