[Qt-creator] Generic Linux Target GDB Session not terminated
Tim Sander
tim01 at iss.tu-darmstadt.de
Sat Jun 2 00:39:24 CEST 2012
Hi André
> > I'd like to bump this again, since i had no replys at all since posting
> > the logs.
>
> Sorry, it fell through the cracks.
Well im happy to have your answer now :-)
> > Even a rough direction what might be wrong would be helpful so i have
> > a starting point for trying to debug the debug problem :-):
> >
> > The problem is that the debugging session to a generic linux target is
> > not terminated. Any ideas why that might be? The logs don't point me
> > to an error, as it seems there is no problem, but well the process is
> > still running and the next debug session fails because of that.
>
> There are a couple of more or less fishy things here.
>
> 1. <30-break-insert -f "\"connection.cpp\":782"
>
> >&"No source file named connection.cpp.\n"
> >30^done,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",add
> >r="<
> >PENDING>",pending="\"connection.cpp\":782",times="0",original-locatio
> >n="\" connection.cpp\":782"}
>
> Unless this is really in a not-yet-loaded shared object, this is
> a good indication that debug information for the main executable
> was not found.
The debugger works for me (tm) so far. But with my limited debugger knowledge
i havent seen this message as a problem.
> This might already be the reason for the rest.
Well i can debug and all, so the debugger is working... at least i am
thinking that it is :-).
>
> 2. "warning: .dynamic section for..."
>
> [Assuming 1. is really explained by not-yet-loaded shared objects]
I am having a .so used by the program which is stripped on the target.
> Are you sure the libraries you have in the sysroot (you set it to
> /home/sander/speedy/trunk/ptx/platform-pmx-one/root-debug) are exact
> copies of the ones you have on the device, and that their debug
> information is up-to-date"?
Might the fact that the library on the target is stripped be the source for
this message?
> > > >32^running
> > >
> > > dNOTE: INFERIOR RUN OK
> > > sLäuft.
> > > dState changed from InferiorRunRequested(10) to InferiorRunOk(11)
> > > [master]
> > >
> > > >*running,thread-id="all"
> > > >&"warning: .dynamic section for
> > > >\"/home/sander/speedy/trunk/ptx/platform-pmx-one/root-debug/usr/lib/li
> > > >bPM X.so.0\" is not at the expected address (wrong library or version
> > > >mismatch?)\n"
> > >
> > > loaded="0",thread-group="i1"
> > > sBibliothek /usr/lib/libdbus-1.so.3 geladen
> > > dQUIT DEBUGGER REQUESTED IN STATE 11
>
> State 11 is RunOk. Something or someone decided that's a good idea to quit
> now "out of band". Did you use Debug->Abort, or did the connection die?
I used the stop button. So this is where it should kill the process but
doesn't. In this run i just started the debugger and then stopped it after the
program started. This was just for producing this log.
> > > dState changed from InferiorRunOk(11) to InferiorStopRequested(13)
> > > [master] dCALL: INTERRUPT INFERIOR
> > > sUnterbreche.
> > > <33-exec-interrupt
> > >
> > > >33^done
> > > >*stopped,reason="signal-received",signal-name="SIGINT",signal-meaning=
> > > >"Int
> > > >errupt",frame={addr="0x407cc02c",func="*__GI___poll",args=[{name="fds
> > > >",val ue="0x461e0"},
> > >
> > > {name="nfds",value="2"},{name="timeout",value="-1"}],file="../sysdeps/u
> > > nix/
> > > sysv/linux/poll.c",fullname="/home/sander/projekte/debs/toolchain/OSEL
> > > AS.To olchain-2011.03.1/platform-arm-1136jfs-
> > > linux-gnueabi-gcc-4.5.2-glibc-2.13-binutils-2.21-kernel-2.6.36-sanitize
> > > d/b
> > > uild-target/glibc-2.13/sysdeps/unix/sysv/linux/poll.c",line="83"},thre
> > > ad-id ="1",stopped-threads="all",core="0" dNOTE: INFERIOR STOP OK
> > > dNOTE: ... WHILE DYING.
> > > dNOTE: ... FORWARDING TO 'STOP OK'.
>
> This is already part of an emergency shutdown triggered by the
> "QUIT DEBUGGER REQUESTED IN STATE"
>
> > > dState changed from InferiorStopRequested(13) to InferiorStopOk(14)
> > > [master] dState changed from InferiorStopOk(14) to
> > > InferiorShutdownRequested(17) [master] dQUEUE: SHUTDOWN INFERIOR
> > > dNOTE: ... IGNORING STOP MESSAGE
> > > dCALL: SHUTDOWN INFERIOR
> > > <34detach
> > >
> > > >&"detach\n"
>
> 4. "detach", not "kill" is strange, but the reason why the gdbserver
> is still running. This is usually only done if the connection is
> established using "Attach [... to something]" from the Debug menu.
Mh i missed the detach command. So this at least explains why the gdbserver
is still running. But i pressed the red stop button and i think this should
kill the debugging session? It to late for me right now but thats something
i can grep for...
> How did you start debugging? "<F5>, with a fully configured
> generic remote linux setuop", or by using something from the
> Debug menu?
I have configured my device as a generic linux target and started via debug
button not the menu.
The generic linux target is a really nice feature btw. The only thing which is
missing is automatic toolchain detection for embedded target distributions
like open embedded or ptxdist (which i am using). But thats would really just
be a convinience function.
As far as i remember someone stated that the toolchain stuff should been
modularized. So adding this detection would be easier. Has this modularization
happend.
Thanks for reading
Tim
More information about the Qt-creator
mailing list