vscode配置gdb调试外部程序
有一个工程是用qtcreator编译的
我现在用vscode远程访问的这个工程,目前只能在vscode界面编辑代码。
编译需要在qtcreator下面。
刚开始也只能在 qtcreator下面 调试(debug,打断点)
目前在vscode里面安装了 gdb工具之后,就可以直接调试 qtcreator 编译好的二进制文件了。而且可以打断点。
下面是launch.json文件里面的配置。注意路径地址。
{ // Use IntelliSense to learn about possible attributes. // Hover to view descriptions of existing attributes. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ { "type": "cppdbg", "request": "launch", "name": "gdb1", "program": "${workspaceFolder}/common/bin/x64/Debug/guide_pg_server", "MIMode": "gdb", "cwd": "${workspaceFolder}/common/bin/x64/Debug" }, { "type": "cppdbg", "request": "launch", "name": "gdb2", "program": "${workspaceFolder}/common/bin/x64/Debug/gd_pgclient_unit_d", "MIMode": "gdb", "cwd": "${workspaceFolder}/common/bin/x64/Debug" }, { "type": "cppdbg", "request": "launch", "name": "gdb3", "program": "${workspaceFolder}/common/bin/x64/Debug/guide_pgclient_service", "MIMode": "gdb", "cwd": "${workspaceFolder}/common/bin/x64/Debug" } ] }
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· DeepSeek 开源周回顾「GitHub 热点速览」
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· AI与.NET技术实操系列(二):开始使用ML.NET
· 单线程的Redis速度为什么快?
2023-04-12 python dict, list 转字符串
2023-04-12 Python json 读取 json 文件并转为 dict
2023-04-12 关于Python里面小数点精度控制的问题
2023-04-12 Python使用字典get()方法TypeError: get() takes no keyword arguments
2020-04-12 Node.js快速创建一个Express应用的几个步骤
2013-04-12 STL学习笔记-- priority_queue