Я бы хотел отладить C DLL quickfuncs.dll
, скомпилированную с помощью -g (символы отладки) MinGW64 в VSCode.Эта DLL-библиотека используется C # DLL (также скомпилированной с символами отладки), которая запускается: "C:\Program Files\dotnet\dotnet.exe" exec "D:\Server\bin\Debug\netcoreapp2.0\Server.dll" Parameter1=test
Я настроил launch.json
на основе https://github.com/Microsoft/vscode-cpptools/blob/master/launch.md
{
// 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": "(gdb) Attach to process",
"type": "cppdbg",
"request": "attach",
"program": "C:/Program Files/dotnet/dotnet.exe",
"processId": "${command:pickProcess}",
"MIMode": "gdb",
"miDebuggerPath": "c:/msys2/mingw64/bin/gdb.exe",
"targetArchitecture": "x64",
"additionalSOLibSearchPath": "${workspaceFolder}/bin/Debug/win64/;d:\\Server\\src\\Server\\WorkingDirectory\\",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": false,
}
],
"logging": {
"trace": true,
"traceResponse": true
},
}
]
}
После присоединения процесса, не мог установить точку брака с этим журналом:
C setBreakpoints: {"source":{"name":"api.c","path":"D:\\c_code\\quickfuncs\\api.c"},"lines":[246],"breakpoints":[{"line":246}],"sourceModified":false}
R: {"success":true,"message":null,"request_seq":11,"command":"setBreakpoints","body":{"breakpoints":[{"id":3,"verified":true,"line":246,"message":null}]},"running":false,"refs":null,"seq":0,"type":"response"}
E breakpoint: {"reason":"changed","breakpoint":{"id":3,"verified":false,"line":246,"message":"Attempting to bind the breakpoint...."},"type":"breakpoint"}
Не могли бы вы помочь мне, пожалуйста?