This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Do unset_currtarget_info ldscript for all simulator testsuites.


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=a9d9677441e54816aa76ffd1736419ec096b4ef1

commit a9d9677441e54816aa76ffd1736419ec096b4ef1
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Mon Apr 13 01:54:43 2015 +0200

    Do unset_currtarget_info ldscript for all simulator testsuites.
    
    sim/testsuite:
    	* sim-defs.exp (sim_init): Unset target ldscript here.
    
    sim/testsuite/sim/mips:
    	* basic.exp: Don't unset target ldscript here.

Diff:
---
 sim/testsuite/ChangeLog          |  4 ++++
 sim/testsuite/lib/sim-defs.exp   | 10 ++++++++++
 sim/testsuite/sim/mips/ChangeLog |  4 ++++
 sim/testsuite/sim/mips/basic.exp |  6 ------
 4 files changed, 18 insertions(+), 6 deletions(-)

diff --git a/sim/testsuite/ChangeLog b/sim/testsuite/ChangeLog
index 6bae4e5..20038f1 100644
--- a/sim/testsuite/ChangeLog
+++ b/sim/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2015-04-13  Hans-Peter Nilsson  <hp@axis.com>
+
+	* sim-defs.exp (sim_init): Unset target ldscript here.
+
 2015-03-30  Mike Frysinger  <vapier@gentoo.org>
 
 	* configure.ac: Add d10v-*-elf.
diff --git a/sim/testsuite/lib/sim-defs.exp b/sim/testsuite/lib/sim-defs.exp
index fb2346a..2faf5dc 100644
--- a/sim/testsuite/lib/sim-defs.exp
+++ b/sim/testsuite/lib/sim-defs.exp
@@ -12,6 +12,16 @@ proc sim_init { args } {
     global sim_path
     set sim_path [board_info target sim]
     # Need to return an empty string (copied from GAS).
+
+    # As gross as it is, we unset the linker script specified by the target
+    # board.  The simulator board file mips-sim.exp, sets ldscript to the
+    # MIPS libgloss linker scripts which include libgcc (and possibly other
+    # libraries), which the linker (used to link these tests rather than the
+    # compiler) can't necessarily find.  Similarly iq2000-sim.exp and
+    # m68hc11-sim.exp.  So, we make it a common rule to clear the slate for
+    # all simulators.
+    unset_currtarget_info ldscript
+
     return ""
 }
 
diff --git a/sim/testsuite/sim/mips/ChangeLog b/sim/testsuite/sim/mips/ChangeLog
index 5505144..d2080d1 100644
--- a/sim/testsuite/sim/mips/ChangeLog
+++ b/sim/testsuite/sim/mips/ChangeLog
@@ -1,3 +1,7 @@
+2015-04-13  Hans-Peter Nilsson  <hp@axis.com>
+
+	* basic.exp: Don't unset target ldscript here.
+
 2011-01-06  Hans-Peter Nilsson  <hp@axis.com>
 
 	* testutils.inc: Correct comment syntax fallout from
diff --git a/sim/testsuite/sim/mips/basic.exp b/sim/testsuite/sim/mips/basic.exp
index 1c78c87..ddef535 100644
--- a/sim/testsuite/sim/mips/basic.exp
+++ b/sim/testsuite/sim/mips/basic.exp
@@ -1,11 +1,5 @@
 # MIPS simulator instruction tests
 
-# As gross as it is, we unset the linker script specified by the target
-# board.  The MIPS libgloss linker scripts include libgcc (and possibly
-# other libraries), which the linker (used to link these tests rather
-# than the compiler) can't necessarily find.
-unset_currtarget_info ldscript
-
 # Do "run_sim_test TESTFILE MODELS" for each combination of the
 # mf{lo,hi} -> mult/div/mt{lo,hi} hazard described in mips.igen.
 # Insert NOPS nops after the mflo or mfhi.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]