aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-x86-64/line.exp
diff options
context:
space:
mode:
Diffstat (limited to 'ld/testsuite/ld-x86-64/line.exp')
-rw-r--r--ld/testsuite/ld-x86-64/line.exp13
1 files changed, 10 insertions, 3 deletions
diff --git a/ld/testsuite/ld-x86-64/line.exp b/ld/testsuite/ld-x86-64/line.exp
index c68daaa..3ddaf17 100644
--- a/ld/testsuite/ld-x86-64/line.exp
+++ b/ld/testsuite/ld-x86-64/line.exp
@@ -1,6 +1,6 @@
# Test that the linker reports undefined symbol line number correctly.
#
-# Copyright 2007 Free Software Foundation, Inc.
+# Copyright 2007, 2012 Free Software Foundation, Inc.
#
# This file is part of the GNU Binutils.
#
@@ -20,10 +20,17 @@
# MA 02110-1301, USA.
if { !([istarget "x86_64-*-elf*"]
+ || [istarget "x86_64-*-nacl*"]
|| [istarget "x86_64-*-linux*"]) } {
return
}
+if [istarget "*-*-nacl*"] {
+ set emul "elf_x86_64_nacl"
+} else {
+ set emul "elf_x86_64"
+}
+
set testline "undefined line"
if ![ld_assemble $as "--64 $srcdir/$subdir/undefined.s" tmpdir/undefined.o] {
@@ -36,8 +43,8 @@ remote_file host delete "tmpdir/undefined"
# Using -e start prevents the SunOS linker from trying to build a
# shared library.
-send_log "$ld -e start -melf_x86_64 -o tmpdir/undefined tmpdir/undefined.o\n"
-set exec_output [run_host_cmd "$ld" "-e start -melf_x86_64 -o tmpdir/undefined tmpdir/undefined.o"]
+send_log "$ld -e start -m$emul -o tmpdir/undefined tmpdir/undefined.o\n"
+set exec_output [run_host_cmd "$ld" "-e start -m$emul -o tmpdir/undefined tmpdir/undefined.o"]
send_log "$exec_output\n"
verbose "$exec_output"