[gdb/testsuite] Fix index-cache.exp with cc-with-{gdb-index,debug-names}
authorTom de Vries <tdevries@suse.de>
Mon, 6 May 2019 06:42:24 +0000 (08:42 +0200)
committerTom de Vries <tdevries@suse.de>
Mon, 6 May 2019 06:42:24 +0000 (08:42 +0200)
commit5a56d6a65f8406f1aadb4569fbb8ff00a6e92d02
treed3034dd247a995c5bc52560caaeb13d1cf4e3bdc
parente1cbf07ac4f8c8525dfadaa19bfb2997a2bfaad9
[gdb/testsuite] Fix index-cache.exp with cc-with-{gdb-index,debug-names}

In gdb.base/index-cache.exp, handle the case that binfile contains either a
.gdb_index or .debug_names index section.

Tested on x86_64-linux with native, cc-with-gdb-index and cc-with-debug-names.

gdb/testsuite/ChangeLog:

2019-05-06  Tom de Vries  <tdevries@suse.de>

* lib/gdb.exp (exec_has_index_section): New proc.
* gdb.base/index-cache.exp: Handle case that binfile contains an index
section.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/index-cache.exp
gdb/testsuite/lib/gdb.exp