VISUAL STUDIO CODE + CMAKE + C++ | DEBUG/RELEASE | LINUX/WINDOWS | ОТЛАДКА

156 Просмотры
Издатель
ОТЛАДКА: 3:33
===launch.json

{

"version": "0.2.0",
"configurations": [

{
"name": "CMAKE Debug",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/Debug/Acord",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"preLaunchTask": "build_debug",
"MIMode": "gdb",
"setupCommands": [
{
"description": "Включить автоматическое форматирование для gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
},
{
"name": "CMAKE Release",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/Release/Acord",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"preLaunchTask": "build_release",
"MIMode": "gdb",
"setupCommands": [
{
"description": "Включить автоматическое форматирование для gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
=====TASKS=====
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "build_debug_cmake",
"type": "shell",
"command": "cmake",
"args": [
"-DCMAKE_BUILD_TYPE=Debug",
"../../"
],
"options": {
"cwd": "${workspaceFolder}/build/Debug"
}
},
{
"label": "make_debug",
"type": "shell",
"command": "make",
"options": {
"cwd": "${workspaceFolder}/build/Debug"
}
},
{
"label": "build_debug",
"dependsOn": [
"build_debug_cmake",
"make_debug"
],

},
{
"label": "build_release_cmake",
"type": "shell",
"command": "cmake",
"args": [
"-DCMAKE_BUILD_TYPE=Release",
"../../"
],
"options": {
"cwd": "${workspaceFolder}/build/Release"
}
},
{
"label": "make_release",
"type": "shell",
"command": "make",
"options": {
"cwd": "${workspaceFolder}/build/Release"
}
},
{
"label": "build_release",
"dependsOn": [
"build_release_cmake",
"make_release"
],

},
]
}
Категория
Язык программирования C++
Комментариев нет.