-
-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Different issues when using MinGW and Cygwin GCC Toolchains #455
Comments
I could solve the debugging problem under MinGW {
"testMate.cpp.test.executables": "**/*test.exe",
"testMate.cpp.debug.configTemplate": {
"type": "cppdbg",
"program": "${exec}",
"args": "${argsArray}",
"cwd": "${cwd}",
"env": "${envObj}",
"environment": "${envObjArray}",
"sourceFileMap": "${sourceFileMapObj}",
"MIMode": "gdb",
"miDebuggerPath": "C:\\GCCRuntime\\msys2\\ucrt64\\bin\\gdb.exe"
}, or add the debugger path to the launch.json {
"version": "0.2.0",
"configurations": [
{
"name": "CMake: Configure project",
"type": "cmake",
"request": "launch",
"cmakeDebugType": "configure",
"clean": true,
"configureAll": false
},
{
"name": "Build + Debug App-test",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceRoot}/cmake-build-debug/App_lib/unit-test-tests/APP-test",
"cwd": "${workspaceRoot}",
"preLaunchTask": "Build APP-test Debug",
"MIMode": "gdb",
"miDebuggerPath": "C:\\GCCRuntime\\msys2\\ucrt64\\bin\\gdb.exe"
},
{
"name": "Build + Run App-test",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceRoot}/cmake-build-debug/App_lib/unit-test-tests/APP-test",
"cwd": "${workspaceRoot}",
"preLaunchTask": "Build APP-test Release"
},
]
} |
For the virtual cygwin paths there is an exe file called cygpath to translate those to the equivalent windows paths. Can this tool be given to the test adapter via the settings file to map those virtual paths to real paths so that the test adapter can find the corresponding source files? |
It could I assume. It's just such a corner case.. This is the relevant code The advance executable |
First of all this a great extension and it works perfectly fine in my linux environment.
Unfortunately for work i still have to use Microsuck OS so i am forced to use either Cygwin
or MinGW to compile our google test suite.
I have different issues with both of those toolchains and this testadapter and maybe there is some configuration to work around those issues?
1. Cygwin
Debugging and running tests from test explorer works but not from the source code, also it is not possible to jump to the source code by double clicking on the test in the test explorer.
I think the cause of those issues is that cygwin uses a /cygrive/c path to mount the C:/ folder and testmate can't parse those virtual
cygwin paths.
Maybe there is a configuration to work around those virtual paths?
2. Mingw
Jumping to test source code from test explorer works because unlike cygdrive mingw translates C:/ to /c which powershell can find by itself.
"Run Tests" works from the green button in the source code and from the test explorer.
But debugging doesn't work neither from the test explorer nor from the green buttons in the source.
I dont know what the debug issue with MinGW might be since i did install gdb and it is available as first find in environment path variable.
BR
The text was updated successfully, but these errors were encountered: