diff --git a/libc/cmake/modules/LLVMLibCTestRules.cmake b/libc/cmake/modules/LLVMLibCTestRules.cmake --- a/libc/cmake/modules/LLVMLibCTestRules.cmake +++ b/libc/cmake/modules/LLVMLibCTestRules.cmake @@ -571,11 +571,11 @@ # The GPU build requires overriding the default CMake triple and architecture. if(LIBC_GPU_TARGET_ARCHITECTURE_IS_AMDGPU) list(APPEND LIBC_HERMETIC_TEST_COMPILE_OPTIONS - -mcpu=${LIBC_GPU_TARGET_ARCHITECTURE} -flto --target=${LIBC_GPU_TARGET_TRIPLE}) + -nogpulib -mcpu=${LIBC_GPU_TARGET_ARCHITECTURE} -flto --target=${LIBC_GPU_TARGET_TRIPLE}) elseif(LIBC_GPU_TARGET_ARCHITECTURE_IS_NVPTX) get_nvptx_compile_options(nvptx_options ${LIBC_GPU_TARGET_ARCHITECTURE}) list(APPEND LIBC_HERMETIC_TEST_COMPILE_OPTIONS - ${nvptx_options} -fno-use-cxa-atexit --target=${LIBC_GPU_TARGET_TRIPLE}) + ${nvptx_options} -nogpulib -fno-use-cxa-atexit --target=${LIBC_GPU_TARGET_TRIPLE}) endif() # Rule to add a hermetic test. A hermetic test is one whose executable is fully