Skip to content

Commit

Permalink
Adding support for overriding LLVM_ENABLE_RUNTIMES for runtimes builds.
Browse files Browse the repository at this point in the history
On some platforms, certain runtimes are not supported. For runtimes builds of
those platforms it would be nice if we could disable certain runtimes (ie
libunwind on Windows).



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


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@371566 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
plotfi committed Sep 10, 2019
1 parent ad04061 commit 8775a1b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion runtimes/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,10 @@ else() # if this is included from LLVM's CMake
endif()
endforeach()

if(NOT RUNTIMES_${name}_LLVM_ENABLE_RUNTIMES)
list(APPEND ${name}_extra_args -DLLVM_ENABLE_RUNTIMES=${LLVM_ENABLE_RUNTIMES})
endif()

if(target IN_LIST LLVM_RUNTIME_BUILD_ID_LINK_TARGETS)
list(APPEND EXTRA_ARGS STRIP_TOOL ${CMAKE_CURRENT_BINARY_DIR}/llvm-strip-link)
endif()
Expand All @@ -482,7 +486,6 @@ else() # if this is included from LLVM's CMake
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON
-DLLVM_RUNTIMES_TARGET=${name}
${${name}_extra_args}
PASSTHROUGH_PREFIXES LLVM_ENABLE_RUNTIMES
TOOLCHAIN_TOOLS clang lld llvm-ar llvm-ranlib llvm-nm llvm-objcopy llvm-objdump llvm-strip
EXTRA_TARGETS ${${name}_extra_targets}
${${name}_test_targets}
Expand Down

0 comments on commit 8775a1b

Please sign in to comment.