All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Cc: Zhenfeng.Zhao@windriver.com
Subject: Re: [PATCH 1/3] lsbinitscripts: Add initscripts to enhance init functions in an lsb image
Date: Wed, 30 May 2012 17:28:11 +0100	[thread overview]
Message-ID: <1338395291.20169.159.camel@ted> (raw)
In-Reply-To: <516ea18ba576f0904bae4b6089838c2dda23f58a.1338284916.git.xiaofeng.yan@windriver.com>

On Wed, 2012-05-30 at 09:47 +0800, xiaofeng.yan@windriver.com wrote:
> From: Xiaofeng Yan <xiaofeng.yan@windriver.com>
> 
> The version of initscripts has more functions than the simple. \
> There could be some errors for current initscripts when running \
> some programe because of absent some functions provided by \
> initscripts.
> 
> [YOCTO #2133]
> 
> Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
> ---
>  meta/recipes-extended/lsb/lsbinitscripts_9.03.bb |   36 ++++++++++++++++++++++
>  1 files changed, 36 insertions(+), 0 deletions(-)
>  create mode 100644 meta/recipes-extended/lsb/lsbinitscripts_9.03.bb
> 
> diff --git a/meta/recipes-extended/lsb/lsbinitscripts_9.03.bb b/meta/recipes-extended/lsb/lsbinitscripts_9.03.bb
> new file mode 100644
> index 0000000..5d2bca8
> --- /dev/null
> +++ b/meta/recipes-extended/lsb/lsbinitscripts_9.03.bb
> @@ -0,0 +1,36 @@
> +DESCRIPTION = "SysV init scripts"

Surely we can be a little more descriptive here and at least mention
LSB?

> +SECTION = "base"
> +LICENSE = "GPLv2"
> +PR = "r0"
> +
> +LIC_FILES_CHKSUM = "file://COPYING;md5=ebf4e8b49780ab187d51bd26aaa022c6"
> +
> +S="${WORKDIR}/initscripts-${PV}"
> +SRC_URI = "http://pkgs.fedoraproject.org/repo/pkgs/initscripts/initscripts-${PV}.tar.bz2/668fa2762b57ef75436303857847bba3/initscripts-${PV}.tar.bz2 \
> +           file://functions.patch \
> +          " 
> +
> +SRC_URI[md5sum] = "668fa2762b57ef75436303857847bba3"
> +SRC_URI[sha256sum] = "d56547a68ce223a7413b2676650b042125f047c8d6d139c5b970e118b3dc958a"
> +
> +do_configure[noexec] = "1" 
> +
> +do_install(){
> +	install -d ${D}/etc/init.d/
> +	install -m 0755 ${S}/rc.d/init.d/functions ${D}/etc/init.d/functions
> +        if [ "${PN}" = "lsbinitscripts" ]; then
> +		mv ${D}${sysconfdir}/init.d/functions ${D}${sysconfdir}/init.d/functions.${PN}
> +	fi
> +}
> +
> +pkg_postinst_${PN}(){
> +        if [ "${PN}" = "lsbinitscripts" ]; then
> +		update-alternatives --install  ${sysconfdir}/init.d/functions functions functions.${PN} 10
> +	fi
> +}
> +
> +pkg_prerm_${PN}(){
> +        if [ "${PN}" = "lsbinitscripts" ]; then
> +		update-alternatives --remove functions  ${sysconfdir}/init.d/functions.${PN}
> +	fi
> +}

Could you update this to use the recently added update-alternatives
class please?

Cheers,

Richard




  reply	other threads:[~2012-05-30 16:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-30  1:47 [PATCH 0/3 V1]:lsb: Add initscripts to enhance init functions in an lsb image xiaofeng.yan
2012-05-30  1:47 ` [PATCH 1/3] lsbinitscripts: " xiaofeng.yan
2012-05-30 16:28   ` Richard Purdie [this message]
2012-05-30  1:47 ` [PATCH 2/3] lsbinitscripts: Patch file functions for confirming to " xiaofeng.yan
2012-05-30  1:47 ` [PATCH 3/3] task-core-lsb: Add another initscripts " xiaofeng.yan

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=1338395291.20169.159.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=Zhenfeng.Zhao@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.