[CMake] Fixing errors in r361513

Summary:
I somehow messed this up. libcxx appends the subdirectories itself, so we don't need to add them here.

Also, r361513 broke the "projects" build of libcxx because it always included the extra targets.

Reviewers: lebedev.ri, mclow.lists

Subscribers: mgorny, llvm-commits

Tags: #llvm

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

llvm-svn: 361535
This commit is contained in:
Chris Bieneman 2019-05-23 18:51:52 +00:00
parent 267ac925fb
commit e836096f01
1 changed files with 1 additions and 1 deletions

View File

@ -209,7 +209,7 @@ if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR})
else() # if this is included from LLVM's CMake
include(LLVMExternalProjectUtils)
if (LLVM_EXTERNAL_LIBCXX_SOURCE_DIR)
if (LLVM_EXTERNAL_LIBCXX_SOURCE_DIR AND "libcxx" IN_LIST LLVM_ENABLE_RUNTIMES)
set(LIBCXX_HEADER_DIR ${LLVM_INCLUDE_DIR}/c++/v1/)
set(CXX_HEADER_TARGET runtime-libcxx-headers)
add_subdirectory(${LLVM_EXTERNAL_LIBCXX_SOURCE_DIR}/include ${CXX_HEADER_TARGET})