binutils-gdb/ld/testsuite
Maciej W. Rozycki 28d810f7ff LD/testsuite: Fix undefined symbol tests for MIPS and S+core targets
Fix commit 647d4de92e ("Test undefined symbols in shared libraries")
and remove "undefined symbols in shared lib (dyn reloc)" test failures
for MIPS and S+core targets.

This test assumes 3 dynamic relocation entries, however the respective
psABIs define an extra single dummy *_NONE relocation at the beginning
of the dynamic relocation table, which results in test output like the
following for MIPS:

Relocation section '.rel.dyn' at offset 0x33c contains 4 entries:
 Offset     Info    Type            Sym.Value  Sym. Name
00000000  00000000 R_MIPS_NONE
00010364  00000903 R_MIPS_REL32      00000000   undef_pfun
00010360  00000a03 R_MIPS_REL32      00000000   undef_data
00010368  00000b03 R_MIPS_REL32      00000000   undef_notype

and S+core:

Relocation section '.rel.dyn' at offset 0x274 contains 4 entries:
 Offset     Info    Type            Sym.Value  Sym. Name
00000000  00000000 R_SCORE_NONE
5ffe0464  00000e12 R_SCORE_REL32     00000000   undef_notype
5ffe045c  00000f12 R_SCORE_REL32     00000000   undef_data
5ffe0460  00001012 R_SCORE_REL32     00000000   undef_pfun

targets respectively, and also n64 MIPS targets pad relocation triplets
they use with extra *_NONE relocations, resulting in output like this:

Relocation section '.rel.dyn' at offset 0x4c0 contains 4 entries:
  Offset          Info           Type           Sym. Value    Sym. Name
000000000000  000000000000 R_MIPS_NONE
                    Type2: R_MIPS_NONE
                    Type3: R_MIPS_NONE
000000010508  000900001203 R_MIPS_REL32      0000000000000000 undef_pfun
                    Type2: R_MIPS_64
                    Type3: R_MIPS_NONE
000000010500  000a00001203 R_MIPS_REL32      0000000000000000 undef_data
                    Type2: R_MIPS_64
                    Type3: R_MIPS_NONE
000000010510  000b00001203 R_MIPS_REL32      0000000000000000 undef_notype
                    Type2: R_MIPS_64
                    Type3: R_MIPS_NONE

Expect the right number of *_NONE relocations then, and adjust the total
number of relocations expected accordingly.

	ld/
	* testsuite/ld-undefined/undefined.exp: Correct the dyn reloc
	test for MIPS and S+core targets.
2017-09-26 12:09:50 +01:00
..
config LD_CLASS: Check .libs/ld-new for linker first 2017-08-09 16:38:09 -07:00
ld-aarch64 PR22118, Incorrectly-capitalized regexp 2017-09-15 20:21:42 +09:30
ld-alpha Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-arc Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-arm More support for ld --hash-style in the ld testsuite 2017-08-08 07:22:36 +09:30
ld-auto-import Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-avr This patch introduces support for specifing views in .loc directives, so that the compiler can use the assembler to generate line number information and have the assembler determine view numbers to multiple views at the same program counter. 2017-07-21 10:13:18 +01:00
ld-bootstrap Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-cdtest Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-checks ld-checks: tweak overflow checks. 2017-03-15 10:23:19 +01:00
ld-cris testsuite/ld-cris various files: Run ld with --hash-style=sysv. 2017-08-30 02:27:14 +02:00
ld-crx Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-cygwin Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-d10v Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-discard Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-elf Add a test for PR ld/22150 2017-09-22 07:05:53 -07:00
ld-elfcomm Fix spelling typos. 2017-07-18 16:58:14 +01:00
ld-elfvers Add -rpath-link to various tests 2017-01-03 12:36:02 +10:30
ld-elfvsb Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-elfweak Add -rpath-link to various tests 2017-01-03 12:36:02 +10:30
ld-fastcall Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-frv More support for ld --hash-style in the ld testsuite 2017-08-08 07:22:36 +09:30
ld-gc Remove pr19161 test hppa xfail 2017-08-23 08:58:42 +09:30
ld-h8300 Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-i386 x86: Cache section contents and relocations 2017-09-14 12:29:29 -07:00
ld-ia64 Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-ifunc Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-libs Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-linkonce Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-m68hc11 Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-m68k Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-mep Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-metag Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-mips-elf MIPS/BFD: Correct microMIPS cross-mode BAL to JALX relaxation 2017-08-30 16:07:45 +01:00
ld-misc Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-mmix PR ld/20125, MMIX weak symbols 2017-08-21 03:43:35 +02:00
ld-mn10300 Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-msp430-elf Improve MSP430 section placement. 2017-08-29 17:18:43 +01:00
ld-nds32 Fix address violation when disassembling a corrupt binary. 2017-06-14 16:50:03 +01:00
ld-nios2 Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-pe pe/coff: handle weak defined symbol for gc-sections. 2017-04-07 10:03:17 +02:00
ld-pie Don't run C tests in ld testsuite unless we have a C compiler 2017-01-03 11:47:47 +10:30
ld-plugin Handle symbol defined in IR and referenced in DSO 2017-04-20 07:48:35 -07:00
ld-powerpc Reduce excessive .eh_frame alignment for powerpc 2017-09-21 23:17:44 +09:30
ld-pru PRU LD Port 2016-12-31 12:04:11 +10:30
ld-s390 Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-scripts Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-selective Support single digit GCC version 2017-07-11 08:41:22 -07:00
ld-sh Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-shared Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-size Pass $NOPIE_LDFLAGS size tests 2017-06-21 14:45:57 -07:00
ld-sparc Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-spu Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-srec Pass $NOPIE_LDFLAGS size tests 2017-06-21 14:45:57 -07:00
ld-tic6x Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-tilegx Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-tilepro Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-undefined LD/testsuite: Fix undefined symbol tests for MIPS and S+core targets 2017-09-26 12:09:50 +01:00
ld-unique Don't fail in elf32_hppa_set_gp 2017-08-05 23:28:21 +09:30
ld-v850 Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-vax-elf Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-versados Run more ld tests when not native 2017-01-02 23:48:08 +10:30
ld-visium Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-vxworks Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-x86-64 x86: Cache section contents and relocations 2017-09-14 12:29:29 -07:00
ld-xc16x Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-xstormy16 Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
ld-xtensa Support different ld --hash-style in the ld testsuite 2017-08-07 22:10:51 +09:30
ld-z8k Update year range in copyright notice of all files. 2017-01-02 14:08:56 +10:30
lib ld: Add "--" after regexp 2017-08-24 17:45:24 -07:00
ChangeLog-2004 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2005 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2006 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2007 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2008 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2009 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2010 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2011 Add copyright notices 2012-12-10 12:48:03 +00:00
ChangeLog-2012 Rotate binutils ChangeLog for 2013 2013-01-02 17:06:32 +00:00
ChangeLog-2013 New Year - binutils ChangeLog rotation 2014-01-08 05:32:12 -08:00
ChangeLog-2014 ChangeLog rotatation and copyright year update 2015-01-02 00:53:45 +10:30
ChangeLog-2015 binutils ChangeLog rotation 2016-01-01 22:59:17 +10:30
ChangeLog-9303 Add copyright notices 2012-12-10 12:48:03 +00:00