dotBunny / CLionSourceCodeAccess

A CLion Plugin for Unreal Engine
138 stars 26 forks source link

Unable to debug on Windows #70

Open filipeuva opened 6 years ago

filipeuva commented 6 years ago

I'm unable to debug with the specified x64 GDB on Windows.

AzazKamaz commented 6 years ago

GDB specified as optional, I mean it can be used, if you want to code on C++ without UE4, then you dont need to configure CLion again

filipeuva commented 6 years ago

I see, I read on the forums people got it working on Linux, just want to understand if the limitation is platform specific and whether the fault lies with GDB or UBT

AzazKamaz commented 6 years ago

Building on Windows generates .pdb debug symbols file, so you cant debug your game with GDB (it cant load .pdb), but maybe you can debug your game with Visual Studio.

If you want to set breakpoint in your code, you need to include and call function __debugbreak() in your code: https://msdn.microsoft.com/en-us/library/f408b4et.aspx

AzazKamaz commented 6 years ago

I usually debug via GEngine->AddOnScreenDebugMessage

filipeuva commented 6 years ago

Is that a limit of platform then ? Maybe I'm interpreting this naively but shouldn't it be a question of signaling UBT to make clang compile with debug symbols ?

On Building on Linux they specify you have to build against the Debug profile for GDB to have access to editor symbols, tried modifying CMakeLists to generate a Debug build but cmake gave me an error 5 : access is denied.

I'm already using that, thanks :) When I really need to debug I switch to VS, we're just so close of having a real alternative to VS on Win that it pains me :D