kernel-fit-image: skip sstate creation for deploy
PATCH 1/1 kernel-fit-image: skip sstate creation for deploy
When building completely from sstate (e.g. in pipeline), the linux-yocto-fitimage recipe deploys from sstate even if the INITRAMFS_IMAGE requires a rebuild.
Using dm-verity or verity image classes, the initramfs image must be rebuilt after the rootfs. However, linux-yocto-fitimage:do_build was skipped and went straight for do_deploy from sstate and deployed a fitImage with an outdated initramfs with old roothash data while the image and INITRAMFS_IMAGE were being built.
Skipping the do_deploy task in a sstate only build, successfully triggers linux-yocto-fitimage:do_build after INITRAMFS_IMAGE:do_image_complete.
This also follows fitimage.bbclass[1] from meta-oe.
[1]: https://git.openembedded.org/meta-openembedded/tree/meta-oe/classes/fitimage.bbclass?h=wrynose#n522
--- meta/classes-recipe/kernel-fit-image.bbclass | 1 + 1 file changed, 1 insertion(+)
meta/classes-recipe/kernel-fit-image.bbclass +1 -0
@@ -241,3 +241,4 @@ do_deploy() { fi } addtask deploy after do_compile before do_build +SSTATE_SKIP_CREATION:task-deploy = "1"
Quoted 27 lines · Tafil Avdyli via lists.openembedded.org
When building completely from sstate (e.g. in pipeline), the linux-yocto-fitimage recipe deploys from sstate even if the
INITRAMFS_IMAGErequires a rebuild.Using dm-verity or verity image classes, the initramfs image must be rebuilt after the rootfs. However, linux-yocto-fitimage:do_build was skipped and went straight for
do_deployfrom sstate and deployed a fitImage with an outdated initramfs with old roothash data while the image andINITRAMFS_IMAGEwere being built.Skipping the
do_deploytask in a sstate only build, successfully triggers linux-yocto-fitimage:do_build after INITRAMFS_IMAGE:do_image_complete.
This also follows fitimage.bbclass[1] from meta-oe.[1]: https://git.openembedded.org/meta-openembedded/tree/meta-oe/classes/fitimage.bbclass?h=wrynose#n522
Signed-off-by Tafil Avdyli <[email protected]>---
meta/classes-recipe/kernel-fit-image.bbclass | 1 +1 file changed, 1 insertion(+)meta/classes-recipe/kernel-fit-image.bbclass +0
-0@@ -241,3 +241,4 @@ do_deploy() {
Quoted 4 lines
fi
}
addtask deploy afterdo_compilebeforedo_build
+SSTATE_SKIP_CREATION:task-deploy = "1"
This is a workaround, it sounds like there is a missing dependency somewhere to trigger the build needed?
Cheers,
Richard
Quoted 28 lines · Richard Purdie via lists.openembedded.org
Quoted 26 lines · Tafil Avdyli via lists.openembedded.org
When building completely from sstate (e.g. in pipeline), the linux-yocto-fitimage recipe deploys from sstate even if the
INITRAMFS_IMAGErequires a rebuild.Using dm-verity or verity image classes, the initramfs image must be
rebuilt after the rootfs. However, linux-yocto-fitimage:do_build was
skipped and went straight fordo_deployfrom sstate and deployed a fitImage with an outdated initramfs with old roothash data while the
image andINITRAMFS_IMAGEwere being built.Skipping the
do_deploytask in a sstate only build, successfully triggers linux-yocto-fitimage:do_build after INITRAMFS_IMAGE:do_image_complete.
This also follows fitimage.bbclass[1] from meta-oe.[1]:
https://git.openembedded.org/meta-openembedded/tree/meta-oe/classes/fitimage.bbclass?h=wrynose#n522Signed-off-by Tafil Avdyli <[email protected]>---
meta/classes-recipe/kernel-fit-image.bbclass | 1 +1 file changed, 1 insertion(+)
Quoted 13 lines
Quoted 10 lines
meta/classes-recipe/kernel-fit-image.bbclass +0
-0@@ -241,3 +241,4 @@ do_deploy() {fi
}
addtask deploy afterdo_compilebeforedo_build
+SSTATE_SKIP_CREATION:task-deploy = "1"This is a workaround, it sounds like there is a missing dependency somewhere to trigger the build needed?
I agree with Richard, this is not the right fix. What are you exactly doing and what are you then going to change before calling bitbake again?
Regards,
Adrian
Quoted 15 lines
Cheers,
Richard
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#238102):
https://lists.openembedded.org/g/openembedded-core/message/238102
Mute This Topic: https://lists.openembedded.org/mt/119630574/4454582
Group Owner: [email protected] Unsubscribe:
https://lists.openembedded.org/g/openembedded-core/unsub [
[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-