Thread overview
Debugging a dub build
Jan 21, 2019
Per Nordlöw
Jan 21, 2019
Per Nordlöw
Jan 21, 2019
JN
Jan 21, 2019
Jacob Carlborg
January 21, 2019
What's the easiest way to debug a dub app build?

Is there a better way than

    dub run

followed by

    gdb run PATH_TO_APP_BINARY

?
January 21, 2019
On Monday, 21 January 2019 at 11:14:35 UTC, Per Nordlöw wrote:
> What's the easiest way to debug a dub app build?
>
> Is there a better way than
>
>     dub run
>
> followed by
>
>     gdb run PATH_TO_APP_BINARY
>
> ?

Correction should be

    dub build --build=unittest

or

    dub build --build=debug

followed by

    gdb PATH_TO_APP_BINARY
January 21, 2019
On Monday, 21 January 2019 at 11:16:31 UTC, Per Nordlöw wrote:
> Correction should be
>
>     dub build --build=unittest
>
> or
>
>     dub build --build=debug
>
> followed by
>
>     gdb PATH_TO_APP_BINARY

Does using an IDE count? Some D IDEs should be able to assist in debugging.
January 21, 2019
On 2019-01-21 12:14, Per Nordlöw wrote:
> What's the easiest way to debug a dub app build?
> 
> Is there a better way than
> 
>      dub run
> 
> followed by
> 
>      gdb run PATH_TO_APP_BINARY

No, there's nothing specific with an application built using Dub. Dub doesn't provide any help with debugging. Just make sure you're debugging a debug build.

-- 
/Jacob Carlborg