[libcxx-commits] [PATCH] D60049: [libc++abi] Add LIBCXXABI_ENABLE_PIC cmake option

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Apr 2 16:58:41 PDT 2019


ldionne added a comment.

In D60049#1452223 <https://reviews.llvm.org/D60049#1452223>, @sbc100 wrote:

> OK I made LIBCXXABI_ENABLE_PIC effect both shared and non-shared versions of the library.


Let's wait for https://reviews.llvm.org/D60166 to land, and then you can rebase on top of it. This is going to fix the issue I mentioned.



================
Comment at: libcxxabi/src/CMakeLists.txt:183
 
-cxxabi_object_library(cxxabi_shared_objects POSITION_INDEPENDENT_CODE ON)
+cxxabi_object_library(cxxabi_shared_objects)
 set(cxxabi_static_sources $<TARGET_OBJECTS:cxxabi_static_objects>)
----------------
This doesn't work because it's an object library. Now `libc++abi.dylib` will never be built with `-fPIC`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D60049/new/

https://reviews.llvm.org/D60049





More information about the libcxx-commits mailing list