diff --git a/libc/test/CMakeLists.txt b/libc/test/CMakeLists.txt --- a/libc/test/CMakeLists.txt +++ b/libc/test/CMakeLists.txt @@ -25,8 +25,8 @@ return() endif() -if(NOT (${LIBC_TARGET_OS} STREQUAL "linux")) - # Integration tests are currently only available for linux. +if(NOT (${LIBC_TARGET_OS} STREQUAL "linux") OR CMAKE_COMPILER_IS_GNUCXX) + # Integration tests are currently only available for clang on linux. return() endif() add_subdirectory(integration) diff --git a/libc/test/src/CMakeLists.txt b/libc/test/src/CMakeLists.txt --- a/libc/test/src/CMakeLists.txt +++ b/libc/test/src/CMakeLists.txt @@ -60,12 +60,14 @@ add_subdirectory(pthread) endif() -if(LLVM_RUNTIMES_BUILD OR LIBC_HDRGEN_EXE) +if(LLVM_RUNTIMES_BUILD OR LIBC_HDRGEN_EXE OR CMAKE_COMPILER_IS_GNUCXX) # The public API test below uses tablegen to generate the test # source file. Since tablegen is not available during a runtimes # build, we will skip the test. # If a different libc-hdrgen binary is being used, then also we # skip the api-test as we cannot generate the test source file. + # Additionally, this is an integration test and those only work with clang + # for the moment. return() endif()