From f6dc277e05ace0d206284e7357dec909181c2e60 Mon Sep 17 00:00:00 2001 From: Yao Qi Date: Thu, 18 Jul 2013 05:07:25 +0000 Subject: [PATCH] gdb/testsuite/ * lib/gdb.exp (gdb_compile): Set gdb_saved_set_unbuffered_mode_obj to set_unbuffered_mode_saved.o if host is remote. Invoke remote_download to copy $unbuf_obj to host. --- gdb/testsuite/ChangeLog | 7 +++++++ gdb/testsuite/lib/gdb.exp | 9 ++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index ca53ee1..6ce8209 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2013-07-18 Yao Qi + + * lib/gdb.exp (gdb_compile): Set + gdb_saved_set_unbuffered_mode_obj to + set_unbuffered_mode_saved.o if host is remote. Invoke + remote_download to copy $unbuf_obj to host. + 2013-07-17 Doug Evans * gdb.python/py-frame-args.c: New file. diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index 376aacc..fc9b071 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -2652,11 +2652,14 @@ proc gdb_compile {source dest type options} { if { $result != "" } { return $result } - - set gdb_saved_set_unbuffered_mode_obj ${objdir}/set_unbuffered_mode_saved.o + if {[is_remote host]} { + set gdb_saved_set_unbuffered_mode_obj set_unbuffered_mode_saved.o + } else { + set gdb_saved_set_unbuffered_mode_obj ${objdir}/set_unbuffered_mode_saved.o + } # Link a copy of the output object, because the # original may be automatically deleted. - remote_exec host "cp -f $unbuf_obj $gdb_saved_set_unbuffered_mode_obj" + remote_download host $unbuf_obj $gdb_saved_set_unbuffered_mode_obj } else { verbose "gdb_saved_set_unbuffered_obj already compiled" } -- 2.7.4