This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Problem writing python tests without installing
- From: Phil Muldoon <pmuldoon at redhat dot com>
- To: Robert Lupton the Good <rhl at astro dot princeton dot edu>
- Cc: gdb at sourceware dot org
- Date: Thu, 10 Nov 2011 15:54:46 +0000
- Subject: Re: Problem writing python tests without installing
- References: <EC31A511-894C-4153-88F3-5EFA012F9AEC@astro.princeton.edu>
- Reply-to: pmuldoon at redhat dot com
Robert Lupton the Good <rhl@astro.princeton.edu> writes:
> When running the testsuite, the python files that are sourced are apparently e.g.
> gdb/testsuite/../data-directory/python/gdb/printing.py
> rather than
> gdb/python/lib/gdb/printing.py
> although the binary is as expected gdb/gdb
Right, but you don't have to do 'make install' to get data-directory.
>
> The files appear to be installed by "make install". This is another
> manifestation of the problem that you cannot apparently work on the
> gdb python code without first installing it (away from it's cvs home
> -- but that can be faked with a link...)
I work with Python every day and I don't have this issue. The files are
correctly sourced from ../data-dictionary.
I could not find the gdb.printing test in my output, but this works fine:
python
>Sending "import gdb.command.prompt" to gdb
Looking to match ""[\r\n]*()[\r\n]+(\(gdb\) | *>)$""
Message is "prompt substitution readline - import gdb.command.prompt"
board_info host exists name
FWIW GDB is spawned in the test as:
Spawning /home/pmuldoon/bugs/setex/obj/gdb/testsuite/../../gdb/gdb -nw -nx -data-directory /home/pmuldoon/bugs/setex/obj/gdb/testsuite/../data-directory
> Is there a proper way to work around this?
There's not enough information on your install/setup to diagnose the
issue. How did you configure the build?
Cheers
Phil