This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: [PLUGIN] dlopen and RTLD_NOW


2011/9/5 Jakub Jelinek <jakub@redhat.com>:
> On Mon, Sep 05, 2011 at 10:22:10AM -0700, Andrew Pinski wrote:
>> On Mon, Sep 5, 2011 at 1:10 AM, Jakub Jelinek <jakub@redhat.com> wrote:
>> > That said, relying on lazy binding is terribly bad design.
>>
>> In fact I was going to say why can't those symbols be marked as weak
>> in your plugin? ?You don't even need to change the GCC headers, just
>> have an extra header that does:
>> #pargma weak
>
> s/pargma/pragma/. ?Yeah, making them weak will work just fine, independently
> on whether it is RTLD_NOW or not, or, when program is directly linked
> against it, with LD_BIND_NOW=1 or not.
>
> ? ? ? ?Jakub
>

Thanks, it works fine. I didn't know about weak symbols.

Romain Geissler


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