comp.lang.ada
 help / color / mirror / Atom feed
* debugging with gdb
@ 2003-12-15 10:32 antonio
  2003-12-15 11:43 ` Georg Bauhaus
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: antonio @ 2003-12-15 10:32 UTC (permalink / raw)


I'totally new in ada95 and i try to debug a simple program written in
ada95 (i.e hello world).I have compiled with gnatmake(-g option)and i
get an executable that   i ran into gdb.It works but i can't see the
original source using the gdb command 'list' and (obviously) i can't
put any break point where i want like i usually do when i work in C.
why?
tank you in advance.

Antonio



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: debugging with gdb
  2003-12-15 10:32 debugging with gdb antonio
@ 2003-12-15 11:43 ` Georg Bauhaus
  2003-12-15 12:20 ` Martin Dowie
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Georg Bauhaus @ 2003-12-15 11:43 UTC (permalink / raw)


antonio <bergnoli@pd.infn.it> wrote:
: I'totally new in ada95 and i try to debug a simple program written in
: ada95 (i.e hello world).I have compiled with gnatmake(-g option)and i
: get an executable that   i ran into gdb.It works but i can't see the
: original source using the gdb command 'list' and (obviously) i can't
: put any break point where i want like i usually do when i work in C.
: why?
: tank you in advance.

What Version of GNAT and what version of gdb are you using?


-- Georg



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: debugging with gdb
  2003-12-15 10:32 debugging with gdb antonio
  2003-12-15 11:43 ` Georg Bauhaus
@ 2003-12-15 12:20 ` Martin Dowie
  2003-12-15 15:39 ` Ludovic Brenta
  2003-12-15 16:01 ` Preben Randhol
  3 siblings, 0 replies; 5+ messages in thread
From: Martin Dowie @ 2003-12-15 12:20 UTC (permalink / raw)


"antonio" <bergnoli@pd.infn.it> wrote in message
news:6b257ddc.0312150232.2cece50@posting.google.com...
> I'totally new in ada95 and i try to debug a simple program written in
> ada95 (i.e hello world).I have compiled with gnatmake(-g option)and i
> get an executable that   i ran into gdb.It works but i can't see the
> original source using the gdb command 'list' and (obviously) i can't
> put any break point where i want like i usually do when i work in C.
> why?
> tank you in advance.

You could try downloading GVD - a GUI front end to gdb. This may
make life little easier. It's now integrated into GPS an IDE for GNAT.

http://libre.act-europe.fr/gps/





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: debugging with gdb
  2003-12-15 10:32 debugging with gdb antonio
  2003-12-15 11:43 ` Georg Bauhaus
  2003-12-15 12:20 ` Martin Dowie
@ 2003-12-15 15:39 ` Ludovic Brenta
  2003-12-15 16:01 ` Preben Randhol
  3 siblings, 0 replies; 5+ messages in thread
From: Ludovic Brenta @ 2003-12-15 15:39 UTC (permalink / raw)


bergnoli@pd.infn.it (antonio) writes:

> I'totally new in ada95 and i try to debug a simple program written in
> ada95 (i.e hello world).I have compiled with gnatmake(-g option)and i
> get an executable that   i ran into gdb.It works but i can't see the
> original source using the gdb command 'list' and (obviously) i can't
> put any break point where i want like i usually do when i work in C.
> why?
> tank you in advance.
> 
> Antonio

Perhaps GDB is looking in the wrong directory for your source files.
You can specify where your source files are using the `dir' command
(try `help dir', too).  I could help better if you gave us the exact
commands you used to compile your program and to run GDB.  Also, does
GDB output any error message when you say `list'?

You can debug Ada programs using GDB, but GDB by default does not
understand Ada syntax, and you won't be able to set breakpoints on
exceptions.  For these additional features, you need an Ada-aware GDB
available from http://libre.act-europe.fr/GDB.  If you are a Debian
user, you can also apt-get install gnat-gdb to get it (in unstable).

Others have pointed you to GVD and GPS.  Both are front-ends to GDB,
so you'll need GDB to work for you anyway.  Emacs also has such a
front-end.

HTH

-- 
Ludovic Brenta.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: debugging with gdb
  2003-12-15 10:32 debugging with gdb antonio
                   ` (2 preceding siblings ...)
  2003-12-15 15:39 ` Ludovic Brenta
@ 2003-12-15 16:01 ` Preben Randhol
  3 siblings, 0 replies; 5+ messages in thread
From: Preben Randhol @ 2003-12-15 16:01 UTC (permalink / raw)


On 2003-12-15, antonio <bergnoli@pd.infn.it> wrote:
> I'totally new in ada95 and i try to debug a simple program written in
> ada95 (i.e hello world).I have compiled with gnatmake(-g option)and i
> get an executable that   i ran into gdb.It works but i can't see the
> original source using the gdb command 'list' and (obviously) i can't
> put any break point where i want like i usually do when i work in C.
> why?
> tank you in advance.
>

You are most likely using a gdb version that is not Ada-aware. PLease
state: OS you use, version of gdb and gnat.


-- 
"Saving keystrokes is the job of the text editor, not the programming
 language."



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-12-15 16:01 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-15 10:32 debugging with gdb antonio
2003-12-15 11:43 ` Georg Bauhaus
2003-12-15 12:20 ` Martin Dowie
2003-12-15 15:39 ` Ludovic Brenta
2003-12-15 16:01 ` Preben Randhol

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox