mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2025-07-05 05:15:23 +02:00
scripts/gcc-plugins: consistently use HOSTCC
The GCC plugins are built using HOSTCC, but the path to the GCC plugins headers is obtained using CC. This can lead to interesting failures if the host compiler and cross compiler are different versions, and the host compiler uses the cross headers. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Kees Cook <keescook@chromium.org> Link: https://lore.kernel.org/r/20210923152811.406516-1-ross.burton@arm.com Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
parent
7280c93f55
commit
f41fc97004
|
@ -9,7 +9,7 @@ menuconfig GCC_PLUGINS
|
|||
bool "GCC plugins"
|
||||
depends on HAVE_GCC_PLUGINS
|
||||
depends on CC_IS_GCC
|
||||
depends on $(success,test -e $(shell,$(CC) -print-file-name=plugin)/include/plugin-version.h)
|
||||
depends on $(success,test -e $(shell,$(HOSTCC) -print-file-name=plugin)/include/plugin-version.h)
|
||||
default y
|
||||
help
|
||||
GCC plugins are loadable modules that provide extra features to the
|
||||
|
|
|
@ -19,7 +19,7 @@ targets += randomize_layout_seed.h randomize_layout_hash.h
|
|||
|
||||
always-y += $(GCC_PLUGIN)
|
||||
|
||||
GCC_PLUGINS_DIR = $(shell $(CC) -print-file-name=plugin)
|
||||
GCC_PLUGINS_DIR = $(shell $(HOSTCXX) -print-file-name=plugin)
|
||||
|
||||
plugin_cxxflags = -Wp,-MMD,$(depfile) $(KBUILD_HOSTCXXFLAGS) -fPIC \
|
||||
-include $(srctree)/include/linux/compiler-version.h \
|
||||
|
|
Loading…
Reference in New Issue
Block a user