From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Marc Khouzam <marc.khouzam@ericsson.com>
Cc: "'Tom Tromey'" <tromey@redhat.com>,
"'gdb-patches@sourceware.org'"
<gdb-patches@sourceware.org>
Subject: [commit] [rfc] Print MI fullname even for non-existing files
Date: Tue, 25 Dec 2012 08:04:00 -0000 [thread overview]
Message-ID: <20121225080350.GB11349@host2.jankratochvil.net> (raw)
In-Reply-To: <E59706EF8DB1D147B15BECA3322E4BDC04CEB7@eusaamb103.ericsson.se>
On Thu, 20 Dec 2012 15:32:55 +0100, Marc Khouzam wrote:
> > Jan> symtab_to_fullname now always returns non-NULL.
> >
> > Jan> Currently this patch only changes from user point of view MI:
> > Jan> (gdb) -file-list-exec-source-file
> > Jan> ^done,line="1",file="deleted.c",macro-info="0"
> > ->
> > Jan>
> > ^done,line="1",file="deleted.c",fullname="/path/to/deleted.c",
> > macro-info="0"
> >
> > Jan> Is there a serious reason why fullname was suppressed for
> > Jan> non-existing files? While it breaks MI compatibility in
> > some way I
> > Jan> find it an acceptable change.
> >
> > It seems pretty reasonable to me as well.
>
> For what it's worth, that is an ok change for Eclipse (we don't
> use that command).
This specific command was just an example. The change affects any MI output
where fullname="/abs/path" was printed. Now it will be printed even if that
source file is not present on the disk. While that may be rather rate case it
would be bad if Eclipse breaks.
I have tested now eclipse-cdt-8.1.1-1.fc18.x86_64, if I remove /usr/src/debug
I get:
unpatched/patched present file:
Subwindow tab title shows the short filename "ioputs.c".
unpatched missing file:
Can't find a source file at "ioputs.c"
Locate the file or edit the source lookup path to include its location.
Subwindow tab title shows the short filename "ioputs.c":
http://people.redhat.com/~jkratoch/eclipse-gdb-unpatched.png
patched missing file:
Can't find a source file at "/usr/src/debug/glibc-2.16-75f0d304/libio/ioputs.c"
Locate the file or edit the source lookup path to include its location.
Subwindow tab title shows the fullname "/usr/src/debug/glibc-2.16-75f0d304/libio/ioputs.c":
http://people.redhat.com/~jkratoch/eclipse-gdb-fullname.png
So I find the patch in fact an improvement even for Eclipse.
Therefore I have checked it in:
http://sourceware.org/ml/gdb-cvs/2012-12/msg00184.html
Besides that the compatibility of Eclipse <-> GDB across versions is not too
great, FSF GDB HEAD fails with eclipse-cdt-8.0.1-4.fc16.x86_64:
Error in final launch sequence
Failed to execute MI command:
maintenance set python print-stack off
Error message from debugger back end:
Undefined maintenance set command: "python print-stack off". Try "help maintenance set".
Thanks,
Jan
next prev parent reply other threads:[~2012-12-25 8:04 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-17 15:59 Jan Kratochvil
2012-12-17 16:13 ` Andrew Burgess
2012-12-17 18:36 ` Jan Kratochvil
2012-12-17 16:33 ` Eli Zaretskii
2012-12-17 16:36 ` Jan Kratochvil
2012-12-17 18:33 ` Tom Tromey
2012-12-17 18:37 ` Jan Kratochvil
2012-12-17 18:41 ` Tom Tromey
2012-12-17 18:59 ` Jan Kratochvil
2012-12-28 0:17 ` Edjunior Barbosa Machado
2012-12-28 9:09 ` [commit] " Jan Kratochvil
2012-12-20 14:33 ` Marc Khouzam
2012-12-25 8:04 ` Jan Kratochvil [this message]
2013-01-03 15:38 ` [commit] " Marc Khouzam
2013-01-03 15:44 ` Jan Kratochvil
2013-01-03 16:04 ` Tom Tromey
2013-01-03 16:57 ` Joel Brobecker
2013-04-02 16:24 ` Pedro Alves
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=20121225080350.GB11349@host2.jankratochvil.net \
--to=jan.kratochvil@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=marc.khouzam@ericsson.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