genericx86-common.inc: add dependency do_image_wic -> do_bootimg
PATCH 1/1 genericx86-common.inc: add dependency do_image_wic -> do_bootimg
do_image_wic depends on do_bootimg on genericx86 machines as it copies files from hddimg/EFI/BOOT directory to boot partition.
--- meta-yocto-bsp/conf/machine/include/genericx86-common.inc | 1 + 1 file changed, 1 insertion(+)
meta-yocto-bsp/conf/machine/include/genericx86-common.inc +1 -0
@@ -23,3 +23,4 @@ EXTRA_OECONF_append_pn-matchbox-panel-2 = " --with-battery=acpi" IMAGE_FSTYPES += "wic" WKS_FILE ?= "mkefidisk.wks" do_image_wic[depends] += "gptfdisk-native:do_populate_sysroot" +do_image_wic[recrdeptask] += "do_bootimg"
Signature · 1 line
2.1.4
Quoted 5 lines · Ed Bartosh
do_image_wicdepends ondo_bootimgon genericx86 machines as it copies files from hddimg/EFI/BOOT directory to boot partition.Signed-off-by Ed Bartosh <[email protected]>
Thoughts on adding
https://github.com/MentorEmbedded/meta-mentor/blob/master/meta-mentor-staging/classes/bootimg-wic.bbclass
to
image.bbclass? I think we can assume the existence of do_bootimg means we should depend on it, as the class was inherited.
Signature · 5 lines
Christopher Larson clarson at kergoth dot com Founder - BitBake, OpenEmbedded, OpenZaurus Maintainer - Tslib Senior Software Engineer, Mentor Graphics
Quoted 6 lines · Christopher Larson
Quoted 3 lines · Ed Bartosh
do_image_wicdepends ondo_bootimgon genericx86 machines as it copies files from hddimg/EFI/BOOT directory to boot partition.
Quoted 8 lines
Quoted 2 lines
Signed-off-by Ed Bartosh <[email protected]>Thoughts on adding
https://github.com/MentorEmbedded/meta-mentor/blob/master/meta-mentor-staging/classes/bootimg-wic.bbclass
to
image.bbclass? I think we can assume the existence ofdo_bootimgmeans we should depend on it, as the class was inherited.
Thank you for the idea! I was looking for something like that.
BTW, even adding dependency without checking anything would work:
do_image_wic[file-checksums] += "${WKS_FILE_CHECKSUM}"
+do_image_wic[recrdeptask] += "do_bootimg"
but it's too implicit. Your suggestion is much better.
I'll send a patch soon.
--
Regards,
Ed
PATCH 1/1 image_types.bbclass: add dependency do_image_wic -> do_bootimg
In reply to Christopher LarsonTo produce certain types of images wic uses do_bootimg results to assemble final image. For example, it copies BOOT/EFI directory produced by do_bootimg to boot partition for every EFI image.
The tricky part of this is that do_bootimg task is not always run, so we can't always make do_image_wic depend on do_bootimg. We only need to do it if do_bootimg present in task graph.
Thank to Cristopher Larson for this fix.
--- meta/classes/image_types.bbclass | 5 +++++ 1 file changed, 5 insertions(+)
meta/classes/image_types.bbclass +5 -0
@@ -219,6 +219,11 @@ USING_WIC = "${@bb.utils.contains_any('IMAGE_FSTYPES', 'wic ' + ' '.join('wic.%s WKS_FILE_CHECKSUM = "${@'${WKS_FULL_PATH}:%s' % os.path.exists('${WKS_FULL_PATH}') if '${USING_WIC}' else ''}" do_image_wic[file-checksums] += "${WKS_FILE_CHECKSUM}" +python () { + if d.getVar('USING_WIC', True) and 'do_bootimg' in d: + bb.build.addtask('do_image_wic', '', 'do_bootimg', d) +} + python do_write_wks_template () { """Write out expanded template contents to WKS_FULL_PATH.""" import re
Signature · 1 line
2.1.4