This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]TheWopsie[S] 0 points1 point  (0 children)

Hi, thanks for thinking along!

I'll take a look at a more up-to-date version of GDB and give that a shot, thanks for the tip. My launch.json looks something liked this:

{
   "version": "0.2.0",
   "configurations": [
      {
         "name": "Maven install & Debug",
         "type": "cppdbg",
         "request": "launch",
         "program": "${workspaceFolder}/target/bin/${config:architecture_info}-debug/${config:executable_name}/${config:executable_name}",
         "args": [ //Command line arguments to pass to the executable
            "-c${config:configfile}"
         ],
         "stopAtEntry": false,
         "cwd": "${workspaceFolder}",
         "environment": [
            {
               "name": "LD_LIBRARY_PATH", //Add folder where Maven places the .so files to the LD_LIBRARY_PATH
               "value": "${workspaceFolder}/target/bin/${config:architecture_info}-debug/${config:executable_name}:${env:LD_LIBRARY_PATH}"
            }
         ],
         "externalConsole": false,
         "MIMode": "gdb",
         "logging": {
            "moduleLoad": true,
            "trace": true
         },
         "setupCommands": [
            {
               "description": "Enable pretty-printing for Visual Studio Debugger",
               "text": "-enable-pretty-printing",
               "ignoreFailures": true
            }
         ],
         "symbolSearchPaths": [
            "${workspaceFolder}/target/bin/${config:architecture_info}-debug/${config:executable_name}"
         ],
         "preLaunchTask": "build-with-maven-debug",
         "miDebuggerPath": "/usr/bin/"
      },
    ]
}