Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion llvm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,10 @@ if(NOT "${FOUND_INDEX}" STREQUAL "-1")
list(REMOVE_ITEM LLVM_ENABLE_PROJECTS "pstl")
endif()

foreach(proj ${LLVM_DISABLE_PROJECTS})
list(REMOVE_ITEM LLVM_ENABLE_PROJECTS "${proj}")
endforeach ()

foreach(proj ${LLVM_ENABLE_PROJECTS})
if (NOT proj STREQUAL "llvm" AND NOT "${proj}" IN_LIST LLVM_KNOWN_PROJECTS)
MESSAGE(FATAL_ERROR "${proj} isn't a known project: ${LLVM_KNOWN_PROJECTS}. Did you mean to enable it as a runtime in LLVM_ENABLE_RUNTIMES?")
Expand Down Expand Up @@ -666,7 +670,7 @@ if(LLVM_EXPERIMENTAL_TARGETS_TO_BUILD STREQUAL "all")
set(LLVM_EXPERIMENTAL_TARGETS_TO_BUILD ${LLVM_ALL_EXPERIMENTAL_TARGETS})
endif()

if("flang" IN_LIST LLVM_ENABLE_PROJECTS AND
if("flang" IN_LIST LLVM_ENABLE_PROJECTS AND
"AArch64" IN_LIST LLVM_TARGETS_TO_BUILD AND
NOT ("compiler-rt" IN_LIST LLVM_ENABLE_RUNTIMES OR "compiler-rt" IN_LIST LLVM_ENABLE_PROJECTS))
message(STATUS "Enabling compiler-rt as a dependency of Flang")
Expand Down
8 changes: 8 additions & 0 deletions llvm/docs/CMake.rst
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,14 @@ its enabled sub-projects. Nearly all of these variable names begin with
of the machine where LLVM is being built. If you are building a cross-compiler,
set it to the target triple of your desired architecture.

**LLVM_DISABLE_PROJECTS**:STRING
Semicolon-separated list of projects to exclude from the build. Sometimes it is
more convenient to exclude a few projects than to have to enumerate all other
projects. This flag can be combined with ``LLVM_ENABLE_PROJECTS`` to easily
select projects of interest in the build. For example, the command:
``cmake ... -DLLVM_ENABLE_PROJECTS=all -DLLVM_DISABLE_PROJECTS=libclc ...``
allows to build all projects but ``libclc``.

**LLVM_DOXYGEN_QCH_FILENAME**:STRING
The filename of the Qt Compressed Help file that will be generated when
``-DLLVM_ENABLE_DOXYGEN=ON`` and
Expand Down