Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/iputils: move binaries to the location also used by Busybox
@ 2019-06-16 20:09 Thomas Petazzoni
  2019-06-16 20:09 ` [Buildroot] [PATCH 2/2] package/iputils: fix IPUTILS_PERMISSIONS Thomas Petazzoni
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Thomas Petazzoni @ 2019-06-16 20:09 UTC (permalink / raw)
  To: buildroot

iputils installs several programs that are also implemented as applets
in Busybox. Two of these (arping and tftpd) are installed by iputils
in /bin, while Busybox installs them in /usr/sbin, causing both to be
present if both iputils and busybox are enabled.

This commit moves the binaries installed by iputils to /usr/sbin, so
that only these are installed (Busybox will be installed later thanks
to its optional dependency on iputils, but it will not override the
tools installed by iputils).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 package/iputils/iputils.mk | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/package/iputils/iputils.mk b/package/iputils/iputils.mk
index 8be54b4788..fbf586729b 100644
--- a/package/iputils/iputils.mk
+++ b/package/iputils/iputils.mk
@@ -52,6 +52,16 @@ endif
 # XSL Stylesheets for DocBook 5 not packaged for buildroot
 IPUTILS_CONF_OPTS += -DBUILD_MANS=false -DBUILD_HTML_MANS=false
 
+# move iputils binaries to the same location as where Busybox installs
+# the corresponding applets, so that we have a single version of the
+# tools (from iputils)
+define IPUTILS_MOVE_BINARIES
+	mv $(TARGET_DIR)/usr/bin/arping $(TARGET_DIR)/usr/sbin/arping
+	mv $(TARGET_DIR)/usr/bin/ping $(TARGET_DIR)/bin/ping
+	mv $(TARGET_DIR)/usr/bin/tftpd $(TARGET_DIR)/usr/sbin/tftpd
+endef
+IPUTILS_POST_INSTALL_TARGET_HOOKS += IPUTILS_MOVE_BINARIES
+
 # handle permissions ourselves
 IPUTILS_CONF_OPTS += -DNO_SETCAP_OR_SUID=true
 define IPUTILS_PERMISSIONS
-- 
2.21.0

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

end of thread, other threads:[~2019-06-18  7:17 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-16 20:09 [Buildroot] [PATCH 1/2] package/iputils: move binaries to the location also used by Busybox Thomas Petazzoni
2019-06-16 20:09 ` [Buildroot] [PATCH 2/2] package/iputils: fix IPUTILS_PERMISSIONS Thomas Petazzoni
2019-06-17 20:32   ` Petr Vorel
2019-06-18  6:49     ` Thomas Petazzoni
2019-06-18  7:01       ` Petr Vorel
2019-06-16 20:20 ` [Buildroot] [PATCH 1/2] package/iputils: move binaries to the location also used by Busybox Yann E. MORIN
2019-06-17 17:31   ` Thomas Petazzoni
2019-06-17 20:24 ` Petr Vorel
2019-06-18  6:46   ` Thomas Petazzoni
2019-06-18  6:59     ` Petr Vorel
2019-06-18  7:17       ` Thomas Petazzoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox