public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug mi/15472] New: Printing of "fullname" when the file is missing is causing problems for Eclipse
@ 2013-05-15 21:22 dje at google dot com
  2013-05-17 23:08 ` [Bug mi/15472] " dje at google dot com
  2013-05-18  7:36 ` jan.kratochvil at redhat dot com
  0 siblings, 2 replies; 3+ messages in thread
From: dje at google dot com @ 2013-05-15 21:22 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15472

             Bug #: 15472
           Summary: Printing of "fullname" when the file is missing is
                    causing problems for Eclipse
           Product: gdb
           Version: 7.6
            Status: NEW
          Severity: normal
          Priority: P2
         Component: mi
        AssignedTo: unassigned@sourceware.org
        ReportedBy: dje@google.com
    Classification: Unclassified


We have a bug report where a user is seeing the following:

Can't find a source file at "/foo/bar/baz.cc"
Locate the file or edit the source lookup path to include its location.

The sources are in a different location from where they were originally
compiled when this happens.
The change in behaviour from 7.5 to 7.6 is that the output now includes
"fullname" even if the file isn't found, and I think(!) this is what causes
Eclipse trouble.

Repro:
[I'm using -fdebug-prefix-map and "b main" as a hack.  The real example does
something different.]

cd $HOME
gcc -g -fdebug-prefix-map=$HOME=. hello.c
cd /tmp
gdb -i=mi2 $HOME/a.out
[...]
b main
&"b main\n"
~"Breakpoint 1 at 0x4004f8: file hello.c, line 6.\n"
=breakpoint-created,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0x00000000004004f8",func="main",file="hello.c",fullname="./hello.c",line="6",thread-groups=["i1"],times="0",original-location="main"}
^done
(gdb)

With 7.5 the "fullname" field is elided and Eclipse uses the "file" field to
find hello.c. [Eclipse has its own source search path.]

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug mi/15472] Printing of "fullname" when the file is missing is causing problems for Eclipse
  2013-05-15 21:22 [Bug mi/15472] New: Printing of "fullname" when the file is missing is causing problems for Eclipse dje at google dot com
@ 2013-05-17 23:08 ` dje at google dot com
  2013-05-18  7:36 ` jan.kratochvil at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: dje at google dot com @ 2013-05-17 23:08 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15472

dje at google dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jan.kratochvil at redhat
                   |                            |dot com, marc.khouzam at
                   |                            |ericsson dot com

--- Comment #1 from dje at google dot com 2013-05-17 23:08:06 UTC ---
Filing for reference sake.
Here is the upstream discussion from the time the patch was submitted.

http://sourceware.org/ml/gdb-patches/2012-12/msg00557.html

http://sourceware.org/ml/gdb-patches/2012-12/msg00811.html

Marc Khouzam said the change was ok for Eclipse here:

http://sourceware.org/ml/gdb-patches/2012-12/msg00740.html

I'm not sure how to proceed.

AIUI, Note that Eclipse maintains its own list of source search directories,
and it will use them if gdb provides it a relative path.  But if gdb provides a
full path then Eclipse will trust that it's correct.  In the failure that
triggered this bug report Eclipse *could* find the source file if gdb didn't
provide the full path to a non-existent file.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug mi/15472] Printing of "fullname" when the file is missing is causing problems for Eclipse
  2013-05-15 21:22 [Bug mi/15472] New: Printing of "fullname" when the file is missing is causing problems for Eclipse dje at google dot com
  2013-05-17 23:08 ` [Bug mi/15472] " dje at google dot com
@ 2013-05-18  7:36 ` jan.kratochvil at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: jan.kratochvil at redhat dot com @ 2013-05-18  7:36 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15472

--- Comment #2 from Jan Kratochvil <jan.kratochvil at redhat dot com> 2013-05-18 07:36:49 UTC ---
I believe Eclipse should use GDB "set directories ..." so that both Eclipse and
GDB know the same source files directories search path.

If you use the GDB console window in Eclipse one should have the same source
files availability there as in Eclipse itself.  (I understand >99% of Eclipse
users do not use the GDB console window but still.)

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-05-18  7:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-15 21:22 [Bug mi/15472] New: Printing of "fullname" when the file is missing is causing problems for Eclipse dje at google dot com
2013-05-17 23:08 ` [Bug mi/15472] " dje at google dot com
2013-05-18  7:36 ` jan.kratochvil at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).