[libclc] Add missing deps for LLVM_ENABLE_RUNTIMES. (#145684)

When libclc is built using LLVM_ENABLE_RUNTIMES, we need all tools to be
available before starting the runtime build. Add the missing deps for
this.
This commit is contained in:
Harald van Dijk
2025-06-25 14:45:21 +01:00
committed by GitHub
parent e99d8bb0dc
commit 183ff08b32

View File

@@ -510,6 +510,13 @@ if(build_runtimes)
endif()
# TODO: We need to consider passing it as '-DRUNTIMES_x86_64_LLVM_ENABLE_RUNTIMES'.
if("libclc" IN_LIST LLVM_ENABLE_RUNTIMES)
foreach(dep clang llvm-as llvm-link opt)
if(TARGET ${dep})
list(APPEND extra_deps ${dep})
endif()
endforeach()
endif()
if("openmp" IN_LIST LLVM_ENABLE_RUNTIMES OR "offload" IN_LIST LLVM_ENABLE_RUNTIMES)
if (${LLVM_TOOL_FLANG_BUILD})
message(STATUS "Configuring build of omp_lib.mod and omp_lib_kinds.mod via flang")