aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
authorLinus Torvalds <torvalds@linux-foundation.org>2026-06-25 09:06:12 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2026-06-25 09:06:12 -0700
commit6cc37b86f80985774809aba82283fe0d564d870f (patch)
treed630cead2441628c0ce6dfc60a5cea078f847ed9 /Makefile
parent504c8065288befdc8a89e98858ac563deae9d7ba (diff)
parent645323a7f4e55bb3abb0cb003b6b9dc715c8dc21 (diff)
downloadath-6cc37b86f80985774809aba82283fe0d564d870f.tar.gz
Merge tag 'kbuild-7.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kbuild/linux
Pull more Kbuild updates from Nathan Chancellor: - Link host programs with ld.lld when $(LLVM) is set to match user's expectations that LLVM will be used exclusively during the build process - Fix modpost warnings from static variable name promotion that can happen more aggressively with the recently merged distributed ThinLTO support - Add an optional warning for user-supplied Kconfig values that changed after processing, such as out of range values or options that have incorrect / missing dependencies * tag 'kbuild-7.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kbuild/linux: kconfig: add optional warnings for changed input values modpost: Ignore Clang LTO suffixes in symbol matching kbuild: Use ld.lld for linking host programs when LLVM is set
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index fae409cd524dd..12fd3d2d47b58 100644
--- a/Makefile
+++ b/Makefile
@@ -528,6 +528,9 @@ OBJCOPY = $(LLVM_PREFIX)llvm-objcopy$(LLVM_SUFFIX)
OBJDUMP = $(LLVM_PREFIX)llvm-objdump$(LLVM_SUFFIX)
READELF = $(LLVM_PREFIX)llvm-readelf$(LLVM_SUFFIX)
STRIP = $(LLVM_PREFIX)llvm-strip$(LLVM_SUFFIX)
+ifeq ($(filter -fuse-ld=% --ld-path=%,$(KBUILD_HOSTLDFLAGS)),)
+KBUILD_HOSTLDFLAGS += -fuse-ld=lld
+endif
else
CC = $(CROSS_COMPILE)gcc
LD = $(CROSS_COMPILE)ld