diff --git a/dist/changelog/changes-10.0.2.md b/dist/changelog/changes-10.0.2.md new file mode 100644 index 00000000000..baf99955de7 --- /dev/null +++ b/dist/changelog/changes-10.0.2.md @@ -0,0 +1,76 @@ +Qt Creator 10.0.2 +================= + +Qt Creator version 10.0.2 contains bug fixes. + +The most important changes are listed in this document. For a complete list of +changes, see the Git log for the Qt Creator sources that you can check out from +the public Git repository. For example: + + git clone git://code.qt.io/qt-creator/qt-creator.git + git log --cherry-pick --pretty=oneline origin/v10.0.1..v10.0.2 + +General +------- + +* Fixed freezes due to excessive file watching (QTCREATORBUG-28957) + +Editing +------- + +### C++ + +* Fixed a crash when following symbols (QTCREATORBUG-28989) +* Fixed the highlighting of raw string literals with empty lines + (QTCREATORBUG-29200) +* Clang Format + * Fixed the editing of custom code styles (QTCREATORBUG-29129) + * Fixed that the wrong code style could be used (QTCREATORBUG-29145) + +Projects +-------- + +* Fixed a crash when triggering a build with unconfigured projects present + (QTCREATORBUG-29207) + +### CMake + +* Fixed that the global `Autorun CMake` option could be overridden by old + settings +* Fixed the `Build CMake Target` locator filter in case a build is already + running (QTCREATORBUG-26699) +* Presets + * Added the expansion of `${hostSystemName}` (QTCREATORBUG-28935) + * Fixed the Qt detection when `CMAKE_TOOLCHAIN_FILE` and `CMAKE_PREFIX_PATH` + are set + +Debugging +--------- + +* Fixed that debugger tooltips in the editor vanished after expanding + (QTCREATORBUG-29083) + +Test Integration +---------------- + +* GoogleTest + * Fixed the reporting of failed tests (QTCREATORBUG-29146) + +Credits for these changes go to: +-------------------------------- +Alessandro Portale +André Pönitz +Artem Sokolovskii +Björn Schäpers +Christian Kandeler +Christian Stenger +Cristian Adam +David Schulz +Eike Ziller +Jaroslaw Kobus +Karim Abdelrahman +Leena Miettinen +Miikka Heikkinen +Patrik Teivonen +Robert Löhning +Sivert Krøvel diff --git a/src/plugins/clangformat/clangformatindenter.cpp b/src/plugins/clangformat/clangformatindenter.cpp index 67d5171b010..2e9781de322 100644 --- a/src/plugins/clangformat/clangformatindenter.cpp +++ b/src/plugins/clangformat/clangformatindenter.cpp @@ -32,7 +32,7 @@ static bool isBeautifierPluginActivated() return std::find_if(specs.begin(), specs.end(), [](ExtensionSystem::PluginSpec *spec) { - return spec->name() == "Beautifier"; + return spec->name() == "Beautifier" && spec->isEffectivelyEnabled(); }) != specs.end(); } diff --git a/src/plugins/clangformat/llvmfilesystem.h b/src/plugins/clangformat/llvmfilesystem.h index 675791f349e..fface01fc08 100644 --- a/src/plugins/clangformat/llvmfilesystem.h +++ b/src/plugins/clangformat/llvmfilesystem.h @@ -50,7 +50,7 @@ public: Q_UNUSED(RequiresNullTerminator); Q_UNUSED(IsVolatile); - const FilePath path = FilePath::fromString(QString::fromStdString(Name.str())); + const FilePath path = FilePath::fromUserInput(QString::fromStdString(Name.str())); const expected_str contents = path.fileContents(FileSize, 0); QTC_ASSERT_EXPECTED(contents, return std::error_code()); @@ -72,7 +72,7 @@ public: ErrorOr status(const Twine &Path) override { - const Utils::FilePath path = FilePath::fromString(QString::fromStdString(Path.str())); + const FilePath path = FilePath::fromUserInput(QString::fromStdString(Path.str())); QFileInfo fInfo(QString::fromStdString(Path.str())); if (!fInfo.exists()) diff --git a/src/plugins/mcusupport/test/unittest.cpp b/src/plugins/mcusupport/test/unittest.cpp index a8a8f091399..697472c23fe 100644 --- a/src/plugins/mcusupport/test/unittest.cpp +++ b/src/plugins/mcusupport/test/unittest.cpp @@ -146,9 +146,9 @@ const QString stmCubeProgrammerDetectionPath{HostOsInfo::isWindowsHost() ? QString("bin/STM32_Programmer_CLI.exe") : QString("bin/STM32_Programmer.sh")}; -const char renesasProgrammerSetting[]{"FlashProgrammerPath"}; +const char renesasProgrammerSetting[]{"RenesasFlashProgrammer"}; const char renesasProgrammerCmakeVar[]{"RENESAS_FLASH_PROGRAMMER_PATH"}; -const QString renesasProgrammerEnvVar{"RenesasFlashProgrammer_PATH"}; +const char renesasProgrammerEnvVar[]{"RENESAS_FLASH_PROGRAMMER_PATH"}; const char renesasProgrammerLabel[]{"Renesas Flash Programmer"}; const QString renesasProgrammerDetectionPath{HostOsInfo::withExecutableSuffix("rfp-cli")}; @@ -1539,9 +1539,9 @@ void McuSupportTest::test_legacy_createThirdPartyPackage_data() << PackageCreator{[this]() { return Legacy::createRenesasProgrammerPackage(settingsMockPtr); }} - << ghs_rh850_d1m1a_baremetal_json << defaultToolPath << defaultToolPath - << renesasProgrammerSetting << renesasProgrammerCmakeVar << renesasProgrammerEnvVar - << renesasProgrammerLabel << renesasProgrammerDetectionPath; + << ghs_rh850_d1m1a_baremetal_json << empty << empty << renesasProgrammerSetting + << renesasProgrammerCmakeVar << renesasProgrammerEnvVar << renesasProgrammerLabel + << renesasProgrammerDetectionPath; } void McuSupportTest::test_legacy_createThirdPartyPackage() @@ -1574,7 +1574,53 @@ void McuSupportTest::test_legacy_createThirdPartyPackage() void McuSupportTest::test_createThirdPartyPackage_data() { - test_legacy_createThirdPartyPackage_data(); + QTest::addColumn("json"); + QTest::addColumn("path"); + QTest::addColumn("defaultPath"); + QTest::addColumn("setting"); + QTest::addColumn("cmakeVar"); + QTest::addColumn("envVar"); + QTest::addColumn("label"); + QTest::addColumn("detectionPath"); + + // Sometimes the jsons have different values than the legacy packages + // Enter the expected values from the jsons here when they diverge from legacy values + QString programFiles = qtcEnvironmentVariable("Env:PROGRAMFILES(x86)"); + const QString renesasProgrammerDefaultPath = { + HostOsInfo::isWindowsHost() + ? QString("%1/Renesas Electronics/Programming Tools/Renesas " + "Flash Programmer V3.09").arg(programFiles) + : QString("")}; + + QTest::newRow("armgcc_mimxrt1050_evk_freertos_json mcuXpresso") + << armgcc_mimxrt1050_evk_freertos_json << xpressoIdePath << xpressoIdePath + << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel + << xpressoIdeDetectionPath; + + QTest::newRow("armgcc_mimxrt1064_evk_freertos_json mcuXpresso") + << armgcc_mimxrt1064_evk_freertos_json << xpressoIdePath << xpressoIdePath + << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel + << xpressoIdeDetectionPath; + + QTest::newRow("armgcc_mimxrt1170_evk_freertos_json mcuXpresso") + << armgcc_mimxrt1170_evk_freertos_json << xpressoIdePath << xpressoIdePath + << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel + << xpressoIdeDetectionPath; + + QTest::newRow("armgcc_stm32h750b_discovery_baremetal_json stmCubeProgrammer") + << armgcc_stm32h750b_discovery_baremetal_json << stmCubeProgrammerPath + << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty + << stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath; + + QTest::newRow("armgcc_stm32f769i_discovery_freertos_json stmCubeProgrammer") + << armgcc_stm32f769i_discovery_freertos_json << stmCubeProgrammerPath + << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty + << stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath; + + QTest::newRow("ghs_rh850_d1m1a_baremetal_json renesasProgrammer") + << ghs_rh850_d1m1a_baremetal_json << renesasProgrammerDefaultPath << empty + << "FlashProgrammerPath" << renesasProgrammerCmakeVar << "RenesasFlashProgrammer_PATH" + << renesasProgrammerLabel << renesasProgrammerDetectionPath; } void McuSupportTest::test_createThirdPartyPackage() diff --git a/src/plugins/projectexplorer/buildmanager.cpp b/src/plugins/projectexplorer/buildmanager.cpp index 28169513cb7..888cc7f14df 100644 --- a/src/plugins/projectexplorer/buildmanager.cpp +++ b/src/plugins/projectexplorer/buildmanager.cpp @@ -61,7 +61,9 @@ static const QList targetsForSelection(const Project *project, { if (targetSelection == ConfigSelection::All) return project->targets(); - return {project->activeTarget()}; + if (project->activeTarget()) + return {project->activeTarget()}; + return {}; } static const QList buildConfigsForSelection(const Target *target, diff --git a/tests/system/suite_general/tst_opencreator_qbs/test.py b/tests/system/suite_general/tst_opencreator_qbs/test.py index ca941547c90..6ff692d41cf 100644 --- a/tests/system/suite_general/tst_opencreator_qbs/test.py +++ b/tests/system/suite_general/tst_opencreator_qbs/test.py @@ -25,8 +25,8 @@ def main(): test.warning("Parsing project timed out") compareProjectTree(rootNodeTemplate % "Qt Creator", "projecttree_creator.tsv") buildIssuesTexts = map(lambda i: str(i[0]), getBuildIssues()) - deprecationWarnings = filter(lambda s: "deprecated" in s, buildIssuesTexts) + deprecationWarnings = "\n".join(set(filter(lambda s: "deprecated" in s, buildIssuesTexts))) if deprecationWarnings: test.warning("Creator claims that the .qbs file uses deprecated features.", - "\n".join(set(deprecationWarnings))) + deprecationWarnings) invokeMenuItem("File", "Exit")