GDB Python support

Yann E. MORIN yann.morin.1998@anciens.enib.fr
Tue Mar 15 18:47:00 GMT 2011


On Tuesday 15 March 2011 02:10:55 Bryce Schober wrote:
> This is what I mean. It requires specifying gdb's configure option
> "—with-python" (my cursory glance at crosstool's configs left me with
> the impression that there was no place to plug in that option),

There is currently no way to add user-supplied options to gdb's
./configure.

Here is attached a untested patch. Care to report, please?
  

There are two places to enable python support:
- for the cross-gdb: we can use the python available on the host
- the native gdb: it is a bit more complex, as it requires an existing
  python to run on the target, *and* an exiting python devel env to run
  on the target. Obviously, we can't readily have this target python,
  as we're still building the toolchain. And, no-no-no, I won't add a
  python devel env in the toolchain.

So, for the native gdb to run on the target:
- either it does not support python scripting,
- or the user will have to build it on his/her own.

> and 
> implies dependencies. I assume that in the context of crosstool, one
> would prefer it to compile its own minimal version of python for that
> purpose. I haven't gone very far down the chain of implications
> myself, but I've scanned through the Qt Creator process for the
> python-enabled gdb that they ship
> (http://developer.qt.nokia.com/wiki/QtCreatorBuildGdb), and at least
> their Linux build process doesn't look too obtuse.

For the cross-gdb, we can assume that the host laready has the python devel
env (headers+libs). For the native gdb, that's a no-no in crostool-NG.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ct-ng.gdb-python-scripting.patch
Type: text/x-diff
Size: 1565 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/crossgcc/attachments/20110315/99fea9c4/attachment.bin>
-------------- next part --------------
--
For unsubscribe information see http://sourceware.org/lists.html#faq


More information about the crossgcc mailing list