+2009-09-15 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * ld-elfcomm/elfcomm.exp: Add appropriate emulation option
+ for sh64*-*-*.
+ * ld-gc/gc.exp (test_gc): Likewise.
+
2009-09-14 H.J. Lu <hongjiu.lu@intel.com>
* ld-undefined/entry-7.d: New.
# Expect script for common symbol tests
-# Copyright 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+# Copyright 2003, 2005, 2006, 2007, 2008, 2009
+# Free Software Foundation, Inc.
#
# This file is part of the GNU Binutils.
#
global ld
global link_output
-if { [ld_simple_link $ld tmpdir/common1.o "-r tmpdir/common1a.o tmpdir/common1b.o"] } {
+set options "-r tmpdir/common1a.o tmpdir/common1b.o"
+
+# SH64 targets needs an extra ld option for this test.
+if [istarget sh64*-*-*] {
+ if [istarget sh64*l*-*-*] {
+ set options "-mshlelf32 $options"
+ } else {
+ set options "-mshelf32 $options"
+ }
+}
+
+if { [ld_simple_link $ld tmpdir/common1.o $options] } {
unresolved $test1w1
return
}
pass $test1c1
}
-if { [ld_simple_link $ld tmpdir/common1.o "-r tmpdir/common1b.o tmpdir/common1a.o"] } {
+set options "-r tmpdir/common1b.o tmpdir/common1a.o"
+
+# SH64 targets needs an extra ld option for this test.
+if [istarget sh64*-*-*] {
+ if [istarget sh64*l*-*-*] {
+ set options "-mshlelf32 $options"
+ } else {
+ set options "-mshelf32 $options"
+ }
+}
+
+if { [ld_simple_link $ld tmpdir/common1.o $options] } {
unresolved $test1w2
return
}
# Expect script for ld-gc tests
-# Copyright 2008
+# Copyright 2008, 2009
# Free Software Foundation, Inc.
#
# This file is part of the GNU Binutils.
}
set outfile "tmpdir/$filename"
+ set options "-L$srcdir/$subdir $ldflags $objfile"
- if ![ld_simple_link $linker $outfile "-L$srcdir/$subdir $ldflags $objfile"] {
+ # SH64 targets needs an extra ld option for this test.
+ if [istarget sh64*-*-*] {
+ if [istarget sh64*l*-*-*] {
+ set options "-mshlelf32 $options"
+ } else {
+ set options "-mshelf32 $options"
+ }
+ }
+
+ if ![ld_simple_link $linker $outfile $options] {
fail $testname
return
}