Preventing preemption of 'protected' symbols in GNU ld 2.26
Cary Coutant
ccoutant@gmail.com
Thu Mar 24 16:06:00 GMT 2016
> I disagree. Protected means that it won't be preempted. It
> doesn't mean the address of protected symbol will be local.
> With copy relocation, the run-time address of the protected
> symbol can be in executable. There are a couple run-time
> tests in glibc to verify it. See:
>
> https://sourceware.org/bugzilla/show_bug.cgi?id=17711
No. You can't just redefine away the meaning of "must resolve to a
definition in that component." A COPY relocation makes a new
definition in the main program and that new definition pre-empts the
one in the shared library. That breaks everything that the rule in the
gABI was designed to allow.
-cary
More information about the Binutils
mailing list