www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.ldc - Does LDC support debugging on Windows with GDB?

reply Bruno Medeiros <brunodomedeiros+dng gmail.com> writes:
I've installed LDC 0.12.1 with the 
i686-w64-mingw32-gcc-dw2-4.8.0-win32_rubenvb.7z MingW installation.

I've tried compiled a simple program with -g and -gc options, but when I 
start GDB, I get:

Reading symbols from D:\devel\Scratchpad.D\DeeTest\myapp.exe...(no 
debugging symbols found)...done.
(gdb) DW_FORM_strp pointing outside of .debug_str section [in module 
D:\devel\Scratchpad.D\DeeTest\myapp-c.exe]

Is LDC outputting debug information in DWARF format or MSVC's? Or is GDB 
not even supported and I have to use LLDB?

-- 
Bruno Medeiros
https://twitter.com/brunodomedeiros
Mar 05 2014
next sibling parent Bruno Medeiros <brunodomedeiros+dng gmail.com> writes:
On 05/03/2014 16:41, Bruno Medeiros wrote:
 I've installed LDC 0.12.1 with the
 i686-w64-mingw32-gcc-dw2-4.8.0-win32_rubenvb.7z MingW installation.

 I've tried compiled a simple program with -g and -gc options, but when I
 start GDB, I get:

 Reading symbols from D:\devel\Scratchpad.D\DeeTest\myapp.exe...(no
 debugging symbols found)...done.
 (gdb) DW_FORM_strp pointing outside of .debug_str section [in module
 D:\devel\Scratchpad.D\DeeTest\myapp-c.exe]

 Is LDC outputting debug information in DWARF format or MSVC's? Or is GDB
 not even supported and I have to use LLDB?
Just found a previous thread regarding the same issue: http://forum.dlang.org/thread/iiqppmojezdrmnsfienq forum.dlang.org Any update on this? -- Bruno Medeiros https://twitter.com/brunodomedeiros
Mar 05 2014
prev sibling parent "Kai Nacke" <kai redstar.de> writes:
Hi Bruno!

On Wednesday, 5 March 2014 at 16:42:03 UTC, Bruno Medeiros wrote:
 I've installed LDC 0.12.1 with the 
 i686-w64-mingw32-gcc-dw2-4.8.0-win32_rubenvb.7z MingW 
 installation.

 I've tried compiled a simple program with -g and -gc options, 
 but when I start GDB, I get:

 Reading symbols from 
 D:\devel\Scratchpad.D\DeeTest\myapp.exe...(no debugging symbols 
 found)...done.
 (gdb) DW_FORM_strp pointing outside of .debug_str section [in 
 module D:\devel\Scratchpad.D\DeeTest\myapp-c.exe]

 Is LDC outputting debug information in DWARF format or MSVC's? 
 Or is GDB not even supported and I have to use LLDB?
LDC emits debug info in DWARF format. It is generally working under Linux. I think it is a LLVM bug. LLVM on MinGW is not very well tested. Regards, Kai
Mar 05 2014