Cross plateform debugging
-
hi,
I have development board installed debian and also Qt library(qt version 5.3.2).
My development platform is Ubuntu 16.04 LTS using qt creator 3.5.1 (based on Qt 5.5.1).
Is it possible to debug application from desktop (remotely from qt creator) to board ?Thanks,
Jignesh Patel -
Yes, you need to set the device up in Tools->Options...->Devices->Add->Generic Linux Device.
One you have that set up and working, debugger should work as well.
-
Thanks for valuable input,
I have try to do as per your step, but still can not remote debug my application.
I have follow the step:-
Set up device from Tools->Options...->Devices->Add->Generic Linux Device and when i have test it following message get in windows.
Connecting to host...
Checking kernel version...
Linux 4.1.15-224529-g1a2007a-dirty armv7l
Checking if specified ports are available...
All specified ports are available.
Device test finished successfully. -
I have set up it in build and run, but here i don't have qmake for my cross platform. it used my development environment. I don't have cross compiler and qmake in my development environment.
When I go for debug my application, My application stop after displaying following message on terminal.
Debugging starts
stdin: is not a tty
Listening on port 10001
Remote debugging from host 192.168.111.122After some time it gives the warning to stop debugging or give GDB more time.
I have attached snapshot also for reference.
Thanks
-
-
Do you have
gdbserver
on your target board? If yes, which version?QtCreators debugger log (menu Window > Views > Debugger Log) may contain more information about what went wrong.
Regards
-
Do you have
gdbserver
on your target board? If yes, which version?QtCreators debugger log (menu Window > Views > Debugger Log) may contain more information about what went wrong.
Regards
Thanks @aha_1980 ,
My GDB and Qt version is as per below:
Board GDB version: GNU gdb (Debian 7.7.1+dfsg-5) 7.7.1
PC GDB version : GNU gdbserver (Ubuntu 7.11.1-0ubuntu1~16.5) 7.11.1
Board qt version : 5.3.2
PC qt version : 5.5.1I have copy GDB debug log where it stop after "584-exec-continue" in wait.
Response time: -file-exec-and-symbols "/home/jignesh/Desktop/QT/Time-zone/build-Sample_App-Device-Debug/Sample_App": 0.137 s
16:35:59.379 [1ms]
582target extended-remote tcp:192.168.111.119:10005
16:35:59.379
16:35:59.383 [4ms]
&"target extended-remote tcp:192.168.111.119:10005\n"
~"Remote debugging using tcp:192.168.111.119:10005\n"
16:35:59.386 [3ms]
Remote debugging from host 192.168.111.122
16:35:59.397 [11ms]
582^done
16:35:59.397
Response time: target extended-remote tcp:192.168.111.119:10005: 0.019 s
16:35:59.397
ATTACHED TO GDB SERVER STARTED
16:35:59.397
Attached to stopped application
16:35:59.398 [1ms]
583-gdb-set remote exec-file
16:35:59.398
16:35:59.406 [8ms]
583^done
16:35:59.406
Response time: -gdb-set remote exec-file : 0.009 s
16:35:59.406
Setting breakpoints...
16:35:59.406
Setting breakpoints...
16:35:59.406
ATTEMPT BREAKPOINT SYNCHRONIZATION
16:35:59.406
BREAKPOINTS ARE SYNCHRONIZED
16:35:59.406
NOTE: INFERIOR SETUP OK
16:35:59.406
State changed from InferiorSetupRequested(4) to InferiorSetupOk(6) [master]
16:35:59.406
State changed from InferiorSetupOk(6) to EngineRunRequested(7) [master]
16:35:59.406
QUEUE: RUN ENGINE
16:35:59.406
16:35:59.406
CALL: RUN ENGINE
16:35:59.406
NOTE: ENGINE RUN AND INFERIOR STOP OK
16:35:59.406
Stopped.
16:35:59.406
State changed from EngineRunRequested(7) to InferiorStopOk(14) [master]
16:35:59.407 [1ms]
NOTE: INFERIOR RUN REQUESTED
16:35:59.407
Run requested...
16:35:59.407
State changed from InferiorStopOk(14) to InferiorRunRequested(10) [master]
16:35:59.408 [1ms]
Running requested...
16:35:59.409 [1ms]
584-exec-continue
16:36:39.222 [39813ms]
584: -exec-continue
16:36:39.222
TIMED OUT WAITING FOR GDB REPLY. COMMANDS STILL IN PROGRESS: "-exec-continue"why GDB doesn't get reponse here, GDB command line is new for me.
How can i solve this issue?Thanks
-
@Jignesh-Patel said in Cross plateform debugging:
Sorry, I have no other idea; but I'm currently not using the remote debugging feature.
Board GDB version: GNU gdb (Debian 7.7.1+dfsg-5) 7.7.1
PC GDB version : GNU gdbserver (Ubuntu 7.11.1-0ubuntu1~16.5) 7.11.1
Board qt version : 5.3.2
PC qt version : 5.5.1Are you sure this is all correct? You should have gdbserver on the board and GDB on your PC.
That said, gdb 7.7.1 is quite old, the Qt versions you use also (but that should not matter for debugging in first place).
If you like to create a bug report you should first try to update both gdb/gdbserver and QtCreator.