Skip to content

Commit

Permalink
[lldb] [cmake] Add LLVM_LIT_ARGS override support for standalone builds
Browse files Browse the repository at this point in the history
Add a LLVM_LIT_ARGS cached variable in order to make it possible
to override lit arguments when doing standalone builds.  Without that,
the user variable is ignored and the default options are always used.

Based on a similar solution found in clang.

Differential Revision: https://reviews.llvm.org/D107700

(cherry picked from commit 614c7d0)
  • Loading branch information
mgorny authored and tstellar committed Aug 10, 2021
1 parent bf742f2 commit 8c1ca94
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lldb/cmake/modules/LLDBStandalone.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ set(LLVM_MAIN_SRC_DIR ${LLVM_BUILD_MAIN_SRC_DIR} CACHE PATH "Path to LLVM source
set(LLVM_MAIN_INCLUDE_DIR ${LLVM_MAIN_INCLUDE_DIR} CACHE PATH "Path to llvm/include")
set(LLVM_BINARY_DIR ${LLVM_BINARY_DIR} CACHE PATH "Path to LLVM build tree")

set(LLVM_LIT_ARGS "-sv" CACHE STRING "Default options for lit")

set(lit_file_name "llvm-lit")
if(CMAKE_HOST_WIN32 AND NOT CYGWIN)
set(lit_file_name "${lit_file_name}.py")
Expand Down

0 comments on commit 8c1ca94

Please sign in to comment.