summaryrefslogtreecommitdiffstats
path: root/libcxx/cmake
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2015-03-03 15:59:51 +0000
committerEric Fiselier <eric@efcs.ca>2015-03-03 15:59:51 +0000
commit0357171f1c2916d353ca328aa006b1e4a22d3efa (patch)
treeed7dbe944f18e2ac5cf57a51cc135fcbe8f91646 /libcxx/cmake
parent14dbeaadc124c7fc7c94fff8a70dece1a15c4199 (diff)
downloadbcm5719-llvm-0357171f1c2916d353ca328aa006b1e4a22d3efa.tar.gz
bcm5719-llvm-0357171f1c2916d353ca328aa006b1e4a22d3efa.zip
[libcxx] Add support for linking libc++ against a static ABI library.
Summary: This patch add the CMake option `LIBCXX_ENABLE_STATIC_ABI_LIBRARY` which, when enabled, will link libc++ against the static version of the ABI library. Reviewers: mclow.lists, jroelofs, danalbert Reviewed By: danalbert Subscribers: compnerd, cfe-commits Differential Revision: http://reviews.llvm.org/D8017 llvm-svn: 231076
Diffstat (limited to 'libcxx/cmake')
-rw-r--r--libcxx/cmake/Modules/HandleLibCXXABI.cmake6
1 files changed, 5 insertions, 1 deletions
diff --git a/libcxx/cmake/Modules/HandleLibCXXABI.cmake b/libcxx/cmake/Modules/HandleLibCXXABI.cmake
index 131941a078c..960df9ec80e 100644
--- a/libcxx/cmake/Modules/HandleLibCXXABI.cmake
+++ b/libcxx/cmake/Modules/HandleLibCXXABI.cmake
@@ -78,7 +78,11 @@ if ("${LIBCXX_CXX_ABI_LIBNAME}" STREQUAL "libstdc++" OR
elseif ("${LIBCXX_CXX_ABI_LIBNAME}" STREQUAL "libcxxabi")
if (LIBCXX_CXX_ABI_INTREE)
# Link against just-built "cxxabi" target.
- set(CXXABI_LIBNAME cxxabi)
+ if (LIBCXX_ENABLE_STATIC_ABI_LIBRARY)
+ set(CXXABI_LIBNAME cxxabi_static)
+ else()
+ set(CXXABI_LIBNAME cxxabi_shared)
+ endif()
set(LIBCXX_LIBCPPABI_VERSION "2" PARENT_SCOPE)
else()
# Assume c++abi is installed in the system, rely on -lc++abi link flag.
OpenPOWER on IntegriCloud