ACK/Cmnt: [SRU][focal/linux-riscv-5.8][PATCH 0/1] gcc version used for kernel configs doesn't match the one used for builds
Stefan Bader
stefan.bader at canonical.com
Tue Jun 29 07:10:14 UTC 2021
On 28.06.21 18:31, Kleber Sacilotto de Souza wrote:
> BugLink: https://bugs.launchpad.net/bugs/1933856
>
> [Impact]
> linux-riscv-5.8 needs to be built with gcc-10 in Focal otherwise it won't boot.
> This was fixed by commit "UBUNTU: [Packaging] Use gcc-10 for riscv 5.8 kernel
> build", which adds gcc-10 as "Build-Depends-Arch" and sets a variable "gcc" in
> 'debian/rules', which is passed down to make by
> 'debian/rules.d/2-binary-arch.mk'.
>
> The other gcc version dependency is when we generate locally the kernel configs
> by running 'make syncconfig', which is called by
> 'debian/scripts/misc/kernelconfig'. Currently, the syncconfig is called using
> the chroot default compiler, which in Focal is gcc-9. So far there hasn't been
> any major differences, however with the update of gcc-10 in Groovy and Focal
> from 10.2.0 to 10.3.0 some KASAN related config options are not available
> anymore, causing some changes on the configs generated. The problem with
> non-matching gcc versions being used, is that there will be a mismatch between
> the configs being generated during the preparation of the kernel and the ones
> during the build.
>
> [Fix]
> The proposed fix is to use the same variable defined for the build, passing it
> down to 'debian/scripts/misc/kernelconfig' and using it to define the correct
> cross-compiler to be used.
>
> [Where problems could occur]
> If the environment variables are not set correctly the build can break in some
> environment which was not tested.
>
> Kleber Sacilotto de Souza (1):
> UBUNTU: [Packaging] Use gcc-10 for riscv-5.8 kernel configs
>
> debian/rules.d/1-maintainer.mk | 4 ++--
> debian/scripts/misc/kernelconfig | 7 ++++---
> 2 files changed, 6 insertions(+), 5 deletions(-)
>
Conceptually this sounds right. The kernelconfig looks ok with a bit of
uncertainty (mostly about upper and lowercase usage of the same name) but I
assume you have tested this. So
Acked-by: Stefan Bader <stefan.bader at canonical.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20210629/67b8c556/attachment.sig>
More information about the kernel-team
mailing list