diff --git a/share/qtcreator/themes/dark.creatortheme b/share/qtcreator/themes/dark.creatortheme
index 1b15cd2db55..545d662548c 100644
--- a/share/qtcreator/themes/dark.creatortheme
+++ b/share/qtcreator/themes/dark.creatortheme
@@ -176,7 +176,7 @@ Timeline_RangeColor=selectedBackground
VcsBase_FileStatusUnknown_TextColor=text
VcsBase_FileAdded_TextColor=ff00ff00
VcsBase_FileModified_TextColor=ff8ee0ff
-VcsBase_FileDeleted_TextColor=fffff6c6c
+VcsBase_FileDeleted_TextColor=ffff6c6c
VcsBase_FileRenamed_TextColor=ffffa500
VcsBase_FileUnmerged_TextColor=ffff4040
diff --git a/share/qtcreator/translations/qtcreator_ru.ts b/share/qtcreator/translations/qtcreator_ru.ts
index c215f4ba9d4..7c0d2dfd5eb 100644
--- a/share/qtcreator/translations/qtcreator_ru.ts
+++ b/share/qtcreator/translations/qtcreator_ru.ts
@@ -35841,7 +35841,7 @@ For more details, see /etc/sysctl.d/10-ptrace.conf
No compiler can produce code for this Qt version. Please define one or more compilers for: %1
- Компилятор не может создавть код для этого профиля Qt. Задайте минимум один компилятор для: %1
+ Компилятор не может создавать код для этого профиля Qt. Задайте минимум один компилятор для: %1
The following ABIs are currently not supported: %1
diff --git a/src/plugins/cpptools/compileroptionsbuilder.cpp b/src/plugins/cpptools/compileroptionsbuilder.cpp
index 9f11c02bb95..8164009bf1c 100644
--- a/src/plugins/cpptools/compileroptionsbuilder.cpp
+++ b/src/plugins/cpptools/compileroptionsbuilder.cpp
@@ -473,18 +473,13 @@ bool CompilerOptionsBuilder::excludeDefineDirective(const ProjectExplorer::Macro
bool CompilerOptionsBuilder::excludeHeaderPath(const QString &headerPath) const
{
- // A clang tool chain might have another version and passing in the
- // intrinsics path from that version will lead to errors (unknown
- // intrinsics, unfavorable order with regard to include_next).
- if (m_projectPart.toolchainType == ProjectExplorer::Constants::CLANG_TOOLCHAIN_TYPEID) {
- if (headerPath.contains("lib/gcc/i686-apple-darwin"))
- return true;
- static QRegularExpression clangIncludeDir(
- QLatin1String("\\A.*/lib/clang/\\d+\\.\\d+(\\.\\d+)?/include\\z"));
- return clangIncludeDir.match(headerPath).hasMatch();
- }
-
- return false;
+ // Always exclude clang system includes (including intrinsics) which do not come with libclang
+ // that Qt Creator uses for code model.
+ // For example GCC on macOS uses system clang include path which makes clang code model
+ // include incorrect system headers.
+ static QRegularExpression clangIncludeDir(
+ QLatin1String("\\A.*/lib/clang/\\d+\\.\\d+(\\.\\d+)?/include\\z"));
+ return clangIncludeDir.match(headerPath).hasMatch();
}
void CompilerOptionsBuilder::addPredefinedHeaderPathsOptions()
diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp
index ed06951a330..42a3d1e4619 100644
--- a/src/plugins/debugger/gdb/gdbengine.cpp
+++ b/src/plugins/debugger/gdb/gdbengine.cpp
@@ -3949,14 +3949,22 @@ void GdbEngine::loadInitScript()
void GdbEngine::setEnvironmentVariables()
{
+ auto isWindowsPath = [this](const QString &str){
+ return HostOsInfo::isWindowsHost()
+ && !isRemoteEngine()
+ && str.compare("path", Qt::CaseInsensitive) == 0;
+ };
+
Environment sysEnv = Environment::systemEnvironment();
Environment runEnv = runParameters().inferior.environment;
foreach (const EnvironmentItem &item, sysEnv.diff(runEnv)) {
+ // imitate the weird windows gdb behavior of setting the case of the path environment
+ // variable name to an all uppercase PATH
+ const QString name = isWindowsPath(item.name) ? "PATH" : item.name;
if (item.operation == EnvironmentItem::Unset)
- runCommand({"unset environment " + item.name});
+ runCommand({"unset environment " + name});
else
- runCommand({"-gdb-set environment " + item.name + '='
- + item.value});
+ runCommand({"-gdb-set environment " + name + '=' + item.value});
}
}
diff --git a/src/plugins/git/gerrit/gerritplugin.cpp b/src/plugins/git/gerrit/gerritplugin.cpp
index e085ab8d963..be3e390318e 100644
--- a/src/plugins/git/gerrit/gerritplugin.cpp
+++ b/src/plugins/git/gerrit/gerritplugin.cpp
@@ -331,6 +331,11 @@ void GerritPlugin::push(const QString &topLevel)
GitPlugin::client()->push(topLevel, {dialog.selectedRemoteName(), dialog.pushTarget()});
}
+static QString currentRepository()
+{
+ return GitPlugin::instance()->currentState().topLevel();
+}
+
// Open or raise the Gerrit dialog window.
void GerritPlugin::openView()
{
@@ -341,8 +346,7 @@ void GerritPlugin::openView()
if (!ICore::showOptionsDialog("Gerrit"))
return;
}
- const QString repository = GitPlugin::instance()->currentState().topLevel();
- GerritDialog *gd = new GerritDialog(m_parameters, m_server, repository, ICore::mainWindow());
+ GerritDialog *gd = new GerritDialog(m_parameters, m_server, currentRepository(), ICore::mainWindow());
gd->setModal(false);
connect(gd, &GerritDialog::fetchDisplay, this,
[this](const QSharedPointer &change) { fetch(change, FetchDisplay); });
@@ -354,6 +358,7 @@ void GerritPlugin::openView()
connect(this, &GerritPlugin::fetchFinished, gd, &GerritDialog::fetchFinished);
m_dialog = gd;
} else {
+ m_dialog->setCurrentPath(currentRepository());
m_dialog->refresh();
}
const Qt::WindowStates state = m_dialog->windowState();
@@ -365,7 +370,7 @@ void GerritPlugin::openView()
void GerritPlugin::push()
{
- push(GitPlugin::instance()->currentState().topLevel());
+ push(currentRepository());
}
Utils::FileName GerritPlugin::gitBinDirectory()
diff --git a/src/plugins/projectexplorer/extracompiler.cpp b/src/plugins/projectexplorer/extracompiler.cpp
index ab020004404..1d5e97add91 100644
--- a/src/plugins/projectexplorer/extracompiler.cpp
+++ b/src/plugins/projectexplorer/extracompiler.cpp
@@ -80,9 +80,6 @@ ExtraCompiler::ExtraCompiler(const Project *project, const Utils::FileName &sour
d->contents.insert(target, QByteArray());
d->timer.setSingleShot(true);
- connect(d->project, &Project::activeTargetChanged, this, &ExtraCompiler::onActiveTargetChanged);
- onActiveTargetChanged();
-
connect(&d->timer, &QTimer::timeout, this, [this](){
if (d->dirty && d->lastEditor) {
d->dirty = false;
@@ -254,41 +251,6 @@ void ExtraCompiler::onEditorAboutToClose(Core::IEditor *editor)
d->lastEditor = nullptr;
}
-void ExtraCompiler::onActiveTargetChanged()
-{
- disconnect(d->activeBuildConfigConnection);
- if (Target *target = d->project->activeTarget()) {
- d->activeBuildConfigConnection = connect(
- target, &Target::activeBuildConfigurationChanged,
- this, &ExtraCompiler::onActiveBuildConfigurationChanged);
- onActiveBuildConfigurationChanged();
- } else {
- disconnect(d->activeEnvironmentConnection);
- setDirty();
- }
-}
-
-void ExtraCompiler::onActiveBuildConfigurationChanged()
-{
- disconnect(d->activeEnvironmentConnection);
- Target *target = d->project->activeTarget();
- QTC_ASSERT(target, return);
- if (BuildConfiguration *bc = target->activeBuildConfiguration()) {
- d->activeEnvironmentConnection = connect(
- bc, &BuildConfiguration::environmentChanged,
- this, &ExtraCompiler::setDirty);
- } else {
- d->activeEnvironmentConnection = connect(KitManager::instance(), &KitManager::kitUpdated,
- this, [this](Kit *kit) {
- Target *target = d->project->activeTarget();
- QTC_ASSERT(target, return);
- if (kit == target->kit())
- setDirty();
- });
- }
- setDirty();
-}
-
Utils::Environment ExtraCompiler::buildEnvironment() const
{
if (Target *target = project()->activeTarget()) {
diff --git a/src/plugins/projectexplorer/extracompiler.h b/src/plugins/projectexplorer/extracompiler.h
index 67cccc60f4d..e69d4b3ca81 100644
--- a/src/plugins/projectexplorer/extracompiler.h
+++ b/src/plugins/projectexplorer/extracompiler.h
@@ -84,8 +84,6 @@ private:
void onTargetsBuilt(Project *project);
void onEditorChanged(Core::IEditor *editor);
void onEditorAboutToClose(Core::IEditor *editor);
- void onActiveTargetChanged();
- void onActiveBuildConfigurationChanged();
void setDirty();
// This method may not block!
virtual void run(const QByteArray &sourceContent) = 0;
diff --git a/src/plugins/qbsprojectmanager/qbsproject.cpp b/src/plugins/qbsprojectmanager/qbsproject.cpp
index 1e4944b3c1d..1a631027bf2 100644
--- a/src/plugins/qbsprojectmanager/qbsproject.cpp
+++ b/src/plugins/qbsprojectmanager/qbsproject.cpp
@@ -125,7 +125,6 @@ QbsProject::QbsProject(const FileName &fileName) :
m_parsingScheduled(false),
m_cancelStatus(CancelStatusNone),
m_cppCodeModelUpdater(new CppTools::CppProjectUpdater(this)),
- m_currentBc(0),
m_extraCompilersPending(false)
{
m_parsingDelay.setInterval(1000); // delay parsing by 1s.
@@ -146,6 +145,7 @@ QbsProject::QbsProject(const FileName &fileName) :
};
subscribeSignal(&BuildConfiguration::environmentChanged, this, delayedParsing);
subscribeSignal(&BuildConfiguration::buildDirectoryChanged, this, delayedParsing);
+ subscribeSignal(&QbsBuildConfiguration::qbsConfigurationChanged, this, delayedParsing);
subscribeSignal(&Target::activeBuildConfigurationChanged, this, delayedParsing);
connect(&m_parsingDelay, &QTimer::timeout, this, &QbsProject::startParsing);
@@ -331,11 +331,6 @@ bool QbsProject::renameFileInProduct(const QString &oldPath, const QString &newP
return addFilesToProduct(QStringList() << newPath, newProductData, newGroupData, &dummy);
}
-void QbsProject::invalidate()
-{
- prepareForParsing();
-}
-
static qbs::AbstractJob *doBuildOrClean(const qbs::Project &project,
const QList &products,
const qbs::BuildOptions &options)
@@ -534,29 +529,8 @@ void QbsProject::handleRuleExecutionDone()
void QbsProject::changeActiveTarget(Target *t)
{
- BuildConfiguration *bc = 0;
- if (t) {
+ if (t)
m_qbsProject = m_qbsProjects.value(t);
- if (t->kit())
- bc = t->activeBuildConfiguration();
- }
- buildConfigurationChanged(bc);
-}
-
-void QbsProject::buildConfigurationChanged(BuildConfiguration *bc)
-{
- if (m_currentBc)
- disconnect(m_currentBc, &QbsBuildConfiguration::qbsConfigurationChanged,
- this, &QbsProject::delayParsing);
-
- m_currentBc = qobject_cast(bc);
- if (m_currentBc) {
- connect(m_currentBc, &QbsBuildConfiguration::qbsConfigurationChanged,
- this, &QbsProject::delayParsing);
- delayParsing();
- } else {
- invalidate();
- }
}
void QbsProject::startParsing()
diff --git a/src/plugins/qbsprojectmanager/qbsproject.h b/src/plugins/qbsprojectmanager/qbsproject.h
index 8af4ef51490..45befb2e675 100644
--- a/src/plugins/qbsprojectmanager/qbsproject.h
+++ b/src/plugins/qbsprojectmanager/qbsproject.h
@@ -107,7 +107,6 @@ public:
void configureAsExampleProject(const QSet &platforms) final;
- void invalidate();
void delayParsing();
private:
@@ -116,7 +115,6 @@ private:
void rebuildProjectTree();
void changeActiveTarget(ProjectExplorer::Target *t);
- void buildConfigurationChanged(ProjectExplorer::BuildConfiguration *bc);
void startParsing();
void parse(const QVariantMap &config, const Utils::Environment &env, const QString &dir,
@@ -165,7 +163,6 @@ private:
CppTools::CppProjectUpdater *m_cppCodeModelUpdater = nullptr;
CppTools::ProjectInfo m_cppCodeModelProjectInfo;
- QbsBuildConfiguration *m_currentBc;
mutable ProjectExplorer::ProjectImporter *m_importer = nullptr;
QTimer m_parsingDelay;
diff --git a/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp b/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp
index 43e54dda238..c49277abf7d 100644
--- a/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp
@@ -57,6 +57,12 @@ void QmlProfilerClientManager::setFlushInterval(quint32 flushInterval)
m_flushInterval = flushInterval;
}
+void QmlProfilerClientManager::clearEvents()
+{
+ if (m_clientPlugin)
+ m_clientPlugin->clearEvents();
+}
+
void QmlProfilerClientManager::clearBufferedData()
{
if (m_clientPlugin)
diff --git a/src/plugins/qmlprofiler/qmlprofilerclientmanager.h b/src/plugins/qmlprofiler/qmlprofilerclientmanager.h
index 8f3c8f668be..8946b595160 100644
--- a/src/plugins/qmlprofiler/qmlprofilerclientmanager.h
+++ b/src/plugins/qmlprofiler/qmlprofilerclientmanager.h
@@ -46,6 +46,7 @@ class QmlProfilerClientManager : public QmlDebug::QmlDebugConnectionManager
public:
explicit QmlProfilerClientManager(QObject *parent = 0);
void setProfilerStateManager(QmlProfilerStateManager *profilerState);
+ void clearEvents();
void setModelManager(QmlProfilerModelManager *modelManager);
void setFlushInterval(quint32 flushInterval);
void clearBufferedData();
diff --git a/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp b/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp
index a7566fd2c05..f64e3c99789 100644
--- a/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp
@@ -691,9 +691,8 @@ QmlProfilerModelManager::State QmlProfilerModelManager::state() const
return d->state;
}
-void QmlProfilerModelManager::clear()
+void QmlProfilerModelManager::doClearEvents()
{
- setState(ClearingData);
d->numLoadedEvents = 0;
d->numFinishedFinalizers = 0;
d->file.remove();
@@ -702,13 +701,25 @@ void QmlProfilerModelManager::clear()
d->eventStream.setDevice(&d->file);
else
emit error(tr("Cannot open temporary trace file to store events."));
- d->eventTypes.clear();
- d->detailsRewriter->clear();
d->traceTime->clear();
d->notesModel->clear();
setVisibleFeatures(0);
setRecordedFeatures(0);
+}
+void QmlProfilerModelManager::clearEvents()
+{
+ setState(ClearingData);
+ doClearEvents();
+ setState(Empty);
+}
+
+void QmlProfilerModelManager::clear()
+{
+ setState(ClearingData);
+ doClearEvents();
+ d->eventTypes.clear();
+ d->detailsRewriter->clear();
setState(Empty);
}
diff --git a/src/plugins/qmlprofiler/qmlprofilermodelmanager.h b/src/plugins/qmlprofiler/qmlprofilermodelmanager.h
index f5fb7158223..576d5f87f17 100644
--- a/src/plugins/qmlprofiler/qmlprofilermodelmanager.h
+++ b/src/plugins/qmlprofiler/qmlprofilermodelmanager.h
@@ -134,6 +134,7 @@ public:
static const char *featureName(ProfileFeature feature);
+ void clearEvents();
void clear();
void restrictToRange(qint64 startTime, qint64 endTime);
bool isRestrictedToRange() const;
@@ -156,6 +157,7 @@ signals:
private:
void setState(State state);
void detailsChanged(int typeId, const QString &newString);
+ void doClearEvents();
class QmlProfilerModelManagerPrivate;
QmlProfilerModelManagerPrivate *d;
diff --git a/src/plugins/qmlprofiler/qmlprofilertool.cpp b/src/plugins/qmlprofiler/qmlprofilertool.cpp
index 4c6c72dbe3b..99c2cf12860 100644
--- a/src/plugins/qmlprofiler/qmlprofilertool.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilertool.cpp
@@ -44,6 +44,7 @@
#include
#include
#include
+#include
#include
#include
#include
@@ -406,7 +407,7 @@ void QmlProfilerTool::recordingButtonChanged(bool recording)
if (checkForUnsavedNotes()) {
if (!d->m_profilerModelManager->aggregateTraces() ||
d->m_profilerModelManager->state() == QmlProfilerModelManager::Done)
- clearData(); // clear before the recording starts, unless we aggregate recordings
+ clearEvents(); // clear before the recording starts, unless we aggregate recordings
if (d->m_profilerState->clientRecording())
d->m_profilerState->setClientRecording(false);
d->m_profilerState->setClientRecording(true);
@@ -471,6 +472,13 @@ void QmlProfilerTool::showTimeLineSearch()
Core::Find::openFindToolBar(Core::Find::FindForwardDirection);
}
+void QmlProfilerTool::clearEvents()
+{
+ d->m_profilerModelManager->clearEvents();
+ d->m_profilerConnections->clearEvents();
+ setRecordedFeatures(0);
+}
+
void QmlProfilerTool::clearData()
{
d->m_profilerModelManager->clear();
@@ -555,6 +563,7 @@ void QmlProfilerTool::attachToWaitingApplication()
IDevice::ConstPtr device = DeviceKitInformation::device(kit);
QTC_ASSERT(device, return);
QUrl toolControl = device->toolControlChannel(IDevice::QmlControlChannel);
+ serverUrl.setScheme(Utils::urlTcpScheme());
serverUrl.setHost(toolControl.host());
serverUrl.setPort(port);
@@ -565,6 +574,8 @@ void QmlProfilerTool::attachToWaitingApplication()
auto profiler = new QmlProfilerRunner(runControl);
profiler->setServerUrl(serverUrl);
+ connect(d->m_profilerConnections, &QmlProfilerClientManager::connectionClosed,
+ runControl, &RunControl::initiateStop);
ProjectExplorerPlugin::startRunControl(runControl);
}
@@ -858,7 +869,7 @@ void QmlProfilerTool::serverRecordingChanged()
d->m_recordingElapsedTime.start();
if (!d->m_profilerModelManager->aggregateTraces() ||
d->m_profilerModelManager->state() == QmlProfilerModelManager::Done)
- clearData();
+ clearEvents();
d->m_profilerModelManager->startAcquiring();
} else {
d->m_recordingTimer.stop();
diff --git a/src/plugins/qmlprofiler/qmlprofilertool.h b/src/plugins/qmlprofiler/qmlprofilertool.h
index 4b784dfe8e1..334e51aeed2 100644
--- a/src/plugins/qmlprofiler/qmlprofilertool.h
+++ b/src/plugins/qmlprofiler/qmlprofilertool.h
@@ -74,6 +74,7 @@ public:
void gotoSourceLocation(const QString &fileUrl, int lineNumber, int columnNumber);
private:
+ void clearEvents();
void clearData();
void showErrorDialog(const QString &error);
void profilerDataModelStateChanged();
diff --git a/src/plugins/qmlprofiler/qmlprofilertraceclient.cpp b/src/plugins/qmlprofiler/qmlprofilertraceclient.cpp
index 31c664e5c78..6c859423d8e 100644
--- a/src/plugins/qmlprofiler/qmlprofilertraceclient.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilertraceclient.cpp
@@ -227,10 +227,8 @@ QmlProfilerTraceClient::~QmlProfilerTraceClient()
delete d;
}
-void QmlProfilerTraceClient::clear()
+void QmlProfilerTraceClient::clearEvents()
{
- d->serverTypeIds.clear();
- d->eventTypeIds.clear();
d->rangesInProgress.clear();
d->pendingMessages.clear();
d->pendingDebugMessages.clear();
@@ -241,6 +239,13 @@ void QmlProfilerTraceClient::clear()
emit cleared();
}
+void QmlProfilerTraceClient::clear()
+{
+ d->eventTypeIds.clear();
+ d->serverTypeIds.clear();
+ clearEvents();
+}
+
void QmlProfilerTraceClient::sendRecordingStatus(int engineId)
{
d->sendRecordingStatus(engineId);
diff --git a/src/plugins/qmlprofiler/qmlprofilertraceclient.h b/src/plugins/qmlprofiler/qmlprofilertraceclient.h
index b71324e21e9..91fb6038b73 100644
--- a/src/plugins/qmlprofiler/qmlprofilertraceclient.h
+++ b/src/plugins/qmlprofiler/qmlprofilertraceclient.h
@@ -55,6 +55,7 @@ public:
virtual void messageReceived(const QByteArray &) override;
virtual void stateChanged(State status) override;
+ void clearEvents();
void clear();
void sendRecordingStatus(int engineId = -1);
void setRequestedFeatures(quint64 features);
diff --git a/src/tools/tools.pro b/src/tools/tools.pro
index 98515b497aa..cce61a59a7f 100644
--- a/src/tools/tools.pro
+++ b/src/tools/tools.pro
@@ -2,11 +2,12 @@ TEMPLATE = subdirs
SUBDIRS = qtpromaker \
../plugins/cpaster/frontend \
- sdktool \
valgrindfake \
3rdparty \
buildoutputparser
+isEmpty(QTC_SKIP_SDKTOOL): SUBDIRS += sdktool
+
qtHaveModule(quick-private): SUBDIRS += qml2puppet
win32 {
diff --git a/tests/system/suite_general/tst_cmake_speedcrunch/test.py b/tests/system/suite_general/tst_cmake_speedcrunch/test.py
index 6801d7c7834..fdfbd1f0651 100644
--- a/tests/system/suite_general/tst_cmake_speedcrunch/test.py
+++ b/tests/system/suite_general/tst_cmake_speedcrunch/test.py
@@ -68,16 +68,13 @@ def main():
treeFile = "projecttree_speedcrunch.tsv"
compareProjectTree(naviTreeView % "speedcrunch( \[\S+\])?", treeFile)
- if not cmakeSupportsServerMode() and JIRA.isBugStillOpen(18290):
- test.xfail("Building with cmake in Tealeafreader mode may fail", "QTCREATORBUG-18290")
- else:
- # Invoke a rebuild of the application
- invokeMenuItem("Build", "Rebuild All")
+ # Invoke a rebuild of the application
+ invokeMenuItem("Build", "Rebuild All")
- # Wait for, and test if the build succeeded
- waitForCompile(300000)
- checkCompile()
- checkLastBuild()
+ # Wait for, and test if the build succeeded
+ waitForCompile(300000)
+ checkCompile()
+ checkLastBuild()
invokeMenuItem("File", "Exit")