summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2017-01-02 21:58:06 +0000
committerEric Fiselier <eric@efcs.ca>2017-01-02 21:58:06 +0000
commitea38cde827cdb83134adb7eade860a9b77a486b6 (patch)
treed153d0f0e3141f6a0722defcd5e47a3698a1e47c /lib
parent766e557e5aba9a26c63ca89bd8d7384a60b20c4c (diff)
Fix configuring and building libc++ w/o an ABI library.
Typically libc++ uses libc++abi or libcxxrt to provide the ABI and runtime bits of the C++ STL. However we also support building w/o an ABI library entirely. This patch fixes building libc++ w/o an ABI library (and incorporates the `~type_info()` fix in D28211). The main changes in this patch are: 1) Add `-DLIBCXX_CXX_ABI=default` instead of using the empty string to mean "default". 2) Fix CMake bits which treated "none" as "default" on OS X. 3) Teach the source files to respect `-D_LIBCPP_BUILDING_HAS_NO_ABI_LIBRARY`. 4) Define ~type_info() when _LIBCPP_BUILDING_HAS_NO_ABI_LIBRARY is defined. Unfortunately this patch doesn't help clean up the macro mess that we use to configure for different ABI libraries. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@290839 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CMakeLists.txt2
-rw-r--r--lib/abi/CMakeLists.txt2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
index f37ac68eb..4383c07d8 100644
--- a/lib/CMakeLists.txt
+++ b/lib/CMakeLists.txt
@@ -34,7 +34,7 @@ add_link_flags_if(LIBCXX_CXX_ABI_LIBRARY_PATH "-L${LIBCXX_CXX_ABI_LIBRARY_PATH}"
add_library_flags_if(LIBCXX_COVERAGE_LIBRARY "${LIBCXX_COVERAGE_LIBRARY}")
if (APPLE AND (LIBCXX_CXX_ABI_LIBNAME STREQUAL "libcxxabi" OR
- LIBCXX_CXX_ABI_LIBNAME STREQUAL "none"))
+ LIBCXX_CXX_ABI_LIBNAME STREQUAL "default"))
set(LIBCXX_OSX_REEXPORT_SYSTEM_ABI_LIBRARY ON)
endif()
diff --git a/lib/abi/CMakeLists.txt b/lib/abi/CMakeLists.txt
index 223dbdbcb..e3eb3bf39 100644
--- a/lib/abi/CMakeLists.txt
+++ b/lib/abi/CMakeLists.txt
@@ -5,7 +5,7 @@ if (DEFINED TARGET_TRIPLE
AND EXISTS "${CMAKE_CURRENT_LIST_DIR}/${TARGET_TRIPLE}.abilist"
AND TARGET cxx_shared
AND ("${LIBCXX_CXX_ABI_LIBNAME}" STREQUAL "libcxxabi" OR
- (APPLE AND "${LIBCXX_CXX_ABI_LIBNAME}" STREQUAL "none"))
+ (APPLE AND "${LIBCXX_CXX_ABI_LIBNAME}" STREQUAL "default"))
AND NOT LIBCXX_ABI_UNSTABLE
AND LIBCXX_ABI_VERSION EQUAL "1")
set(LIBCXX_HAS_ABILIST_CONFIGURATION 1 CACHE INTERNAL "")