diff options
author | Jarek Kobus <jaroslaw.kobus@qt.io> | 2023-05-10 21:38:41 +0200 |
---|---|---|
committer | Jarek Kobus <jaroslaw.kobus@qt.io> | 2023-05-17 06:29:03 +0000 |
commit | f84199f8b70bb03b66a0dbac3ff4dcdb56094d20 (patch) | |
tree | 2227c04675712bd387cea5b193f5b4d3e8196452 /src | |
parent | 520412d147b12ed8fda1a13aef96d79b953590c5 (diff) | |
download | qt-creator-f84199f8b70bb03b66a0dbac3ff4dcdb56094d20.tar.gz |
Solutions: Long live Solutions!
Short live Tasking in Solutions!
Add src/libs/solutions/README.md with the motivation and hints.
Move TaskTree and Barrier from Utils into Tasking object lib,
the first solution in Solutions project.
Tasking: Some more work is still required for adapting auto and
manual tests. Currently they use Async task, which stayed in Utils.
For Qt purposed we most probably need to have a clone of
Async task inside the Tasking namespace that is more Qt-like
(no Utils::FutureSynchronizer, no priority field,
global QThreadPool instead of a custom one for Creator).
Change-Id: I5d10a2d68170ffa467d8c299be5995b9aa4f8f77
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Diffstat (limited to 'src')
37 files changed, 169 insertions, 68 deletions
diff --git a/src/libs/CMakeLists.txt b/src/libs/CMakeLists.txt index fc6b53d81c..2ee109d5cd 100644 --- a/src/libs/CMakeLists.txt +++ b/src/libs/CMakeLists.txt @@ -2,22 +2,22 @@ add_subdirectory(3rdparty) add_subdirectory(advanceddockingsystem) add_subdirectory(aggregation) +add_subdirectory(cplusplus) add_subdirectory(extensionsystem) -add_subdirectory(utils) +add_subdirectory(glsl) +add_subdirectory(languageserverprotocol) add_subdirectory(languageutils) -add_subdirectory(cplusplus) add_subdirectory(modelinglib) add_subdirectory(nanotrace) -add_subdirectory(qmljs) add_subdirectory(qmldebug) add_subdirectory(qmleditorwidgets) -add_subdirectory(glsl) -add_subdirectory(languageserverprotocol) -add_subdirectory(sqlite) -add_subdirectory(tracing) +add_subdirectory(qmljs) add_subdirectory(qmlpuppetcommunication) - add_subdirectory(qtcreatorcdbext) +add_subdirectory(solutions) +add_subdirectory(sqlite) +add_subdirectory(tracing) +add_subdirectory(utils) if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/qlitehtml/src/CMakeLists.txt) option(BUILD_LIBRARY_QLITEHTML "Build library qlitehtml." ${BUILD_LIBRARIES_BY_DEFAULT}) diff --git a/src/libs/libs.qbs b/src/libs/libs.qbs index 141e2a6547..ffc3017cba 100644 --- a/src/libs/libs.qbs +++ b/src/libs/libs.qbs @@ -19,6 +19,7 @@ Project { "qmljs/qmljs.qbs", "qmldebug/qmldebug.qbs", "qtcreatorcdbext/qtcreatorcdbext.qbs", + "solutions/solutions.qbs", "sqlite/sqlite.qbs", "tracing/tracing.qbs", "utils/process_ctrlc_stub.qbs", diff --git a/src/libs/solutions/CMakeLists.txt b/src/libs/solutions/CMakeLists.txt new file mode 100644 index 0000000000..694d940195 --- /dev/null +++ b/src/libs/solutions/CMakeLists.txt @@ -0,0 +1 @@ +add_subdirectory(tasking) diff --git a/src/libs/solutions/README.md b/src/libs/solutions/README.md new file mode 100644 index 0000000000..ab4cc9727d --- /dev/null +++ b/src/libs/solutions/README.md @@ -0,0 +1,48 @@ +# Solutions project + +The Solutions project is designed to contain a collection of +object libraries, independent on any Creator's specific code, +ready to be a part of Qt. Kind of a staging area for possible +inclusions into Qt. + +## Motivation and benefits + +- Such a separation will ensure no future back dependencies to the Creator + specific code are introduced by mistake during maintenance. +- Easy to compile outside of Creator code. +- General hub of ideas to be considered by foundation team to be integrated + into Qt. +- The more stuff of a general purpose goes into Qt, the less maintenance work + for Creator. + +## Conformity of solutions + +Each solution: +- Is a separate object lib. +- Is placed in a separate subdirectory. +- Is enclosed within a namespace (namespace name = solution name). +- Should compile independently, i.e. there are no cross-includes + between solutions. + +## Dependencies of solution libraries + +**Do not add dependencies to non-Qt libraries.** +The only allowed dependencies are to Qt libraries. +Especially, don't add dependencies to any Creator's library +nor to any 3rd party library. + +If you can't avoid a dependency to the other Creator's library +in your solution, place it somewhere else (e.g. inside Utils library). + +The Utils lib depends on the solution libraries. + +## Predictions on possible integration into Qt + +The solutions in this project may have a bigger / faster chance to be +integrated into Qt when they: +- Conform to Qt API style. +- Integrate easily with existing classes / types in Qt + (instead of providing own structures / data types). +- Have full docs. +- Have auto tests. +- Have at least one example (however, autotests often play this role, too). diff --git a/src/libs/solutions/solutions.qbs b/src/libs/solutions/solutions.qbs new file mode 100644 index 0000000000..6184dce2af --- /dev/null +++ b/src/libs/solutions/solutions.qbs @@ -0,0 +1,7 @@ +Project { + name: "Solutions" + + references: [ + "tasking/tasking.qbs", + ].concat(project.additionalLibs) +} diff --git a/src/libs/solutions/tasking/CMakeLists.txt b/src/libs/solutions/tasking/CMakeLists.txt new file mode 100644 index 0000000000..5beed2fe5b --- /dev/null +++ b/src/libs/solutions/tasking/CMakeLists.txt @@ -0,0 +1,9 @@ +add_qtc_library(Tasking OBJECT +# Never add dependencies to non-Qt libraries for this library + DEPENDS Qt::Core + PUBLIC_DEFINES TASKING_LIBRARY + SOURCES + barrier.cpp barrier.h + tasking_global.h + tasktree.cpp tasktree.h +) diff --git a/src/libs/utils/barrier.cpp b/src/libs/solutions/tasking/barrier.cpp index c4daa033b4..c4daa033b4 100644 --- a/src/libs/utils/barrier.cpp +++ b/src/libs/solutions/tasking/barrier.cpp diff --git a/src/libs/utils/barrier.h b/src/libs/solutions/tasking/barrier.h index fe2d7bbe62..6939da5b36 100644 --- a/src/libs/utils/barrier.h +++ b/src/libs/solutions/tasking/barrier.h @@ -3,13 +3,13 @@ #pragma once -#include "utils_global.h" +#include "tasking_global.h" #include "tasktree.h" namespace Tasking { -class QTCREATOR_UTILS_EXPORT Barrier final : public QObject +class TASKING_EXPORT Barrier final : public QObject { Q_OBJECT @@ -34,7 +34,7 @@ private: int m_current = -1; }; -class QTCREATOR_UTILS_EXPORT BarrierTaskAdapter : public Tasking::TaskAdapter<Barrier> +class TASKING_EXPORT BarrierTaskAdapter : public Tasking::TaskAdapter<Barrier> { public: BarrierTaskAdapter() { connect(task(), &Barrier::done, this, &TaskInterface::done); } @@ -70,7 +70,7 @@ using MultiBarrier = TreeStorage<SharedBarrier<Limit>>; // alias template deduction only available with C++20. using SingleBarrier = MultiBarrier<1>; -class QTCREATOR_UTILS_EXPORT WaitForBarrierTask : public BarrierTask +class TASKING_EXPORT WaitForBarrierTask : public BarrierTask { public: template <int Limit> diff --git a/src/libs/solutions/tasking/tasking.qbs b/src/libs/solutions/tasking/tasking.qbs new file mode 100644 index 0000000000..8697b9c009 --- /dev/null +++ b/src/libs/solutions/tasking/tasking.qbs @@ -0,0 +1,14 @@ +QtcLibrary { + name: "Tasking" + Depends { name: "Qt"; submodules: ["core"] } + cpp.defines: base.concat("TASKING_LIBRARY") + + files: [ + "barrier.cpp", + "barrier.h", + "tasking_global.h", + "tasktree.cpp", + "tasktree.h", + ] +} + diff --git a/src/libs/solutions/tasking/tasking_global.h b/src/libs/solutions/tasking/tasking_global.h new file mode 100644 index 0000000000..d7e76fa9e6 --- /dev/null +++ b/src/libs/solutions/tasking/tasking_global.h @@ -0,0 +1,14 @@ +// Copyright (C) 2023 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +#pragma once + +#include <qglobal.h> + +#if defined(TASKING_LIBRARY) +# define TASKING_EXPORT Q_DECL_EXPORT +#elif defined(TASKING_STATIC_LIBRARY) +# define TASKING_EXPORT +#else +# define TASKING_EXPORT Q_DECL_IMPORT +#endif diff --git a/src/libs/utils/tasktree.cpp b/src/libs/solutions/tasking/tasktree.cpp index 75de54c374..4a66d7f674 100644 --- a/src/libs/utils/tasktree.cpp +++ b/src/libs/solutions/tasking/tasktree.cpp @@ -1,4 +1,4 @@ -// Copyright (C) 2022 The Qt Company Ltd. +// Copyright (C) 2023 The Qt Company Ltd. // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 #include "tasktree.h" diff --git a/src/libs/utils/tasktree.h b/src/libs/solutions/tasking/tasktree.h index d8545564b9..bbee1a3fe8 100644 --- a/src/libs/utils/tasktree.h +++ b/src/libs/solutions/tasking/tasktree.h @@ -1,9 +1,9 @@ -// Copyright (C) 2022 The Qt Company Ltd. +// Copyright (C) 2023 The Qt Company Ltd. // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 #pragma once -#include "utils_global.h" +#include "tasking_global.h" #include <QHash> #include <QObject> @@ -16,7 +16,7 @@ class TaskContainer; class TaskNode; class TaskTreePrivate; -class QTCREATOR_UTILS_EXPORT TaskInterface : public QObject +class TASKING_EXPORT TaskInterface : public QObject { Q_OBJECT @@ -28,7 +28,7 @@ signals: void done(bool success); }; -class QTCREATOR_UTILS_EXPORT TreeStorageBase +class TASKING_EXPORT TreeStorageBase { public: bool isValid() const; @@ -110,7 +110,7 @@ enum class TaskAction StopWithError }; -class QTCREATOR_UTILS_EXPORT TaskItem +class TASKING_EXPORT TaskItem { public: // Internal, provided by QTC_DECLARE_CUSTOM_TASK @@ -186,32 +186,32 @@ private: QList<TaskItem> m_children; }; -class QTCREATOR_UTILS_EXPORT Group : public TaskItem +class TASKING_EXPORT Group : public TaskItem { public: Group(const QList<TaskItem> &children) { addChildren(children); } Group(std::initializer_list<TaskItem> children) { addChildren(children); } }; -class QTCREATOR_UTILS_EXPORT Storage : public TaskItem +class TASKING_EXPORT Storage : public TaskItem { public: Storage(const TreeStorageBase &storage) : TaskItem(storage) { } }; -class QTCREATOR_UTILS_EXPORT ParallelLimit : public TaskItem +class TASKING_EXPORT ParallelLimit : public TaskItem { public: ParallelLimit(int parallelLimit) : TaskItem(qMax(parallelLimit, 0)) {} }; -class QTCREATOR_UTILS_EXPORT Workflow : public TaskItem +class TASKING_EXPORT Workflow : public TaskItem { public: Workflow(WorkflowPolicy policy) : TaskItem(policy) {} }; -class QTCREATOR_UTILS_EXPORT OnGroupSetup : public TaskItem +class TASKING_EXPORT OnGroupSetup : public TaskItem { public: template <typename SetupFunction> @@ -237,20 +237,20 @@ private: }; }; -class QTCREATOR_UTILS_EXPORT OnGroupDone : public TaskItem +class TASKING_EXPORT OnGroupDone : public TaskItem { public: OnGroupDone(const GroupEndHandler &handler) : TaskItem({{}, handler}) {} }; -class QTCREATOR_UTILS_EXPORT OnGroupError : public TaskItem +class TASKING_EXPORT OnGroupError : public TaskItem { public: OnGroupError(const GroupEndHandler &handler) : TaskItem({{}, {}, handler}) {} }; // Synchronous invocation. Similarly to Group - isn't counted as a task inside taskCount() -class QTCREATOR_UTILS_EXPORT Sync : public Group +class TASKING_EXPORT Sync : public Group { public: @@ -276,13 +276,13 @@ private: }; -QTCREATOR_UTILS_EXPORT extern ParallelLimit sequential; -QTCREATOR_UTILS_EXPORT extern ParallelLimit parallel; -QTCREATOR_UTILS_EXPORT extern Workflow stopOnError; -QTCREATOR_UTILS_EXPORT extern Workflow continueOnError; -QTCREATOR_UTILS_EXPORT extern Workflow stopOnDone; -QTCREATOR_UTILS_EXPORT extern Workflow continueOnDone; -QTCREATOR_UTILS_EXPORT extern Workflow optional; +TASKING_EXPORT extern ParallelLimit sequential; +TASKING_EXPORT extern ParallelLimit parallel; +TASKING_EXPORT extern Workflow stopOnError; +TASKING_EXPORT extern Workflow continueOnError; +TASKING_EXPORT extern Workflow stopOnDone; +TASKING_EXPORT extern Workflow continueOnDone; +TASKING_EXPORT extern Workflow optional; template <typename Task> class TaskAdapter : public TaskInterface @@ -354,7 +354,7 @@ private: class TaskTreePrivate; -class QTCREATOR_UTILS_EXPORT TaskTree final : public QObject +class TASKING_EXPORT TaskTree final : public QObject { Q_OBJECT @@ -407,7 +407,7 @@ private: TaskTreePrivate *d; }; -class QTCREATOR_UTILS_EXPORT TaskTreeTaskAdapter : public TaskAdapter<TaskTree> +class TASKING_EXPORT TaskTreeTaskAdapter : public TaskAdapter<TaskTree> { public: TaskTreeTaskAdapter(); diff --git a/src/libs/utils/CMakeLists.txt b/src/libs/utils/CMakeLists.txt index 5762fc3902..51511b117d 100644 --- a/src/libs/utils/CMakeLists.txt +++ b/src/libs/utils/CMakeLists.txt @@ -1,5 +1,5 @@ add_qtc_library(Utils - DEPENDS Qt::Qml Qt::Xml + DEPENDS Tasking Qt::Qml Qt::Xml PUBLIC_DEPENDS Qt::Concurrent Qt::Core Qt::Network Qt::Gui Qt::Widgets Qt::Core5Compat @@ -13,7 +13,6 @@ add_qtc_library(Utils archive.cpp archive.h aspects.cpp aspects.h async.cpp async.h - barrier.cpp barrier.h basetreeview.cpp basetreeview.h benchmarker.cpp benchmarker.h buildablehelperlibrary.cpp buildablehelperlibrary.h @@ -171,7 +170,6 @@ add_qtc_library(Utils styleanimator.cpp styleanimator.h styledbar.cpp styledbar.h stylehelper.cpp stylehelper.h - tasktree.cpp tasktree.h templateengine.cpp templateengine.h temporarydirectory.cpp temporarydirectory.h temporaryfile.cpp temporaryfile.h diff --git a/src/libs/utils/async.h b/src/libs/utils/async.h index b08ceaf3dc..f8dc6813a7 100644 --- a/src/libs/utils/async.h +++ b/src/libs/utils/async.h @@ -7,7 +7,8 @@ #include "futuresynchronizer.h" #include "qtcassert.h" -#include "tasktree.h" + +#include <solutions/tasking/tasktree.h> #include <QFutureWatcher> #include <QtConcurrent> diff --git a/src/libs/utils/filestreamer.cpp b/src/libs/utils/filestreamer.cpp index 2d4d490940..6d4a768336 100644 --- a/src/libs/utils/filestreamer.cpp +++ b/src/libs/utils/filestreamer.cpp @@ -4,9 +4,10 @@ #include "filestreamer.h" #include "async.h" -#include "barrier.h" #include "process.h" +#include <solutions/tasking/barrier.h> + #include <QFile> #include <QMutex> #include <QMutexLocker> diff --git a/src/libs/utils/filestreamer.h b/src/libs/utils/filestreamer.h index 8e46d7d164..a5b6ff4f25 100644 --- a/src/libs/utils/filestreamer.h +++ b/src/libs/utils/filestreamer.h @@ -6,7 +6,8 @@ #include "utils_global.h" #include "filepath.h" -#include "tasktree.h" + +#include <solutions/tasking/tasktree.h> #include <QObject> diff --git a/src/libs/utils/process.h b/src/libs/utils/process.h index 272e25f377..83f1bb990b 100644 --- a/src/libs/utils/process.h +++ b/src/libs/utils/process.h @@ -11,7 +11,8 @@ #include "commandline.h" #include "processenums.h" -#include "tasktree.h" + +#include <solutions/tasking/tasktree.h> #include <QProcess> diff --git a/src/libs/utils/utils.qbs b/src/libs/utils/utils.qbs index f316a8b75b..d1c8d0e95e 100644 --- a/src/libs/utils/utils.qbs +++ b/src/libs/utils/utils.qbs @@ -35,6 +35,7 @@ Project { Depends { name: "Qt"; submodules: ["concurrent", "core-private", "network", "qml", "widgets", "xml"] } Depends { name: "Qt.macextras"; condition: Qt.core.versionMajor < 6 && qbs.targetOS.contains("macos") } + Depends { name: "Tasking" } Depends { name: "app_version_header" } Depends { name: "ptyqt" } @@ -51,8 +52,6 @@ Project { "aspects.h", "async.cpp", "async.h", - "barrier.cpp", - "barrier.h", "basetreeview.cpp", "basetreeview.h", "benchmarker.cpp", @@ -308,8 +307,6 @@ Project { "styledbar.h", "stylehelper.cpp", "stylehelper.h", - "tasktree.cpp", - "tasktree.h", "templateengine.cpp", "templateengine.h", "temporarydirectory.cpp", diff --git a/src/plugins/clangtools/clangtoolruncontrol.cpp b/src/plugins/clangtools/clangtoolruncontrol.cpp index 4f1b39a27e..be6f416d2e 100644 --- a/src/plugins/clangtools/clangtoolruncontrol.cpp +++ b/src/plugins/clangtools/clangtoolruncontrol.cpp @@ -23,7 +23,6 @@ #include <utils/algorithm.h> #include <utils/process.h> #include <utils/stringutils.h> -#include <utils/tasktree.h> #include <QLoggingCategory> diff --git a/src/plugins/clangtools/documentclangtoolrunner.cpp b/src/plugins/clangtools/documentclangtoolrunner.cpp index 7077786d32..178022a91a 100644 --- a/src/plugins/clangtools/documentclangtoolrunner.cpp +++ b/src/plugins/clangtools/documentclangtoolrunner.cpp @@ -21,11 +21,12 @@ #include <projectexplorer/projectmanager.h> #include <projectexplorer/target.h> +#include <solutions/tasking/tasktree.h> + #include <texteditor/textdocument.h> #include <texteditor/texteditor.h> #include <utils/qtcassert.h> -#include <utils/tasktree.h> #include <QLoggingCategory> #include <QScopeGuard> diff --git a/src/plugins/coreplugin/locator/ilocatorfilter.h b/src/plugins/coreplugin/locator/ilocatorfilter.h index 8a8114743c..b008c12bb5 100644 --- a/src/plugins/coreplugin/locator/ilocatorfilter.h +++ b/src/plugins/coreplugin/locator/ilocatorfilter.h @@ -5,10 +5,11 @@ #include <coreplugin/core_global.h> +#include <solutions/tasking/tasktree.h> + #include <utils/filepath.h> #include <utils/id.h> #include <utils/link.h> -#include <utils/tasktree.h> #include <QIcon> #include <QKeySequence> diff --git a/src/plugins/coreplugin/progressmanager/taskprogress.cpp b/src/plugins/coreplugin/progressmanager/taskprogress.cpp index 7e59a9b146..c82ec339c5 100644 --- a/src/plugins/coreplugin/progressmanager/taskprogress.cpp +++ b/src/plugins/coreplugin/progressmanager/taskprogress.cpp @@ -6,9 +6,10 @@ #include "futureprogress.h" #include "progressmanager.h" +#include <solutions/tasking/tasktree.h> + #include <utils/mathutils.h> #include <utils/qtcassert.h> -#include <utils/tasktree.h> #include <QFutureWatcher> #include <QTimer> diff --git a/src/plugins/debugger/loadcoredialog.cpp b/src/plugins/debugger/loadcoredialog.cpp index a196fb43d1..4a0fea3f16 100644 --- a/src/plugins/debugger/loadcoredialog.cpp +++ b/src/plugins/debugger/loadcoredialog.cpp @@ -17,7 +17,6 @@ #include <utils/processinterface.h> #include <utils/progressindicator.h> #include <utils/qtcassert.h> -#include <utils/tasktree.h> #include <utils/temporaryfile.h> #include <QCheckBox> diff --git a/src/plugins/diffeditor/diffeditorcontroller.h b/src/plugins/diffeditor/diffeditorcontroller.h index 7f990ecb2f..1f791b2dcb 100644 --- a/src/plugins/diffeditor/diffeditorcontroller.h +++ b/src/plugins/diffeditor/diffeditorcontroller.h @@ -6,7 +6,7 @@ #include "diffeditor_global.h" #include "diffutils.h" -#include <utils/tasktree.h> +#include <solutions/tasking/tasktree.h> #include <QObject> diff --git a/src/plugins/languageclient/clientrequesttask.h b/src/plugins/languageclient/clientrequesttask.h index 98c4888d05..3e08e1a287 100644 --- a/src/plugins/languageclient/clientrequesttask.h +++ b/src/plugins/languageclient/clientrequesttask.h @@ -10,7 +10,8 @@ #include <languageserverprotocol/lsptypes.h> #include <languageserverprotocol/lsputils.h> #include <languageserverprotocol/workspace.h> -#include <utils/tasktree.h> + +#include <solutions/tasking/tasktree.h> namespace LanguageClient { diff --git a/src/plugins/languageclient/currentdocumentsymbolsrequest.h b/src/plugins/languageclient/currentdocumentsymbolsrequest.h index 399a3fe7f0..0b9c11a221 100644 --- a/src/plugins/languageclient/currentdocumentsymbolsrequest.h +++ b/src/plugins/languageclient/currentdocumentsymbolsrequest.h @@ -7,7 +7,8 @@ #include <languageserverprotocol/languagefeatures.h> #include <languageserverprotocol/lsptypes.h> -#include <utils/tasktree.h> + +#include <solutions/tasking/tasktree.h> namespace LanguageClient { diff --git a/src/plugins/projectexplorer/devicesupport/deviceusedportsgatherer.h b/src/plugins/projectexplorer/devicesupport/deviceusedportsgatherer.h index 194ca6f4a6..7be6f9c485 100644 --- a/src/plugins/projectexplorer/devicesupport/deviceusedportsgatherer.h +++ b/src/plugins/projectexplorer/devicesupport/deviceusedportsgatherer.h @@ -7,8 +7,9 @@ #include <projectexplorer/runcontrol.h> +#include <solutions/tasking/tasktree.h> + #include <utils/portlist.h> -#include <utils/tasktree.h> namespace ProjectExplorer { diff --git a/src/plugins/projectexplorer/devicesupport/filetransfer.h b/src/plugins/projectexplorer/devicesupport/filetransfer.h index cb8fcedf9e..f73a374168 100644 --- a/src/plugins/projectexplorer/devicesupport/filetransfer.h +++ b/src/plugins/projectexplorer/devicesupport/filetransfer.h @@ -7,7 +7,7 @@ #include "filetransferinterface.h" #include "idevicefwd.h" -#include <utils/tasktree.h> +#include <solutions/tasking/tasktree.h> namespace Utils { class ProcessResultData; } diff --git a/src/plugins/projectexplorer/devicesupport/idevice.h b/src/plugins/projectexplorer/devicesupport/idevice.h index 55c5e2dea5..f0a902227a 100644 --- a/src/plugins/projectexplorer/devicesupport/idevice.h +++ b/src/plugins/projectexplorer/devicesupport/idevice.h @@ -6,11 +6,12 @@ #include "../projectexplorer_export.h" #include "idevicefwd.h" +#include <solutions/tasking/tasktree.h> + #include <utils/id.h> #include <utils/expected.h> #include <utils/filepath.h> #include <utils/hostosinfo.h> -#include <utils/tasktree.h> #include <QAbstractSocket> #include <QCoreApplication> diff --git a/src/plugins/projectexplorer/extracompiler.h b/src/plugins/projectexplorer/extracompiler.h index bcc0ebee90..1dbda0e424 100644 --- a/src/plugins/projectexplorer/extracompiler.h +++ b/src/plugins/projectexplorer/extracompiler.h @@ -10,7 +10,6 @@ #include <utils/environment.h> #include <utils/filepath.h> -#include <utils/tasktree.h> #include <QByteArray> #include <QHash> @@ -25,6 +24,7 @@ class QPromise; class QThreadPool; QT_END_NAMESPACE +namespace Tasking { class TaskItem; } namespace Utils { class Process; } namespace ProjectExplorer { diff --git a/src/plugins/remotelinux/abstractremotelinuxdeploystep.cpp b/src/plugins/remotelinux/abstractremotelinuxdeploystep.cpp index ae94e6574a..afd4e0e96a 100644 --- a/src/plugins/remotelinux/abstractremotelinuxdeploystep.cpp +++ b/src/plugins/remotelinux/abstractremotelinuxdeploystep.cpp @@ -12,8 +12,9 @@ #include <projectexplorer/projectexplorerconstants.h> #include <projectexplorer/target.h> +#include <solutions/tasking/tasktree.h> + #include <utils/qtcassert.h> -#include <utils/tasktree.h> #include <QDateTime> #include <QPointer> diff --git a/src/plugins/remotelinux/rsyncdeploystep.cpp b/src/plugins/remotelinux/rsyncdeploystep.cpp index a5436c2bbc..84eb47b8cc 100644 --- a/src/plugins/remotelinux/rsyncdeploystep.cpp +++ b/src/plugins/remotelinux/rsyncdeploystep.cpp @@ -18,7 +18,6 @@ #include <utils/algorithm.h> #include <utils/process.h> #include <utils/processinterface.h> -#include <utils/tasktree.h> using namespace ProjectExplorer; using namespace Tasking; diff --git a/src/tools/processlauncher/CMakeLists.txt b/src/tools/processlauncher/CMakeLists.txt index 9360d1e9f6..11149814ab 100644 --- a/src/tools/processlauncher/CMakeLists.txt +++ b/src/tools/processlauncher/CMakeLists.txt @@ -1,7 +1,8 @@ +set(LIBSDIR "${PROJECT_SOURCE_DIR}/src/libs") set(UTILSDIR "${PROJECT_SOURCE_DIR}/src/libs/utils") add_qtc_executable(qtcreator_processlauncher - INCLUDES "${UTILSDIR}" + INCLUDES "${LIBSDIR}" DEPENDS Qt::Core Qt::Network DEFINES UTILS_STATIC_LIBRARY SOURCES diff --git a/src/tools/processlauncher/launchersockethandler.cpp b/src/tools/processlauncher/launchersockethandler.cpp index dae28aa4fb..c7879dc7cc 100644 --- a/src/tools/processlauncher/launchersockethandler.cpp +++ b/src/tools/processlauncher/launchersockethandler.cpp @@ -2,10 +2,10 @@ // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 #include "launchersockethandler.h" - #include "launcherlogging.h" -#include "processreaper.h" -#include "processutils.h" + +#include <utils/processreaper.h> +#include <utils/processutils.h> #include <QCoreApplication> #include <QLocalSocket> @@ -280,4 +280,4 @@ void LauncherSocketHandler::removeProcess(quintptr token) } // namespace Internal } // namespace Utils -#include <launchersockethandler.moc> +#include "launchersockethandler.moc" diff --git a/src/tools/processlauncher/launchersockethandler.h b/src/tools/processlauncher/launchersockethandler.h index d4146ad5f8..05eefb09b8 100644 --- a/src/tools/processlauncher/launchersockethandler.h +++ b/src/tools/processlauncher/launchersockethandler.h @@ -3,7 +3,7 @@ #pragma once -#include <launcherpackets.h> +#include <utils/launcherpackets.h> #include <QByteArray> #include <QHash> diff --git a/src/tools/processlauncher/processlauncher-main.cpp b/src/tools/processlauncher/processlauncher-main.cpp index f23ea88c92..0629ec3c6d 100644 --- a/src/tools/processlauncher/processlauncher-main.cpp +++ b/src/tools/processlauncher/processlauncher-main.cpp @@ -3,7 +3,8 @@ #include "launcherlogging.h" #include "launchersockethandler.h" -#include "singleton.h" + +#include <utils/singleton.h> #include <QtCore/qcoreapplication.h> #include <QtCore/qscopeguard.h> diff --git a/src/tools/processlauncher/processlauncher.qbs b/src/tools/processlauncher/processlauncher.qbs index 757d50f9bb..2f03f7fba5 100644 --- a/src/tools/processlauncher/processlauncher.qbs +++ b/src/tools/processlauncher/processlauncher.qbs @@ -7,7 +7,7 @@ QtcTool { Depends { name: "Qt.network" } cpp.defines: base.concat("UTILS_STATIC_LIBRARY") - cpp.includePaths: base.concat(pathToUtils) + cpp.includePaths: base.concat(pathToLibs) Properties { condition: qbs.targetOS.contains("windows") @@ -24,6 +24,7 @@ QtcTool { "processlauncher-main.cpp", ] + property string pathToLibs: sourceDirectory + "/../../libs" property string pathToUtils: sourceDirectory + "/../../libs/utils" Group { name: "protocol sources" |