赞
踩
提示:以下是本篇文章正文内容,下面案例可供参考
{
"configurations": [
{
"name": "Ubuntu",
"includePath": ["${workspaceFolder}/**", "${workspaceFolder}/include/*"], // 需要更具自己的实际工程添加定义的头文件路径
"defines": ["_DEBUG", "UNICODE", "_UNICODE"],
"windowsSdkVersion": "10.0.17763.0",
//"compilerPath": "", // g++所在路径
"cStandard": "c11",
"cppStandard": "c++11",
"intelliSenseMode": "${default}"
}
],
"version": 4
}
{
// 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": [
{
"name": "g++ - 生成和调试文件",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/SimulateSystemServer",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"setupCommands": [
{
"description": "为 gdb 启用整齐打印",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
"preLaunchTask": "Build", // 要执行的任务的label名
"miDebuggerPath": "/usr/bin/gdb"
}
]
}
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"options": {
"cwd": "${workspaceFolder}/build"
},
"tasks": [
{
"label": "cmake",
"type": "shell",
"command": "cmake",
"args": [
".."
]
},
{
"label": "make",
"group": {
"kind": "build",
"isDefault": true
},
"command": "make", // windows: mingw32-make
"args": [
]
},
{
"label": "Build",
"dependsOrder": "sequence", // 按列出顺序执行任务依赖项
"dependsOn":[
"cmake",
"make"
]
}
]
}
set(CMAKE_BUILD_TYPE Debug)
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。