Make does its work in two distinct phases. The first one basically initializes and expands all variables, which are not in a recipe and the second expands all variables inside recipes and then executes the recipes if necessary. Currently on some mainboards it can happen that cpu_microcode_bins variable is filled with microcode paths AFTER swid-files-y is expanded in the prerequisite for the sbom rule. That causes the "$(build-dir)/intel-microcode-%.json pattern matching rule not to be invoked. At the time, when the recipe is executed however (second phase of make), swid-files-y will now contain the cpu microcode paths from cpu_microcode_bins. That causes the goswid tooling to fail since the necessary files were never created, since "(build-dir)/intel-microcode-%.json" target was never executed. In order to trigger the expansion of swid-files-y at the second make phase (after cpu_microcode_bins is fully filled), this patch makes use of make's secondary expansion feature. Before on some boards (including samsung/lumpy) the goswid tool complained about not finding the microcode sbom files. Test: build samsung/lumpy with CONFIG_SBOM_MICROCODE=y Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com> Change-Id: I884469a388fd48be89d74ccda686dd8f299d63eb Reviewed-on: https://review.coreboot.org/c/coreboot/+/72660 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Elyes Haouas <ehaouas@noos.fr> |
||
|---|---|---|
| .. | ||
| amd-microcode.json | ||
| compiler-clang.json | ||
| compiler-gcc.json | ||
| compiler-generic.json | ||
| coreboot.json | ||
| generic-ec.json | ||
| generic-fsp.json | ||
| intel-bios-acm.json | ||
| intel-me.json | ||
| intel-microcode.json | ||
| intel-sinit-acm.json | ||
| Kconfig | ||
| Makefile.inc | ||
| payload-BOOTBOOT.json | ||
| payload-depthcharge.json | ||
| payload-FILO.json | ||
| payload-GRUB2.json | ||
| payload-iPXE.json | ||
| payload-LinuxBoot.json | ||
| payload-SeaBIOS.json | ||
| payload-skiboot.json | ||
| payload-U-Boot.json | ||
| TAGS | ||