aboutsummaryrefslogtreecommitdiff
path: root/libc/test
diff options
context:
space:
mode:
authorJoseph Huber <huberjn@outlook.com>2024-06-05 18:08:19 -0500
committerJoseph Huber <huberjn@outlook.com>2024-06-05 18:09:06 -0500
commitdbc3e26c25587e5460ae12caed84cb09197c4ed7 (patch)
tree2e9e3b02d1217be6018fffb63126902d45f6b1e6 /libc/test
parenta9342f2eab7993a3be1d1156070c0d2de21ed973 (diff)
downloadllvm-dbc3e26c25587e5460ae12caed84cb09197c4ed7.zip
llvm-dbc3e26c25587e5460ae12caed84cb09197c4ed7.tar.gz
llvm-dbc3e26c25587e5460ae12caed84cb09197c4ed7.tar.bz2
[libc][NFC] More verbose warning message on missing utilities
Summary: The GPU needs both the loader utility and the architecture to be present to run tests. This simply makes it easier to detect which is missing in case of problems.
Diffstat (limited to 'libc/test')
-rw-r--r--libc/test/CMakeLists.txt12
1 files changed, 8 insertions, 4 deletions
diff --git a/libc/test/CMakeLists.txt b/libc/test/CMakeLists.txt
index 5e26a10..b5c989a 100644
--- a/libc/test/CMakeLists.txt
+++ b/libc/test/CMakeLists.txt
@@ -8,10 +8,14 @@ add_custom_target(libc-long-running-tests)
add_subdirectory(UnitTest)
-if(LIBC_TARGET_OS_IS_GPU AND
- (NOT TARGET libc.utils.gpu.loader OR LIBC_GPU_TESTS_DISABLED))
- message(WARNING "Cannot build libc GPU tests, missing loader or architecture")
- return()
+if(LIBC_TARGET_OS_IS_GPU)
+ if(NOT TARGET libc.utils.gpu.loader)
+ message(WARNING "Cannot build libc GPU tests, missing loader.")
+ return()
+ elseif(LIBC_GPU_TESTS_DISABLED)
+ message(WARNING "Cannot build libc GPU tests, missing target architecture.")
+ return()
+ endif()
endif()
add_subdirectory(include)