From: H.J. Lu Date: Thu, 24 Apr 2003 21:00:06 +0000 (+0000) Subject: 2003-04-24 J"orn Rennecke X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=09bf97202b88595b7a2e029bde55b25542b5455b;p=binutils-gdb.git 2003-04-24 J"orn Rennecke * ld-elfcomm/elfcomm.exp: Allow symbols to have '_' prepended. --- diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog index b7438efc7dd..9fc8f0dadf1 100644 --- a/ld/testsuite/ChangeLog +++ b/ld/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2003-04-24 J"orn Rennecke + + * ld-elfcomm/elfcomm.exp: Allow symbols to have '_' prepended. + 2003-04-23 Kaz Kojima * ld-sh/tlsbin-1.d, ld-sh/tlsbin-2.d, ld-sh/tlsbin-3.d, diff --git a/ld/testsuite/ld-elfcomm/elfcomm.exp b/ld/testsuite/ld-elfcomm/elfcomm.exp index 37e5ede0f9d..c9836c116f7 100644 --- a/ld/testsuite/ld-elfcomm/elfcomm.exp +++ b/ld/testsuite/ld-elfcomm/elfcomm.exp @@ -1,4 +1,4 @@ -# Expect script for commom symbol tests +# Expect script for common symbol tests # Copyright 2003 Free Software Foundation, Inc. # # This file is free software; you can redistribute it and/or modify @@ -39,8 +39,8 @@ proc dump_common1 { testname } { send_log "readelf -s tmpdir/common1.o | grep foo\n" catch "exec readelf -s tmpdir/common1.o | grep foo" exec_output - if { ![regexp "(\[ \]*)(\[0-9\]+):(\[ \]*)(\[0\]*)80(\[ \]+)4(\[ \]+)OBJECT(\[ \]+)GLOBAL(\[ \]+)DEFAULT(\[ \]+)COM(\[ \]+)foo2" $exec_output] - || ![regexp "(\[ \]*)(\[0-9\]+):(\[ \]*)(\[0-9\]+)(\[ \]+)21(\[ \]+)OBJECT(\[ \]+)GLOBAL(\[ \]+)DEFAULT(\[ \]+)(\[0-9\]+)(\[ \]+)foo1" $exec_output] } { + if { ![regexp "(\[ \]*)(\[0-9\]+):(\[ \]*)(\[0\]*)80(\[ \]+)4(\[ \]+)OBJECT(\[ \]+)GLOBAL(\[ \]+)DEFAULT(\[ \]+)COM(\[ \]+)_?foo2" $exec_output] + || ![regexp "(\[ \]*)(\[0-9\]+):(\[ \]*)(\[0-9\]+)(\[ \]+)21(\[ \]+)OBJECT(\[ \]+)GLOBAL(\[ \]+)DEFAULT(\[ \]+)(\[0-9\]+)(\[ \]+)_?foo1" $exec_output] } { send_log "$exec_output\n" verbose $exec_output fail $testname @@ -50,7 +50,7 @@ proc dump_common1 { testname } { return 1 } -set test1 "size/aligment change of commom symbols" +set test1 "size/aligment change of common symbols" if { ![ld_compile "$CC $CFLAGS" $srcdir/$subdir/common1a.c tmpdir/common1a.o] || ![ld_compile "$CC $CFLAGS" $srcdir/$subdir/common1b.c tmpdir/common1b.o] } { unresolved $test1 @@ -65,8 +65,8 @@ if { [ld_simple_link $ld tmpdir/common1.o "-r tmpdir/common1a.o tmpdir/common1b. return } -if { ![regexp "Warning: alignment (\[0-9\]+) of symbol \`foo1\' in tmpdir/common1b.o is smaller than 64 in tmpdir/common1a.o" $link_output] - || ![regexp "Warning: size of symbol \`foo1\' changed from 2 in tmpdir/common1a.o to 21 in tmpdir/common1b.o" $link_output] } { +if { ![regexp "Warning: alignment (\[0-9\]+) of symbol \`_?foo1\' in tmpdir/common1b.o is smaller than 64 in tmpdir/common1a.o" $link_output] + || ![regexp "Warning: size of symbol \`_?foo1\' changed from 2 in tmpdir/common1a.o to 21 in tmpdir/common1b.o" $link_output] } { fail "$test1 (warning 1)" } else { pass "$test1 (warning 1)" @@ -81,7 +81,7 @@ if { [ld_simple_link $ld tmpdir/common1.o "-r tmpdir/common1b.o tmpdir/common1a. return } -if { ![regexp "Warning: alignment (\[0-9\]+) of symbol \`foo1\' in tmpdir/common1b.o is smaller than 64 in tmpdir/common1a.o" $link_output] } { +if { ![regexp "Warning: alignment (\[0-9\]+) of symbol \`_?foo1\' in tmpdir/common1b.o is smaller than 64 in tmpdir/common1a.o" $link_output] } { fail "$test1 (warning 2)" } else { pass "$test1 (warning 2)"