diff --git a/lldb/CMakeLists.txt b/lldb/CMakeLists.txt --- a/lldb/CMakeLists.txt +++ b/lldb/CMakeLists.txt @@ -111,7 +111,11 @@ message(WARNING "LLDB test suite requires libc++ in llvm/projects/libcxx or an existing build symlinked to ${cxx_dir}") endif() else() - list(APPEND LLDB_TEST_DEPS cxx) + if (NOT TARGET cxx) + message(WARNING "LLDB test suite requires libc++") + else() + list(APPEND LLDB_TEST_DEPS cxx) + endif() endif() endif() endif()