diff options
author | Tobias Hunger <tobias.hunger@qt.io> | 2019-08-13 12:47:11 +0200 |
---|---|---|
committer | Tobias Hunger <tobias.hunger@qt.io> | 2019-08-29 07:28:26 +0000 |
commit | fb21b78444fa2ff18fecaf45db36bd72b3dfe734 (patch) | |
tree | fd33b814e925bd748579b7222cfcfc2120ae409c | |
parent | b7e4046a173a2c42ede92934cc05c0f76486db5e (diff) | |
download | qt-creator-fb21b78444fa2ff18fecaf45db36bd72b3dfe734.tar.gz |
Autotools: Introduce AutotoolsBuildSystem
Introduce AutotoolsBuildSystem and slim down AutotoolsProject.
Change-Id: I68296152f9ecd5d14198c8d0b36a06c2d1b162ec
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
15 files changed, 111 insertions, 171 deletions
diff --git a/src/plugins/autotoolsprojectmanager/CMakeLists.txt b/src/plugins/autotoolsprojectmanager/CMakeLists.txt index ca8765cba9..ac341c3eaf 100644 --- a/src/plugins/autotoolsprojectmanager/CMakeLists.txt +++ b/src/plugins/autotoolsprojectmanager/CMakeLists.txt @@ -4,8 +4,8 @@ add_qtc_plugin(AutotoolsProjectManager autogenstep.cpp autogenstep.h autoreconfstep.cpp autoreconfstep.h autotoolsbuildconfiguration.cpp autotoolsbuildconfiguration.h + autotoolsbuildsystem.cpp autotoolsbuildsystem.h autotoolsopenprojectwizard.cpp autotoolsopenprojectwizard.h - autotoolsproject.cpp autotoolsproject.h autotoolsprojectconstants.h autotoolsprojectplugin.cpp autotoolsprojectplugin.h configurestep.cpp configurestep.h diff --git a/src/plugins/autotoolsprojectmanager/autogenstep.cpp b/src/plugins/autotoolsprojectmanager/autogenstep.cpp index 1fe6520c3b..2541c1169c 100644 --- a/src/plugins/autotoolsprojectmanager/autogenstep.cpp +++ b/src/plugins/autotoolsprojectmanager/autogenstep.cpp @@ -26,14 +26,12 @@ ****************************************************************************/ #include "autogenstep.h" + #include "autotoolsprojectconstants.h" #include <projectexplorer/buildconfiguration.h> -#include <projectexplorer/buildsteplist.h> -#include <projectexplorer/project.h> #include <projectexplorer/processparameters.h> -#include <projectexplorer/projectexplorer.h> -#include <projectexplorer/projectexplorerconstants.h> +#include <projectexplorer/project.h> #include <projectexplorer/target.h> #include <QDateTime> @@ -43,7 +41,6 @@ using namespace AutotoolsProjectManager::Internal; using namespace ProjectExplorer; using namespace Utils; - // AutogenStepFactory AutogenStepFactory::AutogenStepFactory() diff --git a/src/plugins/autotoolsprojectmanager/autoreconfstep.cpp b/src/plugins/autotoolsprojectmanager/autoreconfstep.cpp index fa15515078..eeb3da1118 100644 --- a/src/plugins/autotoolsprojectmanager/autoreconfstep.cpp +++ b/src/plugins/autotoolsprojectmanager/autoreconfstep.cpp @@ -26,14 +26,12 @@ ****************************************************************************/ #include "autoreconfstep.h" + #include "autotoolsprojectconstants.h" #include <projectexplorer/buildconfiguration.h> -#include <projectexplorer/buildsteplist.h> -#include <projectexplorer/project.h> #include <projectexplorer/processparameters.h> -#include <projectexplorer/projectexplorer.h> -#include <projectexplorer/projectexplorerconstants.h> +#include <projectexplorer/project.h> #include <projectexplorer/target.h> using namespace AutotoolsProjectManager; diff --git a/src/plugins/autotoolsprojectmanager/autotoolsbuildconfiguration.cpp b/src/plugins/autotoolsprojectmanager/autotoolsbuildconfiguration.cpp index 64f31d6642..42f665b0e6 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsbuildconfiguration.cpp +++ b/src/plugins/autotoolsprojectmanager/autotoolsbuildconfiguration.cpp @@ -27,18 +27,13 @@ #include "autotoolsbuildconfiguration.h" -#include "autotoolsproject.h" #include "autotoolsprojectconstants.h" -#include <coreplugin/icore.h> #include <projectexplorer/buildinfo.h> #include <projectexplorer/buildsteplist.h> -#include <projectexplorer/kitinformation.h> +#include <projectexplorer/project.h> #include <projectexplorer/projectexplorerconstants.h> #include <projectexplorer/target.h> -#include <projectexplorer/toolchain.h> -#include <utils/mimetypes/mimedatabase.h> -#include <utils/qtcassert.h> using namespace AutotoolsProjectManager::Constants; using namespace ProjectExplorer; diff --git a/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp b/src/plugins/autotoolsprojectmanager/autotoolsbuildsystem.cpp index 6487d424da..1adf9e003d 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp +++ b/src/plugins/autotoolsprojectmanager/autotoolsbuildsystem.cpp @@ -25,67 +25,36 @@ ** ****************************************************************************/ -#include "autotoolsproject.h" -#include "autotoolsbuildconfiguration.h" -#include "autotoolsprojectconstants.h" -#include "autotoolsopenprojectwizard.h" -#include "makestep.h" +#include "autotoolsbuildsystem.h" + #include "makefileparserthread.h" +#include "makestep.h" -#include <projectexplorer/abi.h> -#include <projectexplorer/toolchain.h> -#include <projectexplorer/kitinformation.h> +#include <cpptools/cppprojectupdater.h> #include <projectexplorer/buildconfiguration.h> -#include <projectexplorer/buildsteplist.h> -#include <projectexplorer/projectexplorerconstants.h> -#include <projectexplorer/projectnodes.h> #include <projectexplorer/target.h> -#include <projectexplorer/headerpath.h> -#include <extensionsystem/pluginmanager.h> -#include <cpptools/cppmodelmanager.h> -#include <cpptools/projectinfo.h> -#include <cpptools/cppprojectupdater.h> -#include <coreplugin/icore.h> -#include <coreplugin/icontext.h> -#include <qtsupport/baseqtversion.h> #include <qtsupport/qtcppkitinfo.h> -#include <qtsupport/qtkitinformation.h> -#include <utils/algorithm.h> -#include <utils/qtcassert.h> + #include <utils/filesystemwatcher.h> -#include <QFileInfo> -#include <QTimer> -#include <QPointer> -#include <QApplication> -#include <QCursor> -#include <QLabel> -#include <QPushButton> -#include <QVBoxLayout> - -using namespace AutotoolsProjectManager; -using namespace AutotoolsProjectManager::Internal; using namespace ProjectExplorer; -AutotoolsProject::AutotoolsProject(const Utils::FilePath &fileName) - : Project(Constants::MAKEFILE_MIMETYPE, fileName) +namespace AutotoolsProjectManager { +namespace Internal { + +AutotoolsBuildSystem::AutotoolsBuildSystem(Project *project) + : BuildSystem(project) , m_cppCodeModelUpdater(new CppTools::CppProjectUpdater) { - setId(Constants::AUTOTOOLS_PROJECT_ID); - setProjectLanguages(Core::Context(ProjectExplorer::Constants::CXX_LANGUAGE_ID)); - setDisplayName(projectDirectory().fileName()); - - setHasMakeInstallEquivalent(true); + connect(project, &Project::activeBuildConfigurationChanged, this, [this]() { requestParse(); }); - connect(this, &AutotoolsProject::projectFileIsDirty, this, &AutotoolsProject::loadProjectTree); + connect(project, &Project::projectFileIsDirty, this, [this]() { requestParse(); }); } -AutotoolsProject::~AutotoolsProject() +AutotoolsBuildSystem::~AutotoolsBuildSystem() { delete m_cppCodeModelUpdater; - setRootProjectNode(nullptr); - if (m_makefileParserThread) { m_makefileParserThread->wait(); delete m_makefileParserThread; @@ -93,65 +62,42 @@ AutotoolsProject::~AutotoolsProject() } } -// This function, is called at the very beginning, to -// restore the settings if there are some stored. -Project::RestoreResult AutotoolsProject::fromMap(const QVariantMap &map, QString *errorMessage) -{ - RestoreResult result = Project::fromMap(map, errorMessage); - if (result != RestoreResult::Ok) - return result; - - // Load the project tree structure. - loadProjectTree(); - - if (!activeTarget()) - addTargetForDefaultKit(); - - return RestoreResult::Ok; -} - -void AutotoolsProject::loadProjectTree() +void AutotoolsBuildSystem::parseProject(BuildSystem::ParsingContext &&ctx) { if (m_makefileParserThread) { - // The thread is still busy parsing a previus configuration. + // The thread is still busy parsing a previous configuration. // Wait until the thread has been finished and delete it. // TODO: Discuss whether blocking is acceptable. - disconnect(m_makefileParserThread, &QThread::finished, - this, &AutotoolsProject::makefileParsingFinished); + disconnect(m_makefileParserThread, + &QThread::finished, + this, + &AutotoolsBuildSystem::makefileParsingFinished); m_makefileParserThread->wait(); delete m_makefileParserThread; m_makefileParserThread = nullptr; } // Parse the makefile asynchronously in a thread - m_makefileParserThread = new MakefileParserThread(projectFilePath().toString(), - guardParsingRun()); + m_makefileParserThread = new MakefileParserThread(project()->projectFilePath().toString(), + std::move(ctx.guard)); - connect(m_makefileParserThread, &MakefileParserThread::started, - this, &AutotoolsProject::makefileParsingStarted); - - connect(m_makefileParserThread, &MakefileParserThread::finished, - this, &AutotoolsProject::makefileParsingFinished); + connect(m_makefileParserThread, + &MakefileParserThread::finished, + this, + &AutotoolsBuildSystem::makefileParsingFinished); m_makefileParserThread->start(); } -void AutotoolsProject::makefileParsingStarted() -{ - QApplication::setOverrideCursor(QCursor(Qt::WaitCursor)); -} - -void AutotoolsProject::makefileParsingFinished() +void AutotoolsBuildSystem::makefileParsingFinished() { // The finished() signal is from a previous makefile-parser-thread // and can be skipped. This can happen, if the thread has emitted the - // finished() signal during the execution of AutotoolsProject::loadProjectTree(). + // finished() signal during the execution of AutotoolsBuildSystem::loadProjectTree(). // In this case the signal is in the message queue already and deleting // the thread of course does not remove the signal again. if (sender() != m_makefileParserThread) return; - QApplication::restoreOverrideCursor(); - if (m_makefileParserThread->isCanceled()) { // The parsing has been cancelled by the user. Don't show any // project data at all. @@ -167,8 +113,8 @@ void AutotoolsProject::makefileParsingFinished() QVector<Utils::FilePath> filesToWatch; - // Apply sources to m_files, which are returned at AutotoolsProject::files() - const QFileInfo fileInfo = projectFilePath().toFileInfo(); + // Apply sources to m_files, which are returned at AutotoolsBuildSystem::files() + const QFileInfo fileInfo = project()->projectFilePath().toFileInfo(); const QDir dir = fileInfo.absoluteDir(); const QStringList files = m_makefileParserThread->sources(); foreach (const QString& file, files) @@ -195,14 +141,14 @@ void AutotoolsProject::makefileParsingFinished() filesToWatch.append(Utils::FilePath::fromString(absConfigureAc)); } - auto newRoot = std::make_unique<ProjectNode>(projectDirectory()); + auto newRoot = std::make_unique<ProjectNode>(project()->projectDirectory()); for (const QString &f : m_files) { const Utils::FilePath path = Utils::FilePath::fromString(f); newRoot->addNestedNode(std::make_unique<FileNode>(path, FileNode::fileTypeForFileName(path))); } - setRootProjectNode(std::move(newRoot)); - setExtraProjectFiles(filesToWatch); + project()->setRootProjectNode(std::move(newRoot)); + project()->setExtraProjectFiles(filesToWatch); updateCppCodeModel(); @@ -228,14 +174,16 @@ static QStringList filterIncludes(const QString &absSrc, const QString &absBuild return result; } -void AutotoolsProject::updateCppCodeModel() +void AutotoolsBuildSystem::updateCppCodeModel() { - QtSupport::CppKitInfo kitInfo(this); - QTC_ASSERT(kitInfo.isValid(), return); + QtSupport::CppKitInfo kitInfo(project()); + QTC_ASSERT(kitInfo.isValid(), return ); + + const Utils::FilePath projectFilePath = project()->projectFilePath(); CppTools::RawProjectPart rpp; - rpp.setDisplayName(displayName()); - rpp.setProjectFileLocation(projectFilePath().toString()); + rpp.setDisplayName(project()->displayName()); + rpp.setProjectFileLocation(projectFilePath.toString()); rpp.setQtVersion(kitInfo.projectPartQtVersion); const QStringList cflags = m_makefileParserThread->cflags(); QStringList cxxflags = m_makefileParserThread->cxxflags(); @@ -244,14 +192,18 @@ void AutotoolsProject::updateCppCodeModel() rpp.setFlagsForC({kitInfo.cToolChain, cflags}); rpp.setFlagsForCxx({kitInfo.cxxToolChain, cxxflags}); - const QString absSrc = projectDirectory().toString(); - const Target *target = activeTarget(); - const QString absBuild = (target && target->activeBuildConfiguration()) - ? target->activeBuildConfiguration()->buildDirectory().toString() : QString(); + const QString absSrc = project()->projectDirectory().toString(); + const Target *target = project()->activeTarget(); + BuildConfiguration *bc = target ? target->activeBuildConfiguration() : nullptr; + + const QString absBuild = bc ? bc->buildDirectory().toString() : QString(); rpp.setIncludePaths(filterIncludes(absSrc, absBuild, m_makefileParserThread->includePaths())); rpp.setMacros(m_makefileParserThread->macros()); rpp.setFiles(m_files); - m_cppCodeModelUpdater->update({this, kitInfo, activeParseEnvironment(), {rpp}}); + m_cppCodeModelUpdater->update({project(), kitInfo, project()->activeParseEnvironment(), {rpp}}); } + +} // namespace Internal +} // namespace AutotoolsProjectManager diff --git a/src/plugins/autotoolsprojectmanager/autotoolsproject.h b/src/plugins/autotoolsprojectmanager/autotoolsbuildsystem.h index 44e5d81657..8bbad6a580 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsproject.h +++ b/src/plugins/autotoolsprojectmanager/autotoolsbuildsystem.h @@ -27,51 +27,31 @@ #pragma once -#include <projectexplorer/project.h> - -#include <utils/fileutils.h> +#include <projectexplorer/buildsystem.h> namespace Utils { class FileSystemWatcher; } namespace CppTools { class CppProjectUpdater; } namespace AutotoolsProjectManager { + namespace Internal { class MakefileParserThread; -/** - * @brief Implementation of the ProjectExplorer::Project interface. - * - * Loads the autotools project and embeds it into the QtCreator project tree. - * The class AutotoolsProject is the core of the autotools project plugin. - * It is responsible to parse the Makefile.am files and do trigger project - * updates if a Makefile.am file or a configure.ac file has been changed. - */ -class AutotoolsProject : public ProjectExplorer::Project +class AutotoolsBuildSystem : public ProjectExplorer::BuildSystem { Q_OBJECT public: - explicit AutotoolsProject(const Utils::FilePath &fileName); - ~AutotoolsProject() override; + explicit AutotoolsBuildSystem(ProjectExplorer::Project *project); + ~AutotoolsBuildSystem() override; protected: - RestoreResult fromMap(const QVariantMap &map, QString *errorMessage) override; + void parseProject(ParsingContext &&ctx) final; private: /** - * Loads the project tree by parsing the makefiles. - */ - void loadProjectTree(); - - /** - * Is invoked when the makefile parsing by m_makefileParserThread has - * been started. Turns the mouse cursor into a busy cursor. - */ - void makefileParsingStarted(); - - /** * Is invoked when the makefile parsing by m_makefileParserThread has * been finished. Adds all sources and files into the project tree and * takes care listen to file changes for Makefile.am and configure.ac diff --git a/src/plugins/autotoolsprojectmanager/autotoolsopenprojectwizard.cpp b/src/plugins/autotoolsprojectmanager/autotoolsopenprojectwizard.cpp index cbfbe47173..ef57ca24ea 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsopenprojectwizard.cpp +++ b/src/plugins/autotoolsprojectmanager/autotoolsopenprojectwizard.cpp @@ -29,10 +29,9 @@ #include <utils/pathchooser.h> -#include <QVBoxLayout> +#include <QDir> #include <QFormLayout> #include <QLabel> -#include <QDir> using namespace AutotoolsProjectManager; using namespace AutotoolsProjectManager::Internal; diff --git a/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.pro b/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.pro index 92b6dd8e7d..37dce96bbb 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.pro +++ b/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.pro @@ -1,8 +1,8 @@ include(../../qtcreatorplugin.pri) -HEADERS = autotoolsprojectplugin.h\ +HEADERS = autotoolsbuildsystem.h \ + autotoolsprojectplugin.h\ autotoolsopenprojectwizard.h\ - autotoolsproject.h\ autotoolsbuildconfiguration.h\ autotoolsprojectconstants.h\ makestep.h\ @@ -12,9 +12,9 @@ HEADERS = autotoolsprojectplugin.h\ makefileparserthread.h\ makefileparser.h -SOURCES = autotoolsprojectplugin.cpp\ +SOURCES = autotoolsbuildsystem.cpp \ + autotoolsprojectplugin.cpp\ autotoolsopenprojectwizard.cpp\ - autotoolsproject.cpp\ autotoolsbuildconfiguration.cpp\ makestep.cpp\ autogenstep.cpp\ diff --git a/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.qbs b/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.qbs index a6e4a2721b..75f81d09b7 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.qbs +++ b/src/plugins/autotoolsprojectmanager/autotoolsprojectmanager.qbs @@ -18,10 +18,10 @@ QtcPlugin { "autoreconfstep.h", "autotoolsbuildconfiguration.cpp", "autotoolsbuildconfiguration.h", + "autotoolsbuildsystem.cpp", + "autotoolsbuildsystem.h", "autotoolsopenprojectwizard.cpp", "autotoolsopenprojectwizard.h", - "autotoolsproject.cpp", - "autotoolsproject.h", "autotoolsprojectconstants.h", "autotoolsprojectplugin.cpp", "autotoolsprojectplugin.h", diff --git a/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.cpp b/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.cpp index 5b3643dcd3..e3cd87f0ce 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.cpp +++ b/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.cpp @@ -26,19 +26,33 @@ ****************************************************************************/ #include "autotoolsprojectplugin.h" -#include "autotoolsproject.h" -#include "autotoolsprojectconstants.h" -#include "autotoolsbuildconfiguration.h" -#include "makestep.h" + #include "autogenstep.h" #include "autoreconfstep.h" +#include "autotoolsbuildconfiguration.h" +#include "autotoolsbuildsystem.h" +#include "autotoolsprojectconstants.h" #include "configurestep.h" +#include "makestep.h" +#include <coreplugin/icontext.h> #include <projectexplorer/projectmanager.h> namespace AutotoolsProjectManager { namespace Internal { +AutotoolsProject::AutotoolsProject(const Utils::FilePath &fileName) + : Project(Constants::MAKEFILE_MIMETYPE, fileName) +{ + setId(Constants::AUTOTOOLS_PROJECT_ID); + setProjectLanguages(Core::Context(ProjectExplorer::Constants::CXX_LANGUAGE_ID)); + setDisplayName(projectDirectory().fileName()); + + setHasMakeInstallEquivalent(true); + + setBuildSystem(std::make_unique<AutotoolsBuildSystem>(this)); +} + class AutotoolsProjectPluginPrivate { public: @@ -69,5 +83,5 @@ bool AutotoolsProjectPlugin::initialize(const QStringList &arguments, return true; } -} // Internal +} // namespace Internal } // AutotoolsProjectManager diff --git a/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.h b/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.h index dd08cbd1c8..bdf319150f 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.h +++ b/src/plugins/autotoolsprojectmanager/autotoolsprojectplugin.h @@ -27,6 +27,8 @@ #pragma once +#include <projectexplorer/project.h> + #include <extensionsystem/iplugin.h> namespace AutotoolsProjectManager { @@ -73,5 +75,19 @@ class AutotoolsProjectPlugin : public ExtensionSystem::IPlugin class AutotoolsProjectPluginPrivate *d; }; +/** + * @brief Implementation of the ProjectExplorer::Project interface. + * + * Loads the autotools project and embeds it into the QtCreator project tree. + * The class AutotoolsProject is the core of the autotools project plugin. + * It is responsible to parse the Makefile.am files and do trigger project + * updates if a Makefile.am file or a configure.ac file has been changed. + */ +class AutotoolsProject : public ProjectExplorer::Project +{ +public: + explicit AutotoolsProject(const Utils::FilePath &fileName); +}; + } // namespace Internal } // namespace AutotoolsProjectManager diff --git a/src/plugins/autotoolsprojectmanager/configurestep.cpp b/src/plugins/autotoolsprojectmanager/configurestep.cpp index 53f4c71a3e..c722aa3a9f 100644 --- a/src/plugins/autotoolsprojectmanager/configurestep.cpp +++ b/src/plugins/autotoolsprojectmanager/configurestep.cpp @@ -26,23 +26,16 @@ ****************************************************************************/ #include "configurestep.h" -#include "autotoolsproject.h" + #include "autotoolsbuildconfiguration.h" #include "autotoolsprojectconstants.h" -#include <projectexplorer/buildsteplist.h> -#include <projectexplorer/target.h> -#include <projectexplorer/toolchain.h> -#include <projectexplorer/gnumakeparser.h> #include <projectexplorer/processparameters.h> -#include <projectexplorer/projectexplorer.h> -#include <projectexplorer/projectexplorerconstants.h> -#include <utils/qtcprocess.h> +#include <projectexplorer/project.h> +#include <projectexplorer/target.h> -#include <QVariantMap> #include <QDateTime> -#include <QLineEdit> -#include <QFormLayout> +#include <QDir> using namespace AutotoolsProjectManager; using namespace AutotoolsProjectManager::Internal; @@ -55,7 +48,7 @@ using namespace Utils; static QString projectDirRelativeToBuildDir(BuildConfiguration *bc) { const QDir buildDir(bc->buildDirectory().toString()); QString projDirToBuildDir = buildDir.relativeFilePath( - bc->target()->project()->projectDirectory().toString()); + bc->project()->projectDirectory().toString()); if (projDirToBuildDir.isEmpty()) return QString("./"); if (!projDirToBuildDir.endsWith('/')) @@ -106,7 +99,6 @@ ConfigureStep::ConfigureStep(BuildStepList *bsl) return param.summaryInWorkdir(displayName()); }); - } bool ConfigureStep::init() diff --git a/src/plugins/autotoolsprojectmanager/makefileparser.cpp b/src/plugins/autotoolsprojectmanager/makefileparser.cpp index 39596a724e..8c379ee823 100644 --- a/src/plugins/autotoolsprojectmanager/makefileparser.cpp +++ b/src/plugins/autotoolsprojectmanager/makefileparser.cpp @@ -30,10 +30,9 @@ #include <utils/qtcassert.h> #include <utils/qtcprocess.h> -#include <QFile> #include <QDir> -#include <QFileInfoList> -#include <QMutexLocker> +#include <QFile> +#include <QFileInfo> using namespace AutotoolsProjectManager::Internal; @@ -49,7 +48,7 @@ bool MakefileParser::parse() { m_mutex.lock(); m_cancel = false; - m_mutex.unlock(), + m_mutex.unlock(); m_success = true; m_executable.clear(); diff --git a/src/plugins/autotoolsprojectmanager/makestep.cpp b/src/plugins/autotoolsprojectmanager/makestep.cpp index 14b58c8368..7a7fbbddb3 100644 --- a/src/plugins/autotoolsprojectmanager/makestep.cpp +++ b/src/plugins/autotoolsprojectmanager/makestep.cpp @@ -26,9 +26,7 @@ ****************************************************************************/ #include "makestep.h" -#include "autotoolsproject.h" #include "autotoolsprojectconstants.h" -#include "autotoolsbuildconfiguration.h" #include <projectexplorer/buildsteplist.h> #include <projectexplorer/projectexplorerconstants.h> diff --git a/src/plugins/projectexplorer/project.h b/src/plugins/projectexplorer/project.h index c4f29f0d1a..9c4f38fecb 100644 --- a/src/plugins/projectexplorer/project.h +++ b/src/plugins/projectexplorer/project.h @@ -232,6 +232,7 @@ public: // FIXME: Make this private and the BuildSystem a friend ParseGuard guardParsingRun() { return ParseGuard(this); } + void setRootProjectNode(std::unique_ptr<ProjectNode> &&root); // Set project files that will be watched and trigger the same callback // as the main project file. @@ -285,7 +286,6 @@ protected: void setCanBuildProducts(); void setId(Core::Id id); - void setRootProjectNode(std::unique_ptr<ProjectNode> &&root); // takes ownership! void setProjectLanguages(Core::Context language); void addProjectLanguage(Core::Id id); void removeProjectLanguage(Core::Id id); |