Patchwork [3/6] package/genext2fs: add host variant

login
register
mail settings
Submitter Yann E. MORIN
Date June 3, 2013, 8:15 p.m.
Message ID <eb1ddff01f34cffea3d4556f414dda0f346ec703.1370289131.git.yann.morin.1998@free.fr>
Download mbox | patch
Permalink /patch/248407/
State Accepted
Commit d8286a993ac1738ef08a6b9aca03e629e5c9bb89
Headers show

Comments

Yann E. MORIN - June 3, 2013, 8:15 p.m.
From: "Yann E. MORIN" <yann.morin.1998@free.fr>

genext2fs is built only if the user selected an ext2 root filesystem.

However, some use-cases can't live with the full target/ dir on the
root filesystem, and requires separate partitions (eg. for /usr).
In this case, the user would not select an ext2 root fs in the
Buildrooot menu, and would only generate a tarball of the rootfs.
This tarball would then be used from a post-image script to build
the actual required FSes.

But then, genext2fs is not built, since the ext2 root FS was not
selected.

As for the other filesystem generators, provide a host variant of
genext2fs (genext2fs is already host-package aware, so only needs
adding a Kconfig entry).

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
---
 fs/ext2/Config.in                | 1 +
 package/Config.in.host           | 1 +
 package/genext2fs/Config.in.host | 9 +++++++++
 3 files changed, 11 insertions(+)
 create mode 100644 package/genext2fs/Config.in.host
Peter Korsgaard - June 3, 2013, 9:09 p.m.
>>>>> "Yann" == Yann E MORIN <yann.morin.1998@free.fr> writes:

 Yann> From: "Yann E. MORIN" <yann.morin.1998@free.fr>
 Yann> genext2fs is built only if the user selected an ext2 root filesystem.

 Yann> However, some use-cases can't live with the full target/ dir on the
 Yann> root filesystem, and requires separate partitions (eg. for /usr).
 Yann> In this case, the user would not select an ext2 root fs in the
 Yann> Buildrooot menu, and would only generate a tarball of the rootfs.
 Yann> This tarball would then be used from a post-image script to build
 Yann> the actual required FSes.

 Yann> But then, genext2fs is not built, since the ext2 root FS was not
 Yann> selected.

 Yann> As for the other filesystem generators, provide a host variant of
 Yann> genext2fs (genext2fs is already host-package aware, so only needs
 Yann> adding a Kconfig entry).

Committed, thanks.

Patch

diff --git a/fs/ext2/Config.in b/fs/ext2/Config.in
index e75ef54..c26482f 100644
--- a/fs/ext2/Config.in
+++ b/fs/ext2/Config.in
@@ -1,5 +1,6 @@ 
 config BR2_TARGET_ROOTFS_EXT2
 	bool "ext2/3/4 root filesystem"
+	select BR2_PACKAGE_HOST_GENEXT2FS
 	select BR2_PACKAGE_HOST_E2FSPROGS
 	help
 	  Build an ext2/3/4 root filesystem
diff --git a/package/Config.in.host b/package/Config.in.host
index 54178ea..5fd2570 100644
--- a/package/Config.in.host
+++ b/package/Config.in.host
@@ -3,6 +3,7 @@  menu "Host utilities"
 source "package/dfu-util/Config.in.host"
 source "package/dosfstools/Config.in.host"
 source "package/e2fsprogs/Config.in.host"
+source "package/genext2fs/Config.in.host"
 source "package/genimage/Config.in.host"
 source "package/genpart/Config.in.host"
 source "package/lpc3250loader/Config.in.host"
diff --git a/package/genext2fs/Config.in.host b/package/genext2fs/Config.in.host
new file mode 100644
index 0000000..a03e16b
--- /dev/null
+++ b/package/genext2fs/Config.in.host
@@ -0,0 +1,9 @@ 
+config BR2_PACKAGE_HOST_GENEXT2FS
+	bool "host genext2fs"
+	help
+	  genext2fs generates an ext2 filesystem as a normal (non-root)
+	  user.  It does not require you to mount the image file to
+	  copy files on it, nor does it require that you become the
+	  superuser to make device nodes.
+
+	  http://genext2fs.sourceforge.net/