Re: A question about data-directory

Srinath Avadhanula
2010-08-30T23:22:08Z

Hi Daniel,

On Mon, Aug 30, 2010 at 7:00 PM, Daniel Jacobowitz <dan@codesourcery.com> wrote:
> On Mon, Aug 30, 2010 at 06:46:49PM -0400, Srinath Avadhanula wrote:
>> I was expecting the output from the auto-load script to say 'getting
>> here' before getting back to the prompt. If I place test-gdb.py in the
>> same directory as the executable (i.e. at /tmp/test/test-gdb.py) then
>> I do get a line saying 'getting here'.
>
> IIUC, that's what's supposed to happen right now.  The 'python'
> directory in datadir is added to the Python search path, but gdb.py
> files are searched for next to the object file.
>

That seems to flatly contradict what is mentioned in the doc:

----------%<------------
Finally, if this file does not exist, then gdb will look for a file
named data-directory/python/auto-load/real-name, where data-directory
is gdb's data directory (available via show data-directory, see Data
Files), and real-name is the object file's real name, as described
above.
----------%<------------

It does say that "gdb will look for a file named ..." rather than it
being only available on Python's search path.

Is the doc wrong/out-dated?

Regards,
Srinath