Subject: [blymn@baesystems.com.au: Re: gdb 5.0 in NetBSD?]
To: None <ac131313@cygnus.com>
From: Frank van der Linden <frank@wins.uva.nl>
List: tech-toolchain
Date: 05/31/2000 10:55:18
I'm forwarding this one to Andrew Cagney and tech-toolchain, hopefully
it can be analyzed/fixed.

- Frank

----- Forwarded message from Brett Lymn <blymn@baesystems.com.au> -----

From: blymn@baesystems.com.au (Brett Lymn)
Subject: Re: gdb 5.0 in NetBSD?

[...]
Your doubts are correct, at least on i386.  GDB barfs in gdb/solib.c
in, to me, a non-obvious way -they have these defines at the top of
the file:

#define SOLIB_EXTRACT_ADDRESS(member) \
  extract_address (&member, sizeof (member))
#define LM_ADDR(so) (SOLIB_EXTRACT_ADDRESS ((so) -> lm.lm_addr))

and this line of code:

      p->addr += LM_ADDR (so);

gets translated to this:

      p->addr += (extract_address (& ( so ) -> lm. som_addr  , sizeof ( ( so ) -> lm. som_addr  )) ) ;

Note the "som_addr" - what puzzles me is how that turned up.