Boost logo

Boost :

Subject: Re: [boost] Making Boost invisible
From: Peter Dimov (lists_at_[hidden])
Date: 2018-09-25 18:08:01


John Maddock wrote:
> Folks I have a bug report against Boost.Config that I don't know what (if
> anything) I should do about: https://github.com/boostorg/config/issues/243
>
> The issue is this: lets say I build boost as static libraries
> with -fvisibilty=hidden because I want my application or shared library to
> *hide all boost symbols*. But there are some parts of boost which
> unconditionally make things visible - throw_exception is one particular
> culprit, but there are others, probably anything which uses
> BOOST_SYMBOL_VISIBLE in fact.
>
> Question: should we support this? If so how? The only thing I can think
> of is a user-defined macro which when set, disables symbol visibility.

That's the only thing we can do. #ifdef something, #define
BOOST_SYMBOL_VISIBLE to nothing, let them deal with whatever happens.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk