Daniel Stenberg <dan...@haxx.se> writes:

> On Fri, 9 Jul 2010, Simon Josefsson wrote:
>
>> I don't know how to best resolve this -- GnuTLS contains a dozen of
>> internal functions (mostly from gnulib, like the one you noticed)
>> that cannot be marked 'static' because they are used from multiple
>> .c files in GnuTLS.  So they end up being exported into a static
>> library.  I suppose almost any non-trivial static library has the
>> same problem.  Any suggestions?
>
> I would advice that all non-static global symbols use the regular
> name-space procedures: you use a prefix for them that are specific for
> your library. As you say, it doesn't matter that you don't "export"
> them since in a static lib case they're all basically "exported".
>
> Common approaches are to use "prefix__" (double underscore) for global
> private functions or "_prefix_" (initial underscore in front of
> prefix).

Yes, that is indeed the best solution, but I don't know how to implement
this for GnuTLS because that functions (and tons others) comes from
gnulib.  I'll take this up on the gnulib list...

/Simon

Reply via email to