]> git.baikalelectronics.ru Git - kernel.git/commit
gcc-plugins: use KERNELVERSION for plugin version
authorMasahiro Yamada <masahiroy@kernel.org>
Tue, 24 May 2022 13:55:41 +0000 (22:55 +0900)
committerKees Cook <keescook@chromium.org>
Tue, 24 May 2022 15:25:16 +0000 (08:25 -0700)
commitc1553a9d96fb88322bdf6641fa6dc07c115ce7c4
treeec5948bdf2b36ecaa47106ef0f28aaa74da8573b
parent82f80da580fa1a4e787163889bd721f5dd1ee26d
gcc-plugins: use KERNELVERSION for plugin version

Commit bb698b65a1e3 ("gcc-plugins: Change all version strings match
kernel") broke parallel builds.

Instead of adding the dependency between GCC plugins and utsrelease.h,
let's use KERNELVERSION, which does not require any build artifact.

Another reason why I want to avoid utsrelease.h is because it depends
on CONFIG_LOCALVERSION(_AUTO) and localversion* files.

(include/generated/utsrelease.h depends on include/config/kernel.release,
which is generated by scripts/setlocalversion)

I want to keep host tools independent of the kernel configuration.

There is no good reason to rebuild GCC plugins just because of
CONFIG_LOCALVERSION being changed.

We just want to associate the plugin versions with the kernel source
version. KERNELVERSION should be enough for our purpose.

Fixes: bb698b65a1e3 ("gcc-plugins: Change all version strings match kernel")
Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/linux-mm/202205230239.EZxeZ3Fv-lkp@intel.com
Reported-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220524135541.1453693-1-masahiroy@kernel.org
scripts/gcc-plugins/Makefile
scripts/gcc-plugins/latent_entropy_plugin.c
scripts/gcc-plugins/randomize_layout_plugin.c
scripts/gcc-plugins/sancov_plugin.c
scripts/gcc-plugins/stackleak_plugin.c
scripts/gcc-plugins/structleak_plugin.c