博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
配置visual studio code for Mac 调试c/c++
阅读量:7225 次
发布时间:2019-06-29

本文共 4084 字,大约阅读时间需要 13 分钟。

c_cpp_properties.json:

1 { 2     "configurations": [ 3         { 4             "name": "Mac", 5             "includePath": [ 6                 "/usr/local/include", 7                 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1", 8                 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include", 9                 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include",10                 "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include",11                 "${workspaceRoot}"12             ],13             "defines": [],14             "intelliSenseMode": "clang-x64",15             "browse": {16                 "path": [17                     "/usr/local/include",18                     "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1",19                     "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include",20                     "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include",21                     "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include",22                     "${workspaceRoot}"23                 ],24                 "limitSymbolsToIncludedHeaders": true,25                 "databaseFilename": ""26             },27             "macFrameworkPath": [28                 "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks"29             ]30         },31         {32             "name": "Linux",33             "includePath": [34                 "/usr/include",35                 "/usr/local/include",36                 "${workspaceRoot}"37             ],38             "defines": [],39             "intelliSenseMode": "clang-x64",40             "browse": {41                 "path": [42                     "/usr/include",43                     "/usr/local/include",44                     "${workspaceRoot}"45                 ],46                 "limitSymbolsToIncludedHeaders": true,47                 "databaseFilename": ""48             }49         },50         {51             "name": "Win32",52             "includePath": [53                 "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include",54                 "${workspaceRoot}"55             ],56             "defines": [57                 "_DEBUG",58                 "UNICODE"59             ],60             "intelliSenseMode": "msvc-x64",61             "browse": {62                 "path": [63                     "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include/*",64                     "${workspaceRoot}"65                 ],66                 "limitSymbolsToIncludedHeaders": true,67                 "databaseFilename": ""68             }69         }70     ],71     "version": 372 }

launch.json:

1     // 使用 IntelliSense 了解相关属性。  2     // 悬停以查看现有属性的描述。 3     // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387 4     { 5         "version": "0.2.0", 6         "configurations": [ 7     { 8         "name": "(lldb) Launch", 9         "type": "cppdbg",10         "request": "launch",11         "program": "${workspaceRoot}/a.out",12         "args": [],13         "stopAtEntry": false,14         "cwd": "${workspaceRoot}",15         "environment": [],16         "externalConsole": true,17         "MIMode": "lldb"18     }

tasks.json:

1 {2     // See https://go.microsoft.com/fwlink/?LinkId=7335583     // for the documentation about the tasks.json format4     "version": "0.1.0",5     "command": "clang", //使用clang编译C文件,如果你使用C++开发,改成clang++6     "isShellCommand": true,7     "args": ["main.c", "-g"],//如果使用的是C++,则改成main.cpp或者相对应的cpp入口文件。如果需要支持C++11,添加"-std=c++11"8     "showOutput": "always"9 }

 

转载于:https://www.cnblogs.com/stephenzhang0713/p/8018496.html

你可能感兴趣的文章
无标题
查看>>
我的友情链接
查看>>
Web前端入门学习(3)——CSS选择器
查看>>
DNS的搭建
查看>>
Apache/Nginx 访问日志分析脚本
查看>>
Curator的使用
查看>>
第五章 集合类型
查看>>
我的友情链接
查看>>
nagios监控服务出现FLAPPING状态时无法发出邮件报警信息
查看>>
数据库链接字符串方法
查看>>
The DCI Architecture: A New Vision of Object-Oriented Programming(一篇具有里程碑式意义的论文)...
查看>>
RIP路由配置实例V2
查看>>
Bytescout Spreadsheet SDK for.NET
查看>>
我的友情链接
查看>>
Haproxy的三种保持客户端会话保持方式
查看>>
iOS的数学函数
查看>>
python 模块 chardet下载及介绍(转)
查看>>
能力工场--关于在JavaScript中使用EL表达式的问题
查看>>
NFS服务器设置
查看>>
s:iterator 中的status 使用方法
查看>>