Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Startting remote program from GDB using "target remote"

Hi,

We are trying to extend CDT to support our embedded
board. 
Our main interest is the Windows version of
Eclispe/CDT.

So far, we managed to add a support for a new Launch
Configuration and we are able now to automatically
download the binaries using oor own downloader and run
these binaries on the board.

We also have ported GDB to support our board. It works
from the command-line without any problems. We use:
target remote hotname:port and 
target remote /dev/ttyS1

The problem is that we don't know how to integrate
this GDB version into Eclispe. We managed to tell
Eclipse that it should start our own version of GDB
and this works. We also tried to tell GDB that it
should use our own .gdbinit file, but it seems that it
does not take it into account. And it is not clear how
to tell CDT that GDB should execute "target remote"
instead of "run" when it starts a debugging session.
>From the output in a console windows, I have the
impression that CDT still tries to execute the "run"
command and then it tells that it cannot do it.

May be I have to define my own Session class that will
start GDB in a custom way? But it is not clear for me,
how do I tell it that it should not execute "run" on
start, but instead "target remote". And if I manage
that, will CDT automatically do the rest, i.e. ask the
programm being debugged about its current state, etc?
Or should I issue a special GDB command/CDT call after
"target remote"???

BTW, the program on the board is always in a running
mode, when GDB connects to it. I mean it is already
started and waits inside the GDB support stub for the
input from GDB. Should I explain this circumstance to
CDT somehow? May be setting the state of the process
to "suspended" or something else?

Thanks,
 Roman




		
__________________________________ 
Yahoo! Music Unlimited 
Access over 1 million songs. Try it free. 
http://music.yahoo.com/unlimited/


Back to the top