aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSivert Krøvel <sivert.krovel@qt.io>2022-11-03 20:07:29 +0100
committerSivert Krøvel <sivert.krovel@qt.io>2022-11-04 14:56:49 +0000
commit6aaf33bee5eb205e03baace73147a222f1144246 (patch)
tree247b75eaf910854d16d209579ef719ed2fdc5f24
parent7203d6d44b1652388d66ba3ec06b385950a5e09d (diff)
McuSupport: Do not update paths in kits for different SDK versions
When updating paths for a target in Devices > MCU, the paths were updated in the corresponding kits for all Qt for MCUs versions. This would break existing kits made for a different version than the currently active one. With this change, only kits made for the same SDK version as the currently selected target will be modified. Task-number: UL-6755 Change-Id: I6fda050094b5603914fbbc29a5fc2e83d974a2d6 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Rainer Keller <Rainer.Keller@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
-rw-r--r--src/plugins/mcusupport/mcukitmanager.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/plugins/mcusupport/mcukitmanager.cpp b/src/plugins/mcusupport/mcukitmanager.cpp
index 84299939e1..cdee6cf581 100644
--- a/src/plugins/mcusupport/mcukitmanager.cpp
+++ b/src/plugins/mcusupport/mcukitmanager.cpp
@@ -593,6 +593,11 @@ void updatePathsInExistingKits(const SettingsHandler::Ptr &settingsHandler)
for (const auto &target : std::as_const(repo.mcuTargets)) {
if (target->isValid()) {
for (auto *kit : kitsWithMismatchedDependencies(target.get())) {
+ if (kitQulVersion(kit) != target->qulVersion()) {
+ //Do not update kits made for other Qt for MCUs SDK versions
+ continue;
+ }
+
auto changes = cMakeConfigToMap(CMakeConfigurationKitAspect::configuration(kit));
const auto updateForPackage = [&changes](const McuPackagePtr &package) {