diff options
| author | lntue <lntue@google.com> | 2025-06-04 15:44:19 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-04 15:44:19 -0400 |
| commit | 52ad2747d0da1ae4e6cf93b93edbf69bfceb7b13 (patch) | |
| tree | 955b387166f9f7e7750c4d12da06654d8f9d4c88 /llvm | |
| parent | 21580369340a07bafa6c606bf0b3e46d7e374cfa (diff) | |
[libc][cmake] Make libc not included in LLVM_ENABLE_PROJECTS=all. (#142626)
Make LLVM libc to not be included in `LLVM_ENABLE_PROJECTS=all`. It can
still be manually added to LLVM_ENABLE_PROJECTS list.
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/CMakeLists.txt | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/llvm/CMakeLists.txt b/llvm/CMakeLists.txt index ed44b16bf9ae..1440646762f6 100644 --- a/llvm/CMakeLists.txt +++ b/llvm/CMakeLists.txt @@ -108,15 +108,20 @@ endif() # LLVM_EXTERNAL_${project}_SOURCE_DIR using LLVM_ALL_PROJECTS # This allows an easy way of setting up a build directory for llvm and another # one for llvm+clang+... using the same sources. -set(LLVM_ALL_PROJECTS "bolt;clang;clang-tools-extra;compiler-rt;cross-project-tests;libc;libclc;lld;lldb;mlir;openmp;polly;pstl") +# These projects will be included when "all" is included in LLVM_ENABLE_PROJECTS. +set(LLVM_ALL_PROJECTS "bolt;clang;clang-tools-extra;compiler-rt;cross-project-tests;libclc;lld;lldb;mlir;openmp;polly;pstl") if (${CMAKE_SYSTEM_NAME} MATCHES "AIX") # Disallow 'openmp' as a LLVM PROJECT on AIX as the supported way is to use # LLVM_ENABLE_RUNTIMES. list(REMOVE_ITEM LLVM_ALL_PROJECTS openmp) endif() -# The flang project is not yet part of "all" projects (see C++ requirements) -set(LLVM_EXTRA_PROJECTS "flang") +# The "libc" project, which is not part of "all" projects, could be included in +# LLVM_ENABLE_PROJECTS. It is preferred to include "libc" in +# LLVM_ENABLE_RUNTIMES instead of LLVM_ENABLE_PROJECTS. +# +# The flang project is not yet part of "all" projects (see C++ requirements). +set(LLVM_EXTRA_PROJECTS "flang" "libc") # List of all known projects in the mono repo set(LLVM_KNOWN_PROJECTS "${LLVM_ALL_PROJECTS};${LLVM_EXTRA_PROJECTS}") set(LLVM_ENABLE_PROJECTS "" CACHE STRING @@ -167,8 +172,7 @@ if ("flang" IN_LIST LLVM_ENABLE_PROJECTS) endif() if ("libc" IN_LIST LLVM_ENABLE_PROJECTS) - message(WARNING "Using LLVM_ENABLE_PROJECTS=libc is deprecated now, and will " - "become a fatal error in the LLVM 21 release. Please use " + message(WARNING "Using LLVM_ENABLE_PROJECTS=libc is deprecated. Please use " "-DLLVM_ENABLE_RUNTIMES=libc or see the instructions at " "https://libc.llvm.org/ for building the runtimes.") endif() |
