Reputation: 23
I have the following setup in my VS solution:
What I want to do is have "Project" set as the startup project, but when it is run, actually run Editor.exe, and have breakpoints work across all three.
On both C++ projects, I have the debugger set to Mixed (.Net Core). Below are some relevant bits in my premake configuration for both:
filter "configurations:Debug or configurations:Editor"
runtime "Debug"
defines {
"ENABLE_MIXED_MODE_DEBUG",
"_DEBUG"
}
symbols "Full"
optimize "Off"
editandcontinue "Off"
debuggertype "NativeWithManagedCore"
justmycode "Off"
symbolspath "$(OutDir)$(TargetName).pdb"
flags {
"MultiProcessorCompile",
"NoIncrementalLink"
}
On the C# project I have the Editor.exe set up as the executable path to run in my launch profiles, native code debugging is enabled, and unsafe code is enabled. The launch settings look like this:
{
"profiles": {
"Mixed Debug": {
"commandName": "Executable",
"workingDirectory": "PATH_TO_EDITOR",
"executablePath": "PATH_TO_EDITOR/Editor.exe",
"nativeDebugging": true,
"symbolLoadInfo": {
"loadAllSymbols": true,
"searchPaths": [
"PATH_TO_EDITOR",
"PATH_TO_CORE"
]
}
}
}
}
(Both Core and Editor properly produce PDBs)
A few relevant bits from the Project's premake file:
symbols "Full"
clr "Unsafe"
location("../")
editandcontinue "Off"
justmycode "Off"
debuggertype "NativeWithManagedCore"
-- These two are probably not needed due to the launch profile.
debugcommand(PATH_TO_EDITOR/Editor.exe)
debugdir(PATH_TO_EDITOR)
filter "configurations:Debug or configurations:Editor"
optimize "Off"
defines { "DEBUG", "TRACE", "ENABLE_MIXED_MODE_DEBUG" }
The result of all this is that it does not work. If I even just run the Editor project directly, breakpoints won't be hit with the debugger type set to Mixed (Net Core). The debugger's modules window will just be empty. If I switch the debugger type back to auto, the Editor and Core projects break normally.
However if I set Project as the startup project, the no matter what the Engine's and Core's debugger type is set to, breakpoints won't work, the modules window is gonna be empty, and if I try to break by hitting the pause button, I get the error "Unable to break execution. The debugger is unable to stop this process as no CLR has been loaded".
Upvotes: 0
Views: 128