diff options
| author | Louis Dionne <ldionne@apple.com> | 2019-10-04 18:32:46 +0000 |
|---|---|---|
| committer | Louis Dionne <ldionne@apple.com> | 2019-10-04 18:32:46 +0000 |
| commit | ce452b1ca9fdb12604db3dc2059246e189e55d7b (patch) | |
| tree | 2a8a580abd323cf0770f5a887540b50ac48af77c /libcxxabi/src | |
| parent | 5fd467feb813e9999efe3558da434cb038213582 (diff) | |
| download | bcm5719-llvm-ce452b1ca9fdb12604db3dc2059246e189e55d7b.tar.gz bcm5719-llvm-ce452b1ca9fdb12604db3dc2059246e189e55d7b.zip | |
[libc++abi] Link against libSystem on Apple platforms
On Apple platforms, libSystem is an umbrella for all other system
libraries, and libpthread (and friends) are actually just symlinks
to libSystem.
llvm-svn: 373770
Diffstat (limited to 'libcxxabi/src')
| -rw-r--r-- | libcxxabi/src/CMakeLists.txt | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/libcxxabi/src/CMakeLists.txt b/libcxxabi/src/CMakeLists.txt index 6cfcb9cb3df..cbf4b21c31f 100644 --- a/libcxxabi/src/CMakeLists.txt +++ b/libcxxabi/src/CMakeLists.txt @@ -60,11 +60,16 @@ if (LIBCXXABI_HAS_CXA_THREAD_ATEXIT_IMPL) add_definitions(-DHAVE___CXA_THREAD_ATEXIT_IMPL) endif() -if (LIBCXXABI_ENABLE_THREADS) - add_library_flags_if(LIBCXXABI_HAS_PTHREAD_LIB pthread) +if (APPLE) + add_library_flags_if(LIBCXXABI_HAS_SYSTEM_LIB System) +else() + if (LIBCXXABI_ENABLE_THREADS) + add_library_flags_if(LIBCXXABI_HAS_PTHREAD_LIB pthread) + endif() + + add_library_flags_if(LIBCXXABI_HAS_C_LIB c) endif() -add_library_flags_if(LIBCXXABI_HAS_C_LIB c) if (LIBCXXABI_USE_LLVM_UNWINDER) # Prefer using the in-tree version of libunwind, either shared or static. If # none are found fall back to using -lunwind. |

