Bug 14797 - ovmf fails to build with gcc12
Summary: ovmf fails to build with gcc12
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: unspecified
Hardware: All Multiple
: Medium+ normal
Target Milestone: 4.1 M2
Assignee: Ross Burton
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2022-04-28 16:11 UTC by Bernhard Rosenkränzer
Modified: 2022-07-12 10:53 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernhard Rosenkränzer 2022-04-28 16:11:08 UTC
Despite some efforts to fix it in the recipe, building edk2 (part of ovmf) uses the host system's gcc.

This can be easily observed by installing gcc 12 on the host (edk2 currently doesn't compile with gcc 12, patches for that are underway).
Comment 1 Ross Burton 2022-05-05 14:38:18 UTC
Can you share a log showing this problem?  Note that edk2 does build some tools with the host compiler because it needs to run them at build time.
Comment 2 Ross Burton 2022-05-05 15:24:35 UTC
The reason I believe this is entirely expected use of host GCC to build binaries to run on the host is that I can build ovmf on aarch64, or edk2 for Arm on a x86, so the host compiler is definitely not being used to compile target code.
Comment 3 Ross Burton 2022-07-12 10:52:27 UTC
Looks like this was fixed with oe-core 7b67f19d353d88107f52cceda3c858730ac1db54.