summaryrefslogtreecommitdiff
path: root/tools/scripts/Makefile.include
diff options
context:
space:
mode:
authorThomas Weißschuh <linux@weissschuh.net>2026-02-26 22:23:58 +0100
committerNicolas Schier <nsc@kernel.org>2026-03-03 17:42:11 +0100
commit7239ae5331ae077c2621740a5db89e65611182cd (patch)
treef708abd507d8f58722686fa848e8956ac9b7ac4f /tools/scripts/Makefile.include
parent8830b2e5907325bd80543bf6001f80819f5cbfc5 (diff)
downloadlwn-7239ae5331ae077c2621740a5db89e65611182cd.tar.gz
lwn-7239ae5331ae077c2621740a5db89e65611182cd.zip
tools/build: Reject unexpected values for LLVM=
Since commit 502678b88cb3 ("kbuild: Reject unexpected values for LLVM=") the regular kbuild rejects unexpected values of LLVM=1 instead of silently treating them as LLVM=1. Align the tools build to kbuild. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Reviewed-by: Nicolas Schier <nsc@kernel.org> Reviewed-by: Nathan Chancellor <nathan@kernel.org> Link: https://patch.msgid.link/20260226-kbuild-llvm-followup-v1-2-201cc2a492d9@weissschuh.net Signed-off-by: Nicolas Schier <nsc@kernel.org>
Diffstat (limited to 'tools/scripts/Makefile.include')
-rw-r--r--tools/scripts/Makefile.include2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/scripts/Makefile.include b/tools/scripts/Makefile.include
index b5ecf137febc..41971a68972d 100644
--- a/tools/scripts/Makefile.include
+++ b/tools/scripts/Makefile.include
@@ -56,6 +56,8 @@ ifneq ($(filter %/,$(LLVM)),)
LLVM_PREFIX := $(LLVM)
else ifneq ($(filter -%,$(LLVM)),)
LLVM_SUFFIX := $(LLVM)
+else ifneq ($(LLVM),1)
+$(error Invalid value for LLVM, see Documentation/kbuild/llvm.rst)
endif
$(call allow-override,CC,$(LLVM_PREFIX)clang$(LLVM_SUFFIX))