Index: libcxx/cmake/Modules/HandleLibCXXABI.cmake =================================================================== --- libcxx/cmake/Modules/HandleLibCXXABI.cmake +++ libcxx/cmake/Modules/HandleLibCXXABI.cmake @@ -107,12 +107,12 @@ set(LIBCXX_CXX_ABI_INCLUDE_PATHS "${LIBCXX_SOURCE_DIR}/../libcxxabi/include") endif() - if(LIBCXX_STANDALONE_BUILD AND NOT (LIBCXX_CXX_ABI_INTREE OR HAVE_LIBCXXABI)) - set(shared c++abi) - set(static c++abi) - else() + if(TARGET cxxabi_shared OR TARGET cxxabi_static) set(shared cxxabi_shared) set(static cxxabi_static) + else() + set(shared c++abi) + set(static c++abi) endif() setup_abi_lib(