[uClinux-dev] Debugging C++ application
davidm at snapgear.com
Mon Jan 16 18:48:46 EST 2006
Jivin Lei Sun lays it down ...
> Thanks for the info!
> I will try to follow that, I am using Intel Xscale with mmu disabled.
> armeb-nofpu target.
> BTW, is there any elf2flt maintainer around? The tool seems to have
Send patched here, we'll take care of them.
> some problems handling PIC compiled code. So I have to compilie
> everything into static.
That is somewhat true, it will see the GOT and assume you are using
XIP, which is not always true. XIP requires specific compile support
which the arm-linux toolchain does not have.
When you build your elf2flt, use the --disable-got-check option to
force it to treat the files like non-XIP binaries.
Otherwise, do not use -fPIC or -fpic options when you build and it
should get it right.
> On 1/16/06, David McCullough <davidm at snapgear.com> wrote:
> > Jivin Lei Sun lays it down ...
> > > Hi:
> > > I am trying to port a very large C++ application to mmu-less
> > > uCLinux(executable is 3.7M). My C application looks good, and small
> > > hello, world C++ program worked as well. All binary is in FLAT format
> > > and statically linked. But the large C++ application crashed mybox. I
> > > tested the simple case, let it print out version information in the
> > > main() program and call _exit(0). after that, my shell got core dumped
> > > on every command after that.
> > > I suspect it's the stack problem and increased the stack to 256K,
> > > but didn't do the trick.
> > > I managed to build a native GDB debugger, but it doesn't support
> > > FLAT file format.So I am stucked.
> > > Does anybody have any tip on how to debug this? or has anybody got
> > > big C++ application working in mmu-less uClinux?
> > Should be basically the same as a C program, just harder to follow :-)
> > If you are using coldfire/m68k (and even if not):
> > http://www.ucdot.org/article.pl?sid=03/01/30/0548223
> > Otherwise we may need some more info to help,
> > Cheers,
> > Davidm
> > --
> > David McCullough, davidm at cyberguard.com.au, Custom Embedded Solutions + Security
> > Ph:+61 734352815 Fx:+61 738913630 http://www.uCdot.org http://www.cyberguard.com
> > _______________________________________________
> > uClinux-dev mailing list
> > uClinux-dev at uclinux.org
> > http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
> > This message was resent by uclinux-dev at uclinux.org
> uClinux-dev mailing list
> uClinux-dev at uclinux.org
> This message was resent by uclinux-dev at uclinux.org
David McCullough, davidm at cyberguard.com.au, Custom Embedded Solutions + Security
Ph:+61 734352815 Fx:+61 738913630 http://www.uCdot.org http://www.cyberguard.com
More information about the uClinux-dev