
ipiano/gdb-mcp
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
ipiano/gdb-mcp は [https://github.com/ipiano/gdb-mcp.] からインポートされた MCP サーバー候補です
概要
ipiano/gdb-mcp は [https://github.com/ipiano/gdb-mcp.] からインポートされた MCP サーバー候補です
概要(AI 翻訳)
GDBデバッグセッションへのプログラムアクセスでAIアシスタントを提供するMCP(Model Context Protocol)サーバー。 これは、AIモデルは、GDB / MI(機械インタフェース)プロトコルを使用して、VSコードやCLionなどのIDEと同じ方法でデバッガと対話することができます。
##特徴
- 完全なGDB制御:開始セッション、コマンドの実行、プログラムの実行の制御
- スレッド解析: スレッドを検査し、後退し、スレッドの状態を分析する
- ブレイクポイント管理: 条件付きブレークポイントの設定、一時的なブレークポイント
- 可変的な点検:式を評価し、変数を点検し、登録して下さい -コアダンプ解析:カスタム初期化でコアダンプをロードおよび解析
- 柔軟な初期化:起動時にGDBスクリプトまたはコマンドを実行
アーキテクチャ
このサーバーは、プロのIDEで使用される同じインターフェイスである**GDB/MI (機械インタフェース)**プロトコルを使用します。 それは提供します:
- 構造化された、機械parseable出力
- GDBのデバッグ機能へのフルアクセス
- 信頼性の高いコマンド実行と応答処理
インストール
前提条件
- Python 3.10以上
- PATH に GDB を取付け、利用できる
クイックスタート
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
GDB MCP Server
An MCP (Model Context Protocol) server that provides AI assistants with programmatic access to GDB debugging sessions. This allows AI models to interact with debuggers in the same way IDEs like VS Code and CLion do, using the GDB/MI (Machine Interface) protocol.
Features
- Full GDB Control: Start sessions, execute commands, control program execution
- Thread Analysis: Inspect threads, get backtraces, analyze thread states
- Breakpoint Management: Set conditional breakpoints, temporary breakpoints
- Variable Inspection: Evaluate expressions, inspect variables and registers
- Core Dump Analysis: Load and analyze core dumps with custom initialization
- Flexible Initialization: Run GDB scripts or commands on startup
Architecture
This server uses the GDB/MI (Machine Interface) protocol, which is the same interface used by professional IDEs. It provides:
- Structured, machine-parseable output
- Full access to GDB’s debugging capabilities
- Reliable command execution and response handling
Installation
Prerequisites
- Python 3.10 or higher
- GDB installed and available in PATH
Quick Start
# Install pipx if needed
python3 -m pip install --user pipx
python3 -m pipx ensurepath
# Install gdb-mcp-server
cd /path/to/gdb-mcp
pipx install .
For alternative installation methods (virtual environment, manual setup), see INSTALL.md.
Configuration
Claude Desktop
Add this to your Claude Desktop configuration file:
Location:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Linux:
~/.config/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Configuration:
{
"mcpServers": {
"gdb": {
"command": "gdb-mcp-server"
}
}
}
For other installation methods and MCP clients, see INSTALL.md.
Environment Variables
The GDB MCP Server supports the following environment variables:
GDB_PATH
Specify the path to the GDB executable to use. This is useful when:
- You have multiple GDB versions installed
- GDB is installed in a non-standard location
- You want to use a custom or patched GDB build
Default: gdb (resolved via system PATH)
Example:
export GDB_PATH=/usr/local/bin/gdb-13.2
gdb-mcp-server
Note: The gdb_path parameter in the gdb_start_session tool overrides this environment variable if both are specified.
GDB_MCP_LOG_LEVEL
Set the logging level for the server.
Default: INFO
Options: DEBUG, INFO, WARNING, ERROR, CRITICAL
Example:
export GDB_MCP_LOG_LEVEL=DEBUG
gdb-mcp-server
Available Tools
The GDB MCP Server provides 22 tools for controlling GDB debugging sessions:
Session Management:
gdb_start_session- Start a new GDB session with optional initialization
インストール
This server does not publish a one-line install command.
Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →設定
{
"mcpServers": {
"gdb": {
"command": "gdb-mcp-server"
}
}
}