diff options
author | Siva Chandra Reddy <sivachandra@google.com> | 2021-12-22 22:19:38 +0000 |
---|---|---|
committer | Siva Chandra Reddy <sivachandra@google.com> | 2021-12-22 22:38:03 +0000 |
commit | e8a0af80137a282ed850e2e53075cbd9d678084d (patch) | |
tree | 75367b2e8492fcb8b7b237fe83b03755e42adb28 | |
parent | 5fc4323eda60ee15ef4c87d989d468cd0e6d77c1 (diff) | |
download | llvm-e8a0af80137a282ed850e2e53075cbd9d678084d.zip llvm-e8a0af80137a282ed850e2e53075cbd9d678084d.tar.gz llvm-e8a0af80137a282ed850e2e53075cbd9d678084d.tar.bz2 |
[libc][Obvious] Add target OSUtil tests only if the target OS/arch match.
-rw-r--r-- | libc/test/src/__support/OSUtil/CMakeLists.txt | 4 | ||||
-rw-r--r-- | libc/test/src/__support/OSUtil/linux/CMakeLists.txt | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/libc/test/src/__support/OSUtil/CMakeLists.txt b/libc/test/src/__support/OSUtil/CMakeLists.txt index 494218b..c70fedf 100644 --- a/libc/test/src/__support/OSUtil/CMakeLists.txt +++ b/libc/test/src/__support/OSUtil/CMakeLists.txt @@ -1,3 +1,5 @@ add_libc_testsuite(libc_osutil_tests) -add_subdirectory(linux) +if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS}) + add_subdirectory(${LIBC_TARGET_OS}) +endif() diff --git a/libc/test/src/__support/OSUtil/linux/CMakeLists.txt b/libc/test/src/__support/OSUtil/linux/CMakeLists.txt index 7e2608e..bfb072c 100644 --- a/libc/test/src/__support/OSUtil/linux/CMakeLists.txt +++ b/libc/test/src/__support/OSUtil/linux/CMakeLists.txt @@ -1 +1,3 @@ -add_subdirectory(x86_64) +if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_ARCHITECTURE}) + add_subdirectory(${LIBC_TARGET_ARCHITECTURE}) +endif() |