Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Guinevere Larsen <guinevere@redhat.com>
To: gdb-patches@sourceware.org
Cc: Guinevere Larsen <guinevere@redhat.com>, Tom de Vries <tdevries@suse.de>
Subject: [PATCH] gdb/testsuite: Fix file location for gdb.base/backtrace-through-cu-nodebug
Date: Mon, 20 Jan 2025 09:26:09 -0300	[thread overview]
Message-ID: <20250120122608.115710-2-guinevere@redhat.com> (raw)
In-Reply-To: <7fa350c1-a2b7-4284-a59b-be68c1af9221@suse.de>

The newly added test gdb.base/backtrace-through-cu-nodebug.exp had a
problem in the call to gdb_comiple, that caused the .o files to be
outputted in the GDB file tree. This commit fixes the issues in the calls.

Reported-By: Tom de Vries <tdevries@suse.de>
---

Hi Tom,

Sorry about that, this patch should fix it. I'm not sure if this counts
as obvious, so I haven't pushed it yet, do let me know if this is ok :)

---
 .../gdb.base/backtrace-through-cu-nodebug.exp      | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/gdb/testsuite/gdb.base/backtrace-through-cu-nodebug.exp b/gdb/testsuite/gdb.base/backtrace-through-cu-nodebug.exp
index d6e686539c9..53bf642a92c 100644
--- a/gdb/testsuite/gdb.base/backtrace-through-cu-nodebug.exp
+++ b/gdb/testsuite/gdb.base/backtrace-through-cu-nodebug.exp
@@ -17,8 +17,8 @@
 # trace goes through a function with no debug information.
 
 standard_testfile -caller.c -main.c
-set objmainfile ${testfile}-main.o
-set objcallerfile ${testfile}-caller.o
+set objmainfile [standard_output_file ${testfile}-main.o]
+set objcallerfile [standard_output_file ${testfile}-caller.o]
 
 # Recompile the inferior with or without CFI information, then run the
 # inferior until the point where the important test starts.
@@ -28,7 +28,7 @@ proc prepare_test {has_cfi} {
     if {$has_cfi} {
 	set extension "cfi"
 	if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" \
-	     "${srcdir}/${subdir}/${objcallerfile}" \
+	     "${objcallerfile}" \
 	     object [list {additional_flags=-fomit-frame-pointer \
 		 -funwind-tables -fasynchronous-unwind-tables}]] != "" } {
 	    untested "couldn't compile with cfi"
@@ -37,7 +37,7 @@ proc prepare_test {has_cfi} {
     } else {
 	set extension "no-cfi"
 	if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" \
-	     "${srcdir}/${subdir}/${objcallerfile}" \
+	     "${objcallerfile}" \
 	     object [list {additional_flags=-fomit-frame-pointer \
 		 -fno-unwind-tables \
 		 -fno-asynchronous-unwind-tables}]] != "" } {
@@ -45,8 +45,8 @@ proc prepare_test {has_cfi} {
 	    return false
       }
     }
-    if {[gdb_compile [list "${srcdir}/${subdir}/${objmainfile}" \
-	    "${srcdir}/${subdir}/${objcallerfile}"] \
+    if {[gdb_compile [list "${objmainfile}" \
+	    "${objcallerfile}"] \
 	    "${binfile}-${extension}" binfile {}] != ""} {
 	untested "couldn't link object files"
 	return false
@@ -66,7 +66,7 @@ proc prepare_test {has_cfi} {
 }
 
 if {[gdb_compile "${srcdir}/${subdir}/${srcfile2}" \
-	"${srcdir}/${subdir}/${objmainfile}" \
+	"${objmainfile}" \
 	object {debug}] != "" } {
     untested "couldn't compile main file"
     return
-- 
2.48.1


  reply	other threads:[~2025-01-20 12:28 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-10 19:51 [PATCH v8 0/5] Modernize frame unwinders and add disable feature Guinevere Larsen
2024-12-10 19:51 ` [PATCH v8 1/5] gdb: make gdbarch store a vector of frame unwinders Guinevere Larsen
2025-01-14 14:28   ` Andrew Burgess
2025-01-14 20:34     ` Guinevere Larsen
2024-12-10 19:51 ` [PATCH v8 2/5] gdb: add "unwinder class" to " Guinevere Larsen
2025-01-14 15:28   ` Andrew Burgess
2024-12-10 19:51 ` [PATCH v8 3/5] gdb: Migrate frame unwinders to use C++ classes Guinevere Larsen
2025-01-14 17:13   ` Andrew Burgess
2024-12-10 19:51 ` [PATCH v8 4/5] gdb: introduce ability to disable frame unwinders Guinevere Larsen
2025-01-16 12:06   ` Andrew Burgess
2025-01-17 12:40     ` Guinevere Larsen
2025-01-17 13:55       ` Andrew Burgess
2025-01-17 14:47         ` Guinevere Larsen
2025-01-16 16:22   ` Andrew Burgess
2024-12-10 19:51 ` [PATCH v8 5/5] gdb/testsuite: Test for a backtrace through object without debuginfo Guinevere Larsen
2025-01-16 14:37   ` Andrew Burgess
2025-01-16 18:42     ` Guinevere Larsen
2025-01-17 13:58       ` Andrew Burgess
2025-01-18  8:07     ` Tom de Vries
2025-01-20 12:26       ` Guinevere Larsen [this message]
2025-01-20 12:46         ` [PATCH] gdb/testsuite: Fix file location for gdb.base/backtrace-through-cu-nodebug Tom de Vries
2025-01-20 12:48           ` Guinevere Larsen
2025-01-07 12:11 ` [PING][PATCH v8 0/5] Modernize frame unwinders and add disable feature Guinevere Larsen
2025-01-17 14:49 ` [PATCH " Guinevere Larsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250120122608.115710-2-guinevere@redhat.com \
    --to=guinevere@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tdevries@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox