[OE-core] [PATCH 5/5] busybox.inc: Install hwclock init script only if rtc is present in MACHINE_FEATURES

Richard Purdie richard.purdie at linuxfoundation.org
Tue Jul 10 16:02:34 UTC 2012


On Tue, 2012-07-10 at 17:59 +0300, Andrei Gherzan wrote:
> Signed-off-by: Andrei Gherzan <andrei at gherzan.ro>
> ---
>  meta/recipes-core/busybox/busybox.inc |   10 +++++++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/meta/recipes-core/busybox/busybox.inc b/meta/recipes-core/busybox/busybox.inc
> index 82137a3..17ff442 100644
> --- a/meta/recipes-core/busybox/busybox.inc
> +++ b/meta/recipes-core/busybox/busybox.inc
> @@ -180,9 +180,13 @@ do_install () {
>  	if grep "CONFIG_UDHCPD=y" ${WORKDIR}/defconfig; then
>  		install -m 0755 ${WORKDIR}/busybox-udhcpd ${D}${sysconfdir}/init.d/
>  	fi
> -	if grep "CONFIG_HWCLOCK=y" ${WORKDIR}/defconfig; then
> -		install -m 0755 ${WORKDIR}/hwclock.sh ${D}${sysconfdir}/init.d/
> -	fi
> +	case "${MACHINE_FEATURES}" in
> +	*rtc*)
> +		if grep "CONFIG_HWCLOCK=y" ${WORKDIR}/defconfig; then
> +			install -m 0755 ${WORKDIR}/hwclock.sh ${D}${sysconfdir}/init.d/
> +		fi
> +		;;
> +	esac
>  	if grep "CONFIG_UDHCPC=y" ${WORKDIR}/defconfig; then
>  		install -d ${D}${sysconfdir}/udhcpc.d
>  		install -d ${D}${datadir}/udhcpc

This makes busybox machine specific? Is that really what you want to do?

Cheers,

Richard





More information about the Openembedded-core mailing list