MCP GDB サーバー
Claude やその他の AI アシスタントで使用するための GDB デバッグ機能を提供するモデル コンテキスト プロトコル (MCP) サーバー。
特徴
GDBデバッグセッションを開始および管理する
分析のためにプログラムとコアダンプをロードする
ブレークポイントを設定し、コードをステップ実行し、メモリを調べる
コールスタック、変数、レジスタを表示する
任意のGDBコマンドを実行する
Related MCP server: GCP MCP
インストール
# Clone the repository
git clone https://github.com/signal-slot/mcp-gdb.git
cd mcp-gdb
# Install dependencies
npm install
# Build the project
npm run build使用法
Claude や他の MCP 対応アシスタントと併用する
このサーバーを含めるように、Claude デスクトップ アプリまたはブラウザ拡張機能で MCP 設定を構成します。
{
"mcpServers": {
"gdb": {
"command": "node",
"args": ["/path/to/mcp-gdb/build/index.js"],
"disabled": false
}
}
}Claude を再起動するか、ページを更新してください。
これで、Claude との会話で GDB ツールを使用できるようになります。
コマンド例
Claude を介して GDB MCP サーバーを使用する例をいくつか示します。
GDBセッションの開始
Use gdb_start to start a new debugging sessionプログラムの読み込み
Use gdb_load to load /path/to/my/program with the sessionId that was returned from gdb_startブレークポイントの設定
Use gdb_set_breakpoint to set a breakpoint at main in the active GDB sessionプログラムの実行
Use gdb_continue to start execution変数の検討
Use gdb_print to evaluate the expression "my_variable" in the current contextバックトレースを取得する
Use gdb_backtrace to see the current call stackセッションを終了する
Use gdb_terminate to end the debugging sessionサポートされているGDBコマンド
gdb_start: 新しいGDBセッションを開始するgdb_load: プログラムをGDBにロードするgdb_command: 任意のGDBコマンドを実行するgdb_terminate: GDBセッションを終了するgdb_list_sessions: アクティブなGDBセッションをすべて一覧表示するgdb_attach: 実行中のプロセスにアタッチするgdb_load_core: コアダンプファイルをロードするgdb_set_breakpoint: ブレークポイントを設定するgdb_continue: プログラムの実行を継続するgdb_step: ステッププログラム実行gdb_next: 関数呼び出しをステップオーバーするgdb_finish: 現在の関数が戻るまで実行するgdb_backtrace: コールスタックを表示するgdb_print: 式の値を印刷するgdb_examine: メモリを調べるgdb_info_registers: レジスタを表示する
ライセンス
マサチューセッツ工科大学
Resources
Looking for Admin?
Admins can modify the Dockerfile, update the server description, and track usage metrics. If you are the server author, to access the admin panel.