[PATCH] Support -z initfirst for multiple shared libraries

Yury Gribov y.gribov@samsung.com
Wed May 4 07:00:00 GMT 2016


On 05/02/2016 11:06 AM, Florian Weimer wrote:
> On 04/26/2016 10:58 PM, d wk wrote:
>> In a project of mine, I needed to run some code before any constructors
>> from any system libraries (such as libc or libpthread). The linker/loader
>> -z initfirst feature is perfect for this, but it only supports one shared
>> library.
>
> Does -z initfirst affect just constructor execution, or symbol binding
> as well?

It's only about construction order.

>
> As initfirst is currently defined for GNU, there can only be one
> initfirst library.
>
> Florian
>
>



More information about the Libc-alpha mailing list