]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
kernel-devsrc: fix mismatched compiler warning
authorBruce Ashfield <bruce.ashfield@gmail.com>
Fri, 24 Mar 2023 15:08:46 +0000 (11:08 -0400)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sun, 26 Mar 2023 17:48:56 +0000 (18:48 +0100)
commit70419f281a4571d01975bd79a47a6ed7ae70b1ae
tree6f0581cc2c92c01bf8e07a0ff646e0651a8d4765
parent7be1bc5ce77b31bb634bd3572d8553cad127f38e
kernel-devsrc: fix mismatched compiler warning

When building a module on target, we use the native compiler
(always "gcc") versus the same compiler, but named in a cross
compiler manner, for the kernel build.

The kernel captures the compiler string in several places,
some of which we are already fixing, but others we are not
(as they don't cause issues).

But when building an on target module, the main kernel Makefile
compares compiler strings and outputs a warning similar to:

  warning: the compiler differs from the one used to build the kernel
    The kernel was built by: x86_64-poky-linux-gcc (GCC) 11.3.0
    You are using:           gcc (GCC) 11.3.0

We drop the cross compilation prefix from the captured compiler
string, and we avoid the warning.

RP: tweaked one sed expression to fix quoting issue with 5.15
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-kernel/linux/kernel-devsrc.bb