binutils-gdb/ld/testsuite/ld-mips-elf/pic-and-nonpic-5b.ad
Matthew Fortune a5499fa464 Add support for DT_MIPS_RLD_MAP_REL.
This tag makes it possible to access the debug map when debugging position
independent executables.

bfd/

	* elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Use executable
	instead of !shared to indicate an application vs shared library.
	(_bfd_mips_elf_size_dynamic_sections): Likewise.
	(_bfd_mips_elf_finish_dynamic_sections): Handle DT_MIPS_RLD_MAP_REL.
	(_bfd_mips_elf_get_target_dtag): Likewise.

binutils/

	* readelf.c (get_mips_dynamic_type): Handle DT_MIPS_RLD_MAP_REL.

include/

	* elf/mips.h (DT_MIPS_RLD_MAP_REL): New macro.

ld/testsuite/

	* ld-mips-elf/pic-and-nonpic-3b.ad: Adjust for extra dynamic tag.
	* ld-mips-elf/pic-and-nonpic-4b.ad: Likewise.
	* ld-mips-elf/pic-and-nonpic-5b.ad: Likewise.
	* ld-mips-elf/pic-and-nonpic-6-n32.ad: Likewise.
	* ld-mips-elf/pic-and-nonpic-6-n64.ad: Likewise.
	* ld-mips-elf/pic-and-nonpic-6-o32.ad: Likewise.
	* ld-mips-elf/tlsdyn-o32-1.d: Likewise.
	* ld-mips-elf/tlsdyn-o32-1.got: Likewise.
	* ld-mips-elf/tlsdyn-o32-2.d: Likewise.
	* ld-mips-elf/tlsdyn-o32-2.got: Likewise.
	* ld-mips-elf/tlsdyn-o32-3.d: Likewise.
	* ld-mips-elf/tlsdyn-o32-3.got: Likewise.
	* ld-mips-elf/tlsdyn-o32.d: Likewise.
	* ld-mips-elf/tlsdyn-o32.got: Likewise.
	* ld-mips-elf/pie-n32.d: New file.
	* ld-mips-elf/pie-n64.d: Likewise.
	* ld-mips-elf/pie-o32.d: Likewise.
	* ld-mips-elf/pie.s: Likewise.
	* ld-mips-elf/mips-elf.exp: Add new tests.
2015-06-26 11:53:33 +01:00

34 lines
1.0 KiB
Plaintext

Dynamic section at offset .* contains .*:
* Tag * Type * Name/Value
0x00000001 \(NEEDED\) .*
0x00000001 \(NEEDED\) .*
0x00000004 \(HASH\) .*
0x00000005 \(STRTAB\) .*
0x00000006 \(SYMTAB\) .*
0x0000000a \(STRSZ\) .*
0x0000000b \(SYMENT\) .*
0x70000016 \(MIPS_RLD_MAP\) * 0x80000
0x70000035 \(MIPS_RLD_MAP_REL\) .*
0x00000015 \(DEBUG\) * 0x0
0x00000016 \(TEXTREL\) * 0x0
0x00000003 \(PLTGOT\) * 0xa0000
0x00000011 \(REL\) * 0x43000
0x00000012 \(RELSZ\) * 48 \(bytes\)
0x00000013 \(RELENT\) * 8 \(bytes\)
0x70000001 \(MIPS_RLD_VERSION\) * 1
0x70000005 \(MIPS_FLAGS\) * NOTPOT
0x70000006 \(MIPS_BASE_ADDRESS\) * 0x40000
# This must be the number of GOT entries - 2. The last two entries are
# for "bar" and "obj2".
0x7000000a \(MIPS_LOCAL_GOTNO\) * 2
# This must be MIPS_GOTSYM + 2.
0x70000011 \(MIPS_SYMTABNO\) * 8
0x70000012 \(MIPS_UNREFEXTNO\) * .*
0x70000013 \(MIPS_GOTSYM\) * 0x6
0x00000014 \(PLTREL\) * REL
0x00000017 \(JMPREL\) * 0x43030
0x00000002 \(PLTRELSZ\) * 8 \(bytes\)
0x70000032 \(MIPS_PLTGOT\) * 0x81000
0x00000000 \(NULL\) * 0x0