This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: External debug symbols
- From: Alexander Larsson <alexl at redhat dot com>
- To: Daniel Jacobowitz <drow at mvista dot com>
- Cc: Elena Zannoni <ezannoni at redhat dot com>, <gdb at sources dot redhat dot com>, Jim Blandy <jimb at redhat dot com>
- Date: Mon, 23 Sep 2002 03:46:15 -0400 (EDT)
- Subject: Re: External debug symbols
On Fri, 20 Sep 2002, Daniel Jacobowitz wrote:
> On Fri, Sep 20, 2002 at 11:11:09AM -0400, Elena Zannoni wrote:
> >
> > I have looked at this. I think it's a valuable thing to have. I have
> > a few questions about the approach, and a few more specific comments
> > about the code. I haven't followed all the implications of this patch.
> > What do other folks think?
>
> In general, I'm in love with it.
>
> > > diff --exclude '*~' --exclude '*.orig' --exclude '*.rej' --exclude '.#*' --exclude '*.o' --exclude CVS --exclude SCCS --exclude RCS --exclude '.*.flags' --exclude .cvsignore --exclude .depend -ur gdb-5.2.1/gdb/configure.in gdb-5.2.1.separate_debug_symbols/gdb/configure.in
> > > --- gdb-5.2.1/gdb/configure.in Thu Mar 28 05:28:00 2002
> > > +++ gdb-5.2.1.separate_debug_symbols/gdb/configure.in Mon Aug 26 17:02:48 2002
> > > @@ -234,6 +234,14 @@
> > > AC_CHECK_LIB(socket, socketpair)
> > > AC_CHECK_FUNCS(socketpair)
> > >
> > > +debugdir=${libdir}/debug
> > > +
> > > +AC_ARG_WITH(separate-debug-dir,
> > > +[ --with-separate-debug-dir=path Look for global separate debug info in this path [LIBDIR/debug]],
> > > +[debugdir="${withval}"])
> > > +
> > > +AC_DEFINE_DIR(DEBUGDIR, debugdir)
> > > +#AC_DEFINE_UNQUOTED(DEBUGDIR, "$debugdir"),
> > >
> >
> > Could this be done alternatively using an environment variable,
> > instead of being set at configure time? something like
> > DEBUG_INFO_PATH, or similar. I don't have a strong preference, but
> > seems to me that an environment variable is more flexible.
>
> I'd have to change this for local GDB packages anyway. Full
> relocatable installs are a must for me, so I'd have to make this path
> follow the current location of the GDB binary. I'm hoping to put the
> necessary support code in libiberty eventually...
That's only the default value, you can change it as a gdb variable too.
Although having it relocate correctly would be really nice.
> > Thinking out loud...
> >
> > I wonder if it wouldn't be more intuitive to add the debug info to the
> > objfile, instead of creating another objfile. So that in the end we
> > would have just a new field added to the objfile, indicating the name
> > of the debug info file.
>
> I like this idea; it seems a lot less fragile.
I'm not sure exactly what is meant by it though. But I'm not really a gdb
hacker. :)
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Alexander Larsson Red Hat, Inc
alexl@redhat.com alla@lysator.liu.se
He's a scarfaced soccer-playing photographer from the 'hood. She's a pregnant
bisexual angel who don't take no shit from nobody. They fight crime!