diff options
Diffstat (limited to 'recipes-containers')
| -rw-r--r-- | recipes-containers/vcontainer/vcontainer-tarball.bb | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/recipes-containers/vcontainer/vcontainer-tarball.bb b/recipes-containers/vcontainer/vcontainer-tarball.bb index 42a13527..7e59c77d 100644 --- a/recipes-containers/vcontainer/vcontainer-tarball.bb +++ b/recipes-containers/vcontainer/vcontainer-tarball.bb | |||
| @@ -140,6 +140,25 @@ VCONTAINER_ARCHITECTURES ?= "x86_64 aarch64" | |||
| 140 | 140 | ||
| 141 | # Conditionally set mcdepends based on available multiconfigs | 141 | # Conditionally set mcdepends based on available multiconfigs |
| 142 | # (avoids parse errors when BBMULTICONFIG is not set, e.g. yocto-check-layer) | 142 | # (avoids parse errors when BBMULTICONFIG is not set, e.g. yocto-check-layer) |
| 143 | # | ||
| 144 | # Two layers of dependency per arch: | ||
| 145 | # | ||
| 146 | # 1. initramfs-create:do_deploy | ||
| 147 | # Task ordering — guarantees the rootfs.img / kernel / initramfs are | ||
| 148 | # staged under tmp-<mc>/deploy/images/<machine>/<tool>/<arch>/ before | ||
| 149 | # do_populate_sdk reads them. | ||
| 150 | # | ||
| 151 | # 2. rootfs-image:do_image_complete | ||
| 152 | # Defence-in-depth for sstate consistency. Without this, a rootfs | ||
| 153 | # content change (e.g. adding netavark, switching iptables -> nftables) | ||
| 154 | # would only invalidate the tarball's sstate hash if it propagates | ||
| 155 | # cleanly through rootfs-image:do_build -> initramfs-create:do_compile | ||
| 156 | # -> initramfs-create:do_deploy -> mcdepends. Any break in that chain | ||
| 157 | # (the DEPLOY_DIR-input sstate pattern is one known way to get a stale | ||
| 158 | # hit) re-introduces the netavark-stale-tarball failure mode. Listing | ||
| 159 | # the rootfs-image task directly puts its hash in our chain regardless | ||
| 160 | # of intermediate propagation, and costs nothing if the chain was | ||
| 161 | # already healthy. | ||
| 143 | python () { | 162 | python () { |
| 144 | bbmulticonfig = (d.getVar('BBMULTICONFIG') or "").split() | 163 | bbmulticonfig = (d.getVar('BBMULTICONFIG') or "").split() |
| 145 | mcdeps = [] | 164 | mcdeps = [] |
| @@ -147,6 +166,8 @@ python () { | |||
| 147 | if mc in bbmulticonfig: | 166 | if mc in bbmulticonfig: |
| 148 | mcdeps.append('mc::%s:vdkr-initramfs-create:do_deploy' % mc) | 167 | mcdeps.append('mc::%s:vdkr-initramfs-create:do_deploy' % mc) |
| 149 | mcdeps.append('mc::%s:vpdmn-initramfs-create:do_deploy' % mc) | 168 | mcdeps.append('mc::%s:vpdmn-initramfs-create:do_deploy' % mc) |
| 169 | mcdeps.append('mc::%s:vdkr-rootfs-image:do_image_complete' % mc) | ||
| 170 | mcdeps.append('mc::%s:vpdmn-rootfs-image:do_image_complete' % mc) | ||
| 150 | if mcdeps: | 171 | if mcdeps: |
| 151 | d.setVarFlag('do_populate_sdk', 'mcdepends', ' '.join(mcdeps)) | 172 | d.setVarFlag('do_populate_sdk', 'mcdepends', ' '.join(mcdeps)) |
| 152 | 173 | ||
