]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
[gdb/testsuite] Require cooked index in two test-cases
authorTom de Vries <tdevries@suse.de>
Sat, 23 Aug 2025 06:44:34 +0000 (08:44 +0200)
committerTom de Vries <tdevries@suse.de>
Sat, 23 Aug 2025 06:44:34 +0000 (08:44 +0200)
After running the testsuite with target board cc-with-gdb-index I ran found
failures in test-cases:
- gdb.dwarf2/backward-spec-inter-cu.exp
- gdb.dwarf2/forward-spec-inter-cu.exp

Fix this by requiring a cooked index.

Tested on x86_64-linux.

gdb/testsuite/gdb.dwarf2/backward-spec-inter-cu.exp
gdb/testsuite/gdb.dwarf2/forward-spec-inter-cu.exp

index b62f9288a772ca81cd35fb2a163553ef0caa990e..1876849afd3c0ad2d3efeeed5c4040e02dfee003 100644 (file)
@@ -20,6 +20,7 @@ load_lib dwarf.exp
 
 # This test can only be run on targets which support DWARF-2 and use gas.
 require dwarf2_support
+require !readnow
 
 standard_testfile main.c -debug.S
 
@@ -98,6 +99,11 @@ foreach_with_prefix worker_threads $worker_threads_list {
 
     gdb_load $binfile
 
+    set index [have_index $binfile]
+    if { ![string eq $index ""] } {
+       return
+    }
+
     gdb_test "pipe maint print objfiles | grep ns::v" \
        "$ws+qualified:$ws+ns::v" \
        "v has parent ns"
index e92e582b68a2c14bf3f4fbe986948bde2068efc3..26d0af6706b08b86adee1ac0e4a762ed98f5d6de 100644 (file)
@@ -20,6 +20,7 @@ load_lib dwarf.exp
 
 # This test can only be run on targets which support DWARF-2 and use gas.
 require dwarf2_support
+require !readnow
 
 standard_testfile main.c -debug.S
 
@@ -98,6 +99,11 @@ foreach_with_prefix worker_threads $worker_threads_list {
 
     gdb_load $binfile
 
+    set index [have_index $binfile]
+    if { ![string eq $index ""] } {
+       return
+    }
+
     gdb_test "pipe maint print objfiles | grep ns::v" \
        "$ws+qualified:$ws+ns::v" \
        "v has parent ns"