[compiler-rt] [compiler-rt][www] replace deprecated LLVM_CONFIG_PATH with LLVM_CMAKE_DIR (PR #71500)

Cullen Rhodes via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 15 02:18:42 PDT 2024


================
@@ -123,7 +123,7 @@ <h2>Get it and get involved!</h2>
   <li>cd llvm-project</li>
   <li>mkdir build-compiler-rt</li>
   <li>cd build-compiler-rt</li>
-  <li>cmake ../compiler-rt -DLLVM_CONFIG_PATH=/path/to/llvm-config</li>
+  <li>cmake ../compiler-rt -DLLVM_CMAKE_DIR=/path/to/llvm-project/cmake/modules</li>
----------------
c-rhodes wrote:

> It does not work -DCOMPILER_RT_INCLUDE_TESTS=ON (which I guess default):
> -- Builtin supported architectures:
> CMake Error at test/CMakeLists.txt:47 (umbrella_lit_testsuite_begin):
> Unknown CMake command "umbrella_lit_testsuite_begin".
> 
> but work with -DCOMPILER_RT_INCLUDE_TESTS=OFF

I don't think `COMPILER_RT_INCLUDE_TESTS=ON` is always the default, only if `LLVM_TREE_AVAILABLE`:
https://github.com/llvm/llvm-project/blob/8fcb822da632ab4330b47641826ace01af0768e0/compiler-rt/cmake/base-config-ix.cmake#L35-L41

I can reproduce the error you're seeing when `COMPILER_RT_INCLUDE_TESTS=ON`:

> 
> cmake -G Ninja -S compiler-rt -B build-compiler-rt -DCMAKE_C_COMPILER=$HOME/clang+llvm-17.0.4-aarch64-linux-gnu/bin/clang-17 -DCMAKE_CXX_COMPILER=$HOME/clang+llvm-17.0.4-aarch64-linux-gnu/bin/clang++ -DLLVM_CMAKE_DIR=cmake -DCOMPILER_RT_INCLUDE_TESTS=ON
> -- Builtin supported architectures:
> Traceback (most recent call last):
>   File "<string>", line 22, in <module>
> IndexError: list index out of range
> CMake Error at test/CMakeLists.txt:47 (umbrella_lit_testsuite_begin):
>   Unknown CMake command "umbrella_lit_testsuite_begin".

but the fix proposed in #98707 doesn't fix it for me.

https://github.com/llvm/llvm-project/pull/71500


More information about the llvm-commits mailing list