Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 773376 - sys-kernel/gentoo-kernel-bin: installs potentially incompatible gcc plugin
Summary: sys-kernel/gentoo-kernel-bin: installs potentially incompatible gcc plugin
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Distribution Kernel Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-02-28 09:50 UTC by Michał Górny
Modified: 2021-03-01 11:55 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2021-02-28 09:50:16 UTC
I guess we should compile host tools and use the binpkg for the kernel itself only.


E.g.:
```
 * Preparing vhba module
make -j12 HOSTCC=x86_64-pc-linux-gnu-gcc-10.2.0 CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' KDIR=/usr/src/linux modules 
make -C /usr/src/linux M=/tmp/portage/sys-fs/vhba-20200106-r1/work/vhba-module-20200106 modules
make[1]: Entering directory '/usr/src/linux-5.11.2'
  CC [M]  /tmp/portage/sys-fs/vhba-20200106-r1/work/vhba-module-20200106/vhba.o
cc1: error: incompatible gcc/plugin versions
cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so
make[2]: *** [scripts/Makefile.build:279: /tmp/portage/sys-fs/vhba-20200106-r1/work/vhba-module-20200106/vhba.o] Error 1
```
Comment 1 Larry the Git Cow gentoo-dev 2021-03-01 11:55:45 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cbf649f3b2a9b5f3ac80c0aba43859ea2fbc6d0d

commit cbf649f3b2a9b5f3ac80c0aba43859ea2fbc6d0d
Author:     Michał Górny <mgorny@gentoo.org>
AuthorDate: 2021-03-01 00:03:11 +0000
Commit:     Michał Górny <mgorny@gentoo.org>
CommitDate: 2021-03-01 11:55:41 +0000

    sys-kernel/gentoo-kernel-bin: Rebuild host tooling
    
    Rebuild host tooling from source when installing the binary kernel.
    This ensures that it is compatible with the system libraries
    and toolchain, in particular reducing the risk of gcc plugin version
    collision.
    
    Closes: https://bugs.gentoo.org/773376
    Signed-off-by: Michał Górny <mgorny@gentoo.org>

 sys-kernel/gentoo-kernel-bin/Manifest              |   9 ++
 .../gentoo-kernel-bin-5.10.19-r2.ebuild            | 115 +++++++++++++++++++++
 .../gentoo-kernel-bin-5.11.2-r2.ebuild             | 115 +++++++++++++++++++++
 .../gentoo-kernel-bin-5.4.101-r2.ebuild            | 115 +++++++++++++++++++++
 4 files changed, 354 insertions(+)