All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wenlin Kang <wenlin.kang@windriver.com>
To: <openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] busybox: fix a sh link wrong
Date: Thu, 28 Aug 2014 17:37:26 +0800	[thread overview]
Message-ID: <53FEF856.4060402@windriver.com> (raw)
In-Reply-To: <1396941362-27622-1-git-send-email-wenlin.kang@windriver.com>

On 2014年04月08日 15:16, Wenlin Kang wrote:
> When both bash and busybox be installed, without ash support
> in busybox,if bash is installed before busybox in the final stage,
> even if ALTERNATIVE_PRIORITY of bash > ALTERNATIVE_PRIORITY of busybox,
> the symlink from /bin/sh to bash can be yet overwritten by busybox.
>
> Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com>
> ---
>   meta/recipes-core/busybox/busybox.inc |    8 ++++++--
>   1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/meta/recipes-core/busybox/busybox.inc b/meta/recipes-core/busybox/busybox.inc
> index 69b9b0c..bf2ddc1 100644
> --- a/meta/recipes-core/busybox/busybox.inc
> +++ b/meta/recipes-core/busybox/busybox.inc
> @@ -188,7 +188,9 @@ do_install () {
>   			install -m 0755 ${B}/busybox.nosuid ${D}${base_bindir}
>   			install -m 0644 ${S}/busybox.links.suid ${D}${sysconfdir}
>   			install -m 0644 ${S}/busybox.links.nosuid ${D}${sysconfdir}
> -			ln -sf busybox.nosuid ${D}${base_bindir}/sh
> +			if grep -q "CONFIG_FEATURE_SH_IS_ASH=y" ${B}/.config; then
> +				ln -sf busybox.nosuid ${D}${base_bindir}/sh
> +			fi
>   			# Keep a default busybox for people who want to invoke busybox directly.
>   			# This is also useful for the on device upgrade. Because we want
>   			# to use the busybox command in postinst.
> @@ -200,7 +202,9 @@ do_install () {
>   				install -m 0755 ${B}/busybox ${D}${base_bindir}
>   			fi
>   			install -m 0644 ${S}/busybox.links ${D}${sysconfdir}
> -			ln -sf busybox ${D}${base_bindir}/sh
> +			if grep -q "CONFIG_FEATURE_SH_IS_ASH=y" ${B}/.config; then
> +				ln -sf busybox ${D}${base_bindir}/sh
> +			fi
>   			# We make this symlink here to eliminate the error when upgrading together
>   			# with busybox-syslog. Without this symlink, the opkg may think of the
>   			# busybox.nosuid as obsolete and remove it, resulting in dead links like


ping ...

-- 
Thanks,
Wenlin Kang



  reply	other threads:[~2014-08-28  9:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-08  7:16 [PATCH] busybox: fix a sh link wrong Wenlin Kang
2014-08-28  9:37 ` Wenlin Kang [this message]
2014-08-28 12:12   ` Bernhard Reutner-Fischer

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=53FEF856.4060402@windriver.com \
    --to=wenlin.kang@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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 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.