[llvm] [compiler-rt] Add some missing dependencies on Windows (PR #155019)
Aiden Grossman via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 22 12:26:30 PDT 2025
https://github.com/boomanaiden154 created https://github.com/llvm/llvm-project/pull/155019
Trying to run check-compiler-rt on Windows currently fails due to several missing dependencies. These seem to get included transitively on Linux as there is nothing obvious adding them. I had to rework the ordering in llvm/CMakeLists.txt to be able to add the KillTheDoctor dep.
>From c7eeb1aad0e4ba4f6548000dfcb39ea154445713 Mon Sep 17 00:00:00 2001
From: Aiden Grossman <aidengrossman at google.com>
Date: Fri, 22 Aug 2025 19:23:49 +0000
Subject: [PATCH] [compiler-rt] Add some missing dependencies on Windows
Trying to run check-compiler-rt on Windows currently fails due to
several missing dependencies. These seem to get included transitively on
Linux as there is nothing obvious adding them. I had to rework the
ordering in llvm/CMakeLists.txt to be able to add the KillTheDoctor dep.
---
llvm/CMakeLists.txt | 17 +++++++++++------
llvm/runtimes/CMakeLists.txt | 5 +++++
2 files changed, 16 insertions(+), 6 deletions(-)
diff --git a/llvm/CMakeLists.txt b/llvm/CMakeLists.txt
index 970eb7be8af8f..a90be4f6235e6 100644
--- a/llvm/CMakeLists.txt
+++ b/llvm/CMakeLists.txt
@@ -1376,6 +1376,17 @@ if( LLVM_INCLUDE_TOOLS )
add_subdirectory(tools)
endif()
+# We need to setup KillTheDoctor before setting up the runtimes build because
+# the runtimes build needs to add a KillTheDoctor dep for compiler-rt on
+# Windows.
+if (LLVM_INCLUDE_TESTS)
+ if (WIN32)
+ # This utility is used to prevent crashing tests from calling Dr. Watson on
+ # Windows.
+ add_subdirectory(utils/KillTheDoctor)
+ endif()
+endif()
+
if( LLVM_INCLUDE_RUNTIMES )
add_subdirectory(runtimes)
endif()
@@ -1400,12 +1411,6 @@ if( LLVM_INCLUDE_TESTS )
add_subdirectory(test)
add_subdirectory(unittests)
- if (WIN32)
- # This utility is used to prevent crashing tests from calling Dr. Watson on
- # Windows.
- add_subdirectory(utils/KillTheDoctor)
- endif()
-
umbrella_lit_testsuite_end(check-all)
get_property(LLVM_ALL_LIT_DEPENDS GLOBAL PROPERTY LLVM_ALL_LIT_DEPENDS)
get_property(LLVM_ALL_ADDITIONAL_TEST_DEPENDS
diff --git a/llvm/runtimes/CMakeLists.txt b/llvm/runtimes/CMakeLists.txt
index 94a43b96d2188..86cfd0285aa84 100644
--- a/llvm/runtimes/CMakeLists.txt
+++ b/llvm/runtimes/CMakeLists.txt
@@ -482,8 +482,10 @@ if(build_runtimes)
llvm-lto
llvm-jitlink
llvm-nm
+ llvm-strip
llvm-objdump
llvm-profdata
+ llvm-readobj
llvm-size
llvm-symbolizer
llvm-xray
@@ -499,6 +501,9 @@ if(build_runtimes)
list(APPEND extra_deps ${dep})
endif()
endforeach()
+ if(WIN32)
+ list(APPEND extra_deps KillTheDoctor)
+ endif()
endif()
# Forward user-provived system configuration to runtimes for requirement introspection.
More information about the llvm-commits
mailing list