comp.lang.ada
 help / color / mirror / Atom feed
* GCC on Sparc (was Re: GCC/GDB for UnixWare)
       [not found]       ` <3a5r6o$rnb@hustle.rahul.net>
@ 1994-11-16  1:51         ` Cary Jamison
  1994-11-17  5:47           ` Cyrille Comar
  0 siblings, 1 reply; 2+ messages in thread
From: Cary Jamison @ 1994-11-16  1:51 UTC (permalink / raw)


In article <3a5r6o$rnb@hustle.rahul.net>, "Ronald F. Guilmette"
<rfg@rahul.net> wrote:

> The truth is that the vendor (Cygnus) has already acted to `fix' this
> problem.  You can already get versions of GCC and G++ and GDB which
> know how to write (and read) STABS-in-ELF.  Just call Cygnus and sign
> up as a support customer.  (This functionality may be available in the
> FSF versions of these tools someday also.  For all I know, it may already
> be available in the FSF versions.  It certainly already is if you happen
> to be working on a Sparc.  Just don't try using GCC or G++ with Sun's
> DBX debugger or using Sun's C or C++ compilers with GDB.  This doesn't
> work because Sun's STABS are different from, and incompatible with Cygnus'
> STABS.)

I've got an Ada application that calls C routines.  I'm using SunAda 2.1
and GCC 2.5.8 on Solaris 2.3.  The GCC manual says it can produce stabs
info either with or without extra GDB stuff.  Are you saying that without
the extra GDB stuff, it still isn't compatible (-gstabs)?

The SunAda debugger says it can debug C routines, but I'm having trouble
getting it to work properly.  One problem is that it crashes with a signal
11 if I turn on 'set verbose on' in the .dbrc file, which it says to do to
debug C.  Has anyone else got this to work, either with GCC or Sun's CC?

(SunAda also says to compile C with -xs, from reading the man pages, it
appears I can do the same with GCC -Wa,-s.)

My next step is to try to debug the Ada program in GDB!  I hope I can at
least step through the C code I want to look at.

-- 
Cary Jamison
cary@svl.trw.com



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

* Re: GCC on Sparc (was Re: GCC/GDB for UnixWare)
  1994-11-16  1:51         ` GCC on Sparc (was Re: GCC/GDB for UnixWare) Cary Jamison
@ 1994-11-17  5:47           ` Cyrille Comar
  0 siblings, 0 replies; 2+ messages in thread
From: Cyrille Comar @ 1994-11-17  5:47 UTC (permalink / raw)


cary@svl.trw.com (Cary Jamison) writes:
: 
: I've got an Ada application that calls C routines.  I'm using SunAda 2.1
: and GCC 2.5.8 on Solaris 2.3.  The GCC manual says it can produce stabs
: info either with or without extra GDB stuff.  Are you saying that without
: the extra GDB stuff, it still isn't compatible (-gstabs)?
: 
: The SunAda debugger says it can debug C routines, but I'm having trouble
: getting it to work properly.  One problem is that it crashes with a signal
: 11 if I turn on 'set verbose on' in the .dbrc file, which it says to do to
: debug C.  Has anyone else got this to work, either with GCC or Sun's CC?
: 
: (SunAda also says to compile C with -xs, from reading the man pages, it
: appears I can do the same with GCC -Wa,-s.)
: 
: My next step is to try to debug the Ada program in GDB!  I hope I can at
: least step through the C code I want to look at.

GDB works perfectly well with a program written partially in C, in C++ and in
Ada, at least when you use the gcc compilers (gcc, g++ and gnat).
you can step in all code whatever the language it is written in.
GDB has no specific knowledge about Ada (it has about C and C++) but eventhough
it is possible use it quite efficiently with Ada code, you just have to use
C expressions instead of Ada's. 
We have been using it successfully for more than one year for the GNAT
development which is written in Ada9x and in C.
I have been testing the new GNAT/C++ interface recently and GDB works perfectly
well in this context too...
-- 
------------------------------------------------------------------------
Cyrille Comar,                                  E-mail: comar@cs.nyu.edu
Gnat Project                                    US phone: (212) 998-3489




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

end of thread, other threads:[~1994-11-17  5:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <39707e$k94@csbh.mhv.net>
     [not found] ` <39de69$69g@potogold.rmii.com>
     [not found]   ` <FB.94Nov7173725@oce-int.oceonics.nl>
     [not found]     ` <Cz0M0z.As3@gsl.com>
     [not found]       ` <3a5r6o$rnb@hustle.rahul.net>
1994-11-16  1:51         ` GCC on Sparc (was Re: GCC/GDB for UnixWare) Cary Jamison
1994-11-17  5:47           ` Cyrille Comar

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