summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMehdi Amini <mehdi.amini@apple.com>2017-03-30 04:40:56 +0000
committerMehdi Amini <mehdi.amini@apple.com>2017-03-30 04:40:56 +0000
commit994e17b8153e3ef618ef220b2e915ff5e2955687 (patch)
treebebd553676fc624b89063c93a8bdd1bd24ba1842
parent01ddc1cfd546f95d5536b7054bbfd444c44b6da4 (diff)
downloadbcm5719-llvm-994e17b8153e3ef618ef220b2e915ff5e2955687.tar.gz
bcm5719-llvm-994e17b8153e3ef618ef220b2e915ff5e2955687.zip
Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete
llvm-svn: 299052
-rw-r--r--libcxx/lib/CMakeLists.txt6
1 files changed, 5 insertions, 1 deletions
diff --git a/libcxx/lib/CMakeLists.txt b/libcxx/lib/CMakeLists.txt
index a8dd4eb8aef..e6f3b4c5581 100644
--- a/libcxx/lib/CMakeLists.txt
+++ b/libcxx/lib/CMakeLists.txt
@@ -150,7 +150,11 @@ if (LIBCXX_OSX_REEXPORT_SYSTEM_ABI_LIBRARY)
"-Wl,-unexported_symbols_list,${CMAKE_CURRENT_SOURCE_DIR}/libc++unexp.exp"
"/usr/lib/libSystem.B.dylib")
else()
- if (DEFINED CMAKE_OSX_SYSROOT AND NOT CMAKE_OSX_SYSROOT STREQUAL "")
+ if (LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS)
+ # We can't use the "-reexported_symbols_list" when we build the
+ # new/delete operators as part of the dylib: the linker would fail.
+ set(OSX_RE_EXPORT_LINE "-Wl,-reexport_library,${CMAKE_OSX_SYSROOT}/usr/lib/libc++abi.dylib")
+ elseif (DEFINED CMAKE_OSX_SYSROOT AND NOT CMAKE_OSX_SYSROOT STREQUAL "")
list(FIND CMAKE_OSX_ARCHITECTURES "armv7" OSX_HAS_ARMV7)
if (NOT OSX_HAS_ARMV7 EQUAL -1)
set(OSX_RE_EXPORT_LINE
OpenPOWER on IntegriCloud