diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2019-05-10 11:22:31 +0200 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2019-05-10 11:22:31 +0200 |
commit | db4a3f1f91a5ddec9c6447e28ced46e6e381ac18 (patch) | |
tree | a3f4619d19a53d40c8a41968a540efd0f5cddbff /share/qbs | |
parent | fe497bfaa009b9dff1e7f3fb68d6207968a247c5 (diff) | |
parent | 6429e872494925508bcf84f3d3b2f3f821d4eba5 (diff) |
Merge 1.13 into master
Change-Id: Ic02d717f80f5d831f0cedb3b7c565a9bfef3a2a3
Diffstat (limited to 'share/qbs')
5 files changed, 13 insertions, 5 deletions
diff --git a/share/qbs/module-providers/Qt/templates/QtPlugin.qbs b/share/qbs/module-providers/Qt/templates/QtPlugin.qbs index 23a6795f3..88bfa5a65 100644 --- a/share/qbs/module-providers/Qt/templates/QtPlugin.qbs +++ b/share/qbs/module-providers/Qt/templates/QtPlugin.qbs @@ -12,6 +12,8 @@ QtModule { return false; if (!isStaticLibrary) return false; + if (!Qt.plugin_support.linkPlugins) + return false; if (!(Qt.plugin_support.enabledPlugins || []).contains(qtModuleName)) return false; if (!extendsModules || extendsModules.length === 0) diff --git a/share/qbs/module-providers/Qt/templates/core.qbs b/share/qbs/module-providers/Qt/templates/core.qbs index b2f05d8e9..63d9a4cb5 100644 --- a/share/qbs/module-providers/Qt/templates/core.qbs +++ b/share/qbs/module-providers/Qt/templates/core.qbs @@ -13,7 +13,7 @@ Module { || architectures.contains(qbs.architecture)) readonly property bool isCombinedUIKitBuild: ["ios", "tvos", "watchos"].contains(targetPlatform) - && ["x86", "x86_64"].contains(qbs.architecture) + && (!qbs.architecture || ["x86", "x86_64"].contains(qbs.architecture)) && qbs.targetPlatform === targetPlatform + "-simulator" Depends { name: "cpp" } diff --git a/share/qbs/module-providers/Qt/templates/plugin_support.qbs b/share/qbs/module-providers/Qt/templates/plugin_support.qbs index 13d95c383..1de923f17 100644 --- a/share/qbs/module-providers/Qt/templates/plugin_support.qbs +++ b/share/qbs/module-providers/Qt/templates/plugin_support.qbs @@ -1,6 +1,8 @@ Module { // Set by user. property varList pluginsByType + property bool linkPlugins: product.type + && (product.type.contains("application") || product.type.contains("sharedlibrary")) // Set by Qt modules. property stringList pluginTypes diff --git a/share/qbs/module-providers/Qt/templates/qml.js b/share/qbs/module-providers/Qt/templates/qml.js index c7829d81b..3a86ce695 100644 --- a/share/qbs/module-providers/Qt/templates/qml.js +++ b/share/qbs/module-providers/Qt/templates/qml.js @@ -44,7 +44,10 @@ function getLibsForPlugin(pluginData, buildVariant, targetOS, toolchain, qtLibDi var pluginLib; var otherLibs = ""; var line; - while (line = prlFile.readLine()) { + while (!prlFile.atEof()) { + line = prlFile.readLine().trim(); + if (!line) + continue; if (line.startsWith("QMAKE_PRL_TARGET")) pluginLib = FileInfo.joinPaths(pluginData.path, getPrlRhs(line)); if (line.startsWith("QMAKE_PRL_LIBS")) { diff --git a/share/qbs/module-providers/Qt/templates/qml.qbs b/share/qbs/module-providers/Qt/templates/qml.qbs index 2b11abbd5..c95c0f367 100644 --- a/share/qbs/module-providers/Qt/templates/qml.qbs +++ b/share/qbs/module-providers/Qt/templates/qml.qbs @@ -24,12 +24,13 @@ QtModule { readonly property string pluginListFilePathDebug: product.buildDirectory + "/plugins.list.d" readonly property string pluginListFilePathRelease: product.buildDirectory + "/plugins.list" + property bool linkPlugins: isStaticLibrary && Qt.plugin_support.linkPlugins hasLibrary: @has_library@ architectures: @archs@ targetPlatform: @targetPlatform@ - staticLibsDebug: (isStaticLibrary ? ['@' + pluginListFilePathDebug] : []).concat(@staticLibsDebug@) - staticLibsRelease: (isStaticLibrary ? ['@' + pluginListFilePathRelease] : []).concat(@staticLibsRelease@) + staticLibsDebug: (linkPlugins ? ['@' + pluginListFilePathDebug] : []).concat(@staticLibsDebug@) + staticLibsRelease: (linkPlugins ? ['@' + pluginListFilePathRelease] : []).concat(@staticLibsRelease@) dynamicLibsDebug: @dynamicLibsDebug@ dynamicLibsRelease: @dynamicLibsRelease@ linkerFlagsDebug: @linkerFlagsDebug@ @@ -60,7 +61,7 @@ QtModule { } Rule { - condition: isStaticLibrary + condition: linkPlugins multiplex: true requiresInputs: false inputs: ["qt.qml.qml"] |