This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [commit] Update help.exp
- From: Tom Tromey <tromey at redhat dot com>
- To: Yufeng Zhang <Yufeng dot Zhang at arm dot com>
- Cc: "dje\ at google dot com" <dje at google dot com>, gdb-patches at sourceware dot org
- Date: Mon, 10 Sep 2012 11:29:06 -0600
- Subject: Re: [commit] Update help.exp
- References: <yjt2txw65wca.fsf@ruffy2.mtv.corp.google.com> <503DF8D2.8070807@arm.com>
>>>>> ">" == Yufeng Zhang <Yufeng.Zhang@arm.com> writes:
>> help.exp still fails with --without-python. "Convenience functions
>> are defined via the Python API" is printed only when HAVE_PYTHON is
>> defined (see
>> http://sourceware.org/ml/gdb-patches/2012-08/msg00342.html).
I ran into this too.
Here's my proposed fix.
Tested on x86-64 F16, both with and without Python enabled.
Tom
b/gdb/testsuite/ChangeLog:
2012-09-10 Tom Tromey <tromey@redhat.com>
* gdb.base/help.exp: Conditionally allow Python output.
diff --git a/gdb/testsuite/gdb.base/help.exp b/gdb/testsuite/gdb.base/help.exp
index 7fffd00..3270565 100644
--- a/gdb/testsuite/gdb.base/help.exp
+++ b/gdb/testsuite/gdb.base/help.exp
@@ -517,7 +517,7 @@ gdb_test "help show complaints" "Show max number of complaints about incorrect s
# test help show confirm
gdb_test "help show confirm" "Show whether to confirm potentially dangerous operations\." "help show confirm"
# test help show convenience
-gdb_test "help show convenience" "Debugger convenience \\(\"\\\$foo\"\\) variables and functions\.\[\r\n\]+Convenience variables are created when you assign them values;\[\r\n\]+thus, \"set \\\$foo=1\" gives \"\\\$foo\" the value 1\. Values may be any type\.\[\r\n\]+A few convenience variables are given values automatically:\[\r\n\]+\"\\\$_\"holds the last address examined with \"x\" or \"info lines\",\[\r\n\]+\"\\\$__\" holds the contents of the last address examined with \"x\"\.\[\r\n\]+Convenience functions are defined via the Python API\." "help show convenience"
+gdb_test "help show convenience" "Debugger convenience \\(\"\\\$foo\"\\) variables and functions\.\[\r\n\]+Convenience variables are created when you assign them values;\[\r\n\]+thus, \"set \\\$foo=1\" gives \"\\\$foo\" the value 1\. Values may be any type\.\[\r\n\]+A few convenience variables are given values automatically:\[\r\n\]+\"\\\$_\"holds the last address examined with \"x\" or \"info lines\",\[\r\n\]+\"\\\$__\" holds the contents of the last address examined with \"x\"\.\[\r\n\]+(Convenience functions are defined via the Python API\.)?" "help show convenience"
# test help show directories
gdb_test "help show directories" "Show the search path for finding source files\.\[\r\n\]+\\\$cwd in the path means the current working directory\.\[\r\n\]+\\\$cdir in the path means the compilation directory of the source file\..*" "help show directories"
# test help show editing