diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt --- a/clang/CMakeLists.txt +++ b/clang/CMakeLists.txt @@ -403,7 +403,7 @@ # Determine HOST_LINK_VERSION on Darwin. set(HOST_LINK_VERSION) -if (APPLE) +if (APPLE AND NOT CMAKE_LINKER MATCHES ".*lld.*") set(LD_V_OUTPUT) execute_process( COMMAND sh -c "${CMAKE_LINKER} -v 2>&1 | head -1"