This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PING: [PATCH] Add --enable-static-pie to build static PIE


On 27/09/17 09:30, H.J. Lu wrote:
> On 9/26/17, Joseph Myers <joseph@codesourcery.com> wrote:
>> On Tue, 26 Sep 2017, H.J. Lu wrote:
>>
>>> Any objections?
>>
>> This is a complicated feature; it clearly needs someone to do a detailed
>> technical review before it can go in, however long that takes.  It's only
>> borderline-obvious patches one might consider committing after a while in
>> the absence of objections but without review or relevant maintainership.
>>
>> Perhaps you could expand more on the design and the rationale for the
> 
> Dynamic linker, ld.so, is a standalone program which can be loaded at
> any address.  This patch adds a configure option, --enable-static-pie,
> to embed the part of ld.so in static executable to create static position
> independent executable (static PIE).
> 

can it be too late to do the relocation in __libc_start_main?

that comes after the crt1 startup code and an arch specific wrapper
which may end up having R_*_RELATIVE relocs for various function
pointers (including __libc_start_main itself and its arguments)

what guarantees that __libc_start_main can always be called
without relocations (pc relative calls have limits on some
targets)?

i'd expect the relocation to happen in the crt1.o startup code.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]