launch.json 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. {
  2. // Use IntelliSense to learn about possible attributes.
  3. // Hover to view descriptions of existing attributes.
  4. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
  5. "version": "0.2.0",
  6. "configurations": [
  7. {
  8. "name": "(gdb) Launch", // 配置名称,可以根据需要修改
  9. "type": "cppdbg", // 调试器类型
  10. "request": "launch", // 请求类型:启动调试
  11. "program": "${workspaceFolder}/build/fastweb", // 指定要调试的可执行程序路径
  12. "args": [
  13. "start",
  14. "/home/nianhua/www/config.ini"
  15. ], // 程序运行时的命令行参数
  16. "stopAtEntry": false, // 是否在程序入口停止
  17. "cwd": "/home/nianhua/www", // 工作目录
  18. "environment": [], // 运行时的环境变量
  19. "externalConsole": false, // 是否使用外部终端
  20. "MIMode": "gdb", // 使用GDB作为调试器
  21. "miDebuggerPath": "/usr/bin/gdb", // GDB的路径
  22. "preLaunchTask": "build", // 调试前执行的任务
  23. "logging": {
  24. "engineLogging": true // 启用引擎日志记录
  25. },
  26. "setupCommands": [
  27. {
  28. "description": "Enable pretty-printing for gdb",
  29. "text": "-enable-pretty-printing",
  30. "ignoreFailures": true
  31. },
  32. {
  33. "description": "Set Disassembly Flavor to Intel",
  34. "text": "-gdb-set disassembly-flavor intel",
  35. "ignoreFailures": true
  36. }
  37. ]
  38. }
  39. ]
  40. }