p11_kit_fini / p11_kit_init - Should these be public symbols?

Andreas Metzler ametzler at downhill.at.eu.org
Sun Mar 17 08:02:12 PDT 2013


On 2013-03-09 Andreas Metzler <ametzler at downhill.at.eu.org> wrote:
> On 2013-03-09 Stef Walter <stef at thewalter.net> wrote:
>> On 09.03.2013 10:13, Andreas Metzler wrote:
>>> 0.16 exports two new symbols in libp11-kit.so: p11_kit_fini /
>>> p11_kit_init. As there is no corresponding prototype in p11-kit.h I
>>> am wondering whether this is done intentionally.

>> Yup, these are a library constructor and finalizer when running on Linux
>> (with appropriate compiler attributes). They are not meant to be called
>> explicitly. Is there a better way to name them?

> Hello,
> I am not completely, totally sure but I do not think
> constructor/deconstructor need to be exported, making these private
> symbols (p11_kit_fini -> _p11_kit_fini / p11_kit_init ->
> _p11_kit_init) seems to work for me. Could you please doublecheck and
> comment? (I am out of my depth.)

FWIW I have uploaded 0.16.4 with the attached patch to
Debian/experimental.

cu andreas
-- 
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'
-------------- next part --------------
A non-text attachment was scrubbed...
Name: noexport_constructor.diff
Type: text/x-diff
Size: 911 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/p11-glue/attachments/20130317/859166e7/attachment.diff>


More information about the p11-glue mailing list