This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: weird ro mapping generate by ld-linux.so
Mathieu Lacage <mathieu.lacage@gmail.com> writes:
> I wonder why the linker does not simply generate 3 PT_LOAD entries
> (RO, RO, RW) to do this instead of generating only two (RO,RW).
Because the relro segment must be relocated, so it cannot be made ro at
first (without reverting to the much more expensive TEXTREL). Loaders
that don't know about relro can just ignore it and do the right thing
(by keeping it rw).
Andreas.
--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."