Page 14 of 14
Page 269
launch.json
{
"configurations": [
{
"name": "Remote C Debug",
"type": "cppdbg",
"request": "launch",
"program": "${config:remoteDirectory}/${relativeFileDirname}/${fileBasenameNoExtension}",
"args": [],
"stopAtEntry": false,
"cwd": "${config:remoteDirectory}/${relativeFileDirname}",
"environment": [],
"externalConsole": false,
"pipeTransport": {
"debuggerPath": "/usr/bin/gdb",
"pipeProgram": "C:/Windows/System32/OpenSSH/ssh",
"pipeArgs": [
"${config:sshUser}@${config:sshEndpoint}"
],
"pipeCwd": "${workspaceFolder}"
},
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
"sourceFileMap": {
"${config:remoteDirectory}/${relativeFileDirname}": "${fileDirname}"
},
"preLaunchTask": "CopyBuildRemote",
}
]
}
tasks.json
{
"version": "2.0.0",
"tasks": [
{
"label": "copyToRemote",
"type": "shell",
"command": "scp -r ${fileDirname} ${config:sshUser}@${config:sshEndpoint}:${config:remoteDirectory}/",
"problemMatcher": [],
"presentation": {
"showReuseMessage": false,
"clear": true
}
},
{
"label": "copyHeader",
"type": "shell",
"command": "mkdir ${workspaceFolder}/headers/;scp -r ${config:sshUser}@${config:sshEndpoint}:${config:header} ${workspaceFolder}/headers/ ",
"problemMatcher": [],
"presentation": {
"showReuseMessage": false,
"clear": true
}
},
{
"label": "buildRemote",
"type": "shell",
"command": "ssh ${config:sshUser}@${config:sshEndpoint} 'gcc -g -std=${config:std} ${config:remoteDirectory}/${relativeFileDirname}/${fileBasename} ${config:libs} -o${config:remoteDirectory}/${relativeFileDirname}/${fileBasenameNoExtension}'",
"problemMatcher": [],
"presentation": {
"showReuseMessage": false,
"clear": false
}
},
{
"label": "runRemote",
"type": "shell",
"command": "ssh ${config:sshUser}@${config:sshEndpoint} '${config:remoteDirectory}/${relativeFileDirname}/${fileBasenameNoExtension}'",
"problemMatcher": [
"$gcc"
],
"presentation": {
"showReuseMessage": true,
"clear": false
}
},
{
"label": "CopyBuildRunRemote",
"dependsOrder": "sequence",
"dependsOn": [
"copyToRemote",
"buildRemote",
"runRemote"
],
"problemMatcher": [],
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "CopyBuildRemote",
"dependsOrder": "sequence",
"dependsOn": [
"copyToRemote",
"buildRemote",
],
"problemMatcher": [],
},
{
"label": "StopREmoteC",
"type": "shell",
"command": "ssh ${config:sshUser}@${config:sshEndpoint} 'pkill ${fileBasenameNoExtension}'",
"problemMatcher": [],
"presentation": {
"showReuseMessage": true,
}
},
{
"label": "copyARMheaders",
"type": "shell",
"command": "mkdir ${workspaceFolder}/include/; scp -r ${config:sshUser}@${config:sshEndpoint}:/usr/include ${workspaceFolder}/include/ ",
"problemMatcher": [],
"presentation": {
"showReuseMessage": true,
"clear": true
}
},
],
}
c_cpp_properties.json for Mingw
{
"configurations": [
{
"name": "Win32",
"includePath": [
"${workspaceFolder}/**",
"C:/Program Files (x86)/mingw-w64/i686-8.1.0-posix-dwarf-rt_v6-rev0/mingw32/i686-w64-mingw32/include"
],
"defines": [
"_DEBUG",
"UNICODE",
"_UNICODE"
],
"cStandard": "c99",
"intelliSenseMode": "gcc-arm"
}
],
"version": 4
}
- << Prev
- Next