]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Minor] Do not use lld when clang is not the compiler...
authorVsevolod Stakhov <vsevolod@rspamd.com>
Sun, 16 Jul 2023 21:09:46 +0000 (22:09 +0100)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Sun, 16 Jul 2023 21:10:13 +0000 (22:10 +0100)
cmake/Toolset.cmake

index fc019cf35a80086640c69b194ea944bc5b5f1fbc..dfd1d30088d76655ecba5496a1711c612e7c2a76 100644 (file)
@@ -78,7 +78,15 @@ find_program(GOLD_PATH NAMES "ld.gold" "gold")
 
 if(NOT LINKER_NAME)
     if(LLD_PATH)
-        set(LINKER_NAME "lld")
+        if (COMPILER_CLANG)
+            set(LINKER_NAME "lld")
+        else()
+            if(GOLD_PATH)
+                set(LINKER_NAME "gold")
+            else()
+                message(STATUS "Use generic 'ld' as a linker")
+            endif()
+        endif()
     elseif(GOLD_PATH)
         set(LINKER_NAME "gold")
     else()