Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-debug-dev] Re: Adapting CDT-debugging to AVR-elf targets: Build problem using CVS sources

> 1) In order to specify the location and port of the remote GDB server, it
> would be necessary to give the user the possibility to specify the initial
> gdb commands so that he can replace the usual "run" by somthing a bit more
> complex like "target localhost:3141 , load,  run"

Would it be sufficient if you could manually type in the GDB commands to
attach to your target?

If you can type in the commands manually, you can of course also create
a GDB init file to execute the sequence of commands.

My modifications to CDT simply removed the issuing of the "run" command,
and lets the user type in whatever he wants in order to attach to the
target.

> 2) It will be helpful to provide a means for excecuting a command-line tool
> once when starting and finishing a debug session. For AVR targets it is
> neccessary to start a gdb-server process that gdb can connect to and that
> establishes the link to the emulator hardware. Giving the user the
> possibility to specify a shell command for starting and killing the gdb
> server process will do the job. (This however, could in a first step been
> done by a tool external to eclipse.)

How about:

http://sources.redhat.com/gdb/onlinedocs/gdb_3.html#SEC11

I don't know if GDB has a "shutdown script" feature.

Eclipse has a generic feature to launch command line tools. Perhaps that
could serve your needs?

> 3) It also would be helpful to provide a means for the user to explicitly
> execute the gdb command "load" during a debug session.

I always thought that CDT should not make the assumption that there is a
single GDB debug session in a single CDT Debug session.

What is stopping you from executing the "load" command? 

Here is how I attach to an EB40a target using the serial port(and my
modified CDT plugin, see below):

(gdb) set remotebaud 38400
(gdb) target remote /dev/ttyS4
(gdb) load
(gdb) break main
(gdb) continue


> I was just about trying to implement these things. As a starting point I
> wanted to use Øyvind Harboe's modifications that already should be a 80%
> solution of my personal needs.

Have you tried my changes? They should work for you as is.

Comments? 


I've built a CDT plugin that is available for download from:

http://www.zylin.com/opensource.html 

> Unfortunately, I now again got stuck when trying to build CDT using the
> sources retreived from the devel.eclipse.org CVS server. I thought that I
> imported all required plugins and fragments. It, however, seems that a
> couple of unresolved references remain. So there is my new question:
> 
> Is there a kind of guide document describing how to build CDT from
> sources -- e.g. stating which kind of plugins are required for building
> org.eclipse.cdt.debug* ?

I've had lots of little hickups when trying to compile CDT lately. I get
the impression that this is Eclipse M9/CDT integration problems that are
rapidly being resolved. I went from completely dead in the water to
being able to compile CDT without too much hazzle in a week, just by
running Eclipse M9 + latest CDT from CVS.

-- 
Øyvind Harboe
http://www.zylin.com




Back to the top