From: Michael Grzeschik <mgr@pengutronix.de>
To: ptxdist@pengutronix.de
Subject: Re: [ptxdist] [PATCH 1/3] busybox: don't install /sbin/init link if busybox is not the initmethod
Date: Fri, 3 Aug 2018 17:04:54 +0200 [thread overview]
Message-ID: <20180803150454.wxzdnklitdlqy3dp@pengutronix.de> (raw)
In-Reply-To: <20180803133356.4177-2-m.grzeschik@pengutronix.de>
[-- Attachment #1.1: Type: text/plain, Size: 2270 bytes --]
On Fri, Aug 03, 2018 at 03:33:54PM +0200, Michael Grzeschik wrote:
> 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.grzeschik@pengutronix.de>
> ---
> rules/busybox.make | 11 +++++++++--
> 1 file changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/rules/busybox.make b/rules/busybox.make
> index 28d61f5ef..970ac6b4d 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_TEMPLTE = "/sbin/init"
^^^^^^^
This should be BUSYBOX_RM_TEMPLATE.
> +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
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
next prev parent reply other threads:[~2018-08-03 15:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-03 13:33 [ptxdist] [PATCH 0/3] lxc: add support in ptxdist Michael Grzeschik
2018-08-03 13:33 ` [ptxdist] [PATCH 1/3] busybox: don't install /sbin/init link if busybox is not the initmethod Michael Grzeschik
2018-08-03 15:04 ` Michael Grzeschik [this message]
2018-08-03 13:33 ` [ptxdist] [PATCH 2/3] lxc: add new package Michael Grzeschik
2018-08-04 9:17 ` Michael Grzeschik
2018-08-03 13:33 ` [ptxdist] [PATCH 3/3] host-lxc: add new hostside package Michael Grzeschik
2018-08-03 15:05 ` Michael Grzeschik
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180803150454.wxzdnklitdlqy3dp@pengutronix.de \
--to=mgr@pengutronix.de \
--cc=ptxdist@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox