From 70ffdb99d8d6b0610ab4a6bc6f765f1c46b59980 Mon Sep 17 00:00:00 2001 From: Tomasz Olszak Date: Thu, 29 Jun 2017 15:00:11 +0200 Subject: [PATCH 1/3] Add QML2_IMPORT_PATH to qmlplugindump if defined in build configuration Change-Id: I0e3a6beda6cca2a065b2d47115b04362d82c879a Reviewed-by: Thomas Hartmann Reviewed-by: Marco Benelli --- src/plugins/qmljstools/qmljsmodelmanager.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/plugins/qmljstools/qmljsmodelmanager.cpp b/src/plugins/qmljstools/qmljsmodelmanager.cpp index 60f7566713b..d28cc3ab87e 100644 --- a/src/plugins/qmljstools/qmljsmodelmanager.cpp +++ b/src/plugins/qmljstools/qmljsmodelmanager.cpp @@ -106,6 +106,10 @@ ModelManagerInterface::ProjectInfo ModelManager::defaultProjectInfoForProject( if (BuildConfiguration *bc = activeTarget->activeBuildConfiguration()) { preferDebugDump = bc->buildType() == BuildConfiguration::Debug; setPreferDump = true; + // Append QML2_IMPORT_PATH if it is defined in build configuration. + // It enables qmlplugindump to correctly dump custom plugins or other dependent + // plugins that are not installed in default Qt qml installation directory. + projectInfo.qmlDumpEnvironment.appendOrSet("QML2_IMPORT_PATH", bc->environment().value("QML2_IMPORT_PATH"), ":"); } } if (!setPreferDump && qtVersion) From 144cfd83b07dc6f5fad910ad804f8c99b8b610f8 Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Tue, 4 Jul 2017 17:20:24 +0200 Subject: [PATCH 2/3] Debugger: Fix build Change-Id: I9e9231b17b6ded2260854fe60ecc8a9aae63ceb5 Reviewed-by: Tim Jenssen Reviewed-by: hjk --- src/plugins/debugger/analyzer/analyzermanager.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/plugins/debugger/analyzer/analyzermanager.h b/src/plugins/debugger/analyzer/analyzermanager.h index 5907c819aa5..053056abd1f 100644 --- a/src/plugins/debugger/analyzer/analyzermanager.h +++ b/src/plugins/debugger/analyzer/analyzermanager.h @@ -30,6 +30,8 @@ #include "../debuggermainwindow.h" +#include + #include #include From 985180d38453376b9cd1d19d1cbd5e30040b0c78 Mon Sep 17 00:00:00 2001 From: Ivan Donchevskii Date: Mon, 3 Jul 2017 14:38:46 +0200 Subject: [PATCH 3/3] Toolchain: set triple in msvctoolchain class Move triple set up to msvc toolchain class, use another triple for x86_64 Change-Id: I3aebb051eb5d93accc6073e01391bf972199c2cb Reviewed-by: Nikolai Kosjar Reviewed-by: Tobias Hunger --- src/plugins/cpptools/projectinfo.cpp | 4 +--- src/plugins/projectexplorer/abstractmsvctoolchain.cpp | 7 +++++++ src/plugins/projectexplorer/abstractmsvctoolchain.h | 2 ++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/plugins/cpptools/projectinfo.cpp b/src/plugins/cpptools/projectinfo.cpp index e0db5fd54f3..1ca95e3e9c0 100644 --- a/src/plugins/cpptools/projectinfo.cpp +++ b/src/plugins/cpptools/projectinfo.cpp @@ -40,9 +40,7 @@ ToolChainInfo::ToolChainInfo(const ProjectExplorer::ToolChain *toolChain, isMsvc2015ToolChain = toolChain->targetAbi().osFlavor() == ProjectExplorer::Abi::WindowsMsvc2015Flavor; wordWidth = toolChain->targetAbi().wordWidth(); - targetTriple = type == ProjectExplorer::Constants::MSVC_TOOLCHAIN_TYPEID - ? QLatin1String("i686-pc-windows-msvc") - : toolChain->originalTargetTriple(); // OK, compiler run is already cached. + targetTriple = toolChain->originalTargetTriple(); // ...and save the potentially expensive operations for later so that // they can be run from a worker thread. diff --git a/src/plugins/projectexplorer/abstractmsvctoolchain.cpp b/src/plugins/projectexplorer/abstractmsvctoolchain.cpp index 386fc33e19e..121e2b43b4f 100644 --- a/src/plugins/projectexplorer/abstractmsvctoolchain.cpp +++ b/src/plugins/projectexplorer/abstractmsvctoolchain.cpp @@ -97,6 +97,13 @@ bool AbstractMsvcToolChain::isValid() const return fi.isFile() && fi.isExecutable(); } +QString AbstractMsvcToolChain::originalTargetTriple() const +{ + return m_abi.wordWidth() == 64 + ? QLatin1String("x86_64-pc-windows-msvc") + : QLatin1String("i686-pc-windows-msvc"); +} + ToolChain::PredefinedMacrosRunner AbstractMsvcToolChain::createPredefinedMacrosRunner() const { Utils::Environment env(m_lastEnvironment); diff --git a/src/plugins/projectexplorer/abstractmsvctoolchain.h b/src/plugins/projectexplorer/abstractmsvctoolchain.h index 2b8c86f4d42..9a96faea0eb 100644 --- a/src/plugins/projectexplorer/abstractmsvctoolchain.h +++ b/src/plugins/projectexplorer/abstractmsvctoolchain.h @@ -50,6 +50,8 @@ public: bool isValid() const override; + QString originalTargetTriple() const override; + PredefinedMacrosRunner createPredefinedMacrosRunner() const override; QByteArray predefinedMacros(const QStringList &cxxflags) const override; CompilerFlags compilerFlags(const QStringList &cxxflags) const override;