Skip to contentSkip to conversation

e2fsprogs: split dumpe2fs into its own package

PATCH In review André Draszik 2 participants 2 messages Dec 12, 2019 – Dec 16, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 e2fsprogs: split dumpe2fs into its own package

This is a mere 24KB (on 32bit arm), avoiding to pull in all of the remainder +300KB in small initramfs images when not needed.
Add this new package to RDEPENDS of e2fsprogs so as to not break existing users.

Also, remove a stale reference to the non-existent e2fsprogs-fsck package which was removed in 2012 from here in commit 98b1b9f047ef ("e2fsprogs: Drop fsck binary"), commit 93d647172786 in poky, and sort some of the lists alphabetically.

---
 meta/recipes-devtools/e2fsprogs/e2fsprogs.inc       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.4.bb | 7 ++++---
 2 files changed, 5 insertions(+), 4 deletions(-)
meta/recipes-devtools/e2fsprogs/e2fsprogs.inc +1 -1
index a54a11c354..009f5ed807 100644
@@ -4,9 +4,9 @@ fixing, configuring , and debugging ext2 filesystems."
 HOMEPAGE = "http://e2fsprogs.sourceforge.net/"
 
 LICENSE = "GPLv2 & LGPLv2 & BSD & MIT"
+LICENSE_e2fsprogs-dumpe2fs = "GPLv2"
 LICENSE_e2fsprogs-e2fsck = "GPLv2"
 LICENSE_e2fsprogs-mke2fs = "GPLv2"
-LICENSE_e2fsprogs-fsck = "GPLv2"
 LICENSE_e2fsprogs-tune2fs = "GPLv2"
 LICENSE_e2fsprogs-badblocks = "GPLv2"
 LIC_FILES_CHKSUM = "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.4.bb +4 -3
index ab44c28f2a..6e69eea21c 100644
@@ -82,12 +82,13 @@ do_install_append_class-target() {
 	mv ${D}${base_sbindir}/tune2fs ${D}${base_sbindir}/tune2fs.e2fsprogs
 }
 
-RDEPENDS_e2fsprogs = "e2fsprogs-badblocks"
+RDEPENDS_e2fsprogs = "e2fsprogs-badblocks e2fsprogs-dumpe2fs"
 RRECOMMENDS_e2fsprogs = "e2fsprogs-mke2fs e2fsprogs-e2fsck"
 
-PACKAGES =+ "e2fsprogs-e2fsck e2fsprogs-e2scrub e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
+PACKAGES =+ "e2fsprogs-badblocks e2fsprogs-dumpe2fs e2fsprogs-e2fsck e2fsprogs-e2scrub e2fsprogs-mke2fs e2fsprogs-resize2fs e2fsprogs-tune2fs"
 PACKAGES =+ "libcomerr libss libe2p libext2fs"
 
+FILES_e2fsprogs-dumpe2fs = "${base_sbindir}/dumpe2fs"
 FILES_e2fsprogs-resize2fs = "${base_sbindir}/resize2fs*"
 FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*"
 FILES_e2fsprogs-e2scrub = "${base_sbindir}/e2scrub*"
@@ -117,7 +118,7 @@ ALTERNATIVE_LINK_NAME[tune2fs] = "${base_sbindir}/tune2fs"
 
 RDEPENDS_e2fsprogs-e2scrub = "bash"
 RDEPENDS_${PN}-ptest += "coreutils procps bash bzip2 diffutils perl sed"
-RDEPENDS_${PN}-ptest += "e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
+RDEPENDS_${PN}-ptest += "e2fsprogs-badblocks e2fsprogs-dumpe2fs e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-resize2fs e2fsprogs-tune2fs"
 
 do_compile_ptest() {
 	oe_runmake -C ${B}/tests
Signature · 1 line
2.24.0
#1 lore raw
Quoted 5 lines · André Draszik

This is a mere 24KB (on 32bit arm), avoiding to pull in all of the remainder +300KB in small initramfs images when not needed.
Add this new package to RDEPENDS of e2fsprogs so as to not break existing users.

Between this and util-linux, there's a lot of boilerplate to split up a recipe into every smaller fragments. Should we just take this to the logical conclusion and split it per-binary?

I'm starting to wonder if we need a "split binaries" class that can just split a recipe into a package-per-binary, adding the dependencies for you.

Ross