diff options
author | Brad King <brad.king@kitware.com> | 2022-03-03 12:58:00 -0500 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-03-03 12:58:00 -0500 |
commit | 7edc09b4f622201d551e0facf84d1101c252650b (patch) | |
tree | ad789f51ab52481eac0187f08d29165a0b4c0f2a /Modules | |
parent | 371235e0d7fad2881cb2067450d6aa7fadac1388 (diff) | |
parent | 29ea94e17c61b485f5cd1036e0ba8282b44ebb0e (diff) | |
download | cmake-7edc09b4f622201d551e0facf84d1101c252650b.tar.gz |
Merge branch 'binutils-llvm-ar-clang-macos' into release-3.22
Merge-request: !7039
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/CMakeFindBinUtils.cmake | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Modules/CMakeFindBinUtils.cmake b/Modules/CMakeFindBinUtils.cmake index 6c81754d3c..6dbe62675a 100644 --- a/Modules/CMakeFindBinUtils.cmake +++ b/Modules/CMakeFindBinUtils.cmake @@ -172,7 +172,10 @@ else() else() list(PREPEND _CMAKE_LINKER_NAMES "ld.lld") endif() - list(PREPEND _CMAKE_AR_NAMES "llvm-ar") + if(NOT APPLE) + # llvm-ar does not generate a symbol table that the Apple ld64 linker accepts. + list(PREPEND _CMAKE_AR_NAMES "llvm-ar") + endif() list(PREPEND _CMAKE_RANLIB_NAMES "llvm-ranlib") if("${CMAKE_${_CMAKE_PROCESSING_LANGUAGE}_COMPILER_VERSION}" VERSION_GREATER_EQUAL 11) # llvm-strip versions prior to 11 require additional flags we do not yet add. |