[3/7,gdb/testsuite] fix test gdb.base/jit-reader-exec.exp for remote execution

Message ID 20221025162946.727169-4-ivan.tetyushkin@syntacore.com
State New
Headers
Series introduce get_runtime_path |

Commit Message

Ivan Tetyushkin Oct. 25, 2022, 4:29 p.m. UTC
  ---
 gdb/testsuite/gdb.base/jit-reader-exec.exp | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
  

Patch

diff --git a/gdb/testsuite/gdb.base/jit-reader-exec.exp b/gdb/testsuite/gdb.base/jit-reader-exec.exp
index c5ee8ef89a3..8b03b24f1e6 100644
--- a/gdb/testsuite/gdb.base/jit-reader-exec.exp
+++ b/gdb/testsuite/gdb.base/jit-reader-exec.exp
@@ -26,8 +26,9 @@  standard_testfile jit-reader-exec.c
 set testfile2 "jit-reader-execd"
 set srcfile2 ${testfile2}.c
 set binfile2 [standard_output_file ${testfile2}]
+set runtimefile2 [get_runtime_file $binfile2]
 
-set compile_options [list debug additional_flags=-DPROGRAM=\"$binfile2\"]
+set compile_options [list debug additional_flags=-DPROGRAM=\"$runtimefile2\"]
 
 if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \
 	 executable $compile_options] != ""} {
@@ -43,6 +44,8 @@  if {[gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" \
 
 clean_restart $binfile
 
+gdb_remote_download target $binfile2
+
 if {![runto_main]} {
     return
 }