Commit Graph

2 Commits (c6bb4d25f34ab8f1f5c649cb6894e8022bd8458d)

Author SHA1 Message Date
Alper Nebi Yasak bee5054077 build/roms: Make coreboot crossgcc usable for payloads and modules
Add the coreboot-built cross-architecture toolchains to the PATH so that
modules and payloads can use them. When building for a foreign-arch
board, also export CROSS_COMPILE pointing to the appropriate prefix.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
2022-12-10 14:19:00 +03:00
Alper Nebi Yasak 1dc05e4066 build/payload: Add helper script to build U-Boot as payload
This enables building U-Boot for boards which have config files in
resources/u-boot, and copying built files that could be usable to make
coreboot payloads. Right now, there is no such board in this repo.

The most important file here is "u-boot.elf", which is a combination of
the U-Boot binary and the appropriate device-tree file for the board.
Building this needs CONFIG_REMAKE_ELF=y on the U-Boot part, and using
this with CONFIG_PAYLOAD_ELF=y on the coreboot build works fine.

Note that this isn't enough to make U-Boot-only releases, since
low-level prerequisites like arm-trusted-firmware aren't passed in to
the U-Boot build system. Coreboot builds its own copy of TF-A and sets
it up on the board, so using these U-Boot builds as payloads should
still work.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
2022-08-28 13:09:52 +03:00