PING: [PATCH] Add --enable-static-pie to build static PIE
Szabolcs Nagy
szabolcs.nagy@arm.com
Thu Oct 5 15:22:00 GMT 2017
On 05/10/17 14:11, H.J. Lu wrote:
> On 9/29/17, H.J. Lu <hjl.tools@gmail.com> wrote:
>> I submitted patches for other targets to address obvious issues with static
>> PIE. Build results of build-many-glibcs.py with --enable-static-pie with
>> all
>> patches for static PIE applied are
>>
>> PASS: glibcs-aarch64_be-linux-gnu build
>> PASS: glibcs-aarch64-linux-gnu build
can you tell me the binutils version used?
building fails with recent binutils master:
builddir/libc.a(dl-reloc-static-pie.o): In function `elf_get_dynamic_info':
srcdir/elf/get-dynamic-info.h:73:(.text+0x4c): relocation truncated to fit: R_AARCH64_ADR_PREL_PG_HI21 against
symbol `_dl_main_map' defined in .data.rel.local section in builddir/libc.a(dl-support.o)
srcdir/elf/get-dynamic-info.h:70:(.text+0x50): relocation truncated to fit: R_AARCH64_ADR_PREL_PG_HI21 against
symbol `_dl_main_map' defined in .data.rel.local section in builddir/libc.a(dl-support.o)
and
$ objdump -t builddir/elf/dl-support.o
...
0000000000000000 g O .data.rel.local 0000000000000468 .hidden _dl_main_map
...
$ objdump -r builddir/elf/dl-reloc-static-pie.o
...
000000000000004c R_AARCH64_ADR_PREL_PG_HI21 _dl_main_map+0x000000037ffffa40
0000000000000050 R_AARCH64_ADR_PREL_PG_HI21 _dl_main_map+0x000000037ffff1e0
...
those offsets look wrong, i'll need to investigate
More information about the Libc-alpha
mailing list