This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 08/13] simple changes in gdb.base
- From: Pedro Alves <palves at redhat dot com>
- To: Tom Tromey <tromey at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 27 Aug 2013 14:31:09 +0100
- Subject: Re: [PATCH 08/13] simple changes in gdb.base
- Authentication-results: sourceware.org; auth=none
- References: <1377290210-483-1-git-send-email-tromey at redhat dot com> <1377290210-483-9-git-send-email-tromey at redhat dot com>
On 08/23/2013 09:36 PM, Tom Tromey wrote:
> +
> +foreach file $all_files {
> + if {[is_remote host]} {
> + set this_name $file
> + } else {
> + set this_name [standard_output_file $file]
> + }
> +
> + lappend filenames [set ${file} $this_name]
Took me a second to realize/notice it's this loop that
creates the intarr1.bin etc. variables used in:
> +make_dump_file "dump val [set intarr1.bin] intarray"
etc. How about adding a comment here, or above the loop?
> +}
> +
> +remote_exec host "rm -f $filenames"
>
> # Test help (FIXME:)
>
> @@ -96,34 +115,34 @@ proc make_dump_file { command msg } {
> }
> }
>
> -make_dump_file "dump val intarr1.bin intarray" \
> +make_dump_file "dump val [set intarr1.bin] intarray" \
> "dump array as value, default"
> --- a/gdb/testsuite/gdb.base/dump.exp
> +++ b/gdb/testsuite/gdb.base/dump.exp
> @@ -63,7 +63,26 @@ if {${data_address} > ${max_32bit_address}} then {
>
> # Clean up any stale output files from previous test runs
>
> -remote_exec build "rm -f intarr1.bin intarr1b.bin intarr1.ihex intarr1.srec intarr1.tekhex intarr2.bin intarr2b.bin intarr2.ihex intarr2.srec intarr2.tekhex intstr1.bin intstr1b.bin intstr1.ihex intstr1.srec intstr1.tekhex intstr2.bin intstr2b.bin intstr2.ihex intstr2.srec intstr2.tekhex intarr3.srec"
...
> +remote_exec host "rm -f $filenames"
...
> # clean up files
>
> -remote_exec build "rm -f intarr1.bin intarr1b.bin intarr1.ihex intarr1.srec intarr1.tekhex intarr2.bin intarr2b.bin intarr2.ihex intarr2.srec intarr2.tekhex intstr1.bin intstr1b.bin intstr1.ihex intstr1.srec intstr1.tekhex intstr2.bin intstr2b.bin intstr2.ihex intstr2.srec intstr2.tekhex intarr3.srec"
> +remote_exec build "rm -f $filenames"
s/build/host ?
>
> -set solib_binfile_target [gdb_download ${solib_binfile}]
> +if {[is_remote target]} {
> + set solib_binfile_target [gdb_download ${solib_binfile}]
> +} else {
> + set solib_binfile_target $solib_binfile
> +}
>
Sounds like this should be using gdb_load_shlibs.
--
Pedro Alves