Messages in this thread | | | Date | Mon, 13 Sep 2021 23:54:15 +0930 | From | Arthur Marsh <> | Subject | Cross-comilation from amd64 to i686 - issue with /usr/src/linux/arch/x86/boot/tools/build |
| |
Hi, I had a problem when doing a Linux kernel cross compile from amd64 to i386/i686 a few days ago which I solved quickly, but wonder if the issue points to a problem:
/usr/src/linux/arch/x86/boot/tools/build had (apparently) been compiled over a year earlier when I was running under amd64 without multilib support, when I installed the i386/i686 gcc-11 under amd64, and attempted to cross-compile the kernel for i386, I received an error about bzImage:
BUILD arch/x86/boot/bzImage make[5]: *** [arch/x86/boot/Makefile:84: arch/x86/boot/bzImage] Error 139 make[5]: *** Deleting file 'arch/x86/boot/bzImage' make[4]: *** [arch/x86/Makefile:273: bzImage] Error 2
Once I removed the old /usr/src/linux/arch/x86/boot/tools/build binary and re-ran the kernel build, a new "build" binary was built and the kernel build process succeeded and the built kernels ran fine on my i386/i686 system.
I'm not sure if running a cross-compile from amd64 to i386 for the first time or in fact any update of the host CC or cross-compiler CC should have triggered a recompilation of /usr/src/linux/arch/x86/boot/tools/build.c
Kernel build command for the cross-compilation was:
make ARCH=i386 CROSS_COMPILE=i686-linux-gnu- CC=i686-linux-gnu-gcc-11 -j6 menuconfig bindeb-pkg
Arthur.
| |