On Tue, May 08, 2012 at 06:36:36PM -0700, Luke wrote:
> To do this properly, it seems like openocd would have to be aware of
> which version of gdb was going to be used with it, and conditionally
> compile this file appropriately.  Alternatively, a future release of
> OpenOCD could simply require gdb version 7.3 or newer.  Or, perhaps
> there is a way to determine the version of gdb at runtime, and act
> appropriately?  All of these options have their pros/cons.
> 
> >From a maintenance point of view, it seems dropping support for the
> older versions of gdb would be the simplest, but this will probably
> hurt many people using canned toolchains that have older versions of
> gdb.  Then again, maybe those people are using the old releases of
> OpenOCD, and aren't keeping up with the git stuff, so this wouldn't
> affect most people.  Adding conditional compilation and/or runtime
> version checking seems like it could be a can of worms and a potential
> maintenance burden, but maybe I'm wrong.

I think dropping support for older gdb versions is not a feasible option -
there are too many pre-built toolchains around, and people who do not build
their own gdb will probably have problems getting a "new enough" gdb for
some time to come.

I think first we should determine the root cause of the problem. If there is
a way to get this working with any gdb by putting some settings in .gdbrc,
then documenting these should be sufficient.

If no such solution exists, the only clean option would be to add a runtime
config command to OpenOCD to switch the behaviour. Compile-time switching is
not enough - users may use different versions with OpenOCD for different
targets (I do - I use OpenOCD for ARMv5TE and Cortex-m3, using different
toolchains and different gdb versions).

cu
Michael

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to