[meta-freescale] debugging with gdb & gdbserver (host and target)

Thanassis Silis djnass_18 at hotmail.com
Mon Oct 14 09:26:31 PDT 2013


Hi all,I must be doing something wrong with the way I use gdb but I cannot figure out what it is. could you please look into it?
The board is sabrelite with imx6q running an rootfs with debug enabled (unstripped libs too). The rootfs resides extracted  on the host as well in path: /home/nass/yocto/dev/sysroots-gui-sdk
Application is built on host , where I set up my environment with yocto's modified env file (I can provide it if you think it is essential)
I also have a .gdbinit file in my $HOME which contains:add-auto-load-safe-path /home/nass/eclipse/cor_mer/.gdbinitAnd another .gdbinit in my project's folder which contains:set sysroot /home/nass/yocto/dev/sysroots-gui-sdk
Finally I scp my executable in the target, and execute it with gdbserver :38383 <appname>
then on the host I start gdb as arm-poky-linux-gnueabi-gdb bin/<appname> 
Within gdb I run:(gdb) target remote armboard:38383and I get the replyReading symbols from /home/nass/yocto/dev/sysroots-gui-sdk/lib/ld-linux.so.3...done.Loaded symbols for /home/nass/yocto/dev/sysroots-gui-sdk/lib/ld-linux.so.30x42570e30 in ?? ()
This ?? (): should it be there?
I can run the program normally,(gdb) cContinuing.
but I can not interrupt the execution to add another breakpoint later . I can only add breakpoints in the beginning.(gdb) ^C^C Interrupted while waiting for the program.(gdb) Give up (and stop debugging it)? (y or n) 
If on the other hand I run gdb directly on the board, I can interrupt the execution and add breakpoints fine.The problem with the latter approach is that I don't have the source files.
Have  I setup something wrong? Do you set your debug environment differently?
Thank you in advance for your help..


 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-freescale/attachments/20131014/d26007d3/attachment.html>


More information about the meta-freescale mailing list