Message ID | 20240327141556.542243-1-felix.moessbauer@siemens.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
Series | [isar-cip-core,1/1] fix(sid): copy immutable dpkg db | expand |
On 27.03.24 15:15, Felix Moessbauer wrote: > The immutable copy of the dpkg db is not supported on pre-bookworm. > However, the logic only made it available on bookworm but not on any > later release. > > This patch fixes this by inverting the logic: We always enable it and > just exclude buster and bullseye. > > Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com> > --- > classes/read-only-rootfs.bbclass | 8 ++++++-- > 1 file changed, 6 insertions(+), 2 deletions(-) > > diff --git a/classes/read-only-rootfs.bbclass b/classes/read-only-rootfs.bbclass > index bb8ab9a..fa56b2e 100644 > --- a/classes/read-only-rootfs.bbclass > +++ b/classes/read-only-rootfs.bbclass > @@ -18,9 +18,13 @@ IMAGE_INSTALL += "home-fs" > IMAGE_INSTALL += "tmp-fs" > > # For pre bookworm images, empty /var is not usable > -IMAGE_INSTALL:append:bookworm = " immutable-rootfs" > +IMAGE_INSTALL:append = " immutable-rootfs" > +IMAGE_INSTALL:remove:buster = " immutable-rootfs" > +IMAGE_INSTALL:remove:bullseye = " immutable-rootfs" > > -ROOTFS_POSTPROCESS_COMMAND:append:bookworm =" copy_dpkg_state" > +ROOTFS_POSTPROCESS_COMMAND:append =" copy_dpkg_state" > +ROOTFS_POSTPROCESS_COMMAND:remove:buster =" copy_dpkg_state" > +ROOTFS_POSTPROCESS_COMMAND:remove:bullseye =" copy_dpkg_state" > copy_dpkg_state() { > IMMUTABLE_VAR_LIB="${ROOTFSDIR}/usr/share/immutable-data/var/lib" > sudo mkdir -p "$IMMUTABLE_VAR_LIB" Thanks, applied. Jan
diff --git a/classes/read-only-rootfs.bbclass b/classes/read-only-rootfs.bbclass index bb8ab9a..fa56b2e 100644 --- a/classes/read-only-rootfs.bbclass +++ b/classes/read-only-rootfs.bbclass @@ -18,9 +18,13 @@ IMAGE_INSTALL += "home-fs" IMAGE_INSTALL += "tmp-fs" # For pre bookworm images, empty /var is not usable -IMAGE_INSTALL:append:bookworm = " immutable-rootfs" +IMAGE_INSTALL:append = " immutable-rootfs" +IMAGE_INSTALL:remove:buster = " immutable-rootfs" +IMAGE_INSTALL:remove:bullseye = " immutable-rootfs" -ROOTFS_POSTPROCESS_COMMAND:append:bookworm =" copy_dpkg_state" +ROOTFS_POSTPROCESS_COMMAND:append =" copy_dpkg_state" +ROOTFS_POSTPROCESS_COMMAND:remove:buster =" copy_dpkg_state" +ROOTFS_POSTPROCESS_COMMAND:remove:bullseye =" copy_dpkg_state" copy_dpkg_state() { IMMUTABLE_VAR_LIB="${ROOTFSDIR}/usr/share/immutable-data/var/lib" sudo mkdir -p "$IMMUTABLE_VAR_LIB"
The immutable copy of the dpkg db is not supported on pre-bookworm. However, the logic only made it available on bookworm but not on any later release. This patch fixes this by inverting the logic: We always enable it and just exclude buster and bullseye. Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com> --- classes/read-only-rootfs.bbclass | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)