[libcxx] r291723 - [CMake][libcxx] Check that we have libcxxabi before using it

Petr Hosek via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 11 15:11:40 PST 2017


Author: phosek
Date: Wed Jan 11 17:11:40 2017
New Revision: 291723

URL: http://llvm.org/viewvc/llvm-project?rev=291723&view=rev
Log:
[CMake][libcxx] Check that we have libcxxabi before using it

When doing standalone build, check that we actually have libcxxabi
before attempting to use it.

Differential Revision: https://reviews.llvm.org/D28580

Modified:
    libcxx/trunk/CMakeLists.txt

Modified: libcxx/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/CMakeLists.txt?rev=291723&r1=291722&r2=291723&view=diff
==============================================================================
--- libcxx/trunk/CMakeLists.txt (original)
+++ libcxx/trunk/CMakeLists.txt Wed Jan 11 17:11:40 2017
@@ -119,7 +119,8 @@ if (LIBCXX_CXX_ABI STREQUAL "default")
           ${LLVM_MAIN_SRC_DIR}/runtimes/libcxxabi/include
     NO_DEFAULT_PATH
   )
-  if (IS_DIRECTORY "${LIBCXX_LIBCXXABI_INCLUDES_INTERNAL}")
+  if ((NOT LIBCXX_STANDALONE_BUILD OR HAVE_LIBCXXABI) AND
+      IS_DIRECTORY "${LIBCXX_LIBCXXABI_INCLUDES_INTERNAL}")
     set(LIBCXX_CXX_ABI_LIBNAME "libcxxabi")
     set(LIBCXX_CXX_ABI_INCLUDE_PATHS "${LIBCXX_LIBCXXABI_INCLUDES_INTERNAL}")
     set(LIBCXX_CXX_ABI_INTREE 1)




More information about the cfe-commits mailing list