From: Richard Stallman <rms@gnu.org>
To: eliz@is.elta.co.il
Cc: per@bothner.com, tromey@redhat.com, gdb@sources.redhat.com,
emacs-hackers@gnu.org
Subject: Re: Using gdb with emacs
Date: Mon, 10 Sep 2001 15:50:00 -0000 [thread overview]
Message-ID: <200109102250.QAA05383@aztec.santafe.edu> (raw)
In-Reply-To: <2561-Sun09Sep2001203900+0300-eliz@is.elta.co.il>
The debug info recorded in the executable says that one of the source
files is ../foo/bar/baz.c. How can GDB know that a file you are
visiting, whose absolute file name is /home/user/project/foo/bar/baz.c,
is that file?
If the files named baz.c have full names ../foo/bar/baz.c and
../foo/lose/baz.c, GDB could figure out that
/home/user/project/foo/bar/baz.c, must be the former rather than the
latter. It could move up in the file names, eliminating possibilities
when it sees a mismatch, and if at some point only one file name still
remains undisqualified, that is the one.
Because gcc, for each .o file (at least when using stabs) emits
*both* the relative filename *and* the current working directory.
So gdb can calculete the absolute filename.
It can do that, and that may be one good thing to try; but that may
not be the full solution. It is not unusual to move directories
around; when that has happened, this method would fail just like now.
Perhaps it should first try to recognize the absolute file name,
and then, if that fails, try what I suggested above.
next prev parent reply other threads:[~2001-09-10 15:50 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-09-06 18:23 Tom Tromey
2001-09-06 19:56 ` Per Bothner
2001-09-07 1:01 ` Eli Zaretskii
2001-09-07 13:26 ` Tom Tromey
2001-09-07 13:59 ` Tom Tromey
2001-09-08 0:36 ` Eli Zaretskii
2001-09-09 8:03 ` Richard Stallman
2001-09-09 9:17 ` Eli Zaretskii
2001-09-09 10:04 ` Per Bothner
2001-09-09 10:41 ` Eli Zaretskii
2001-09-09 21:34 ` Per Bothner
2001-09-10 15:50 ` Richard Stallman [this message]
2001-09-10 19:58 ` Tom Tromey
2001-09-11 8:16 ` Andrew Cagney
2001-09-11 11:18 ` Eli Zaretskii
2001-09-09 8:03 ` Richard Stallman
2001-09-10 20:01 ` Tom Tromey
2001-09-08 7:27 ` Richard Stallman
2001-09-08 10:22 ` Andrew Cagney
2001-09-08 10:49 ` Fernando Nasser
2001-09-08 12:54 ` Christopher Faylor
2001-09-10 9:04 ` pathmap patch dropped [was: Re: Using gdb with emacs] Jim Blandy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200109102250.QAA05383@aztec.santafe.edu \
--to=rms@gnu.org \
--cc=eliz@is.elta.co.il \
--cc=emacs-hackers@gnu.org \
--cc=gdb@sources.redhat.com \
--cc=per@bothner.com \
--cc=tromey@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox