Re: proposal, patch: allow multiple plpgsql plugins - Mailing list pgsql-hackers

From Marko Tiikkaja
Subject Re: proposal, patch: allow multiple plpgsql plugins
Date
Msg-id 53139AC5.4050105@joh.to
Whole thread Raw
In response to Re: proposal, patch: allow multiple plpgsql plugins  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: proposal, patch: allow multiple plpgsql plugins
List pgsql-hackers
On 3/2/14, 8:47 PM, Pavel Stehule wrote:
> 2014-03-02 19:59 GMT+01:00 Marko Tiikkaja <marko@joh.to>:
>> Undefined symbols for architecture x86_64:
>>    "_plpgsql_register_plugin", referenced from:
>>        __PG_init in plpgtest.o
>>
>> I'm guessing this is because PL/PgSQL is a shared library and not in core?
>>   Is there a way around this?
>>
>
> yes, PLpgSQL is not referenced and, if I remember well, clang is too
> restrictive.
>
> probably
> http://stackoverflow.com/questions/17281901/ignoring-an-undefined-symbol-in-a-dynamic-library-from-xcode
>
> or you can add a reference on plpgsql to your Makefile

That seems unbelievably ugly, but worse, loading the library in 
shared_preload_libraries doesn't work:

14782  FATAL:  could not load library 
"/usr/local/pgsql/lib/plpgtest.so": 
dlopen(/usr/local/pgsql/lib/plpgtest.so, 10): Symbol not found: 
_plpgsql_register_plugin  Referenced from: /usr/local/pgsql/lib/plpgtest.so  Expected in: flat namespace in
/usr/local/pgsql/lib/plpgtest.so

I even tried putting plpgsql.so before it in the list, but no go.


Regards,
Marko Tiikkaja



pgsql-hackers by date:

Previous
From: Stephen Frost
Date:
Subject: Re: Securing "make check" (CVE-2014-0067)
Next
From: Josh Berkus
Date:
Subject: Re: Securing "make check" (CVE-2014-0067)