diff options
author | Doug Evans <dje@google.com> | 2010-12-07 17:26:06 +0000 |
---|---|---|
committer | Doug Evans <dje@google.com> | 2010-12-07 17:26:06 +0000 |
commit | aae1c79a03aa76ca68e9a989e7652703178362f0 (patch) | |
tree | 26d741796b72507358fc01ea1d5ae36e5c18b587 /gdb/testsuite | |
parent | c20cbc067b6fa714b4dc3e6d4025d5b11d605c80 (diff) | |
download | gdb-aae1c79a03aa76ca68e9a989e7652703178362f0.zip gdb-aae1c79a03aa76ca68e9a989e7652703178362f0.tar.gz gdb-aae1c79a03aa76ca68e9a989e7652703178362f0.tar.bz2 |
PR python/12227
* NEWS: Mention -data-directory.
* main.c (captured_main): Recognize -data-directory.
doc/
* gdb.texinfo (Mode Options): Document -data-directory.
(Data Files): Add reference to -data-directory.
testsuite/
* gdb.base/catch-syscall.exp (do_syscall_tests): Remove setting
of data-directory.
* lib/gdb-python.exp (gdb_check_python_config): Delete, all callers
updated.
* lib/gdb.exp (INTERNAL_GDBFLAGS): Add -data-directory.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/ChangeLog | 8 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/catch-syscall.exp | 4 | ||||
-rw-r--r-- | gdb/testsuite/gdb.python/lib-types.exp | 3 | ||||
-rw-r--r-- | gdb/testsuite/gdb.python/py-pp-maint.exp | 3 | ||||
-rw-r--r-- | gdb/testsuite/lib/gdb-python.exp | 18 | ||||
-rw-r--r-- | gdb/testsuite/lib/gdb.exp | 2 |
6 files changed, 11 insertions, 27 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 569c7b6..523374e 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2010-12-07 Doug Evans <dje@google.com> + + * gdb.base/catch-syscall.exp (do_syscall_tests): Remove setting + of data-directory. + * lib/gdb-python.exp (gdb_check_python_config): Delete, all callers + updated. + * lib/gdb.exp (INTERNAL_GDBFLAGS): Add -data-directory. + 2010-11-29 Michael Snyder <msnyder@msnyder-server.eng.vmware.com> * gdb.base/callfuncs.exp: Test for skip_float_tests. diff --git a/gdb/testsuite/gdb.base/catch-syscall.exp b/gdb/testsuite/gdb.base/catch-syscall.exp index 7845655..b84c0dd 100644 --- a/gdb/testsuite/gdb.base/catch-syscall.exp +++ b/gdb/testsuite/gdb.base/catch-syscall.exp @@ -277,8 +277,8 @@ proc test_catch_syscall_fail_nodatadir {} { proc do_syscall_tests {} { global gdb_prompt srcdir - # First, we need to set GDB datadir. - gdb_test_no_output "set data-directory [pwd]/../data-directory" + # NOTE: We don't have to point gdb at the correct data-directory. + # For the build tree that is handled by INTERNAL_GDBFLAGS. # Verify that the 'catch syscall' help is available set thistest "help catch syscall" diff --git a/gdb/testsuite/gdb.python/lib-types.exp b/gdb/testsuite/gdb.python/lib-types.exp index 0599b0d..07480f5 100644 --- a/gdb/testsuite/gdb.python/lib-types.exp +++ b/gdb/testsuite/gdb.python/lib-types.exp @@ -44,9 +44,6 @@ if ![runto_main] then { return 0 } -# Ensure sys.path, et.al. are initialized properly. -gdb_check_python_config - gdb_test_no_output "python import gdb.types" # test get_basic_type const stripping diff --git a/gdb/testsuite/gdb.python/py-pp-maint.exp b/gdb/testsuite/gdb.python/py-pp-maint.exp index 7474584..b613e41 100644 --- a/gdb/testsuite/gdb.python/py-pp-maint.exp +++ b/gdb/testsuite/gdb.python/py-pp-maint.exp @@ -51,9 +51,6 @@ if ![runto_main ] then { return -1 } -# Ensure sys.path, et.al. are initialized properly. -gdb_check_python_config - gdb_test "b [gdb_get_line_number {break to inspect} ${testfile}.c ]" \ ".*Breakpoint.*" gdb_test "continue" ".*Breakpoint.*" diff --git a/gdb/testsuite/lib/gdb-python.exp b/gdb/testsuite/lib/gdb-python.exp index 58deadc..4a15d7a 100644 --- a/gdb/testsuite/lib/gdb-python.exp +++ b/gdb/testsuite/lib/gdb-python.exp @@ -45,21 +45,3 @@ proc gdb_py_test_multiple { name args } { } return 0 } - -# Establish various python configuration parameters if necessary. -# E.g. sys.path. - -proc gdb_check_python_config { } { - global USE_INSTALLED_TREE - # If we're running an installed version of gdb, and we want to test the - # installed versions of the python support scripts, then we don't want - # to point data-directory at the build tree. - if { [info exists USE_INSTALLED_TREE] && "$USE_INSTALLED_TREE" == "yes" } { - verbose -log "Assuming system config already installed." - } else { - verbose -log "Installing system config from build tree." - set gdb_data_dir "[pwd]/../data-directory" - gdb_test_no_output "set data-directory $gdb_data_dir" - gdb_test_no_output "python GdbSetPythonDirectory ('$gdb_data_dir/python')" - } -} diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index fc8751f..50e2c70 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -56,7 +56,7 @@ verbose "using GDBFLAGS = $GDBFLAGS" 2 # INTERNAL_GDBFLAGS contains flags that the testsuite requires. global INTERNAL_GDBFLAGS if ![info exists INTERNAL_GDBFLAGS] { - set INTERNAL_GDBFLAGS "-nw -nx" + set INTERNAL_GDBFLAGS "-nw -nx -data-directory [pwd]/../data-directory" } # The variable gdb_prompt is a regexp which matches the gdb prompt. |