[PATCH] D28580: [CMake][libcxx] Check that we have libcxxabi before using it

Petr Hosek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 11 14:51:40 PST 2017


phosek created this revision.
phosek added reviewers: beanz, EricWF.
phosek added subscribers: llvm-commits, krasin.
phosek set the repository for this revision to rL LLVM.
Herald added a subscriber: mgorny.

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


Repository:
  rL LLVM

https://reviews.llvm.org/D28580

Files:
  CMakeLists.txt


Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -119,7 +119,8 @@
           ${LLVM_MAIN_SRC_DIR}/runtimes/libcxxabi/include
     NO_DEFAULT_PATH
   )
-  if (IS_DIRECTORY "${LIBCXX_LIBCXXABI_INCLUDES_INTERNAL}")
+  if (NOT (LIBCXX_STANDALONE_BUILD AND NOT 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)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28580.84028.patch
Type: text/x-patch
Size: 577 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170111/cd14e0c1/attachment.bin>


More information about the llvm-commits mailing list