This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Get wrapper.exp testcase passing with stdio gdbserver
- From: Doug Evans <dje at google dot com>
- To: gdb-patches <gdb-patches at sourceware dot org>
- Date: Wed, 16 Apr 2014 10:45:29 -0700
- Subject: Re: [PATCH] Get wrapper.exp testcase passing with stdio gdbserver
- Authentication-results: sourceware.org; auth=none
- References: <yjt2ha84574t dot fsf at ruffy dot mtv dot corp dot google dot com>
On Wed, Feb 12, 2014 at 1:54 PM, Doug Evans <dje@google.com> wrote:
> Hi.
>
> The wrapper.exp testcase is failing with stdio gdbserver.
>
> make check RUNTESTFLAGS="--target_board=native-stdio-gdbserver wrapper.exp"
> FAIL: gdb.server/wrapper.exp: continue to marker (the program is no longer running)
> FAIL: gdb.server/wrapper.exp: print d
>
> The problem is the "stdio" port argument isn't being properly
> passed to gdbserver.
>
> This patch fixes things by removing the clunky argument parsing
> native-stdio-gdbserver.exp does to insert "stdio" and instead
> adds a new setting that the board file can use to compute the "port"
> argument.
>
> Regression tested with native-gdbserver.exp, native-stdio-gdbserver.exp,
> and remote-stdio-gdbserver.exp on amd64-linux.
>
> 2014-02-12 Doug Evans <dje@google.com>
>
> testsuite/
> * lib/gdbserver-support.exp (gdbserver_default_get_remote_address):
> Add comment.
> (gdbserver_default_get_comm_port): New function.
> (gdbserver_start): Check if board file provided
> "gdbserver,get_comm_port" and use it if so.
> * boards/native-stdio-gdbserver.exp (sockethost): Set to "".
> (gdb,socketport): Set to "stdio".
> (gdbserver,get_comm_port): Set to ${board}_get_comm_port.
> (stdio_gdbserver_template): Delete.
> (${board}_get_remote_address): Update.
> (${board}_build_remote_cmd): Delete.
> (${board}_get_comm_port): New function.
> (${board}_spawn): Update.
> * boards/remote-stdio-gdbserver.exp (${board}_build_remote_cmd):
> Delete.
> (${board}_get_remote_address): Update.
> (${board}_get_comm_port): New function.
Committed.