From 7ce2692371e290a6a0fedacfab262c5f4e174263 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Mon, 17 Nov 2025 09:34:28 -0800 Subject: [PATCH] test: remove stdlib unittest dependency for tests When building without the standard library, we exclude the standard library from the test dependencies. The unittest framework is dependency on the standard library and cannot be built without it. Remove this dependency in that case as well. --- test/CMakeLists.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 67f304858d2ae..cf32123d6db36 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -474,9 +474,11 @@ foreach(SDK ${SWIFT_SDKS}) list(APPEND test_dependencies "touch-covering-tests") endif() - list(APPEND test_dependencies - "swiftStdlibCollectionUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}" - "swiftStdlibUnicodeUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}") + if(SWIFT_BUILD_STDLIB) + list(APPEND test_dependencies + "swiftStdlibCollectionUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}" + "swiftStdlibUnicodeUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}") + endif() set(validation_test_dependencies)