Question about readelf output from shared library built with lld, gold, and bfd linkers

Nick Clifton nickc@redhat.com
Mon Nov 21 15:16:56 GMT 2022


Hi Tom,

>> I assume that you have compared started up times when linking with "-z now"
>> vs "-z lazy" ?
>>
> 
> I thought -z lazy was the default, and that if you wanted the equivalent of
> LD_BIND_NOW=1 on the command line, then one would use -z now.

It depends upon the environment.  In Fedora (and RHEL) "-z now" is the
default.  The reason is program security - lazy binding means that an
attacker might be able to alter the relocations before they are evaluated,
allowing all kinds of unexpected things to happen.

Cheers
   Nick




More information about the Binutils mailing list