www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - generate debug file, DUB, LDC etc...

reply willo <no here.com> writes:
Im trying to get MSVC to debug my binary. I've added...

"dflags": ["-g"],

at the top level in dub.json to try and get LDC to generate debug 
info. But doesnt seem to have done anything.
Nov 19 2018
parent reply kinke <noone nowhere.com> writes:
On Monday, 19 November 2018 at 10:04:25 UTC, willo wrote:
 Im trying to get MSVC to debug my binary. I've added...

 "dflags": ["-g"],

 at the top level in dub.json to try and get LDC to generate 
 debug info. But doesnt seem to have done anything.
I guess you need `-g` for the `lflags` too, assuming dub uses LDC for linking.
Nov 19 2018
parent willo <no here.com> writes:
On Monday, 19 November 2018 at 19:52:31 UTC, kinke wrote:
 On Monday, 19 November 2018 at 10:04:25 UTC, willo wrote:
 Im trying to get MSVC to debug my binary. I've added...

 "dflags": ["-g"],

 at the top level in dub.json to try and get LDC to generate 
 debug info. But doesnt seem to have done anything.
I guess you need `-g` for the `lflags` too, assuming dub uses LDC for linking.
My bad, I didn't read the output properly, the debugger couldn't find the debug info for all the system dlls but had found it for my program. There's a box you tick in MSVC options to get it to download debug info for the system dlls, worked ok after that. That said it doesn't work very well.
Nov 20 2018