Latest GDB version problems

Piotrek starpit at tlen.pl
Mon May 10 11:48:16 PDT 2010


Hi,

I tried to debug program in gdb (with d support) but with no big success.

I'm on kubuntu 10.04

I compiled gdb from trunk.  7.1.50.20100504

I use the -gc switch with dmd of course.

With this example (brakeboint at line 8)

1. import std.stdio;
2.
3.
4. void main()
5. {
6.     int i = 1;
7.     string s = "Hello";
8.     float f;
9. }

gdb produces:

(gdb) info locals
i = 1
s = 578159222890430469
f = 9.55146781e-38
(gdb) show language
The current source language is "auto; currently d".



worse is that following example:

1. import std.stdio;
2.
3.
4. void main()
5. {
6.     int i = 1;
7.     string s = "Hello";
8.     float f;
9.     writeln ("Hello");
10.}

gives seg falut:

Reading symbols from 
/home/pio/dev/d/projects/cb_test/hello...Segmentation fault


Does anyone can work with gdb on linux?

Cheers
Piotrek



More information about the Digitalmars-d-learn mailing list