aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/plugins/compilationdatabaseprojectmanager/compilationdatabaseproject.cpp5
-rw-r--r--src/plugins/cpptools/CMakeLists.txt1
-rw-r--r--src/plugins/cpptools/cppkitinfo.cpp64
-rw-r--r--src/plugins/cpptools/cppkitinfo.h56
-rw-r--r--src/plugins/cpptools/cppprojectinfogenerator.cpp7
-rw-r--r--src/plugins/cpptools/cppprojectinfogenerator.h4
-rw-r--r--src/plugins/cpptools/cppprojectupdater.cpp2
-rw-r--r--src/plugins/cpptools/cppprojectupdater.h5
-rw-r--r--src/plugins/cpptools/cpptools.pro4
-rw-r--r--src/plugins/cpptools/cpptools.qbs2
-rw-r--r--src/plugins/cpptools/projectinfo.cpp38
-rw-r--r--src/plugins/cpptools/projectinfo.h44
-rw-r--r--src/plugins/projectexplorer/rawprojectpart.cpp62
-rw-r--r--src/plugins/projectexplorer/rawprojectpart.h68
-rw-r--r--src/plugins/qtsupport/qtcppkitinfo.cpp4
-rw-r--r--src/plugins/qtsupport/qtcppkitinfo.h4
-rw-r--r--tests/unit/unittest/cppprojectinfogenerator-test.cpp2
17 files changed, 147 insertions, 225 deletions
diff --git a/src/plugins/compilationdatabaseprojectmanager/compilationdatabaseproject.cpp b/src/plugins/compilationdatabaseprojectmanager/compilationdatabaseproject.cpp
index 4d763e333f..ec16d72bd5 100644
--- a/src/plugins/compilationdatabaseprojectmanager/compilationdatabaseproject.cpp
+++ b/src/plugins/compilationdatabaseprojectmanager/compilationdatabaseproject.cpp
@@ -29,7 +29,6 @@
#include "compilationdbparser.h"
#include <coreplugin/icontext.h>
-#include <cpptools/cppkitinfo.h>
#include <cpptools/cppprojectupdater.h>
#include <cpptools/projectinfo.h>
#include <projectexplorer/buildinfo.h>
@@ -170,7 +169,7 @@ void addDriverModeFlagIfNeeded(const ToolChain *toolchain,
RawProjectPart makeRawProjectPart(const Utils::FilePath &projectFile,
Kit *kit,
- CppTools::KitInfo &kitInfo,
+ ProjectExplorer::KitInfo &kitInfo,
const QString &workingDir,
const Utils::FilePath &fileName,
QStringList flags)
@@ -338,7 +337,7 @@ void createTree(std::unique_ptr<ProjectNode> &root,
void CompilationDatabaseProject::buildTreeAndProjectParts()
{
- CppTools::KitInfo kitInfo(this);
+ ProjectExplorer::KitInfo kitInfo(this);
QTC_ASSERT(kitInfo.isValid(), return);
// Reset toolchains to pick them based on the database entries.
kitInfo.cToolChain = nullptr;
diff --git a/src/plugins/cpptools/CMakeLists.txt b/src/plugins/cpptools/CMakeLists.txt
index 0908442f8b..ea1ff7a7d9 100644
--- a/src/plugins/cpptools/CMakeLists.txt
+++ b/src/plugins/cpptools/CMakeLists.txt
@@ -48,7 +48,6 @@ add_qtc_plugin(CppTools
cpphoverhandler.cpp cpphoverhandler.h
cppincludesfilter.cpp cppincludesfilter.h
cppindexingsupport.cpp cppindexingsupport.h
- cppkitinfo.cpp cppkitinfo.h
cpplocalsymbols.cpp cpplocalsymbols.h
cpplocatordata.cpp cpplocatordata.h
cpplocatorfilter.cpp cpplocatorfilter.h
diff --git a/src/plugins/cpptools/cppkitinfo.cpp b/src/plugins/cpptools/cppkitinfo.cpp
deleted file mode 100644
index e57a4dbd73..0000000000
--- a/src/plugins/cpptools/cppkitinfo.cpp
+++ /dev/null
@@ -1,64 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2019 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of Qt Creator.
-**
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3 as published by the Free Software
-** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
-** included in the packaging of this file. Please review the following
-** information to ensure the GNU General Public License requirements will
-** be met: https://www.gnu.org/licenses/gpl-3.0.html.
-**
-****************************************************************************/
-
-#include "cppkitinfo.h"
-
-#include <projectexplorer/kit.h>
-#include <projectexplorer/kitinformation.h>
-#include <projectexplorer/kitmanager.h>
-#include <projectexplorer/project.h>
-#include <projectexplorer/projectexplorerconstants.h>
-#include <projectexplorer/target.h>
-
-#include <qtsupport/qtkitinformation.h>
-
-namespace CppTools {
-
-using namespace ProjectExplorer;
-
-KitInfo::KitInfo(Project *project)
-{
- // Kit
- if (Target *target = project->activeTarget())
- kit = target->kit();
- else
- kit = KitManager::defaultKit();
-
- // Toolchains
- if (kit) {
- cToolChain = ToolChainKitAspect::toolChain(kit, Constants::C_LANGUAGE_ID);
- cxxToolChain = ToolChainKitAspect::toolChain(kit, Constants::CXX_LANGUAGE_ID);
- }
-
- // Sysroot
- sysRootPath = ProjectExplorer::SysRootKitAspect::sysRoot(kit).toString();
-}
-
-bool KitInfo::isValid() const
-{
- return kit;
-}
-
-} // namespace CppTools
diff --git a/src/plugins/cpptools/cppkitinfo.h b/src/plugins/cpptools/cppkitinfo.h
deleted file mode 100644
index a3033c62af..0000000000
--- a/src/plugins/cpptools/cppkitinfo.h
+++ /dev/null
@@ -1,56 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2019 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of Qt Creator.
-**
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3 as published by the Free Software
-** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
-** included in the packaging of this file. Please review the following
-** information to ensure the GNU General Public License requirements will
-** be met: https://www.gnu.org/licenses/gpl-3.0.html.
-**
-****************************************************************************/
-
-#pragma once
-
-#include <projectexplorer/rawprojectpart.h>
-
-#include "cpptools_global.h"
-
-namespace ProjectExplorer {
-class Kit;
-class Project;
-class ToolChain;
-} // namespace ProjectExplorer
-
-namespace CppTools {
-
-class CPPTOOLS_EXPORT KitInfo
-{
-public:
- explicit KitInfo(ProjectExplorer::Project *project);
-
- bool isValid() const;
-
- ProjectExplorer::Kit *kit = nullptr;
- ProjectExplorer::ToolChain *cToolChain = nullptr;
- ProjectExplorer::ToolChain *cxxToolChain = nullptr;
-
- Utils::QtVersion projectPartQtVersion = Utils::QtVersion::None;
-
- QString sysRootPath;
-};
-
-} // namespace CppTools
diff --git a/src/plugins/cpptools/cppprojectinfogenerator.cpp b/src/plugins/cpptools/cppprojectinfogenerator.cpp
index 28b953389e..c013e62566 100644
--- a/src/plugins/cpptools/cppprojectinfogenerator.cpp
+++ b/src/plugins/cpptools/cppprojectinfogenerator.cpp
@@ -35,8 +35,9 @@
namespace CppTools {
namespace Internal {
-ProjectInfoGenerator::ProjectInfoGenerator(const QFutureInterface<void> &futureInterface,
- const ProjectUpdateInfo &projectUpdateInfo)
+ProjectInfoGenerator::ProjectInfoGenerator(
+ const QFutureInterface<void> &futureInterface,
+ const ProjectExplorer::ProjectUpdateInfo &projectUpdateInfo)
: m_futureInterface(futureInterface)
, m_projectUpdateInfo(projectUpdateInfo)
{
@@ -147,7 +148,7 @@ ProjectPart::Ptr ProjectInfoGenerator::createProjectPart(
Utils::LanguageExtensions languageExtensions)
{
ProjectExplorer::RawProjectPartFlags flags;
- ToolChainInfo tcInfo;
+ ProjectExplorer::ToolChainInfo tcInfo;
if (language == Language::C) {
flags = rawProjectPart.flagsForC;
tcInfo = m_projectUpdateInfo.cToolChainInfo;
diff --git a/src/plugins/cpptools/cppprojectinfogenerator.h b/src/plugins/cpptools/cppprojectinfogenerator.h
index 1a0535ac2d..2dbc4cd2fa 100644
--- a/src/plugins/cpptools/cppprojectinfogenerator.h
+++ b/src/plugins/cpptools/cppprojectinfogenerator.h
@@ -37,7 +37,7 @@ class ProjectInfoGenerator
{
public:
ProjectInfoGenerator(const QFutureInterface<void> &futureInterface,
- const ProjectUpdateInfo &projectUpdateInfo);
+ const ProjectExplorer::ProjectUpdateInfo &projectUpdateInfo);
ProjectInfo generate();
@@ -53,7 +53,7 @@ private:
private:
const QFutureInterface<void> m_futureInterface;
- const ProjectUpdateInfo &m_projectUpdateInfo;
+ const ProjectExplorer::ProjectUpdateInfo &m_projectUpdateInfo;
};
} // namespace Internal
} // namespace CppTools
diff --git a/src/plugins/cpptools/cppprojectupdater.cpp b/src/plugins/cpptools/cppprojectupdater.cpp
index 23842f15f3..342db21265 100644
--- a/src/plugins/cpptools/cppprojectupdater.cpp
+++ b/src/plugins/cpptools/cppprojectupdater.cpp
@@ -46,7 +46,7 @@ CppProjectUpdater::~CppProjectUpdater()
cancelAndWaitForFinished();
}
-void CppProjectUpdater::update(const ProjectUpdateInfo &projectUpdateInfo)
+void CppProjectUpdater::update(const ProjectExplorer::ProjectUpdateInfo &projectUpdateInfo)
{
// Stop previous update.
cancelAndWaitForFinished();
diff --git a/src/plugins/cpptools/cppprojectupdater.h b/src/plugins/cpptools/cppprojectupdater.h
index 65eb1522a1..460cf707fb 100644
--- a/src/plugins/cpptools/cppprojectupdater.h
+++ b/src/plugins/cpptools/cppprojectupdater.h
@@ -34,7 +34,6 @@
namespace CppTools {
class ProjectInfo;
-class ProjectUpdateInfo;
class CPPTOOLS_EXPORT CppProjectUpdater : public QObject
{
@@ -44,7 +43,7 @@ public:
CppProjectUpdater();
~CppProjectUpdater() override;
- void update(const ProjectUpdateInfo &projectUpdateInfo);
+ void update(const ProjectExplorer::ProjectUpdateInfo &projectUpdateInfo);
void cancel();
private:
@@ -54,7 +53,7 @@ private:
void onProjectInfoGenerated();
private:
- ProjectUpdateInfo m_projectUpdateInfo;
+ ProjectExplorer::ProjectUpdateInfo m_projectUpdateInfo;
QFutureInterface<void> m_futureInterface;
QFutureWatcher<ProjectInfo> m_generateFutureWatcher;
diff --git a/src/plugins/cpptools/cpptools.pro b/src/plugins/cpptools/cpptools.pro
index b8b625845a..7ca9a8bc6f 100644
--- a/src/plugins/cpptools/cpptools.pro
+++ b/src/plugins/cpptools/cpptools.pro
@@ -103,7 +103,6 @@ HEADERS += \
cppmodelmanagerinterface.h \
cppbuiltinmodelmanagersupport.h \
headerpathfilter.h \
- cppkitinfo.h \
cpptools_clazychecks.h
SOURCES += \
@@ -190,8 +189,7 @@ SOURCES += \
cppprojectpartchooser.cpp \
wrappablelineedit.cpp \
cppbuiltinmodelmanagersupport.cpp \
- headerpathfilter.cpp \
- cppkitinfo.cpp
+ headerpathfilter.cpp
FORMS += \
clangdiagnosticconfigswidget.ui \
diff --git a/src/plugins/cpptools/cpptools.qbs b/src/plugins/cpptools/cpptools.qbs
index 26ed1c1181..ddbc9d8375 100644
--- a/src/plugins/cpptools/cpptools.qbs
+++ b/src/plugins/cpptools/cpptools.qbs
@@ -116,8 +116,6 @@ Project {
"cppincludesfilter.h",
"cppindexingsupport.cpp",
"cppindexingsupport.h",
- "cppkitinfo.cpp",
- "cppkitinfo.h",
"cpplocalsymbols.cpp",
"cpplocalsymbols.h",
"cpplocatordata.cpp",
diff --git a/src/plugins/cpptools/projectinfo.cpp b/src/plugins/cpptools/projectinfo.cpp
index 9c6428f258..a7047dc972 100644
--- a/src/plugins/cpptools/projectinfo.cpp
+++ b/src/plugins/cpptools/projectinfo.cpp
@@ -25,48 +25,14 @@
#include "projectinfo.h"
-#include "cppkitinfo.h"
-
#include <projectexplorer/abi.h>
-#include <projectexplorer/toolchain.h>
#include <projectexplorer/kitinformation.h>
#include <projectexplorer/projectexplorerconstants.h>
+#include <projectexplorer/rawprojectpart.h>
+#include <projectexplorer/toolchain.h>
namespace CppTools {
-ToolChainInfo::ToolChainInfo(const ProjectExplorer::ToolChain *toolChain,
- const QString &sysRootPath, const Utils::Environment &env)
-{
- if (toolChain) {
- // Keep the following cheap/non-blocking for the ui thread...
- type = toolChain->typeId();
- isMsvc2015ToolChain
- = toolChain->targetAbi().osFlavor() == ProjectExplorer::Abi::WindowsMsvc2015Flavor;
- wordWidth = toolChain->targetAbi().wordWidth();
- targetTriple = toolChain->originalTargetTriple();
- extraCodeModelFlags = toolChain->extraCodeModelFlags();
-
- // ...and save the potentially expensive operations for later so that
- // they can be run from a worker thread.
- this->sysRootPath = sysRootPath;
- headerPathsRunner = toolChain->createBuiltInHeaderPathsRunner(env);
- macroInspectionRunner = toolChain->createMacroInspectionRunner();
- }
-}
-
-ProjectUpdateInfo::ProjectUpdateInfo(ProjectExplorer::Project *project,
- const KitInfo &kitInfo,
- const Utils::Environment &env,
- const ProjectExplorer::RawProjectParts &rawProjectParts)
- : project(project)
- , rawProjectParts(rawProjectParts)
- , cToolChain(kitInfo.cToolChain)
- , cxxToolChain(kitInfo.cxxToolChain)
- , cToolChainInfo(ToolChainInfo(cToolChain, kitInfo.sysRootPath, env))
- , cxxToolChainInfo(ToolChainInfo(cxxToolChain, kitInfo.sysRootPath, env))
-{
-}
-
ProjectInfo::ProjectInfo(QPointer<ProjectExplorer::Project> project)
: m_project(project)
{
diff --git a/src/plugins/cpptools/projectinfo.h b/src/plugins/cpptools/projectinfo.h
index e8f585e384..347e72f477 100644
--- a/src/plugins/cpptools/projectinfo.h
+++ b/src/plugins/cpptools/projectinfo.h
@@ -40,50 +40,6 @@
namespace CppTools {
-class KitInfo;
-
-class ToolChainInfo
-{
-public:
- ToolChainInfo() = default;
- ToolChainInfo(const ProjectExplorer::ToolChain *toolChain,
- const QString &sysRootPath, const Utils::Environment &env);
-
- bool isValid() const { return type.isValid(); }
-
-public:
- Core::Id type;
- bool isMsvc2015ToolChain = false;
- unsigned wordWidth = 0;
- QString targetTriple;
- QStringList extraCodeModelFlags;
-
- QString sysRootPath; // For headerPathsRunner.
- ProjectExplorer::ToolChain::BuiltInHeaderPathsRunner headerPathsRunner;
- ProjectExplorer::ToolChain::MacroInspectionRunner macroInspectionRunner;
-};
-
-class CPPTOOLS_EXPORT ProjectUpdateInfo
-{
-public:
- ProjectUpdateInfo() = default;
- ProjectUpdateInfo(ProjectExplorer::Project *project,
- const KitInfo &kitInfo,
- const Utils::Environment &env,
- const ProjectExplorer::RawProjectParts &rawProjectParts);
- bool isValid() const { return project && !rawProjectParts.isEmpty(); }
-
-public:
- QPointer<ProjectExplorer::Project> project;
- ProjectExplorer::RawProjectParts rawProjectParts;
-
- const ProjectExplorer::ToolChain *cToolChain = nullptr;
- const ProjectExplorer::ToolChain *cxxToolChain = nullptr;
-
- ToolChainInfo cToolChainInfo;
- ToolChainInfo cxxToolChainInfo;
-};
-
class CPPTOOLS_EXPORT ProjectInfo
{
public:
diff --git a/src/plugins/projectexplorer/rawprojectpart.cpp b/src/plugins/projectexplorer/rawprojectpart.cpp
index deb60d18d7..4f24eaf49e 100644
--- a/src/plugins/projectexplorer/rawprojectpart.cpp
+++ b/src/plugins/projectexplorer/rawprojectpart.cpp
@@ -27,7 +27,9 @@
#include "abi.h"
#include "kitinformation.h"
+#include "project.h"
#include "projectexplorerconstants.h"
+#include "target.h"
#include <utils/algorithm.h>
@@ -148,4 +150,64 @@ void RawProjectPart::setBuildTargetType(BuildTargetType type)
buildTargetType = type;
}
+KitInfo::KitInfo(Project *project)
+{
+ // Kit
+ if (Target *target = project->activeTarget())
+ kit = target->kit();
+ else
+ kit = KitManager::defaultKit();
+
+ // Toolchains
+ if (kit) {
+ cToolChain = ToolChainKitAspect::toolChain(kit, Constants::C_LANGUAGE_ID);
+ cxxToolChain = ToolChainKitAspect::toolChain(kit, Constants::CXX_LANGUAGE_ID);
+ }
+
+ // Sysroot
+ sysRootPath = SysRootKitAspect::sysRoot(kit).toString();
+}
+
+bool KitInfo::isValid() const
+{
+ return kit;
+}
+
+ToolChainInfo::ToolChainInfo(const ToolChain *toolChain,
+ const QString &sysRootPath,
+ const Utils::Environment &env)
+{
+ if (toolChain) {
+ // Keep the following cheap/non-blocking for the ui thread...
+ type = toolChain->typeId();
+ isMsvc2015ToolChain = toolChain->targetAbi().osFlavor() == Abi::WindowsMsvc2015Flavor;
+ wordWidth = toolChain->targetAbi().wordWidth();
+ targetTriple = toolChain->originalTargetTriple();
+ extraCodeModelFlags = toolChain->extraCodeModelFlags();
+
+ // ...and save the potentially expensive operations for later so that
+ // they can be run from a worker thread.
+ this->sysRootPath = sysRootPath;
+ headerPathsRunner = toolChain->createBuiltInHeaderPathsRunner(env);
+ macroInspectionRunner = toolChain->createMacroInspectionRunner();
+ }
+}
+
+ProjectUpdateInfo::ProjectUpdateInfo(Project *project,
+ const KitInfo &kitInfo,
+ const Utils::Environment &env,
+ const RawProjectParts &rawProjectParts)
+ : project(project)
+ , rawProjectParts(rawProjectParts)
+ , cToolChain(kitInfo.cToolChain)
+ , cxxToolChain(kitInfo.cxxToolChain)
+ , cToolChainInfo(ToolChainInfo(cToolChain, kitInfo.sysRootPath, env))
+ , cxxToolChainInfo(ToolChainInfo(cxxToolChain, kitInfo.sysRootPath, env))
+{}
+
+bool ProjectUpdateInfo::isValid() const
+{
+ return project && !rawProjectParts.isEmpty();
+}
+
} // namespace ProjectExplorer
diff --git a/src/plugins/projectexplorer/rawprojectpart.h b/src/plugins/projectexplorer/rawprojectpart.h
index 4f6969d92a..eda3ce5ad7 100644
--- a/src/plugins/projectexplorer/rawprojectpart.h
+++ b/src/plugins/projectexplorer/rawprojectpart.h
@@ -31,13 +31,20 @@
#include "projectexplorer_global.h"
#include "projectmacro.h"
+// this include style is forced for the cpp unit test mocks
+#include <projectexplorer/toolchain.h>
+
#include <utils/cpplanguage_details.h>
+#include <utils/environment.h>
+
+#include <QPointer>
#include <functional>
namespace ProjectExplorer {
-class ToolChain;
+class Kit;
+class Project;
class PROJECTEXPLORER_EXPORT RawProjectPartFlags
{
@@ -114,4 +121,63 @@ public:
using RawProjectParts = QVector<RawProjectPart>;
+class PROJECTEXPLORER_EXPORT KitInfo
+{
+public:
+ explicit KitInfo(Project *project);
+
+ bool isValid() const;
+
+ Kit *kit = nullptr;
+ ToolChain *cToolChain = nullptr;
+ ToolChain *cxxToolChain = nullptr;
+
+ Utils::QtVersion projectPartQtVersion = Utils::QtVersion::None;
+
+ QString sysRootPath;
+};
+
+class PROJECTEXPLORER_EXPORT ToolChainInfo
+{
+public:
+ ToolChainInfo() = default;
+ ToolChainInfo(const ProjectExplorer::ToolChain *toolChain,
+ const QString &sysRootPath,
+ const Utils::Environment &env);
+
+ bool isValid() const { return type.isValid(); }
+
+public:
+ Core::Id type;
+ bool isMsvc2015ToolChain = false;
+ unsigned wordWidth = 0;
+ QString targetTriple;
+ QStringList extraCodeModelFlags;
+
+ QString sysRootPath; // For headerPathsRunner.
+ ProjectExplorer::ToolChain::BuiltInHeaderPathsRunner headerPathsRunner;
+ ProjectExplorer::ToolChain::MacroInspectionRunner macroInspectionRunner;
+};
+
+class PROJECTEXPLORER_EXPORT ProjectUpdateInfo
+{
+public:
+ ProjectUpdateInfo() = default;
+ ProjectUpdateInfo(Project *project,
+ const KitInfo &kitInfo,
+ const Utils::Environment &env,
+ const RawProjectParts &rawProjectParts);
+ bool isValid() const;
+
+public:
+ QPointer<Project> project;
+ RawProjectParts rawProjectParts;
+
+ const ToolChain *cToolChain = nullptr;
+ const ToolChain *cxxToolChain = nullptr;
+
+ ToolChainInfo cToolChainInfo;
+ ToolChainInfo cxxToolChainInfo;
+};
+
} // namespace ProjectExplorer
diff --git a/src/plugins/qtsupport/qtcppkitinfo.cpp b/src/plugins/qtsupport/qtcppkitinfo.cpp
index 0d69e087b4..17a201dfc2 100644
--- a/src/plugins/qtsupport/qtcppkitinfo.cpp
+++ b/src/plugins/qtsupport/qtcppkitinfo.cpp
@@ -30,10 +30,8 @@
namespace QtSupport {
-using namespace CppTools;
-
CppKitInfo::CppKitInfo(ProjectExplorer::Project *project)
- : KitInfo(project)
+ : ProjectExplorer::KitInfo(project)
{
if (kit && (qtVersion = QtKitAspect::qtVersion(kit))) {
if (qtVersion->qtVersion() < QtSupport::QtVersionNumber(5, 0, 0))
diff --git a/src/plugins/qtsupport/qtcppkitinfo.h b/src/plugins/qtsupport/qtcppkitinfo.h
index d20853a034..fe5d90e317 100644
--- a/src/plugins/qtsupport/qtcppkitinfo.h
+++ b/src/plugins/qtsupport/qtcppkitinfo.h
@@ -27,13 +27,13 @@
#include "qtsupport_global.h"
-#include <cpptools/cppkitinfo.h>
+#include <projectexplorer/rawprojectpart.h>
namespace QtSupport {
class BaseQtVersion;
-class QTSUPPORT_EXPORT CppKitInfo : public CppTools::KitInfo
+class QTSUPPORT_EXPORT CppKitInfo : public ProjectExplorer::KitInfo
{
public:
CppKitInfo(ProjectExplorer::Project *project);
diff --git a/tests/unit/unittest/cppprojectinfogenerator-test.cpp b/tests/unit/unittest/cppprojectinfogenerator-test.cpp
index 058d46af1a..ceb3c8b8aa 100644
--- a/tests/unit/unittest/cppprojectinfogenerator-test.cpp
+++ b/tests/unit/unittest/cppprojectinfogenerator-test.cpp
@@ -35,10 +35,10 @@
using CppTools::Internal::ProjectInfoGenerator;
using CppTools::ProjectFile;
using CppTools::ProjectInfo;
-using CppTools::ProjectUpdateInfo;
using CppTools::ProjectPart;
using ProjectExplorer::Macros;
+using ProjectExplorer::ProjectUpdateInfo;
using ProjectExplorer::RawProjectPart;
using ProjectExplorer::ToolChain;