Problem with Cross Platform Native Debugging

Dec 16, 2003 1 Replies

Hello, I am relatively new to embedded linux and could successfully build a cross-platform IDE(PowerPC Toolchain on x86) with Eclipse for Linux with the exception of a debugger.



I have successfully compiled a program(ppc on x86) with the following command ppc-gcc -g -o test test.c



and when i run the ppc-gdb ..it shows the configuration as "--host=i386-redhat-linux --target=ppc-linux"



but when i run the program in debugger it displays the following error Starting program: /opt/eclipse/projects/test Don't know how to run. Try "help target".



I tried 'target exec test'..but it displays the same...hope someone would suggest a solution.Thanks in Advance



Regards, DSKR


Do you try to run it in gdb directly? (then you try to execute a ppc binary on x86) If so instead you should try to

  • transfer the binary to the target
  • remote login into the target
  • execute "gdb-server host-name:2345 ppc-binary" on the target Now you can connect with gdb-server from the host gdb: target remote target-name:2345 (or extended-remote) The host/target-name:2345 can be replaced by serial ports.

But on the otherhand do not NEED to execute on the target, compile for x86, debug, when it works recompile for ppc.

/RogerL

Roger Larsson Skellefteå Sweden

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required