[uClinux-dev] gdb, gdbserver, and global variables

Gavin Lambert gavinl at compacsort.com
Wed Aug 3 01:01:48 EDT 2005

I've managed to get GDB & Insight talking to a gdbserver on my board;
though I had to replace a couple of files (as discussed in this thread:
-- why oh why isn't that standard?) in order to get breakpoints to work.

I can now debug with source, a call stack, breakpoints, and local
variables.  Sadly not globals, however.

What do I need to do to get GDB/Insight to show the correct values for
my global variables?  Searching has revealed some discussion about
looking at A5 and doing an objcopy to relocate the .bss section.  I've
tried that but it doesn't seem to make much difference (which means that
I probably did it wrong).  Any chance of a step-by-step guide, anyone?
Please? :)

(I'm using the uClinux 200412 tarball, the binary toolchain package for
m68k-elf (3.4.0), and a custom-compiled GDB/Insight 6.1.  Targeting a
Coldfire 5272.)

More information about the uClinux-dev mailing list