Can I use old gcc?

Ralf Corsepius corsepiu at faw.uni-ulm.de
Tue Sep 2 06:22:59 UTC 2003


On Mon, 2003-09-01 at 13:14, Leon Pollak wrote:
> On Monday 01 September 2003 08:44, you wrote:
> > On Sun, 2003-08-31 at 21:24, Leon Pollak wrote:
> > > Hello.
> > > 	For some specific reason I am forced to use the old gcc 2.95 (old
> > > binults, etc...).
> > I wonder why one would want to do THAT :-) ?
> The cause is very prosaic :-))
> gcc 3.2.xx requires gdb> 5.2. I want to work with mpc860-bdm in linux, which 
> was developed for 5.0. My attempts to patch 5.2 failed - too many structural 
> changes where done to 5.2 and my knowledge of gdb is zero.
> 
> BTW, my previous question you commented about the debug info is the 
> illustration to what I said above - gdb 5.0 does not recognize the DWARF info 
> produced by gcc 3.2. 
FWIW: From what I see in gcc's source code, 
gcc-2.95.2 seems to be using dwarf, while gcc-3.2.x seems to be using
dwarf2. (cf. asm_debug in
/opt/rtems/lib/gcc-lib/powerpc-rtems/3.2.3/specs).

In addition to that, make/custom/mbx8xx.cfg for some reason I don't
know, has -ggdb in its CFLAGS_DEBUG_V.

So, if the cause of gdb-bdm-5.0 not being able to read the debug info
produced by gcc-3.2.3, is lack of dwarf2-support in gdb or your BSP's
*.cfg forcing -ggdb, you might get away by explicitly using -gdwarf in
your BSP's CFLAGS.

[A brute force way to try this would be to remove all -g* flags from
<BSP>.cfg and to replace the -gdwarf2 in gcc's specs with -gdwarf].

Ralf





More information about the users mailing list