Собранный из исходников clang под mac os не видит ld

Собрал последнюю версию clang под mac os. При попытке скомпилировать код, clang выдает ошибку что не видит компоновщик ld. Но ld установлен по дефолтному пути /usr/bin/ld, в PATH есть этот путь, как мне явно указать clang где лежит компановщик?

CMake Error at /Users/a.mamedov/Library/Application Support/JetBrains/Toolbox/apps/CLion/ch-0/212.5712.21/CLion.app/Contents/bin/cmake/mac/share/cmake-3.20/Modules/CMakeTestCCompiler.cmake:66 (message):
  The C compiler

    "/usr/local/bin/clang"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: /Users/a.mamedov/dev/cxxcoro/cmake-build-debug-clang16/CMakeFiles/CMakeTmp
    
    Run Build Command(s):/usr/bin/make -f Makefile cmTC_faa40/fast && /Applications/Xcode.app/Contents/Developer/usr/bin/make  -f CMakeFiles/cmTC_faa40.dir/build.make CMakeFiles/cmTC_faa40.dir/build
    Building C object CMakeFiles/cmTC_faa40.dir/testCCompiler.c.o
    /usr/local/bin/clang    -MD -MT CMakeFiles/cmTC_faa40.dir/testCCompiler.c.o -MF CMakeFiles/cmTC_faa40.dir/testCCompiler.c.o.d -o CMakeFiles/cmTC_faa40.dir/testCCompiler.c.o -c /Users/a.mamedov/dev/cxxcoro/cmake-build-debug-clang16/CMakeFiles/CMakeTmp/testCCompiler.c
    Linking C executable cmTC_faa40
    "/Users/a.mamedov/Library/Application Support/JetBrains/Toolbox/apps/CLion/ch-0/212.5712.21/CLion.app/Contents/bin/cmake/mac/bin/cmake" -E cmake_link_script CMakeFiles/cmTC_faa40.dir/link.txt --verbose=1
    /usr/local/bin/clang -Wl,-search_paths_first -Wl,-headerpad_max_install_names CMakeFiles/cmTC_faa40.dir/testCCompiler.c.o -o cmTC_faa40 
    clang-16: error: unable to execute command: Executable "ld" doesn't exist!
    clang-16: error: linker command failed with exit code 1 (use -v to see invocation)
    make[1]: *** [cmTC_faa40] Error 1
    make: *** [cmTC_faa40/fast] Error 2

Ответы (0 шт):