All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux
@ 2017-04-22 11:59 Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net Arnout Vandecappelle
                   ` (11 more replies)
  0 siblings, 12 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

 This is v8 of the large patch sent previously by Carlos Santos, split
up into smaller bits for each individual change.

 There are also a few things I modified myself - each individual patch
contains a comment that explains what I changed. For completeness, the
diff between the end of this series and the v7 previously posted by
Carlos is below.

 I have not tested this series as extensively as Carlos, but as you can
see in the diff below there is nothing major or risky that I changed.

 Regards,
 Arnout

---
Carlos Santos (12):
  e2fsprogs: change upstream URL sf.net -> sourceforge.net
  e2fsprogs: add missing arch depends to comment
  e2fsprogs: change into menuconfig
  e2fsprogs: remove uuidgen support
  e2fsprogs: use libblkid and libuuid from util-linux for host
  e2fsprogs: let it create symlinks
  e2fsprogs: refactor to fix conflicts with busybox and util-linux
  e2fsprogs: add help text for all config options
  e2fsprogs: disable unneeded features for host
  e2fsprogs: add explicit --enable/--disable configure options
  e2fsprogs: avoid conflict with util-linux fsck wrapper
  e2fsprogs: only add -lintl for static builds

 package/e2fsprogs/Config.in      |  84 ++++++++----------------
 package/e2fsprogs/Config.in.host |   1 +
 package/e2fsprogs/e2fsprogs.mk   | 134 +++++++++++----------------------------
 3 files changed, 63 insertions(+), 156 deletions(-)
---
diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index 03a17c9dc6..819d82760c 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -3,6 +3,7 @@ menuconfig BR2_PACKAGE_E2FSPROGS
 	depends on BR2_USE_MMU # util-linux/libblkid
 	select BR2_PACKAGE_UTIL_LINUX
 	select BR2_PACKAGE_UTIL_LINUX_LIBBLKID
+	select BR2_PACKAGE_UTIL_LINUX_LIBUUID
 	help
 	  The EXT2 file system utilities.
 
@@ -16,7 +17,7 @@ menuconfig BR2_PACKAGE_E2FSPROGS
 
 	  Other programs can be selected individually.
 
-	  http://e2fsprogs.sourceforge.net/
+	  http://e2fsprogs.sourceforge.net
 
 if BR2_PACKAGE_E2FSPROGS
 
@@ -49,9 +50,6 @@ config BR2_PACKAGE_E2FSPROGS_FSCK
 	  Check and repair a Linux file system. This is a wrapper around
 	  the filesystem-specific fsck tools.
 
-comment "the fsck from util-linux has preference over this one"
-	depends on BR2_PACKAGE_UTIL_LINUX_FSCK
-
 config BR2_PACKAGE_E2FSPROGS_FUSE2FS
 	bool "fuse2fs"
 	depends on !BR2_STATIC_LIBS # libfuse
@@ -65,7 +63,6 @@ comment "fuse2fs needs a toolchain w/ threads, dynamic library"
 
 config BR2_PACKAGE_E2FSPROGS_RESIZE2FS
 	bool "resize2fs"
-	default y
 	help
 	  ext2/ext3/ext4 file system resizer
 
diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index 2a736838a9..84af7abab8 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -7,8 +7,8 @@
 E2FSPROGS_VERSION = 1.43.4
 E2FSPROGS_SOURCE = e2fsprogs-$(E2FSPROGS_VERSION).tar.xz
 E2FSPROGS_SITE = $(BR2_KERNEL_MIRROR)/linux/kernel/people/tytso/e2fsprogs/v$(E2FSPROGS_VERSION)
-E2FSPROGS_LICENSE = GPL-2.0, BSD-3-Clause (libuuid), MIT-like with advertising clause (libss and libet)
-E2FSPROGS_LICENSE_FILES = NOTICE lib/uuid/COPYING lib/ss/mit-sipb-copyright.h lib/et/internal.h
+E2FSPROGS_LICENSE = GPL-2.0, MIT-like with advertising clause (libss and libet)
+E2FSPROGS_LICENSE_FILES = NOTICE lib/ss/mit-sipb-copyright.h lib/et/internal.h
 E2FSPROGS_INSTALL_STAGING = YES
 
 # Use libblkid and libuuid from util-linux for host and target packages.
@@ -23,46 +23,43 @@ ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 E2FSPROGS_DEPENDENCIES += busybox
 endif
 
-ifeq ($(BR2_PACKAGE_E2FSPROGS_FUSE2FS),y)
-E2FSPROGS_DEPENDENCIES += libfuse
-endif
-
 # e4defrag doesn't build on older systems like RHEL5.x, and we don't
 # need it on the host anyway.
 # Disable fuse2fs as well to avoid carrying over deps, and it's unused
-# Set the binary directories to "$(HOST_DIR)/bin" and "$(HOST_DIR)/sbin"
-# to match the target paths (the $(HOST_DIR) prefix is required because
-# passing DESTDIR=$(HOST_DIR) in the install command does not work).
 HOST_E2FSPROGS_CONF_OPTS = \
 	--disable-defrag \
+	--disable-e2initrd-helper \
 	--disable-fuse2fs \
-	--bindir=$(HOST_DIR)/bin \
-	--sbindir=$(HOST_DIR)/sbin \
-	--enable-symlink-install \
 	--disable-libblkid \
 	--disable-libuuid \
-	--disable-e2initrd-helper \
-	--disable-testio-debug \
-	--disable-rpath
+	--enable-symlink-install \
+	--disable-testio-debug
 
 # Set the binary directories to "/bin" and "/sbin" to override programs
 # installed by busybox.
 E2FSPROGS_CONF_OPTS = \
+	--bindir=/bin \
+	--sbindir=/sbin \
 	$(if $(BR2_STATIC_LIBS),--disable-elf-shlibs,--enable-elf-shlibs) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_DEBUGFS),--enable-debugfs,--disable-debugfs) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_E2IMAGE),--enable-imager,--disable-imager) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_E4DEFRAG),--enable-defrag,--disable-defrag) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_FSCK),--enable-fsck,--disable-fsck) \
-	$(if $(BR2_PACKAGE_E2FSPROGS_FUSE2FS),--enable-fuse2fs,--disable-fuse2fs) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_RESIZE2FS),--enable-resizer,--disable-resizer) \
-	--bindir=/bin \
-	--sbindir=/sbin \
-	--enable-symlink-install \
+	--disable-uuidd \
 	--disable-libblkid \
 	--disable-libuuid \
 	--disable-e2initrd-helper \
 	--disable-testio-debug \
-	--disable-rpath
+	--disable-rpath \
+	--enable-symlink-install
+
+ifeq ($(BR2_PACKAGE_E2FSPROGS_FUSE2FS),y)
+E2FSPROGS_CONF_OPTS += --enable-fuse2fs
+E2FSPROGS_DEPENDENCIES += libfuse
+else
+E2FSPROGS_CONF_OPTS += --disable-fuse2fs
+endif
 
 ifeq ($(BR2_nios2),y)
 E2FSPROGS_CONF_ENV += ac_cv_func_fallocate=no

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:28   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment Arnout Vandecappelle
                   ` (10 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

sf.net redirects to sourceforge.net, so directly use that as upstream
URL. Config.in.host already uses that URL.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout: remove trailing /]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index d1914a9953..da6aacf2fd 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -7,7 +7,7 @@ config BR2_PACKAGE_E2FSPROGS
 	help
 	  The EXT2 file system utilities.
 
-	  http://e2fsprogs.sf.net
+	  http://e2fsprogs.sourceforge.net
 
 if BR2_PACKAGE_E2FSPROGS
 
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:28   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig Arnout Vandecappelle
                   ` (9 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index da6aacf2fd..c83f84530d 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -51,6 +51,7 @@ config BR2_PACKAGE_E2FSPROGS_E4DEFRAG
 	depends on !BR2_TOOLCHAIN_USES_UCLIBC # sync_file_range not impl
 
 comment "e4defrag needs a glibc or musl toolchain"
+	depends on !BR2_nios2
 	depends on BR2_TOOLCHAIN_USES_UCLIBC
 
 config BR2_PACKAGE_E2FSPROGS_FILEFRAG
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:28   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support Arnout Vandecappelle
                   ` (8 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

We decided some time ago that config entries with 5 or more suboptions
should be turned into a menuconfig. e2fsprogs has many more than that.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index c83f84530d..055ad5067f 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -1,4 +1,4 @@
-config BR2_PACKAGE_E2FSPROGS
+menuconfig BR2_PACKAGE_E2FSPROGS
 	bool "e2fsprogs"
 	depends on BR2_USE_MMU # util-linux/libblkid
 	select BR2_PACKAGE_UTIL_LINUX
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (2 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:29   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host Arnout Vandecappelle
                   ` (7 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

In fact, uuidgen was never built because we pass --disable-libuuid. So
the option was a NOP.

Remove the license info for libuuid.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout:
 - do not remove --disable-uuidd - even though that is implied by
   --disable-libuuid, it's better to be explicit about it;
 - remove license info of libuuid]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in    | 7 +++----
 package/e2fsprogs/e2fsprogs.mk | 5 ++---
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index 055ad5067f..79b77eac4c 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -7,6 +7,9 @@ menuconfig BR2_PACKAGE_E2FSPROGS
 	help
 	  The EXT2 file system utilities.
 
+	  The uuid utilities (uuidd, uuidgen) are not built. Use the
+	  ones from util-linux, instead.
+
 	  http://e2fsprogs.sourceforge.net
 
 if BR2_PACKAGE_E2FSPROGS
@@ -95,8 +98,4 @@ config BR2_PACKAGE_E2FSPROGS_TUNE2FS
 	default y
 	select BR2_PACKAGE_E2FSPROGS_E2LABEL
 
-config BR2_PACKAGE_E2FSPROGS_UUIDGEN
-	bool "uuidgen"
-	default y
-
 endif
diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index 3f235c5372..896f01414d 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -7,8 +7,8 @@
 E2FSPROGS_VERSION = 1.43.4
 E2FSPROGS_SOURCE = e2fsprogs-$(E2FSPROGS_VERSION).tar.xz
 E2FSPROGS_SITE = $(BR2_KERNEL_MIRROR)/linux/kernel/people/tytso/e2fsprogs/v$(E2FSPROGS_VERSION)
-E2FSPROGS_LICENSE = GPL-2.0, BSD-3-Clause (libuuid), MIT-like with advertising clause (libss and libet)
-E2FSPROGS_LICENSE_FILES = NOTICE lib/uuid/COPYING lib/ss/mit-sipb-copyright.h lib/et/internal.h
+E2FSPROGS_LICENSE = GPL-2.0, MIT-like with advertising clause (libss and libet)
+E2FSPROGS_LICENSE_FILES = NOTICE lib/ss/mit-sipb-copyright.h lib/et/internal.h
 E2FSPROGS_INSTALL_STAGING = YES
 E2FSPROGS_DEPENDENCIES = host-pkgconf util-linux
 # we don't have a host-util-linux
@@ -91,7 +91,6 @@ E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_LOGSAVE) += usr/sbin/logsave
 E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_LSATTR) += usr/bin/lsattr
 E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKE2FS) += usr/sbin/mke2fs
 E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND) += usr/sbin/mklost+found
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_UUIDGEN) += usr/bin/uuidgen
 
 # files to remove
 E2FSPROGS_TXTTARGETS_ = \
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (3 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:30   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks Arnout Vandecappelle
                   ` (6 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

We have a host-util-linux, so we can use it to provide libblkid and
libuuid. This makes it consistent with the target package.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in.host |  1 +
 package/e2fsprogs/e2fsprogs.mk   | 13 ++++++++++---
 2 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/package/e2fsprogs/Config.in.host b/package/e2fsprogs/Config.in.host
index de9148e31d..7591bbcb7e 100644
--- a/package/e2fsprogs/Config.in.host
+++ b/package/e2fsprogs/Config.in.host
@@ -1,5 +1,6 @@
 config BR2_PACKAGE_HOST_E2FSPROGS
 	bool "host e2fsprogs"
+	select BR2_PACKAGE_HOST_UTIL_LINUX
 	help
 	  The EXT2/3/4 file system utilities.
 
diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index 896f01414d..5231a97f9c 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -10,14 +10,21 @@ E2FSPROGS_SITE = $(BR2_KERNEL_MIRROR)/linux/kernel/people/tytso/e2fsprogs/v$(E2F
 E2FSPROGS_LICENSE = GPL-2.0, MIT-like with advertising clause (libss and libet)
 E2FSPROGS_LICENSE_FILES = NOTICE lib/ss/mit-sipb-copyright.h lib/et/internal.h
 E2FSPROGS_INSTALL_STAGING = YES
+
+# Use libblkid and libuuid from util-linux for host and target packages.
+# This prevents overriding them with e2fsprogs' ones, which may cause
+# problems for other packages.
 E2FSPROGS_DEPENDENCIES = host-pkgconf util-linux
-# we don't have a host-util-linux
-HOST_E2FSPROGS_DEPENDENCIES = host-pkgconf
+HOST_E2FSPROGS_DEPENDENCIES = host-pkgconf host-util-linux
 
 # e4defrag doesn't build on older systems like RHEL5.x, and we don't
 # need it on the host anyway.
 # Disable fuse2fs as well to avoid carrying over deps, and it's unused
-HOST_E2FSPROGS_CONF_OPTS += --disable-defrag --disable-fuse2fs
+HOST_E2FSPROGS_CONF_OPTS = \
+	--disable-defrag \
+	--disable-fuse2fs \
+	--disable-libblkid \
+	--disable-libuuid
 
 E2FSPROGS_CONF_OPTS = \
 	$(if $(BR2_STATIC_LIBS),,--enable-elf-shlibs) \
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (4 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 12:49   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (5 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

We have post-install hooks to create the symlinks mkfs.ext2 -> mke2fs
etc. However, the e2fsprogs build system creates those symlinks itself.
So just rely on that.

fsck.ext4dev and mkfs.ext4dev were dropped in version 1.43.4.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout: keep configure options more or less alphabetical]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/e2fsprogs.mk | 45 ++++--------------------------------------
 1 file changed, 4 insertions(+), 41 deletions(-)

diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index 5231a97f9c..d9efb00a2a 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -24,7 +24,8 @@ HOST_E2FSPROGS_CONF_OPTS = \
 	--disable-defrag \
 	--disable-fuse2fs \
 	--disable-libblkid \
-	--disable-libuuid
+	--disable-libuuid \
+	--enable-symlink-install
 
 E2FSPROGS_CONF_OPTS = \
 	$(if $(BR2_STATIC_LIBS),,--enable-elf-shlibs) \
@@ -38,7 +39,8 @@ E2FSPROGS_CONF_OPTS = \
 	--enable-fsck \
 	--disable-e2initrd-helper \
 	--disable-testio-debug \
-	--disable-rpath
+	--disable-rpath \
+	--enable-symlink-install
 
 ifeq ($(BR2_PACKAGE_E2FSPROGS_FUSE2FS),y)
 E2FSPROGS_CONF_OPTS += --enable-fuse2fs
@@ -99,43 +101,12 @@ E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_LSATTR) += usr/bin/lsattr
 E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKE2FS) += usr/sbin/mke2fs
 E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND) += usr/sbin/mklost+found
 
-# files to remove
-E2FSPROGS_TXTTARGETS_ = \
-	usr/sbin/mkfs.ext[234] \
-	usr/sbin/mkfs.ext4dev \
-	usr/sbin/fsck.ext[234] \
-	usr/sbin/fsck.ext4dev \
-	usr/sbin/tune2fs
-
 define E2FSPROGS_TARGET_REMOVE_UNNEEDED
 	rm -f $(addprefix $(TARGET_DIR)/, $(E2FSPROGS_BINTARGETS_))
-	rm -f $(addprefix $(TARGET_DIR)/, $(E2FSPROGS_TXTTARGETS_))
 endef
 
 E2FSPROGS_POST_INSTALL_TARGET_HOOKS += E2FSPROGS_TARGET_REMOVE_UNNEEDED
 
-define E2FSPROGS_TARGET_MKE2FS_SYMLINKS
-	ln -sf mke2fs $(TARGET_DIR)/usr/sbin/mkfs.ext2
-	ln -sf mke2fs $(TARGET_DIR)/usr/sbin/mkfs.ext3
-	ln -sf mke2fs $(TARGET_DIR)/usr/sbin/mkfs.ext4
-	ln -sf mke2fs $(TARGET_DIR)/usr/sbin/mkfs.ext4dev
-endef
-
-ifeq ($(BR2_PACKAGE_E2FSPROGS_MKE2FS),y)
-E2FSPROGS_POST_INSTALL_TARGET_HOOKS += E2FSPROGS_TARGET_MKE2FS_SYMLINKS
-endif
-
-define E2FSPROGS_TARGET_E2FSCK_SYMLINKS
-	ln -sf e2fsck $(TARGET_DIR)/usr/sbin/fsck.ext2
-	ln -sf e2fsck $(TARGET_DIR)/usr/sbin/fsck.ext3
-	ln -sf e2fsck $(TARGET_DIR)/usr/sbin/fsck.ext4
-	ln -sf e2fsck $(TARGET_DIR)/usr/sbin/fsck.ext4dev
-endef
-
-ifeq ($(BR2_PACKAGE_E2FSPROGS_E2FSCK),y)
-E2FSPROGS_POST_INSTALL_TARGET_HOOKS += E2FSPROGS_TARGET_E2FSCK_SYMLINKS
-endif
-
 # If BusyBox is included, its configuration may supply its own variant
 # of ext2-related tools. Since Buildroot desires having full blown
 # variants take precedence (in this case, e2fsprogs), we want to remove
@@ -159,13 +130,5 @@ endef
 E2FSPROGS_PRE_INSTALL_TARGET_HOOKS += E2FSPROGS_REMOVE_BUSYBOX_APPLETS
 endif
 
-define E2FSPROGS_TARGET_TUNE2FS_SYMLINK
-	ln -sf e2label $(TARGET_DIR)/usr/sbin/tune2fs
-endef
-
-ifeq ($(BR2_PACKAGE_E2FSPROGS_TUNE2FS),y)
-E2FSPROGS_POST_INSTALL_TARGET_HOOKS += E2FSPROGS_TARGET_TUNE2FS_SYMLINK
-endif
-
 $(eval $(autotools-package))
 $(eval $(host-autotools-package))
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (5 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 13:03   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 08/12] e2fsprogs: add help text for all config options Arnout Vandecappelle
                   ` (4 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

So far we attempted to solve the conflicts between busybox and e2fsprogs
by removing busybox programs from /bin and /sbin, leaving the e2fsprogs
ones at /usr/bin and /usr/sbin. This fails with BR2_ROOTFS_MERGED_USR=y,
leading to situations like the one described in bug 9436.

We could provide a better solution by means of a fine-grained selection
of programs, like util-linux does, but this would require big changes in
e2fsprogs. So instead of resorting to dirty tricks we switch to a more
pragmatic approach:

- Drop all configs to select/deselect utilities without corresponding
  enable/disable options to the configure script. In other words, we
  always install the basic set of utilities.

- fsck has a configure option, so use it. Note that --enable-fsck is
  only about the wrapper, not about e2fsck.

- Install e2fsprogs utilities at /bin and /sbin, overriding the ones
  eventually installed by busybox.

Notice that these changes do exactly the opposite of what is requested
in bug 9436. On the other hand the policy for e2fsprogs becomes coherent
with the one for util-linux: busybox never wins.

Fixes:
  https://bugs.busybox.net/show_bug.cgi?id=9436 (no fix, in fact)

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout:
 - don't add 'default y' to resize2fs;
 - don't install the host package in /bin instead of /usr/bin - we
   install everything under /usr (until /usr will be removed, soon)]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
Splitting up the change of installation paths from the removal of some
enable/disable options is slightly more involved, so I chose to keep
these two changes in a single commit. -- Arnout
---
 package/e2fsprogs/Config.in    | 60 +++++-------------------------------------
 package/e2fsprogs/e2fsprogs.mk | 57 ++++++++-------------------------------
 2 files changed, 18 insertions(+), 99 deletions(-)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index 79b77eac4c..676327dc2f 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -7,47 +7,26 @@ menuconfig BR2_PACKAGE_E2FSPROGS
 	help
 	  The EXT2 file system utilities.
 
+	  The following programs are always built and installed:
+	  badblocks chattr debugfs dumpe2fs e2freefrag e2fsck e2image
+	  e2undo e4crypt e4defrag filefrag fsck fuse2fs logsave lsattr
+	  mke2fs mklost+found resize2fs tune2fs
+
 	  The uuid utilities (uuidd, uuidgen) are not built. Use the
 	  ones from util-linux, instead.
 
+	  Other programs can be selected individually.
+
 	  http://e2fsprogs.sourceforge.net
 
 if BR2_PACKAGE_E2FSPROGS
 
-config BR2_PACKAGE_E2FSPROGS_BADBLOCKS
-	bool "badblocks"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_CHATTR
-	bool "chattr"
-	default y
-
 config BR2_PACKAGE_E2FSPROGS_DEBUGFS
 	bool "debugfs"
 
-config BR2_PACKAGE_E2FSPROGS_DUMPE2FS
-	bool "dumpe2fs"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_E2FREEFRAG
-	bool "e2freefrag"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_E2FSCK
-	bool "e2fsck"
-	default y
-
 config BR2_PACKAGE_E2FSPROGS_E2IMAGE
 	bool "e2image"
 
-config BR2_PACKAGE_E2FSPROGS_E2LABEL
-	bool "e2label"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_E2UNDO
-	bool "e2undo"
-	default y
-
 config BR2_PACKAGE_E2FSPROGS_E4DEFRAG
 	bool "e4defrag"
 	depends on !BR2_nios2 # fallocate not implemented
@@ -57,10 +36,6 @@ comment "e4defrag needs a glibc or musl toolchain"
 	depends on !BR2_nios2
 	depends on BR2_TOOLCHAIN_USES_UCLIBC
 
-config BR2_PACKAGE_E2FSPROGS_FILEFRAG
-	bool "filefrag"
-	default y
-
 config BR2_PACKAGE_E2FSPROGS_FSCK
 	bool "fsck"
 	default y
@@ -74,28 +49,7 @@ config BR2_PACKAGE_E2FSPROGS_FUSE2FS
 comment "fuse2fs needs a toolchain w/ threads, dynamic library"
 	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS
 
-config BR2_PACKAGE_E2FSPROGS_LOGSAVE
-	bool "logsave"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_LSATTR
-	bool "lsattr"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_MKE2FS
-	bool "mke2fs"
-	default y
-
-config BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND
-	bool "mklost+found"
-	default y
-
 config BR2_PACKAGE_E2FSPROGS_RESIZE2FS
 	bool "resize2fs"
 
-config BR2_PACKAGE_E2FSPROGS_TUNE2FS
-	bool "tune2fs"
-	default y
-	select BR2_PACKAGE_E2FSPROGS_E2LABEL
-
 endif
diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index d9efb00a2a..e0a7fa9354 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -17,6 +17,12 @@ E2FSPROGS_INSTALL_STAGING = YES
 E2FSPROGS_DEPENDENCIES = host-pkgconf util-linux
 HOST_E2FSPROGS_DEPENDENCIES = host-pkgconf host-util-linux
 
+# If both e2fsprogs and busybox are selected, make certain e2fsprogs
+# wins the fight over who gets to have their utils actually installed
+ifeq ($(BR2_PACKAGE_BUSYBOX),y)
+E2FSPROGS_DEPENDENCIES += busybox
+endif
+
 # e4defrag doesn't build on older systems like RHEL5.x, and we don't
 # need it on the host anyway.
 # Disable fuse2fs as well to avoid carrying over deps, and it's unused
@@ -27,16 +33,20 @@ HOST_E2FSPROGS_CONF_OPTS = \
 	--disable-libuuid \
 	--enable-symlink-install
 
+# Set the binary directories to "/bin" and "/sbin" to override programs
+# installed by busybox.
 E2FSPROGS_CONF_OPTS = \
+	--bindir=/bin \
+	--sbindir=/sbin \
 	$(if $(BR2_STATIC_LIBS),,--enable-elf-shlibs) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_DEBUGFS),,--disable-debugfs) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_E2IMAGE),,--disable-imager) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_E4DEFRAG),,--disable-defrag) \
+	$(if $(BR2_PACKAGE_E2FSPROGS_FSCK),--enable-fsck,--disable-fsck) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_RESIZE2FS),,--disable-resizer) \
 	--disable-uuidd \
 	--disable-libblkid \
 	--disable-libuuid \
-	--enable-fsck \
 	--disable-e2initrd-helper \
 	--disable-testio-debug \
 	--disable-rpath \
@@ -85,50 +95,5 @@ define HOST_E2FSPROGS_INSTALL_CMDS
 	$(HOST_MAKE_ENV) $(MAKE) -C $(@D) install install-libs
 endef
 
-# binaries to keep or remove
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_BADBLOCKS) += usr/sbin/badblocks
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_CHATTR) += usr/bin/chattr
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_DUMPE2FS) += usr/sbin/dumpe2fs
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_E2FREEFRAG) += usr/sbin/e2freefrag
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_E2FSCK) += usr/sbin/e2fsck
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_E2LABEL) += usr/sbin/e2label
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_E2UNDO) += usr/sbin/e2undo
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_E4DEFRAG) += usr/sbin/e4defrag
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_FILEFRAG) += usr/sbin/filefrag
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_FSCK) += usr/sbin/fsck
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_LOGSAVE) += usr/sbin/logsave
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_LSATTR) += usr/bin/lsattr
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKE2FS) += usr/sbin/mke2fs
-E2FSPROGS_BINTARGETS_$(BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND) += usr/sbin/mklost+found
-
-define E2FSPROGS_TARGET_REMOVE_UNNEEDED
-	rm -f $(addprefix $(TARGET_DIR)/, $(E2FSPROGS_BINTARGETS_))
-endef
-
-E2FSPROGS_POST_INSTALL_TARGET_HOOKS += E2FSPROGS_TARGET_REMOVE_UNNEEDED
-
-# If BusyBox is included, its configuration may supply its own variant
-# of ext2-related tools. Since Buildroot desires having full blown
-# variants take precedence (in this case, e2fsprogs), we want to remove
-# BusyBox's variant of e2fsprogs provided binaries. e2fsprogs targets
-# /usr/{bin,sbin} where BusyBox targets /{bin,sbin}. We will attempt to
-# remove BusyBox-generated ext2-related tools from /{bin,sbin}. We need
-# to do this in the pre-install stage to ensure we do not accidentally
-# remove e2fsprogs's binaries in usr-merged environments (ie. if they
-# are removed, they would be re-installed in this package's install
-# stage).
-ifeq ($(BR2_PACKAGE_BUSYBOX),y)
-E2FSPROGS_DEPENDENCIES += busybox
-
-define E2FSPROGS_REMOVE_BUSYBOX_APPLETS
-	$(RM) -f $(TARGET_DIR)/bin/chattr
-	$(RM) -f $(TARGET_DIR)/bin/lsattr
-	$(RM) -f $(TARGET_DIR)/sbin/fsck
-	$(RM) -f $(TARGET_DIR)/sbin/tune2fs
-	$(RM) -f $(TARGET_DIR)/sbin/e2label
-endef
-E2FSPROGS_PRE_INSTALL_TARGET_HOOKS += E2FSPROGS_REMOVE_BUSYBOX_APPLETS
-endif
-
 $(eval $(autotools-package))
 $(eval $(host-autotools-package))
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 08/12] e2fsprogs: add help text for all config options
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (6 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host Arnout Vandecappelle
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index 676327dc2f..23c4db5329 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -23,14 +23,20 @@ if BR2_PACKAGE_E2FSPROGS
 
 config BR2_PACKAGE_E2FSPROGS_DEBUGFS
 	bool "debugfs"
+	help
+	  ext2/ext3/ext4 file system debugger
 
 config BR2_PACKAGE_E2FSPROGS_E2IMAGE
 	bool "e2image"
+	help
+	  Save critical ext2/ext3/ext4 filesystem metadata to a file
 
 config BR2_PACKAGE_E2FSPROGS_E4DEFRAG
 	bool "e4defrag"
 	depends on !BR2_nios2 # fallocate not implemented
 	depends on !BR2_TOOLCHAIN_USES_UCLIBC # sync_file_range not impl
+	help
+	  Online defragmenter for ext4 filesystem
 
 comment "e4defrag needs a glibc or musl toolchain"
 	depends on !BR2_nios2
@@ -39,17 +45,24 @@ comment "e4defrag needs a glibc or musl toolchain"
 config BR2_PACKAGE_E2FSPROGS_FSCK
 	bool "fsck"
 	default y
+	help
+	  Check and repair a Linux file system. This is a wrapper around
+	  the filesystem-specific fsck tools.
 
 config BR2_PACKAGE_E2FSPROGS_FUSE2FS
 	bool "fuse2fs"
 	depends on !BR2_STATIC_LIBS # libfuse
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libfuse
 	select BR2_PACKAGE_LIBFUSE
+	help
+	  FUSE file system client for ext2/ext3/ext4 file systems
 
 comment "fuse2fs needs a toolchain w/ threads, dynamic library"
 	depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS
 
 config BR2_PACKAGE_E2FSPROGS_RESIZE2FS
 	bool "resize2fs"
+	help
+	  ext2/ext3/ext4 file system resizer
 
 endif
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (7 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 08/12] e2fsprogs: add help text for all config options Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 13:03   ` Thomas Petazzoni
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 10/12] e2fsprogs: add explicit --enable/--disable configure options Arnout Vandecappelle
                   ` (2 subsequent siblings)
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

We don't need e2initrd_helper or the test I/O manager for the host, just
like we don't need it for the target.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout: don't add --disable-rpath, since we *do* need rpath for the
 target; otherwise we have to explicitly pass LD_LIBRARY_PATH to be
 able to run tools linked with util-linux' libuuid/libblkid]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/e2fsprogs.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index e0a7fa9354..632fdc250c 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -28,10 +28,12 @@ endif
 # Disable fuse2fs as well to avoid carrying over deps, and it's unused
 HOST_E2FSPROGS_CONF_OPTS = \
 	--disable-defrag \
+	--disable-e2initrd-helper \
 	--disable-fuse2fs \
 	--disable-libblkid \
 	--disable-libuuid \
-	--enable-symlink-install
+	--enable-symlink-install \
+	--disable-testio-debug
 
 # Set the binary directories to "/bin" and "/sbin" to override programs
 # installed by busybox.
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 10/12] e2fsprogs: add explicit --enable/--disable configure options
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (8 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 11/12] e2fsprogs: avoid conflict with util-linux fsck wrapper Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds Arnout Vandecappelle
  11 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
[Arnout: don't split up the fuse2fs CONF_OPTS and DEPENDENCIES
 handling]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/e2fsprogs.mk | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index 632fdc250c..a60c69b395 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -40,12 +40,12 @@ HOST_E2FSPROGS_CONF_OPTS = \
 E2FSPROGS_CONF_OPTS = \
 	--bindir=/bin \
 	--sbindir=/sbin \
-	$(if $(BR2_STATIC_LIBS),,--enable-elf-shlibs) \
-	$(if $(BR2_PACKAGE_E2FSPROGS_DEBUGFS),,--disable-debugfs) \
-	$(if $(BR2_PACKAGE_E2FSPROGS_E2IMAGE),,--disable-imager) \
-	$(if $(BR2_PACKAGE_E2FSPROGS_E4DEFRAG),,--disable-defrag) \
+	$(if $(BR2_STATIC_LIBS),--disable-elf-shlibs,--enable-elf-shlibs) \
+	$(if $(BR2_PACKAGE_E2FSPROGS_DEBUGFS),--enable-debugfs,--disable-debugfs) \
+	$(if $(BR2_PACKAGE_E2FSPROGS_E2IMAGE),--enable-imager,--disable-imager) \
+	$(if $(BR2_PACKAGE_E2FSPROGS_E4DEFRAG),--enable-defrag,--disable-defrag) \
 	$(if $(BR2_PACKAGE_E2FSPROGS_FSCK),--enable-fsck,--disable-fsck) \
-	$(if $(BR2_PACKAGE_E2FSPROGS_RESIZE2FS),,--disable-resizer) \
+	$(if $(BR2_PACKAGE_E2FSPROGS_RESIZE2FS),--enable-resizer,--disable-resizer) \
 	--disable-uuidd \
 	--disable-libblkid \
 	--disable-libuuid \
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 11/12] e2fsprogs: avoid conflict with util-linux fsck wrapper
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (9 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 10/12] e2fsprogs: add explicit --enable/--disable configure options Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds Arnout Vandecappelle
  11 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

The fsck wrapper from util-linux is better maintained, so it should be
preferred. In particular, systemd relies on features in the util-linux
fsck wrapper that don't exist in the e2fsprogs one. However, since
e2fsprogs depends on util-linux, the one from e2fsprogs currently has
precedence. So in order to have e2fsck from e2fsprogs and the fsck
wrapper from util-linux, we disable e2fsprogs' fsck if the one from
util-linux is selected.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
CC: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
[Arnout: don't add comment]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/Config.in | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/e2fsprogs/Config.in b/package/e2fsprogs/Config.in
index 23c4db5329..b3d12b4a63 100644
--- a/package/e2fsprogs/Config.in
+++ b/package/e2fsprogs/Config.in
@@ -45,6 +45,7 @@ comment "e4defrag needs a glibc or musl toolchain"
 config BR2_PACKAGE_E2FSPROGS_FSCK
 	bool "fsck"
 	default y
+	depends on !BR2_PACKAGE_UTIL_LINUX_FSCK
 	help
 	  Check and repair a Linux file system. This is a wrapper around
 	  the filesystem-specific fsck tools.
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds
  2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
                   ` (10 preceding siblings ...)
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 11/12] e2fsprogs: avoid conflict with util-linux fsck wrapper Arnout Vandecappelle
@ 2017-04-22 11:59 ` Arnout Vandecappelle
  2017-04-22 13:04   ` Thomas Petazzoni
  11 siblings, 1 reply; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 11:59 UTC (permalink / raw)
  To: buildroot

From: Carlos Santos <casantos@datacom.ind.br>

For dynamic library builds, it's not needed to pass it explicitly.

Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
 package/e2fsprogs/e2fsprogs.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
index a60c69b395..84af7abab8 100644
--- a/package/e2fsprogs/e2fsprogs.mk
+++ b/package/e2fsprogs/e2fsprogs.mk
@@ -77,17 +77,19 @@ HOST_E2FSPROGS_CONF_ENV += \
 	ac_cv_header_magic_h=no \
 	ac_cv_lib_magic_magic_file=no
 
-ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
+ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE)$(BR2_STATIC_LIBS),yy)
 # util-linux libuuid pulls in libintl if needed, so ensure we also
 # link against it, otherwise static linking fails
 E2FSPROGS_CONF_ENV += LIBS=-lintl
 endif
 
 E2FSPROGS_MAKE_OPTS = LDCONFIG=true
+
 E2FSPROGS_INSTALL_STAGING_OPTS = \
 	DESTDIR=$(STAGING_DIR) \
 	LDCONFIG=true \
 	install-libs
+
 E2FSPROGS_INSTALL_TARGET_OPTS = \
 	DESTDIR=$(TARGET_DIR) \
 	LDCONFIG=true \
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net Arnout Vandecappelle
@ 2017-04-22 12:28   ` Thomas Petazzoni
  0 siblings, 0 replies; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:28 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:44 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> sf.net redirects to sourceforge.net, so directly use that as upstream
> URL. Config.in.host already uses that URL.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> [Arnout: remove trailing /]
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  package/e2fsprogs/Config.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment Arnout Vandecappelle
@ 2017-04-22 12:28   ` Thomas Petazzoni
  0 siblings, 0 replies; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:28 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:45 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  package/e2fsprogs/Config.in | 1 +
>  1 file changed, 1 insertion(+)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig Arnout Vandecappelle
@ 2017-04-22 12:28   ` Thomas Petazzoni
  0 siblings, 0 replies; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:28 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:46 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> We decided some time ago that config entries with 5 or more suboptions
> should be turned into a menuconfig. e2fsprogs has many more than that.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  package/e2fsprogs/Config.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support Arnout Vandecappelle
@ 2017-04-22 12:29   ` Thomas Petazzoni
  2017-04-22 21:57     ` Arnout Vandecappelle
  0 siblings, 1 reply; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:29 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:47 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> In fact, uuidgen was never built because we pass --disable-libuuid. So
> the option was a NOP.
> 
> Remove the license info for libuuid.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> [Arnout:
>  - do not remove --disable-uuidd - even though that is implied by
>    --disable-libuuid, it's better to be explicit about it;
>  - remove license info of libuuid]
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  package/e2fsprogs/Config.in    | 7 +++----
>  package/e2fsprogs/e2fsprogs.mk | 5 ++---
>  2 files changed, 5 insertions(+), 7 deletions(-)

Applied to master, thanks. I suppose the logic for not having a
Config.in.legacy entry is that the tool had never been installed
anyway, so nobody could have been relying on this option to install
uuidgen. Am I right?

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host Arnout Vandecappelle
@ 2017-04-22 12:30   ` Thomas Petazzoni
  0 siblings, 0 replies; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:30 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:48 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> We have a host-util-linux, so we can use it to provide libblkid and
> libuuid. This makes it consistent with the target package.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  package/e2fsprogs/Config.in.host |  1 +
>  package/e2fsprogs/e2fsprogs.mk   | 13 ++++++++++---
>  2 files changed, 11 insertions(+), 3 deletions(-)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks Arnout Vandecappelle
@ 2017-04-22 12:49   ` Thomas Petazzoni
  2017-04-22 22:32     ` Arnout Vandecappelle
  0 siblings, 1 reply; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 12:49 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:49 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> We have post-install hooks to create the symlinks mkfs.ext2 -> mke2fs
> etc. However, the e2fsprogs build system creates those symlinks itself.
> So just rely on that.
> 
> fsck.ext4dev and mkfs.ext4dev were dropped in version 1.43.4.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> [Arnout: keep configure options more or less alphabetical]
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

This would definitely be a very very nice cleanup, but it doesn't seem
to work. I've tried to build the following configuration:

BR2_arm=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_CUSTOM=y
BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y
BR2_TOOLCHAIN_EXTERNAL_URL="http://autobuild.buildroot.org/toolchains/tarballs/br-arm-full-2017.02-756-gae15148.tar.bz2"
BR2_TOOLCHAIN_EXTERNAL_GCC_4_8=y
BR2_TOOLCHAIN_EXTERNAL_HEADERS_3_10=y
BR2_TOOLCHAIN_EXTERNAL_LOCALE=y
# BR2_TOOLCHAIN_EXTERNAL_HAS_THREADS_DEBUG is not set
BR2_TOOLCHAIN_EXTERNAL_CXX=y
BR2_INIT_NONE=y
BR2_SYSTEM_BIN_SH_NONE=y
# BR2_PACKAGE_BUSYBOX is not set
BR2_PACKAGE_E2FSPROGS=y
# BR2_PACKAGE_E2FSPROGS_BADBLOCKS is not set
# BR2_PACKAGE_E2FSPROGS_CHATTR is not set
# BR2_PACKAGE_E2FSPROGS_DUMPE2FS is not set
# BR2_PACKAGE_E2FSPROGS_E2FREEFRAG is not set
# BR2_PACKAGE_E2FSPROGS_E2FSCK is not set
# BR2_PACKAGE_E2FSPROGS_E2LABEL is not set
# BR2_PACKAGE_E2FSPROGS_E2UNDO is not set
# BR2_PACKAGE_E2FSPROGS_FILEFRAG is not set
# BR2_PACKAGE_E2FSPROGS_LOGSAVE is not set
# BR2_PACKAGE_E2FSPROGS_LSATTR is not set
# BR2_PACKAGE_E2FSPROGS_MKE2FS is not set
# BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND is not set
# BR2_PACKAGE_E2FSPROGS_TUNE2FS is not set
# BR2_TARGET_ROOTFS_TAR is not set

and I get numerous broken symbolic links:

thomas at skate:~/projets/buildroot (master)$ ls -l output/target/usr/sbin/
total 116
-rwxr-xr-x 1 thomas thomas 13976 avril 22 14:38 e4crypt
-rwxr-xr-x 1 thomas thomas 18180 avril 22 14:38 fsck
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext2 -> e2fsck
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext3 -> e2fsck
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext4 -> e2fsck
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext2 -> mke2fs
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext3 -> mke2fs
lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext4 -> mke2fs
-rwxr-xr-x 1 thomas thomas 80996 avril 22 14:38 tune2fs

So basically: all the symbolic links are broken. It raises a few
questions:

 - What is the difference between the fsck option and the e2fsck option?

 - Why is this creating the symbolic links even for programs not
   installed (e2fsck and mke2fs in our case) ?

 - Why is tune2fs built/installed even if it wasn't enabled in my
   configuration?

 - Why is e4crypt built/installed?

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
@ 2017-04-22 13:03   ` Thomas Petazzoni
  2017-04-22 22:34     ` Arnout Vandecappelle
  0 siblings, 1 reply; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 13:03 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:50 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:

> +# If both e2fsprogs and busybox are selected, make certain e2fsprogs
> +# wins the fight over who gets to have their utils actually installed
> +ifeq ($(BR2_PACKAGE_BUSYBOX),y)
> +E2FSPROGS_DEPENDENCIES += busybox
> +endif

We recently had a ncurses/busybox discussion, in which to solve a
circular dependency problem we removed such a dependency on Busybox. As
part of this discussion, we started thinking about whether we should
stop using the solution of depending on busybox to allow a package to
override Busybox applets, and instead make sure the corresponding
applets in Busybox are disabled when another package will install the
full featured version of the program.

Should we generalize this idea, and apply it to e2fsprogs as well?

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host Arnout Vandecappelle
@ 2017-04-22 13:03   ` Thomas Petazzoni
  2017-04-22 22:34     ` Arnout Vandecappelle
  0 siblings, 1 reply; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 13:03 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:52 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:
> From: Carlos Santos <casantos@datacom.ind.br>
> 
> We don't need e2initrd_helper or the test I/O manager for the host, just
> like we don't need it for the target.
> 
> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
> [Arnout: don't add --disable-rpath, since we *do* need rpath for the
>  target; otherwise we have to explicitly pass LD_LIBRARY_PATH to be

I guess you meant "we *do* need rpath for the host", right ?

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds
  2017-04-22 11:59 ` [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds Arnout Vandecappelle
@ 2017-04-22 13:04   ` Thomas Petazzoni
  0 siblings, 0 replies; 26+ messages in thread
From: Thomas Petazzoni @ 2017-04-22 13:04 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 22 Apr 2017 13:59:55 +0200, Arnout Vandecappelle
(Essensium/Mind) wrote:

> diff --git a/package/e2fsprogs/e2fsprogs.mk b/package/e2fsprogs/e2fsprogs.mk
> index a60c69b395..84af7abab8 100644
> --- a/package/e2fsprogs/e2fsprogs.mk
> +++ b/package/e2fsprogs/e2fsprogs.mk
> @@ -77,17 +77,19 @@ HOST_E2FSPROGS_CONF_ENV += \
>  	ac_cv_header_magic_h=no \
>  	ac_cv_lib_magic_magic_file=no
>  
> -ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
> +ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE)$(BR2_STATIC_LIBS),yy)
>  # util-linux libuuid pulls in libintl if needed, so ensure we also
>  # link against it, otherwise static linking fails
>  E2FSPROGS_CONF_ENV += LIBS=-lintl
>  endif
>  
>  E2FSPROGS_MAKE_OPTS = LDCONFIG=true
> +

Unrelated change.

>  E2FSPROGS_INSTALL_STAGING_OPTS = \
>  	DESTDIR=$(STAGING_DIR) \
>  	LDCONFIG=true \
>  	install-libs
> +

Ditto.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support
  2017-04-22 12:29   ` Thomas Petazzoni
@ 2017-04-22 21:57     ` Arnout Vandecappelle
  0 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 21:57 UTC (permalink / raw)
  To: buildroot



On 22-04-17 14:29, Thomas Petazzoni wrote:
> Hello,
> 
> On Sat, 22 Apr 2017 13:59:47 +0200, Arnout Vandecappelle
> (Essensium/Mind) wrote:
>> From: Carlos Santos <casantos@datacom.ind.br>
>>
>> In fact, uuidgen was never built because we pass --disable-libuuid. So
>> the option was a NOP.
>>
>> Remove the license info for libuuid.
>>
>> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
>> [Arnout:
>>  - do not remove --disable-uuidd - even though that is implied by
>>    --disable-libuuid, it's better to be explicit about it;
>>  - remove license info of libuuid]
>> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>> ---
>>  package/e2fsprogs/Config.in    | 7 +++----
>>  package/e2fsprogs/e2fsprogs.mk | 5 ++---
>>  2 files changed, 5 insertions(+), 7 deletions(-)
> 
> Applied to master, thanks. I suppose the logic for not having a
> Config.in.legacy entry is that the tool had never been installed
> anyway, so nobody could have been relying on this option to install
> uuidgen. Am I right?

 No, I just forgot :-) But indeed, the option was dysfunctional since commit
044edd063 back in 2011, so no need for legacy handling.


 Regards,
 Arnout

> 
> Best regards,
> 
> Thomas
> 

-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks
  2017-04-22 12:49   ` Thomas Petazzoni
@ 2017-04-22 22:32     ` Arnout Vandecappelle
  0 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 22:32 UTC (permalink / raw)
  To: buildroot



On 22-04-17 14:49, Thomas Petazzoni wrote:
> Hello,
> 
> On Sat, 22 Apr 2017 13:59:49 +0200, Arnout Vandecappelle
> (Essensium/Mind) wrote:
>> From: Carlos Santos <casantos@datacom.ind.br>
>>
>> We have post-install hooks to create the symlinks mkfs.ext2 -> mke2fs
>> etc. However, the e2fsprogs build system creates those symlinks itself.
>> So just rely on that.
>>
>> fsck.ext4dev and mkfs.ext4dev were dropped in version 1.43.4.
>>
>> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
>> [Arnout: keep configure options more or less alphabetical]
>> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> 
> This would definitely be a very very nice cleanup, but it doesn't seem
> to work. I've tried to build the following configuration:
> 
> BR2_arm=y
> BR2_TOOLCHAIN_EXTERNAL=y
> BR2_TOOLCHAIN_EXTERNAL_CUSTOM=y
> BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y
> BR2_TOOLCHAIN_EXTERNAL_URL="http://autobuild.buildroot.org/toolchains/tarballs/br-arm-full-2017.02-756-gae15148.tar.bz2"
> BR2_TOOLCHAIN_EXTERNAL_GCC_4_8=y
> BR2_TOOLCHAIN_EXTERNAL_HEADERS_3_10=y
> BR2_TOOLCHAIN_EXTERNAL_LOCALE=y
> # BR2_TOOLCHAIN_EXTERNAL_HAS_THREADS_DEBUG is not set
> BR2_TOOLCHAIN_EXTERNAL_CXX=y
> BR2_INIT_NONE=y
> BR2_SYSTEM_BIN_SH_NONE=y
> # BR2_PACKAGE_BUSYBOX is not set
> BR2_PACKAGE_E2FSPROGS=y
> # BR2_PACKAGE_E2FSPROGS_BADBLOCKS is not set
> # BR2_PACKAGE_E2FSPROGS_CHATTR is not set
> # BR2_PACKAGE_E2FSPROGS_DUMPE2FS is not set
> # BR2_PACKAGE_E2FSPROGS_E2FREEFRAG is not set
> # BR2_PACKAGE_E2FSPROGS_E2FSCK is not set

 Ah, indeed, I hadn't checked the symlinks with e2fsck disabled.

> # BR2_PACKAGE_E2FSPROGS_E2LABEL is not set
> # BR2_PACKAGE_E2FSPROGS_E2UNDO is not set
> # BR2_PACKAGE_E2FSPROGS_FILEFRAG is not set
> # BR2_PACKAGE_E2FSPROGS_LOGSAVE is not set
> # BR2_PACKAGE_E2FSPROGS_LSATTR is not set
> # BR2_PACKAGE_E2FSPROGS_MKE2FS is not set
> # BR2_PACKAGE_E2FSPROGS_MKLOSTFOUND is not set
> # BR2_PACKAGE_E2FSPROGS_TUNE2FS is not set
> # BR2_TARGET_ROOTFS_TAR is not set
> 
> and I get numerous broken symbolic links:
> 
> thomas at skate:~/projets/buildroot (master)$ ls -l output/target/usr/sbin/
> total 116
> -rwxr-xr-x 1 thomas thomas 13976 avril 22 14:38 e4crypt
> -rwxr-xr-x 1 thomas thomas 18180 avril 22 14:38 fsck
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext2 -> e2fsck
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext3 -> e2fsck
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 fsck.ext4 -> e2fsck
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext2 -> mke2fs
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext3 -> mke2fs
> lrwxrwxrwx 1 thomas thomas     6 avril 22 14:38 mkfs.ext4 -> mke2fs
> -rwxr-xr-x 1 thomas thomas 80996 avril 22 14:38 tune2fs
> 
> So basically: all the symbolic links are broken. It raises a few
> questions:
> 
>  - What is the difference between the fsck option and the e2fsck option?

 fsck is the wrapper, e2fsck is the ext2/3/4-specific checker.


>  - Why is this creating the symbolic links even for programs not
>    installed (e2fsck and mke2fs in our case) ?

 Because e2fsprogs installs them and we remove them.


>  - Why is tune2fs built/installed even if it wasn't enabled in my
>    configuration?

 This I can't explain. tune2fs should be a symlink to e2label, and in addition
it should be removed by Buildroot.


>  - Why is e4crypt built/installed?

 Because it is one of the tools that can't be disabled with configure options,
and it was added to e2fsprogs after the stupid removal hacks were already in
place, and whoever did that bump didn't notice.


 So bottom line: the problem is that this patch individually doesn't work. We
either have to add some complication, or it should be squashed with patch 7.
After patch 7 e2fsck, mke2fs and e2label are always installed so no dead
symlinks anymore.

 OK to squash with patch 7?

 Regards,
 Arnout
-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux
  2017-04-22 13:03   ` Thomas Petazzoni
@ 2017-04-22 22:34     ` Arnout Vandecappelle
  0 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 22:34 UTC (permalink / raw)
  To: buildroot



On 22-04-17 15:03, Thomas Petazzoni wrote:
> Hello,
> 
> On Sat, 22 Apr 2017 13:59:50 +0200, Arnout Vandecappelle
> (Essensium/Mind) wrote:
> 
>> +# If both e2fsprogs and busybox are selected, make certain e2fsprogs
>> +# wins the fight over who gets to have their utils actually installed
>> +ifeq ($(BR2_PACKAGE_BUSYBOX),y)
>> +E2FSPROGS_DEPENDENCIES += busybox
>> +endif
> 
> We recently had a ncurses/busybox discussion, in which to solve a
> circular dependency problem we removed such a dependency on Busybox. As
> part of this discussion, we started thinking about whether we should
> stop using the solution of depending on busybox to allow a package to
> override Busybox applets, and instead make sure the corresponding
> applets in Busybox are disabled when another package will install the
> full featured version of the program.
> 
> Should we generalize this idea, and apply it to e2fsprogs as well?

 Yes, but it should be a separate patch. This patch basically preserves the
existing behaviour of overriding the busybox versions. Note that the dependency
is redundant because we already depend on util-linux which depends on busybox
(for the same reason).


 Regards,
 Arnout

-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host
  2017-04-22 13:03   ` Thomas Petazzoni
@ 2017-04-22 22:34     ` Arnout Vandecappelle
  0 siblings, 0 replies; 26+ messages in thread
From: Arnout Vandecappelle @ 2017-04-22 22:34 UTC (permalink / raw)
  To: buildroot



On 22-04-17 15:03, Thomas Petazzoni wrote:
> Hello,
> 
> On Sat, 22 Apr 2017 13:59:52 +0200, Arnout Vandecappelle
> (Essensium/Mind) wrote:
>> From: Carlos Santos <casantos@datacom.ind.br>
>>
>> We don't need e2initrd_helper or the test I/O manager for the host, just
>> like we don't need it for the target.
>>
>> Signed-off-by: Carlos Santos <casantos@datacom.ind.br>
>> [Arnout: don't add --disable-rpath, since we *do* need rpath for the
>>  target; otherwise we have to explicitly pass LD_LIBRARY_PATH to be
> 
> I guess you meant "we *do* need rpath for the host", right ?

 Yes, for host, obviously...

 Regards,
 Arnout

-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2017-04-22 22:34 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-22 11:59 [Buildroot] [PATCH v8 00/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 01/12] e2fsprogs: change upstream URL sf.net -> sourceforge.net Arnout Vandecappelle
2017-04-22 12:28   ` Thomas Petazzoni
2017-04-22 11:59 ` [Buildroot] [PATCH v8 02/12] e2fsprogs: add missing arch depends to comment Arnout Vandecappelle
2017-04-22 12:28   ` Thomas Petazzoni
2017-04-22 11:59 ` [Buildroot] [PATCH v8 03/12] e2fsprogs: change into menuconfig Arnout Vandecappelle
2017-04-22 12:28   ` Thomas Petazzoni
2017-04-22 11:59 ` [Buildroot] [PATCH v8 04/12] e2fsprogs: remove uuidgen support Arnout Vandecappelle
2017-04-22 12:29   ` Thomas Petazzoni
2017-04-22 21:57     ` Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 05/12] e2fsprogs: use libblkid and libuuid from util-linux for host Arnout Vandecappelle
2017-04-22 12:30   ` Thomas Petazzoni
2017-04-22 11:59 ` [Buildroot] [PATCH v8 06/12] e2fsprogs: let it create symlinks Arnout Vandecappelle
2017-04-22 12:49   ` Thomas Petazzoni
2017-04-22 22:32     ` Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 07/12] e2fsprogs: refactor to fix conflicts with busybox and util-linux Arnout Vandecappelle
2017-04-22 13:03   ` Thomas Petazzoni
2017-04-22 22:34     ` Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 08/12] e2fsprogs: add help text for all config options Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 09/12] e2fsprogs: disable unneeded features for host Arnout Vandecappelle
2017-04-22 13:03   ` Thomas Petazzoni
2017-04-22 22:34     ` Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 10/12] e2fsprogs: add explicit --enable/--disable configure options Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 11/12] e2fsprogs: avoid conflict with util-linux fsck wrapper Arnout Vandecappelle
2017-04-22 11:59 ` [Buildroot] [PATCH v8 12/12] e2fsprogs: only add -lintl for static builds Arnout Vandecappelle
2017-04-22 13:04   ` Thomas Petazzoni

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.