Message ID | 20230317100923.3295331-1-mikko.rapeli@linaro.org |
---|---|
State | New |
Headers | show |
Series | e2fsprogs: switch from master to debian/master branch to fix compatibility | expand |
This doesn’t seem right. We should not give special privileges to tooling from any particular host distro. If you need to manipulate images, build e2fsprogs-native and run that. Alex On Fri 17. Mar 2023 at 10.09, Mikko Rapeli <mikko.rapeli@linaro.org> wrote: > From: Jerome Forissier <jerome.forissier@linaro.org> > > When trying to use e2fsck <= 1.47.0 on the root filesystem (for example, > to resize a partition after copying the image to a USB stick on a > computer running current Ubuntu [22.04] or Debian), an error is > reported: > > e2fsck 1.46.5 (30-Dec-2021) > /dev/sdb2 has unsupported feature(s): FEATURE_C12 > e2fsck: Get a newer version of e2fsck! > > This has been discussed in [2] and a fix was made for use by > Debian-based distros in [3]. Let's pick that version. > > Link: [1] https://gitlab.com/Linaro/trusted-reference-stack/trs/-/issues/1 > Link: [2] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1031622 > Link: [3] > https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?h=debian/master&id=1181f164c48574a4813bfa203dbd7b4123154021 > > Binary compatibility of generated ext4 file system images is important > so it's better to use the "debian/master" branch. > > Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> > Signed-off-by: Mikko Rapeli <mikko.rapeli@linaro.org> > --- > meta/recipes-devtools/e2fsprogs/e2fsprogs.inc | 2 +- > .../e2fsprogs/{e2fsprogs_1.47.0.bb => e2fsprogs_1.47.0-2.bb} | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > rename meta/recipes-devtools/e2fsprogs/{e2fsprogs_1.47.0.bb => > e2fsprogs_1.47.0-2.bb} (99%) > > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > index f41a5d0b4e..2f54896e8c 100644 > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > @@ -19,7 +19,7 @@ LIC_FILES_CHKSUM = > "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \ > SECTION = "base" > DEPENDS = "util-linux attr autoconf-archive" > > -SRC_URI = "git:// > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=master" > +SRC_URI = "git:// > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=debian/master" > S = "${WORKDIR}/git" > > inherit autotools gettext texinfo pkgconfig multilib_header > update-alternatives ptest > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > similarity index 99% > rename from meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > rename to meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > index 2620610903..9bf89ba0c4 100644 > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > @@ -10,7 +10,7 @@ SRC_URI:append:class-native = " \ > file://quiet-debugfs.patch \ > " > > -SRCREV = "f4c9cc4bedacde8408edda3520a32d3842290112" > +SRCREV = "1181f164c48574a4813bfa203dbd7b4123154021" > UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$" > > EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \ > -- > 2.34.1 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#178747): > https://lists.openembedded.org/g/openembedded-core/message/178747 > Mute This Topic: https://lists.openembedded.org/mt/97669707/1686489 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > alex.kanavin@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > >
Hi, On Fri, Mar 17, 2023 at 11:39:23AM +0100, Alexander Kanavin wrote: > This doesn’t seem right. We should not give special privileges to tooling > from any particular host distro. If you need to manipulate images, build > e2fsprogs-native and run that. This is about ext4 images breaking compatibility with older versions of tooling used manipulate the images. For Debian the upstream maintainers and Debian package maintainers agreed to keep the backwards compatibility for longer time. I think that makes sense for yocto too. While I agree that using e2fsprogs-native is a solution too, I also agree that a lot of users are using non-yocto e2fsprogs when e.g. flashing images to target HW. Breaking compatibility can quite simply be avoided and upstream will maintain this branch. Win win from my point of view. Cheers, -Mikko > Alex > > On Fri 17. Mar 2023 at 10.09, Mikko Rapeli <mikko.rapeli@linaro.org> wrote: > > > From: Jerome Forissier <jerome.forissier@linaro.org> > > > > When trying to use e2fsck <= 1.47.0 on the root filesystem (for example, > > to resize a partition after copying the image to a USB stick on a > > computer running current Ubuntu [22.04] or Debian), an error is > > reported: > > > > e2fsck 1.46.5 (30-Dec-2021) > > /dev/sdb2 has unsupported feature(s): FEATURE_C12 > > e2fsck: Get a newer version of e2fsck! > > > > This has been discussed in [2] and a fix was made for use by > > Debian-based distros in [3]. Let's pick that version. > > > > Link: [1] https://gitlab.com/Linaro/trusted-reference-stack/trs/-/issues/1 > > Link: [2] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1031622 > > Link: [3] > > https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?h=debian/master&id=1181f164c48574a4813bfa203dbd7b4123154021 > > > > Binary compatibility of generated ext4 file system images is important > > so it's better to use the "debian/master" branch. > > > > Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> > > Signed-off-by: Mikko Rapeli <mikko.rapeli@linaro.org> > > --- > > meta/recipes-devtools/e2fsprogs/e2fsprogs.inc | 2 +- > > .../e2fsprogs/{e2fsprogs_1.47.0.bb => e2fsprogs_1.47.0-2.bb} | 2 +- > > 2 files changed, 2 insertions(+), 2 deletions(-) > > rename meta/recipes-devtools/e2fsprogs/{e2fsprogs_1.47.0.bb => > > e2fsprogs_1.47.0-2.bb} (99%) > > > > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > index f41a5d0b4e..2f54896e8c 100644 > > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > @@ -19,7 +19,7 @@ LIC_FILES_CHKSUM = > > "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \ > > SECTION = "base" > > DEPENDS = "util-linux attr autoconf-archive" > > > > -SRC_URI = "git:// > > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=master" > > +SRC_URI = "git:// > > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=debian/master" > > S = "${WORKDIR}/git" > > > > inherit autotools gettext texinfo pkgconfig multilib_header > > update-alternatives ptest > > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > similarity index 99% > > rename from meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > rename to meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > index 2620610903..9bf89ba0c4 100644 > > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > @@ -10,7 +10,7 @@ SRC_URI:append:class-native = " \ > > file://quiet-debugfs.patch \ > > " > > > > -SRCREV = "f4c9cc4bedacde8408edda3520a32d3842290112" > > +SRCREV = "1181f164c48574a4813bfa203dbd7b4123154021" > > UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$" > > > > EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \ > > -- > > 2.34.1 > > > > > > -=-=-=-=-=-=-=-=-=-=-=- > > Links: You receive all messages sent to this group. > > View/Reply Online (#178747): > > https://lists.openembedded.org/g/openembedded-core/message/178747 > > Mute This Topic: https://lists.openembedded.org/mt/97669707/1686489 > > Group Owner: openembedded-core+owner@lists.openembedded.org > > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > > alex.kanavin@gmail.com] > > -=-=-=-=-=-=-=-=-=-=-=- > > > >
On Fri 17. Mar 2023 at 12.01, Mikko Rapeli <mikko.rapeli@linaro.org> wrote: > Hi, > > On Fri, Mar 17, 2023 at 11:39:23AM +0100, Alexander Kanavin wrote: > > This doesn’t seem right. We should not give special privileges to tooling > > from any particular host distro. If you need to manipulate images, build > > e2fsprogs-native and run that. > > This is about ext4 images breaking compatibility with older versions of > tooling used manipulate the images. For Debian the upstream maintainers > and Debian package maintainers agreed to keep the backwards > compatibility for longer time. I think that makes sense for yocto too. > > While I agree that using e2fsprogs-native is a solution too, I also > agree that a lot of users are using non-yocto e2fsprogs when e.g. > flashing images to target HW. Breaking compatibility can quite simply be > avoided and upstream will maintain this branch. Win win from my point of > view. But then we should put e2fsprogs into buildtools-tarball(-extended). It’s not any different to providing compatible gcc, when one from the host distro is too old. Taking a custom branch creates a maintenance problem. What if it stops being maintained? Will it follow proper upstream closely? Can we ever drop this backwards compatibility? It creates a long term headache that I do not want. Alex > > Cheers, > > -Mikko > > > Alex > > > > On Fri 17. Mar 2023 at 10.09, Mikko Rapeli <mikko.rapeli@linaro.org> > wrote: > > > > > From: Jerome Forissier <jerome.forissier@linaro.org> > > > > > > When trying to use e2fsck <= 1.47.0 on the root filesystem (for > example, > > > to resize a partition after copying the image to a USB stick on a > > > computer running current Ubuntu [22.04] or Debian), an error is > > > reported: > > > > > > e2fsck 1.46.5 (30-Dec-2021) > > > /dev/sdb2 has unsupported feature(s): FEATURE_C12 > > > e2fsck: Get a newer version of e2fsck! > > > > > > This has been discussed in [2] and a fix was made for use by > > > Debian-based distros in [3]. Let's pick that version. > > > > > > Link: [1] > https://gitlab.com/Linaro/trusted-reference-stack/trs/-/issues/1 > > > Link: [2] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1031622 > > > Link: [3] > > > > https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?h=debian/master&id=1181f164c48574a4813bfa203dbd7b4123154021 > > > > > > Binary compatibility of generated ext4 file system images is important > > > so it's better to use the "debian/master" branch. > > > > > > Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> > > > Signed-off-by: Mikko Rapeli <mikko.rapeli@linaro.org> > > > --- > > > meta/recipes-devtools/e2fsprogs/e2fsprogs.inc | 2 +- > > > .../e2fsprogs/{e2fsprogs_1.47.0.bb => e2fsprogs_1.47.0-2.bb} | 2 > +- > > > 2 files changed, 2 insertions(+), 2 deletions(-) > > > rename meta/recipes-devtools/e2fsprogs/{e2fsprogs_1.47.0.bb => > > > e2fsprogs_1.47.0-2.bb} (99%) > > > > > > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > > b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > > index f41a5d0b4e..2f54896e8c 100644 > > > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc > > > @@ -19,7 +19,7 @@ LIC_FILES_CHKSUM = > > > "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \ > > > SECTION = "base" > > > DEPENDS = "util-linux attr autoconf-archive" > > > > > > -SRC_URI = "git:// > > > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=master" > > > +SRC_URI = "git:// > > > git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=debian/master" > > > S = "${WORKDIR}/git" > > > > > > inherit autotools gettext texinfo pkgconfig multilib_header > > > update-alternatives ptest > > > diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > > b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > > similarity index 99% > > > rename from meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > > rename to meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > > index 2620610903..9bf89ba0c4 100644 > > > --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb > > > +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb > > > @@ -10,7 +10,7 @@ SRC_URI:append:class-native = " \ > > > file://quiet-debugfs.patch \ > > > " > > > > > > -SRCREV = "f4c9cc4bedacde8408edda3520a32d3842290112" > > > +SRCREV = "1181f164c48574a4813bfa203dbd7b4123154021" > > > UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$" > > > > > > EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \ > > > -- > > > 2.34.1 > > > > > > > > > -=-=-=-=-=-=-=-=-=-=-=- > > > Links: You receive all messages sent to this group. > > > View/Reply Online (#178747): > > > https://lists.openembedded.org/g/openembedded-core/message/178747 > > > Mute This Topic: https://lists.openembedded.org/mt/97669707/1686489 > > > Group Owner: openembedded-core+owner@lists.openembedded.org > > > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub > [ > > > alex.kanavin@gmail.com] > > > -=-=-=-=-=-=-=-=-=-=-=- > > > > > > >
Hi, On Fri, Mar 17, 2023 at 03:25:10PM +0000, Alexander Kanavin wrote: > On Fri 17. Mar 2023 at 12.01, Mikko Rapeli <mikko.rapeli@linaro.org> wrote: > > > Hi, > > > > On Fri, Mar 17, 2023 at 11:39:23AM +0100, Alexander Kanavin wrote: > > > This doesn’t seem right. We should not give special privileges to tooling > > > from any particular host distro. If you need to manipulate images, build > > > e2fsprogs-native and run that. > > > > This is about ext4 images breaking compatibility with older versions of > > tooling used manipulate the images. For Debian the upstream maintainers > > and Debian package maintainers agreed to keep the backwards > > compatibility for longer time. I think that makes sense for yocto too. > > > > While I agree that using e2fsprogs-native is a solution too, I also > > agree that a lot of users are using non-yocto e2fsprogs when e.g. > > flashing images to target HW. Breaking compatibility can quite simply be > > avoided and upstream will maintain this branch. Win win from my point of > > view. > > But then we should put e2fsprogs into buildtools-tarball(-extended). It’s > not any different to providing compatible gcc, when one from the host > distro is too old. I think this one is a bit different. At flashing/install step people frequently manipulate rootfs images coming out of yocto builds to match what HW and various boards actually have, like extending the file system to fill full EMMC/SD cards. Like dd the .wic out of a build but extend the file system for the full disk before first boot on the system. > Taking a custom branch creates a maintenance problem. What if it stops > being maintained? Will it follow proper upstream closely? Can we ever drop > this backwards compatibility? It creates a long term headache that I do not > want. This branch is from upstream developers who are also the Debian package maintainers. Of course anything can break and no support can be guaranteed. https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?h=debian/master&id=1181f164c48574a4813bfa203dbd7b4123154021 "author Theodore Ts'o <tytso@mit.edu> 2023-03-04 22:04:29 -0500 Disable metadata_csum_seed and orphan_file by default for Debian There are a lot of debian packages that assume that mkfs.ext4 for Debian N will work on Debian N-1 (and sometimes N-2, N-3, etc.). This is a bad assumption, but it's too late to fix this for Debian Bookworm. So revert making these feature a default for now. We will enable it again post Bookworm. Signed-off-by: Theodore Ts'o <tytso@mit.edu>" That explains the timeline a bit. I think this is sensible to follow. If the branch dies and there are no more updates to CVEs etc triggers, then switching to master branch is ok. Right now the branch is actively maintained. Cheers, -Mikko
On Mon, 20 Mar 2023 at 07:15, Mikko Rapeli <mikko.rapeli@linaro.org> wrote: > > But then we should put e2fsprogs into buildtools-tarball(-extended). It’s > > not any different to providing compatible gcc, when one from the host > > distro is too old. > > I think this one is a bit different. At flashing/install step people > frequently manipulate rootfs images coming out of yocto builds to match > what HW and various boards actually have, like extending the file system > to fill full EMMC/SD cards. Like dd the .wic out of a build but extend > the file system for the full disk before first boot on the system. Sorry Mikko, I'm putting my foot down on this. Yocto does not promise that random tools 'from the host' are going to work for its artefacts, and should not start making that promise. We are not Debian, and we do not promise compatibility with Debian or anyone else beyond what is allowed in HOSTTOOLS. You can instruct developers in your organization to install the tarball and use tools from it for those manipulations. You can also just carry the needed custom patches for e2fsprogs in your builds. Alex
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc index f41a5d0b4e..2f54896e8c 100644 --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc @@ -19,7 +19,7 @@ LIC_FILES_CHKSUM = "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \ SECTION = "base" DEPENDS = "util-linux attr autoconf-archive" -SRC_URI = "git://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=master" +SRC_URI = "git://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git;branch=debian/master" S = "${WORKDIR}/git" inherit autotools gettext texinfo pkgconfig multilib_header update-alternatives ptest diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb similarity index 99% rename from meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb rename to meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb index 2620610903..9bf89ba0c4 100644 --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0.bb +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.47.0-2.bb @@ -10,7 +10,7 @@ SRC_URI:append:class-native = " \ file://quiet-debugfs.patch \ " -SRCREV = "f4c9cc4bedacde8408edda3520a32d3842290112" +SRCREV = "1181f164c48574a4813bfa203dbd7b4123154021" UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$" EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \