LF-2702 scripts: gcc-plugins: make GCC_PLUGINS not default to y
authorDong Aisheng <aisheng.dong@nxp.com>
Tue, 24 Nov 2020 10:28:37 +0000 (18:28 +0800)
committerDong Aisheng <aisheng.dong@nxp.com>
Mon, 14 Dec 2020 02:33:52 +0000 (10:33 +0800)
commite27095b66c2cc9bb13b56189e1cde0edac198de4
tree442d0b34536e1409430b8324145b26e154f1704d
parentee66df5009410583aa09decdff4b9db0bbecaecf
LF-2702 scripts: gcc-plugins: make GCC_PLUGINS not default to y

Currently CONFIG_GCC_PLUGINS is auto enabled by detecting host
build environment as follows:
"depends on $(success,$(srctree)/scripts/gcc-plugin.sh $(CC))"

This potentially cause an inconsistency issue of images built
from two machines e.g. kernel modules built by ourselves
maybe unable to load with a prebuilt kernel image and vice versa.
(Affected by STACKPROTECTOR_PER_TASK which is also default y and
depends on GCC_PLUGINS)

In order to address this image inconsistency issue, we make the
GCC_PLUGINS option not default to y and reply on users to select it
from defconfig file once their host environment can meet the requirement
and want this option enabled.

This issue happened with GCC 10.2 toolchain and have gcc-10-plugin-dev
package installed on host after migrated to Yocto 3.2.

Acked-by: Jason Liu <jason.hui.liu@nxp.com>
Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
scripts/gcc-plugins/Kconfig