On Thu, 2021-03-11 at 10:02 +0100, Martin Jansa wrote: > On Thu, Mar 11, 2021 at 12:46:22AM -0800, Robert Yang wrote: > > This can fix a do_package error when compile with meta-secure-core layer: > > http://layers.openembedded.org/layerindex/branch/master/layer/meta-secure-core/ > > > > $ bitbake kernel-initramfs > > [snip] > > WARNING:kernel-initramfs-1.0-r0 do_package: Manifest > > build/tmp-glibc/sstate-control/manifest-x86_64_x86_64-nativesdk-secure-core-image-initramfs.packagedata > > not found in intel_x86_64 corei7-64 core2-64 x86_64 allarch > > x86_64_x86_64-nativesdk (variant '')? > > [snip] > > > > This is because kernel-initramfs wants to pack an initramfs image into > > kernel-initramfs.rpm which adds a dependency in kernel-initramfs.bb to do > > this: > > > > d.appendVarFlag('do_install', 'depends', ' > > ${INITRAMFS_IMAGE}:do_image_complete') > > > > This causes kernel-initramfs' do_package depends on > > ${INITRAMFS_IMAGE}:do_image_complete's do_packagedata, then we will get the > > error. Delete do_packagedata as other do_package relelated tasks for the > > image > > recipe will fix the error. > > > > Signed-off-by: Robert Yang <[email protected]> > > Acked-by: Martin Jansa <[email protected]> > > I went a bit further and inheritted nopackages, but RP mentioned that it > might be removing too much. Nothing failed with nopackages over night, > but still this smaller version will be safer as this needs to got to > gatesgarth and dunfell as well now.
This has side effects and there was a reason this wasn't done originally. The trouble is that nobody is testing for that, just wanting to fix the problem they see. To prove this isn't straightforward, I tested this locally, comparing task-depends.dot from "bitbake core-image-sato -g" before and after this patch. The differences were: @@ -11036,7 +11036,6 @@ "core-image-sato.do_build" -> "connman.do_build" "core-image-sato.do_build" -> "consolekit.do_build" "core-image-sato.do_build" -> "core-image-sato.do_image_complete" -"core-image-sato.do_build" -> "core-image-sato.do_packagedata" "core-image-sato.do_build" -> "core-image-sato.do_populate_lic_deploy" "core-image-sato.do_build" -> "coreutils.do_build" "core-image-sato.do_build" -> "cross-localedef-native.do_build" @@ -11459,14 +11458,6 @@ "core-image-sato.do_build" -> "zip.do_build" "core-image-sato.do_build" -> "zlib-native.do_build" "core-image-sato.do_build" -> "zlib.do_build" -"core-image-sato.do_compile" [label="core-image-sato do_compile\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_compile" -> "core-image-sato.do_configure" -"core-image-sato.do_configure" [label="core-image-sato do_configure\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_configure" -> "core-image-sato.do_deploy_source_date_epoch" -"core-image-sato.do_configure" -> "core-image-sato.do_patch" -"core-image-sato.do_configure" -> "core-image-sato.do_prepare_recipe_sysroot" -"core-image-sato.do_deploy_source_date_epoch" [label="core-image-sato do_deploy_source_date_epoch\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_deploy_source_date_epoch" -> "core-image-sato.do_patch" "core-image-sato.do_fetch" [label="core-image-sato do_fetch\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] "core-image-sato.do_flush_pseudodb" [label="core-image-sato do_flush_pseudodb\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] "core-image-sato.do_flush_pseudodb" -> "core-image-sato.do_rootfs" @@ -11489,18 +11480,6 @@ "core-image-sato.do_image_qa" -> "core-image-sato.do_rootfs" "core-image-sato.do_image_tar" [label="core-image-sato do_image_tar\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] "core-image-sato.do_image_tar" -> "core-image-sato.do_image" -"core-image-sato.do_install" [label="core-image-sato do_install\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_install" -> "core-image-sato.do_compile" -"core-image-sato.do_install" -> "pseudo-native.do_populate_sysroot" -"core-image-sato.do_package" [label="core-image-sato do_package\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_package" -> "core-image-sato.do_install" -"core-image-sato.do_package" -> "pseudo-native.do_populate_sysroot" -"core-image-sato.do_packagedata" [label="core-image-sato do_packagedata\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_packagedata" -> "core-image-sato.do_package" -"core-image-sato.do_patch" [label="core-image-sato do_patch\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_patch" -> "core-image-sato.do_unpack" -"core-image-sato.do_patch" -> "patch-native.do_populate_sysroot" -"core-image-sato.do_patch" -> "quilt-native.do_populate_sysroot" "core-image-sato.do_populate_lic_deploy" [label="core-image-sato do_populate_lic_deploy\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] "core-image-sato.do_populate_lic_deploy" -> "acl-native.do_populate_lic" "core-image-sato.do_populate_lic_deploy" -> "acl.do_populate_lic" @@ -12036,7 +12015,6 @@ "core-image-sato.do_rootfs" -> "consolekit.do_package_write_ipk" "core-image-sato.do_rootfs" -> "consolekit.do_packagedata" "core-image-sato.do_rootfs" -> "consolekit.do_populate_lic" -"core-image-sato.do_rootfs" -> "core-image-sato.do_packagedata" "core-image-sato.do_rootfs" -> "core-image-sato.do_prepare_recipe_sysroot" "core-image-sato.do_rootfs" -> "coreutils.do_package_qa" "core-image-sato.do_rootfs" -> "coreutils.do_package_write_ipk" @@ -13257,8 +13235,6 @@ "core-image-sato.do_rootfs" -> "zlib.do_package_write_ipk" "core-image-sato.do_rootfs" -> "zlib.do_packagedata" "core-image-sato.do_rootfs" -> "zlib.do_populate_lic" -"core-image-sato.do_unpack" [label="core-image-sato do_unpack\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] -"core-image-sato.do_unpack" -> "core-image-sato.do_fetch" "core-image-sato.do_write_qemuboot_conf" [label="core-image-sato do_write_qemuboot_conf\n:1.0-r0\n/media/build1/poky/meta/recipes-sato/images/core-image-sato.bb"] "core-image-sato.do_write_qemuboot_conf" -> "core-image-sato.do_rootfs" "coreutils.do_build" [label="coreutils do_build\n:8.32-r0\n/media/build1/poky/meta/recipes-core/coreutils/coreutils_8.32.bb"] i.e. it "disconnects" do_rootfs from the existing unpack/patch/configure/compile /install/package tasks. I know last time we tried this I got several complaints from users who use these tasks for things. I'm not sure how we fix this but it isn't straightforward, particularly for something which people are going to want backports into the LTS for. Cheers, Richard
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#149288): https://lists.openembedded.org/g/openembedded-core/message/149288 Mute This Topic: https://lists.openembedded.org/mt/81249042/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
