diff options
author | Alessandro Portale <alessandro.portale@qt.io> | 2019-10-31 16:01:35 +0100 |
---|---|---|
committer | Aurindam Jana <aurindam.jana@qt.io> | 2019-10-31 15:16:26 +0000 |
commit | 907c35dc00ed4965ea30f7434b522f9e72110b15 (patch) | |
tree | 4853bd2121a5cadd104fbd922a1a4698db8812b9 /src/plugins/mcusupport/mcusupportoptions.cpp | |
parent | 28d2134d461075384cc67a910beb6d76044c95ee (diff) |
McuSupport: Enable and preselect usage of the shipped JOM (on Windows)
- Set CMake generator to "NMake Makefiles JOM"
- Add ICore::libexecPath to environment path
- Set the environment for the run configuration
Change-Id: Ie7b2dc1513b366911b429d77cc4a1954be531075
Reviewed-by: Aurindam Jana <aurindam.jana@qt.io>
Diffstat (limited to 'src/plugins/mcusupport/mcusupportoptions.cpp')
-rw-r--r-- | src/plugins/mcusupport/mcusupportoptions.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/plugins/mcusupport/mcusupportoptions.cpp b/src/plugins/mcusupport/mcusupportoptions.cpp index a7e61a6dab4..d3b99baf684 100644 --- a/src/plugins/mcusupport/mcusupportoptions.cpp +++ b/src/plugins/mcusupport/mcusupportoptions.cpp @@ -455,10 +455,10 @@ static void setKitEnvironment(ProjectExplorer::Kit *k, const BoardOptions* board changes.append({package->environmentVariableName(), QDir::toNativeSeparators(package->path())}); } - if (!pathAdditions.isEmpty()) { - pathAdditions.append("${Path}"); - changes.append({"Path", pathAdditions.join(Utils::HostOsInfo::pathListSeparator())}); - } + pathAdditions.append("${Path}"); + if (Utils::HostOsInfo::isWindowsHost()) + pathAdditions.append(QDir::toNativeSeparators(Core::ICore::libexecPath())); // for jom + changes.append({"Path", pathAdditions.join(Utils::HostOsInfo::pathListSeparator())}); EnvironmentKitAspect::setEnvironmentChanges(k, changes); } @@ -471,6 +471,8 @@ static void setKitCMakeOptions(ProjectExplorer::Kit *k, const BoardOptions* boar ("%{CurrentBuild:Env:Qul_DIR}/" + board->toolChainFile()).toUtf8())); CMakeConfigurationKitAspect::setConfiguration(k, config); + if (Utils::HostOsInfo::isWindowsHost()) + CMakeGeneratorKitAspect::setGenerator(k, "NMake Makefiles JOM"); } ProjectExplorer::Kit *McuSupportOptions::kit(const BoardOptions* board) |