This patch fixes the case where we use other initmethod then busybox and want to enable the applet, but don't want to install the link. This is useful to create busybox based lxc containers.
Signed-off-by: Michael Grzeschik <m.grzesc...@pengutronix.de> --- v1 -> v2: - fixed typo in BUSYBOX_RM_TEMPLATE - made variable set early with := rules/busybox.make | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/rules/busybox.make b/rules/busybox.make index 28d61f5ef..4c5e19b14 100644 --- a/rules/busybox.make +++ b/rules/busybox.make @@ -92,6 +92,13 @@ endif # Target-Install # ---------------------------------------------------------------------------- +BUSYBOX_APPLETS_ = $(shell cat $(BUSYBOX_PKGDIR)/etc/busybox.links) + +ifndef PTXCONF_INITMETHOD_BBINIT +BUSYBOX_RM_TEMPLATE := /sbin/init +endif +BUSYBOX_APPLETS = $(filter-out $(BUSYBOX_RM_TEMPLATE),$(BUSYBOX_APPLETS_)) + $(STATEDIR)/busybox.targetinstall: @$(call targetinfo) @@ -107,7 +114,7 @@ ifdef PTXCONF_BUSYBOX_FEATURE_INDIVIDUAL # @$(call install_lib, busybox, 0, 0, 0644, libbusybox) - @cat $(BUSYBOX_PKGDIR)/etc/busybox.links | while read link; do \ + @for link in $(BUSYBOX_APPLETS); do \ $(call install_copy, busybox, 0, 0, 755, \ "$(BUSYBOX_PKGDIR)/usr/lib/busybox/$${link##*/}", "/usr$${link}"); \ done @@ -123,7 +130,7 @@ endif else @$(call install_copy, busybox, 0, 0, 755, -, /usr/bin/busybox) endif - @cat $(BUSYBOX_PKGDIR)/etc/busybox.links | while read link; do \ + @for link in $(BUSYBOX_APPLETS); do \ case "$${link}" in \ /bin/*) to="busybox" ;; \ /*/*) to="../bin/busybox" ;; \ -- 2.18.0 _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de