Skip to content

Instantly share code, notes, and snippets.

@saivert
Created May 26, 2019 10:08
Show Gist options
  • Save saivert/af1fd7244d3f6589164b933aa554f56a to your computer and use it in GitHub Desktop.
Save saivert/af1fd7244d3f6589164b933aa554f56a to your computer and use it in GitHub Desktop.
Trying to get vscode to launch flatpak with gdbserver for remote debugging of flatpaks inside vscode.
{
// 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",
"app-id": "",
"configurations": [
{
"name": "(gdb) Launch",
"type": "cppdbg",
"request": "launch",
"program": "/usr/bin/flatpak-spawn",
"args": [
"--host",
"flatpak",
"run",
"--devel",
"--command=gdbserver",
"music.deadbeef.player//master",
"localhost:2222",
"deadbeef"
],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": true,
"MIMode": "gdb",
"miDebuggerServerAddress": "localhost:2222",
// "debugServerPath": "/usr/bin/flatpak-spawn",
// "debugServerArgs": "--host flatpak run --devel --command=gdbserver music.deadbeef.player//master localhost:2222 deadbeef",
//"serverStarted": "Listening on port 2222",
"sourceFileMap": {
"/app/lib/debug/source/deadbeef": "/home/saivert/code/deadbeef"
},
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment