[Xfce4-commits] <xfce4-dev-tools:master> Don't set the default visibility in XDT_FEATURE_VISIBILITY.

Nick Schermer nickschermer at gmail.com
Fri Oct 23 09:45:24 CEST 2009


2009/10/23 Brian J. Tarricone <brian at tarricone.org>:
> On Thu, Oct 22, 2009 at 15:10, Jannis Pohlmann <jannis at xfce.org> wrote:
>>
>> I'm thinking back and forth here... Nick's concern about
>> -fvisibility=hidden is that exo needs HAVE_GNUC_VISIBILITY for the
>> alias generation but exo's .symbols file has a few exceptions (e.g.
>> exo_atomic_{inc,dec}) which are not declared visible when
>> -fvisiblity=hidden is passed to the compiler. In consequence they don't
>> show up in the .so file even though they would (without -fvisib...)
>> because they'd not be hidden and would pass -export-regex-symbols as
>> well. So there are expections where the alias stuff is used but
>> -fvisibility=hidden is not desired.
>
> I don't think I quite understand.  Why are the atomic ops not declared
> visible with -fvisibility=hidden?

They are not real functions and same for internal variables
(exo_version_*), there the alias code is not suitable too. So, the
visibility macro is nice for xfconf because it only has a simple
library with public functions only, everything else in Xfce needs to
adapt with crapy visibility code.

>> I can also see how we could make it useful and more flexible by adding
>> a parameter to it (e.g. a compiler flag variable), like you suggested
>> on bugzilla.xfce.org. For aliasing, libraries need HAVE_GNUC_VISIBILITY
>> but they may or may not want -fvisibility=hidden.
>
> Right, that's a reasonable change that keeps the current default but
> makes it flexible enough for other use.

Well I think that has not real purpose too. So commit reverted and
thanks for the unusable macro. I'll add the normal visibility code to
all the other libraries.

Nick



More information about the Xfce4-dev mailing list