[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-wget] Re: gnulib read-file module
From: |
Simon Josefsson |
Subject: |
Re: [Bug-wget] Re: gnulib read-file module |
Date: |
Fri, 09 Jul 2010 22:57:50 +0200 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) Emacs/23.1 (gnu/linux) |
Daniel Stenberg <address@hidden> 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