• kaddy 1 I built Clang from source a while back by following the build instructions. • I now want to install clangd . • I am trying to build it from source as well by following the instructions over here. • When I run the first cmake command, I get the following errors: – bolt project is disabled – clang project is disabled – clang-tools-extra project is enabled – compiler-rt project is disabled – cross-project-tests project is disabled – libclc project is disabled – lld project is disabled – lldb project is disabled – mlir project is disabled – openmp project is disabled – polly project is disabled – flang project is disabled – libc project is disabled – LLVM host triple: x86_64-unknown-linux-gnu – Native target architecture is X86 – Threads enabled. • – Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH) – Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH) – OCaml bindings disabled. • – LLVM default target triple: x86_64-unknown-linux-gnu – Building with -fPIC – Targeting AArch64 – Targeting AMDGPU – Targeting ARM – Targeting AVR – Targeting BPF – Targeting Hexagon – Targeting Lanai – Targeting LoongArch – Targeting Mips – Targeting MSP430 – Targeting NVPTX – Targeting PowerPC – Targeting RISCV – Targeting Sparc – Targeting SPIRV – Targeting SystemZ – Targeting VE – Targeting WebAssembly – Targeting X86 – Targeting XCore CMake Error at CMakeLists.txt:1344 (add_subdirectory): add_
Article Summaries:
- A user on Arch Linux attempted to build the clangd language‑server from source after previously compiling Clang. During the initial CMake configuration, the build reported numerous disabled projects and missing dependencies, notably OCaml. It then failed with errors indicating that expected directories (e.g., third‑party/unittest, third‑party/benchmark) and test configuration files were absent. The CMake process could not locate required CMakeLists.txt files for TableGen and other components, leading to an incomplete configuration. The user seeks clarification on the error causes and guidance on resolving the missing files and dependencies to successfully compile clangd.
Sources: