This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH][gdb/testsuite] Fix gdb.go/methods.exp
- From: Tom Tromey <tom at tromey dot com>
- To: Tom de Vries <tdevries at suse dot de>
- Cc: gdb-patches at sourceware dot org
- Date: Fri, 21 Feb 2020 07:54:07 -0700
- Subject: Re: [PATCH][gdb/testsuite] Fix gdb.go/methods.exp
- References: <20200221110152.GA30305@delia>
>>>>> "Tom" == Tom de Vries <tdevries@suse.de> writes:
Tom> +if { [exec_contains_debug_info_string $binfile \
Tom> + "DW_AT_name.*: main.Foo.N6_main.T"] } {
Is there a way to get this information from gdb itself?
Tom> +proc exec_contains_debug_info_string { executable re } {
Tom> + set readelf_program [gdb_find_readelf]
Tom> + set res [catch {exec $readelf_program -wi $executable \
Tom> + | grep -E "$re" }]
If not you should probably find a way to do this with objdump; unless
these tests are already ELF-only for some reason.
Tom