<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Building with -D LLVM_ENABLE_PROJECTS='clang;lldb' on macOS errors for missing dependency target "cxx""
href="https://bugs.llvm.org/show_bug.cgi?id=41866">41866</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Building with -D LLVM_ENABLE_PROJECTS='clang;lldb' on macOS errors for missing dependency target "cxx"
</td>
</tr>
<tr>
<th>Product</th>
<td>Build scripts
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</td>
</tr>
<tr>
<th>OS</th>
<td>MacOS X
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>cmake
</td>
</tr>
<tr>
<th>Assignee</th>
<td>jryans@gmail.com
</td>
</tr>
<tr>
<th>Reporter</th>
<td>jryans@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>jdevlieghere@apple.com, llvm-bugs@lists.llvm.org, stefan.graenitz@gmail.com
</td>
</tr></table>
<p>
<div>
<pre>I typically try to limit the part of LLVM I build a config such as
```
-D LLVM_ENABLE_PROJECTS='clang;lldb'
```
but this particular combo currently fails on macOS with many errors like:
CMake Error at cmake/modules/AddLLVM.cmake:1391 (add_dependencies):
The dependency target "cxx" of target "check-all" does not exist.
Call Stack (most recent call first):
CMakeLists.txt:994 (add_lit_target)
CMake Error at /Users/jryans/Projects/llvm-project/lldb/CMakeLists.txt:137
(add_dependencies):
The dependency target "cxx" of target "lldb-test-deps" does not exist.
CMake Error at /Users/jryans/Projects/llvm-project/lldb/test/CMakeLists.txt:13
(add_dependencies):
The dependency target "cxx" of target "check-lldb-single" does not exist.
Call Stack (most recent call first):
/Users/jryans/Projects/llvm-project/lldb/test/CMakeLists.txt:108
(add_python_test_target)
[... many more lines about "cxx" ...]
The root cause here is that LLDB requires libcxx on macOS, but the errors above
don't make that very clear, at least for those new to LLVM. I think this could
be clarified with two changes:
1. Check whether `libcxx` is enabled as a project, and output a specific error
about this if not
2. Update the LLDB docs to suggest a valid value of `LLVM_ENABLE_PROJECTS`</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>