This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: python help(gdb) doesn't work in my local build.
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Michael Snyder <msnyder at vmware dot com>
- Cc: "gdb at sourceware dot org" <gdb at sourceware dot org>
- Date: Fri, 11 Mar 2011 21:48:37 +0100
- Subject: Re: python help(gdb) doesn't work in my local build.
- References: <4D7A7BCA.5000408@vmware.com>
On Fri, 11 Mar 2011 20:45:14 +0100, Michael Snyder wrote:
> No such file or directory: '/usr/local/share/gdb/python/gdb'
>
> 1) What do I do to tell it where to look locally?
> 2) What do I do to install this by hand?
GDB is intentionally omitted from the standalone-Python help.
On correctly Fedora 14 x86_64 installed Python+GDB:
$ python -c 'help(gdb)'
Traceback (most recent call last):
File "<string>", line 1, in <module>
NameError: name 'gdb' is not defined
$ gdb -q -nx -ex 'python help(gdb)' -ex q
Help on package gdb:
NAME
gdb
[...]
GDB part of the help was intentionally moved out of the standard Python help
directory tree as reading the code providing help texts requires to load the
whole such Python modules which require the bindings provided by GDB itself.
http://bugs.python.org/issue7015
https://bugzilla.redhat.com/show_bug.cgi?id=526313
$ python
>>> help() help> modules gdb
Here is a list of matching modules. Enter any module name to get more help.
Traceback (most recent call last):
<module>
class RequireCommand (gdb.Command):
AttributeError: 'module' object has no attribute 'Command'
Regards,
Jan