This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: Patch: search `directory' path for `break' files
- To: tromey at redhat dot com
- Subject: Re: Patch: search `directory' path for `break' files
- From: "Eli Zaretskii" <eliz at is dot elta dot co dot il>
- Date: Sat, 29 Sep 2001 11:42:42 +0200
- CC: gdb-patches at sources dot redhat dot com
- References: <87r8sq6fa9.fsf@creche.redhat.com>
- Reply-to: Eli Zaretskii <eliz at is dot elta dot co dot il>
> From: Tom Tromey <tromey@redhat.com>
> Date: 28 Sep 2001 17:56:14 -0600
>
> What I've done here is change lookup_symtab and lookup_partial_symtab
> to try to use the full path when looking up a file name. This only
> works on systems with realpath(); it could probably be ported to other
> systems (or a portable realpath() implementation could be found).
>
> With this patch, if the file name argument to lookup_symtab is a full
> path, we run it through realpath. Then we search for each symtab's
> file using the `dir' list. If we find a match, we use it.
IIRC, last time this was discussed, Per Bothner suggested to use the
current directory recorded in the debug info to convert a relative or
semi-relative file name into an absolute one.
Unless I'm mistaken, your patch doesn't do that. Any particular
reason? Per's suggestion did seem like the best solution to this.
> I built and tested this on x86 Red Hat Linux 6.2. I ran make check
> against the cvs head and then again with this patch applied.
I think this needs to be tested with as many debug infor formats as
possible. What format did you use? DWARF2?