diff options
| author | Alejandro Hernandez Samaniego <alejandro@enedino.org> | 2022-12-08 11:43:47 -0700 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2023-01-06 17:33:23 +0000 |
| commit | dc189cf536bc3f0898234eab5e0af678cb58c987 (patch) | |
| tree | 18f959e293c84993efefcbbab86b8e04396d807d /meta/classes | |
| parent | 9cd4e36dd54bc122a4b82d4e3b73cc0c6826d419 (diff) | |
| download | poky-dc189cf536bc3f0898234eab5e0af678cb58c987.tar.gz | |
baremetal-image: Avoid overriding qemu variables from IMAGE_CLASSES
Since qemuboot is part of IMAGE_CLASSES via qemu.inc it is being
inherited before we set the QB_FOO variables.
Since our variables have conditional definitions and at that point
they've already been defined by qemuboot, we can no longer define
them in our class.
Move the IMAGE_CLASSES inherit to execute it after we set the
QB_FOO variables to fix booting via runqemu.
(From OE-Core rev: c588b05ed4bc6b46749e24e80300228df017c694)
Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandro@enedino.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
(cherry picked from commit 8ed78ec262b2502dc3b673b24a868a3eec616a20)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
| -rw-r--r-- | meta/classes/baremetal-image.bbclass | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/meta/classes/baremetal-image.bbclass b/meta/classes/baremetal-image.bbclass index cb9e250350..3a96df1f2d 100644 --- a/meta/classes/baremetal-image.bbclass +++ b/meta/classes/baremetal-image.bbclass | |||
| @@ -95,6 +95,17 @@ QB_OPT_APPEND:append:qemuriscv32 = " -bios none" | |||
| 95 | CFLAGS:append:qemuriscv64 = " -mcmodel=medany" | 95 | CFLAGS:append:qemuriscv64 = " -mcmodel=medany" |
| 96 | 96 | ||
| 97 | 97 | ||
| 98 | ## Emulate image.bbclass | ||
| 99 | # Handle inherits of any of the image classes we need | ||
| 100 | IMAGE_CLASSES ??= "" | ||
| 101 | IMGCLASSES = " ${IMAGE_CLASSES}" | ||
| 102 | inherit ${IMGCLASSES} | ||
| 103 | # Set defaults to satisfy IMAGE_FEATURES check | ||
| 104 | IMAGE_FEATURES ?= "" | ||
| 105 | IMAGE_FEATURES[type] = "list" | ||
| 106 | IMAGE_FEATURES[validitems] += "" | ||
| 107 | |||
| 108 | |||
| 98 | # This next part is necessary to trick the build system into thinking | 109 | # This next part is necessary to trick the build system into thinking |
| 99 | # its building an image recipe so it generates the qemuboot.conf | 110 | # its building an image recipe so it generates the qemuboot.conf |
| 100 | addtask do_rootfs before do_image after do_install | 111 | addtask do_rootfs before do_image after do_install |
