diff --git a/CMakeLists.txt b/CMakeLists.txt index 5528c24611..489a6c86fb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,140 +1,144 @@ # KDevelop version set( KDEVELOP_VERSION_MAJOR 4 ) set( KDEVELOP_VERSION_MINOR 90 ) set( KDEVELOP_VERSION_PATCH 92 ) set( KDEVELOP_VERSION "${KDEVELOP_VERSION_MAJOR}.${KDEVELOP_VERSION_MINOR}.${KDEVELOP_VERSION_PATCH}" ) ################################################################################ cmake_minimum_required(VERSION 2.8.12) project(KDevelop) # we need some parts of the ECM CMake helpers find_package (ECM 0.0.9 REQUIRED NO_MODULE) set(CMAKE_MODULE_PATH ${KDevelop_SOURCE_DIR}/cmake/modules ${ECM_MODULE_PATH}) include(ECMOptionalAddSubdirectory) include(ECMInstallIcons) include(ECMAddAppIcon) include(ECMSetupVersion) include(ECMAddTests) include(ECMMarkNonGuiExecutable) include(ECMGenerateHeaders) include(ECMPackageConfigHelpers) include(CTest) include(GenerateExportHeader) include(CMakePackageConfigHelpers) include(FeatureSummary) include(WriteBasicConfigVersionFile) include(CheckFunctionExists) include(KDEInstallDirs) include(KDECMakeSettings) include(KDECompilerSettings NO_POLICY_SCOPE) set(QT_MIN_VERSION "5.4.0") find_package(Qt5 ${QT_MIN_VERSION} CONFIG REQUIRED Widgets Concurrent Quick QuickWidgets WebKitWidgets Script Test) set(KF5_DEP_VERSION "5.15.0") # we need KCrash::initialize find_package(KF5 ${KF5_DEP_VERSION} REQUIRED COMPONENTS Config Declarative DocTools IconThemes I18n ItemModels ItemViews JobWidgets KCMUtils KIO NewStuff NotifyConfig Parts Service TextEditor ThreadWeaver XmlGui WindowSystem Crash ) +find_package(KF5SysGuard) +set_package_properties(KF5SysGuard PROPERTIES + PURPOSE "Framework for process listing. Required for the 'Attach to Process' feature" +) find_package(KDevelop-PG-Qt 1.90.90) set_package_properties(KDevelop-PG-Qt PROPERTIES PURPOSE "KDevelop parser generator library. Required for the QMake Builder/Manager plugin." ) find_package(KDevPlatform ${KDEVELOP_VERSION} REQUIRED) add_definitions( -DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x050400 -DQT_NO_URL_CAST_FROM_STRING -DQT_STRICT_ITERATORS -DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS ) # Turn off missing-field-initializers warning to avoid noise from false positives with empty {} # See discussion: http://mail.kde.org/pipermail/kdevelop-devel/2014-February/046910.html if (CMAKE_COMPILER_IS_GNUCXX) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-missing-field-initializers") endif() if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=undefined-bool-conversion -Werror=tautological-undefined-compare") endif() include_directories(${KDevelop_SOURCE_DIR} ${KDevelop_BINARY_DIR} ) string(TOLOWER "${CMAKE_BUILD_TYPE}" CMAKE_BUILD_TYPE_TOLOWER) if(CMAKE_BUILD_TYPE_TOLOWER MATCHES "debug" OR CMAKE_BUILD_TYPE_TOLOWER STREQUAL "") set(COMPILER_OPTIMIZATIONS_DISABLED TRUE) else() set(COMPILER_OPTIMIZATIONS_DISABLED FALSE) endif() # create config.h configure_file (config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h ) add_subdirectory(pics) add_subdirectory(app) add_subdirectory(formatters) add_subdirectory(languages) add_subdirectory(projectbuilders) add_subdirectory(projectmanagers) add_subdirectory(debuggers) add_subdirectory(app_templates) add_subdirectory(documentation) add_subdirectory(kdeintegration) add_subdirectory(utils) add_subdirectory(file_templates) add_subdirectory(providers) add_subdirectory(shortcuts) add_subdirectory(doc) set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KDevelop") ecm_configure_package_config_file("${CMAKE_CURRENT_SOURCE_DIR}/KDevelopConfig.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/KDevelopConfig.cmake" INSTALL_DESTINATION ${CMAKECONFIG_INSTALL_DIR} ) ecm_setup_version(${KDEVELOP_VERSION_MAJOR}.${KDEVELOP_VERSION_MINOR}.${KDEVELOP_VERSION_PATCH} VARIABLE_PREFIX KDEVELOP VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/kdevelop_version.h" PACKAGE_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/KDevelopConfigVersion.cmake" SOVERSION ${KDEVELOP_LIB_SOVERSION} ) install(FILES "${CMAKE_CURRENT_BINARY_DIR}/kdevelop_version.h" DESTINATION "${KDE_INSTALL_INCLUDEDIR}/kdevelop") install(FILES "${CMAKE_CURRENT_BINARY_DIR}/KDevelopConfig.cmake" "${CMAKE_CURRENT_BINARY_DIR}/KDevelopConfigVersion.cmake" DESTINATION "${CMAKECONFIG_INSTALL_DIR}" ) install(EXPORT KDevelopTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" NAMESPACE KDev:: FILE KDevelopTargets.cmake) # CTestCustom.cmake has to be in the CTEST_BINARY_DIR. # in the KDE build system, this is the same as CMAKE_BINARY_DIR. configure_file(${CMAKE_SOURCE_DIR}/CTestCustom.cmake ${CMAKE_BINARY_DIR}/CTestCustom.cmake) install(FILES org.kde.kdevelop.appdata.xml DESTINATION ${SHARE_INSTALL_PREFIX}/appdata/) feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) diff --git a/config.h.cmake b/config.h.cmake index d46fe4cb71..c1fe1f7f3a 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -1,13 +1,15 @@ #ifndef KDEVELOP_CONFIG_H #define KDEVELOP_CONFIG_H /* config.h. Generated by cmake from config.h.cmake */ #define VERSION "@KDEVELOP_VERSION_MAJOR@.@KDEVELOP_VERSION_MINOR@.@KDEVELOP_VERSION_PATCH@" #define VERSION_MAJOR "@KDEVELOP_VERSION_MAJOR@" #define VERSION_MINOR "@KDEVELOP_VERSION_MINOR@" #define VERSION_PATCH "@KDEVELOP_VERSION_PATCH@" #cmakedefine01 KDEVELOP_SINGLE_APP +#cmakedefine01 KF5SysGuard_FOUND + #endif // KDEVELOP_CONFIG_H diff --git a/debuggers/common/CMakeLists.txt b/debuggers/common/CMakeLists.txt index 96d5aec005..391d8ab8e4 100644 --- a/debuggers/common/CMakeLists.txt +++ b/debuggers/common/CMakeLists.txt @@ -1,64 +1,60 @@ set(debuggercommon_SRCS mi/mi.cpp mi/milexer.cpp mi/miparser.cpp mi/micommand.cpp mi/micommandqueue.cpp dialogs/selectcoredialog.cpp debuglog.cpp # debug session & debugger midebugger.cpp midebugsession.cpp midebuggerplugin.cpp midebugjobs.cpp # controllers mibreakpointcontroller.cpp miframestackmodel.cpp mivariablecontroller.cpp mivariable.cpp stringhelpers.cpp stty.cpp ) - -find_package(KF5SysGuard) if(KF5SysGuard_FOUND) - add_definitions(-DKDEV_ENABLE_DBG_ATTACH_DIALOG) - set(debuggercommon_SRCS - ${debuggercommon_SRCS} + list(APPEND debuggercommon_SRCS dialogs/processselection.cpp ) endif() ki18n_wrap_ui(debuggercommon_SRCS dialogs/selectcoredialog.ui ) # Use old behavior (ignore the visibility properties for static libraries, object # libraries, and executables without exports) on target kdevdebuggercommon (so the # default public visibility is used). # kdevdebuggercommon is used by target test_gdb which is added by ecm_add_test, # which doesn't set CMP0063 so old behavior is used. # If kdevdebuggercommon honors visibility properties (set to hidden), it will cause # linker warnings about direct access to global weak symbol when link against test_gdb if(NOT CMAKE_VERSION VERSION_LESS "3.3") cmake_policy(SET CMP0063 OLD) endif() add_library(kdevdebuggercommon STATIC ${debuggercommon_SRCS}) target_link_libraries(kdevdebuggercommon PUBLIC KDev::Debugger PRIVATE Qt5::Core Qt5::Gui KDev::Util KDev::Language ) if(KF5SysGuard_FOUND) target_link_libraries(kdevdebuggercommon PUBLIC KF5::ProcessUi ) endif() kde_target_enable_exceptions(kdevdebuggercommon PUBLIC) diff --git a/debuggers/common/midebuggerplugin.cpp b/debuggers/common/midebuggerplugin.cpp index 03bb745b86..e702d08c4a 100644 --- a/debuggers/common/midebuggerplugin.cpp +++ b/debuggers/common/midebuggerplugin.cpp @@ -1,310 +1,310 @@ /* * Common code for MI debugger support * * Copyright 1999-2001 John Birch * Copyright 2001 by Bernd Gehrmann * Copyright 2006 Vladimir Prus * Copyright 2007 Hamish Rodda * Copyright 2016 Aetf * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . * */ #include "midebuggerplugin.h" #include "midebugjobs.h" #include "dialogs/processselection.h" #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace KDevelop; using namespace KDevMI; MIDebuggerPlugin::MIDebuggerPlugin(const QString &componentName, QObject *parent) : KDevelop::IPlugin(componentName, parent) { KDEV_USE_EXTENSION_INTERFACE(KDevelop::IStatus) core()->debugController()->initializeUi(); setupToolviews(); setupActions(); setupDBus(); } void MIDebuggerPlugin::setupToolviews() { // TODO: port tool views /* disassemblefactory = new DebuggerToolFactory( this, "org.kdevelop.debugger.DisassemblerView", Qt::BottomDockWidgetArea); lldbfactory = new DebuggerToolFactory( this, "org.kdevelop.debugger.ConsoleView",Qt::BottomDockWidgetArea); core()->uiController()->addToolView( i18n("Disassemble/Registers"), disassemblefactory); core()->uiController()->addToolView( i18n("LLDB"), lldbfactory); #ifndef WITH_OKTETA memoryviewerfactory = nullptr; #else memoryviewerfactory = new DebuggerToolFactory( this, "org.kdevelop.debugger.MemoryView", Qt::BottomDockWidgetArea); core()->uiController()->addToolView( i18n("Memory"), memoryviewerfactory); #endif */ } void MIDebuggerPlugin::setupActions() { KActionCollection* ac = actionCollection(); QAction * action = new QAction(this); action->setIcon(QIcon::fromTheme("core")); action->setText(i18n("Examine Core File...")); action->setToolTip(i18n("Examine core file")); action->setWhatsThis(i18n("Examine core file" "

This loads a core file, which is typically created " "after the application has crashed, e.g. with a " "segmentation fault. The core file contains an " "image of the program memory at the time it crashed, " "allowing you to do a post-mortem analysis.

")); connect(action, &QAction::triggered, this, &MIDebuggerPlugin::slotExamineCore); ac->addAction("debug_core", action); - #ifdef KDEV_ENABLE_DBG_ATTACH_DIALOG +#if KF5SysGuard_FOUND action = new QAction(this); action->setIcon(QIcon::fromTheme("connect_creating")); action->setText(i18n("Attach to Process...")); action->setToolTip(i18n("Attach to process")); action->setWhatsThis(i18n("Attach to process" "

Attaches the debugger to a running process.

")); connect(action, &QAction::triggered, this, &MIDebuggerPlugin::slotAttachProcess); ac->addAction("debug_attach", action); - #endif +#endif } void MIDebuggerPlugin::setupDBus() { m_drkonqiMap = new QSignalMapper(this); connect(m_drkonqiMap, static_cast(&QSignalMapper::mapped), this, &MIDebuggerPlugin::slotDebugExternalProcess); QDBusConnectionInterface* dbusInterface = QDBusConnection::sessionBus().interface(); for (const auto &service : dbusInterface->registeredServiceNames().value()) { slotDBusServiceRegistered(service); } QDBusServiceWatcher* watcher = new QDBusServiceWatcher(this); connect(watcher, &QDBusServiceWatcher::serviceRegistered, this, &MIDebuggerPlugin::slotDBusServiceRegistered); connect(watcher, &QDBusServiceWatcher::serviceUnregistered, this, &MIDebuggerPlugin::slotDBusServiceUnregistered); } void MIDebuggerPlugin::unload() { // TODO: port tool views /* core()->uiController()->removeToolView(disassemblefactory); core()->uiController()->removeToolView(lldbfactory); core()->uiController()->removeToolView(memoryviewerfactory); */ } MIDebuggerPlugin::~MIDebuggerPlugin() { } void MIDebuggerPlugin::slotDBusServiceRegistered(const QString& service) { if (service.startsWith("org.kde.drkonqi")) { // New registration QDBusInterface* drkonqiInterface = new QDBusInterface(service, "/krashinfo", QString(), QDBusConnection::sessionBus(), this); m_drkonqis.insert(service, drkonqiInterface); connect(drkonqiInterface, SIGNAL(acceptDebuggingApplication()), m_drkonqiMap, SLOT(map())); m_drkonqiMap->setMapping(drkonqiInterface, drkonqiInterface); drkonqiInterface->call("registerDebuggingApplication", i18n("KDevelop")); } } void MIDebuggerPlugin::slotDBusServiceUnregistered(const QString& service) { if (service.startsWith("org.kde.drkonqi")) { // Deregistration if (m_drkonqis.contains(service)) delete m_drkonqis.take(service); } } void MIDebuggerPlugin::slotDebugExternalProcess(QObject* interface) { auto dbusInterface = static_cast(interface); QDBusReply reply = dbusInterface->call("pid"); if (reply.isValid()) { attachProcess(reply.value()); QTimer::singleShot(500, this, &MIDebuggerPlugin::slotCloseDrKonqi); m_drkonqi = m_drkonqis.key(dbusInterface); } core()->uiController()->activeMainWindow()->raise(); } void MIDebuggerPlugin::slotCloseDrKonqi() { if (!m_drkonqi.isEmpty()) { QDBusInterface drkonqiInterface(m_drkonqi, "/MainApplication", "org.kde.KApplication"); drkonqiInterface.call("quit"); m_drkonqi.clear(); } } ContextMenuExtension MIDebuggerPlugin::contextMenuExtension(Context* context) { ContextMenuExtension menuExt = IPlugin::contextMenuExtension(context); if (context->type() != KDevelop::Context::EditorContext) return menuExt; EditorContext *econtext = dynamic_cast(context); if (!econtext) return menuExt; QString contextIdent = econtext->currentWord(); if (!contextIdent.isEmpty()) { QString squeezed = KStringHandler::csqueeze(contextIdent, 30); QAction* action = new QAction(this); action->setText(i18n("Evaluate: %1", squeezed)); action->setWhatsThis(i18n("Evaluate expression" "

Shows the value of the expression under the cursor.

")); connect(action, &QAction::triggered, this, [this, contextIdent](){ emit addWatchVariable(contextIdent); }); menuExt.addAction(ContextMenuExtension::DebugGroup, action); action = new QAction(this); action->setText(i18n("Watch: %1", squeezed)); action->setWhatsThis(i18n("Watch expression" "

Adds the expression under the cursor to the Variables/Watch list.

")); connect(action, &QAction::triggered, this, [this, contextIdent](){ emit evaluateExpression(contextIdent); }); menuExt.addAction(ContextMenuExtension::DebugGroup, action); } return menuExt; } void MIDebuggerPlugin::slotExamineCore() { showStatusMessage(i18n("Choose a core file to examine..."), 1000); if (core()->debugController()->currentSession() != nullptr) { KMessageBox::ButtonCode answer = KMessageBox::warningYesNo( core()->uiController()->activeMainWindow(), i18n("A program is already being debugged. Do you want to abort the " "currently running debug session and continue?")); if (answer == KMessageBox::No) return; } MIExamineCoreJob *job = new MIExamineCoreJob(this, core()->runController()); core()->runController()->registerJob(job); // job->start() is called in registerJob } -#ifdef KDEV_ENABLE_DBG_ATTACH_DIALOG +#if KF5SysGuard_FOUND void MIDebuggerPlugin::slotAttachProcess() { showStatusMessage(i18n("Choose a process to attach to..."), 1000); if (core()->debugController()->currentSession() != nullptr) { KMessageBox::ButtonCode answer = KMessageBox::warningYesNo( core()->uiController()->activeMainWindow(), i18n("A program is already being debugged. Do you want to abort the " "currently running debug session and continue?")); if (answer == KMessageBox::No) return; } ProcessSelectionDialog dlg(core()->uiController()->activeMainWindow()); if (!dlg.exec() || !dlg.pidSelected()) return; // TODO: move check into process selection dialog int pid = dlg.pidSelected(); if (QApplication::applicationPid() == pid) KMessageBox::error(core()->uiController()->activeMainWindow(), i18n("Not attaching to process %1: cannot attach the debugger to itself.", pid)); else attachProcess(pid); } #endif void MIDebuggerPlugin::attachProcess(int pid) { MIAttachProcessJob *job = new MIAttachProcessJob(this, pid, core()->runController()); core()->runController()->registerJob(job); // job->start() is called in registerJob } QString MIDebuggerPlugin::statusName() const { return i18n("Debugger"); } void MIDebuggerPlugin::showStatusMessage(const QString& msg, int timeout) { emit showMessage(this, msg, timeout); } diff --git a/debuggers/common/midebuggerplugin.h b/debuggers/common/midebuggerplugin.h index 412ba13ab6..ba9bab996d 100644 --- a/debuggers/common/midebuggerplugin.h +++ b/debuggers/common/midebuggerplugin.h @@ -1,155 +1,158 @@ /* * Common code for MI debugger support * * Copyright 1999-2001 John Birch * Copyright 2001 by Bernd Gehrmann * Copyright 2007 Hamish Rodda * Copyright 2016 Aetf * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . * */ #ifndef MIDEBUGGERPLUGIN_H #define MIDEBUGGERPLUGIN_H +#include "config.h" + #include #include #include #include #include class QDBusInterface; class QSignalMapper; class QUrl; namespace KDevelop { class Context; } namespace KDevMI { class MIDebugSession; class MIDebuggerPlugin : public KDevelop::IPlugin, public KDevelop::IStatus { Q_OBJECT Q_INTERFACES(KDevelop::IStatus) public: MIDebuggerPlugin(const QString& componentName, QObject *parent); ~MIDebuggerPlugin() override; void unload() override; KDevelop::ContextMenuExtension contextMenuExtension( KDevelop::Context* ) override; virtual MIDebugSession *createSession() const = 0; //BEGIN IStatus public: QString statusName() const override; Q_SIGNALS: void clearMessage(KDevelop::IStatus*) override; void showMessage(KDevelop::IStatus*, const QString & message, int timeout = 0) override; void hideProgress(KDevelop::IStatus*) override; void showProgress(KDevelop::IStatus*, int minimum, int maximum, int value) override; void showErrorMessage(const QString&, int) override; //END IStatus Q_SIGNALS: void reset(); void stopDebugger(); void attachTo(int pid); void coreFile(const QString& core); void runUntil(const QUrl &url, int line); void jumpTo(const QUrl &url, int line); void addWatchVariable(const QString& var); void evaluateExpression(const QString& expr); void raiseDebuggerConsoleViews(); protected Q_SLOTS: void slotDebugExternalProcess(QObject* interface); void slotExamineCore(); - #ifdef KDEV_ENABLE_DBG_ATTACH_DIALOG + +#if KF5SysGuard_FOUND void slotAttachProcess(); - #endif +#endif void slotDBusServiceRegistered(const QString& service); void slotDBusServiceUnregistered(const QString& service); void slotCloseDrKonqi(); protected: void setupToolviews(); void setupActions(); void setupDBus(); void attachProcess(int pid); void showStatusMessage(const QString& msg, int timeout); private: QHash m_drkonqis; QSignalMapper* m_drkonqiMap; QString m_drkonqi; }; template class DebuggerToolFactory : public KDevelop::IToolViewFactory { public: DebuggerToolFactory(Plugin * plugin, const QString &id, Qt::DockWidgetArea defaultArea) : m_plugin(plugin), m_id(id), m_defaultArea(defaultArea) {} QWidget* create(QWidget *parent = 0) override { return new T(m_plugin, parent); } QString id() const override { return m_id; } Qt::DockWidgetArea defaultPosition() override { return m_defaultArea; } void viewCreated(Sublime::View* view) override { if (view->widget()->metaObject()->indexOfSignal(QMetaObject::normalizedSignature("requestRaise()")) != -1) QObject::connect(view->widget(), SIGNAL(requestRaise()), view, SLOT(requestRaise())); } /* At present, some debugger widgets (e.g. breakpoint) contain actions so that shortcuts work, but they don't need any toolbar. So, suppress toolbar action. */ QList toolBarActions(QWidget* viewWidget) const override { Q_UNUSED(viewWidget); return QList(); } private: Plugin * m_plugin; QString m_id; Qt::DockWidgetArea m_defaultArea; }; } // end of namespace KDevMI #endif // MIDEBUGGERPLUGIN_H diff --git a/debuggers/gdb/debuggerplugin.h b/debuggers/gdb/debuggerplugin.h index 6cb7e14239..7458f21106 100644 --- a/debuggers/gdb/debuggerplugin.h +++ b/debuggers/gdb/debuggerplugin.h @@ -1,86 +1,88 @@ /* * GDB Debugger Support * Copyright 2016 Aetf * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . * */ #ifndef _DEBUGGERPART_H_ #define _DEBUGGERPART_H_ +#include "config.h" + #include #include #include #include #include #include #include #include #include "midebuggerplugin.h" #include "debugsession.h" class QLabel; class QMenu; class QDBusInterface; class QSignalMapper; class ProcessWidget; class KToolBar; class QAction; namespace KDevelop { class Context; class ProcessLineMaker; } namespace KDevMI { namespace GDB { class DisassembleWidget; class GDBOutputWidget; class MemoryViewerWidget; class CppDebuggerPlugin : public MIDebuggerPlugin { Q_OBJECT public: friend class DebugSession; CppDebuggerPlugin(QObject *parent, const QVariantList & = QVariantList()); ~CppDebuggerPlugin() override; DebugSession *createSession() const override; void unload() override; private: void setupToolviews(); private: DebuggerToolFactory* disassemblefactory; DebuggerToolFactory* gdbfactory; DebuggerToolFactory* memoryviewerfactory; }; } // end of namespace GDB } // end of namespace KDevMI #endif