path: root/MAINTAINERS
diff options
authorMasahiro Yamada <>2021-01-16 08:35:42 +0900
committerMasahiro Yamada <>2021-02-16 12:01:32 +0900
commitaec6c60a01d3a3170242d6a99372a388e1136dc6 (patch)
treeaac4077abb04923db60033406535c3a128bf9d2c /MAINTAINERS
parent052c805a1851a4415f9e2adfa9654a0b793e0c45 (diff)
kbuild: check the minimum compiler version in Kconfig
Paul Gortmaker reported a regression in the GCC version check. [1] If you use GCC 4.8, the build breaks before showing the error message "error Sorry, your version of GCC is too old - please use 4.9 or newer." I do not want to apply his fix-up since it implies we would not be able to remove any cc-option test. Anyway, I admit checking the GCC version in <linux/compiler-gcc.h> is too late. Almost at the same time, Linus also suggested to move the compiler version error to Kconfig time. [2] I unified the two similar scripts, and into The old scripts invoked the compiler multiple times (3 times for, 4 times for I refactored the code so the new one invokes the compiler just once, and also tried my best to use shell-builtin commands where possible. The new script runs faster. $ time ./scripts/ clang 120000 real 0m0.029s user 0m0.012s sys 0m0.021s $ time ./scripts/ clang Clang 120000 real 0m0.009s user 0m0.006s sys 0m0.004s also shows an error message if the compiler is too old: $ make defconfig CC=clang-9 *** Default configuration is based on 'x86_64_defconfig' *** *** Compiler is too old. *** Your Clang version: 9.0.1 *** Minimum Clang version: 10.0.1 *** scripts/Kconfig.include:46: Sorry, this compiler is not supported. make[1]: *** [scripts/kconfig/Makefile:81: defconfig] Error 1 make: *** [Makefile:602: defconfig] Error 2 The new script takes care of ICC because we have <linux/compiler-intel.h> although I am not sure if building the kernel with ICC is well-supported. [1]: [2]: Fixes: 87de84c9140e ("kbuild: remove cc-option test of -Werror=date-time") Reported-by: Paul Gortmaker <> Suggested-by: Linus Torvalds <> Reviewed-by: Nick Desaulniers <> Tested-by: Nick Desaulniers <> Reviewed-by: Nathan Chancellor <> Tested-by: Nathan Chancellor <> Reviewed-by: Miguel Ojeda <> Tested-by: Miguel Ojeda <> Tested-by: Sedat Dilek <> Signed-off-by: Masahiro Yamada <>
Diffstat (limited to 'MAINTAINERS')
1 files changed, 0 insertions, 1 deletions
index 667d03852191..df820969be1f 100644
@@ -4314,7 +4314,6 @@ C: irc://
F: Documentation/kbuild/llvm.rst
F: include/linux/compiler-clang.h
F: scripts/clang-tools/
-F: scripts/
F: scripts/
K: \b(?i:clang|llvm)\b