[PATCH] D33638: [libcxx] Have separate abi library flags for static and shared builds

Martin Storsjö via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 12 01:49:58 PDT 2017


mstorsjo added a comment.

In https://reviews.llvm.org/D33638#867523, @martell wrote:

> @mstorsjo sorry I missed that comment before. I currently succeed in building shared and static versions by just changing
>  `# define _LIBCPP_DLL_VIS __declspec(dllimport)` to `# define _LIBCPP_DLL_VIS` in `__config` and applying https://reviews.llvm.org/D33620
>
> The correct fix is probably by editing libcxxabi to correctly export symbols.
>  The real issue here though is when we are using a static libc++ clang needs to be able to set `_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS` when using static at compile time which is messy.
>  I am avoiding that by doing that one line change above and the patch linked.


Hmm, maybe that's the same issue that I'm working around by passing `-flto-visibility-public-std`, which makes it skip the implicit dllimport for some implicitly defined C++ symbols.


Repository:
  rL LLVM

https://reviews.llvm.org/D33638





More information about the llvm-commits mailing list