kbuild: Bump the build system to 5.1
authorIlias Apalodimas <ilias.apalodimas@linaro.org>
Fri, 27 Jun 2025 18:57:16 +0000 (21:57 +0300)
committerTom Rini <trini@konsulko.com>
Tue, 8 Jul 2025 19:10:03 +0000 (13:10 -0600)
commit5f520875bdf0ff1269e535fe215ec0ce481c7792
treeb7eee5545ef300b867538cb7e39b9b6e36b529e4
parent22595e7430b878fdc769d7cd126828cf6a385b83
kbuild: Bump the build system to 5.1

Our last sync with the kernel was 5.1. Even that was a partial one
as some patches from 4.x kernels were already missing making the
transition to a modern kbuild infeasible.

We are so out of sync now, that tracking the patches and backporting
them one by one makes little sense and it's going to take ages.

This is an attempt to sync up Makefile[.lib/.kbuild].
Unfortunately due to sheer amount of patches this is not easy to review,
but that's what we decided during a community call.

One of the biggest changes is get rid of partial linking entirely and
build .a archives isntead of .o.
We diaviate from the kernel on that. Instead of calling a custom script
to create the archive symbol table, we call ar with rcTP (isntead of
rcSTP) since we want a resulting archive that's sauble with the linker.

The only affected platforms are PPC ones. Unfortunately I don't have any
of them around to test, but the objdump of the resulting files --
arch/powerpc/lib/built-in.[oa] looks identical.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
18 files changed:
Makefile
board/congatec/common/Makefile
board/cssi/cmpc885/u-boot.lds
board/cssi/mcr3000/u-boot.lds
board/freescale/common/Makefile
board/menlo/mx8menlo/Makefile
board/phytec/common/Makefile
board/samsung/origen/Makefile
board/samsung/smdkv310/Makefile
board/toradex/common/Makefile
doc/api/linker_lists.rst
doc/develop/crash_dumps.rst
scripts/Makefile.build
scripts/Makefile.gcc-plugins [new file with mode: 0644]
scripts/Makefile.kcov [new file with mode: 0644]
scripts/Makefile.lib
scripts/Makefile.xpl
tools/buildman/builderthread.py