All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] initscripts: test whether /etc/init.d/hwclock.sh exists
@ 2012-03-13 19:14 Andreas Oberritter
  2012-03-14  0:20 ` Saul Wold
  0 siblings, 1 reply; 2+ messages in thread
From: Andreas Oberritter @ 2012-03-13 19:14 UTC (permalink / raw)
  To: openembedded-core

* bootmisc.sh executes /etc/init.d/hwclock.sh, which
  is optional (depends on CONFIG_HWCLOCK in busybox).

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
---
 .../initscripts/initscripts-1.0/bootmisc.sh        |    4 ++--
 meta/recipes-core/initscripts/initscripts_1.0.bb   |    2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh b/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
index 5b86e79..4f76cb4 100755
--- a/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
+++ b/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
@@ -65,14 +65,14 @@ fi
 # Set the system clock from hardware clock
 # If the timestamp is more recent than the current time,
 # use the timestamp instead.
-/etc/init.d/hwclock.sh start
+test -x /etc/init.d/hwclock.sh && /etc/init.d/hwclock.sh start
 if test -e /etc/timestamp
 then
 	SYSTEMDATE=`date -u +%4Y%2m%2d%2H%2M`
 	read TIMESTAMP < /etc/timestamp
 	if [ ${TIMESTAMP} -gt $SYSTEMDATE ]; then
 		date -u ${TIMESTAMP#????}${TIMESTAMP%????????}
-		/etc/init.d/hwclock.sh stop
+		test -x /etc/init.d/hwclock.sh && /etc/init.d/hwclock.sh stop
 	fi
 fi
 : exit 0
diff --git a/meta/recipes-core/initscripts/initscripts_1.0.bb b/meta/recipes-core/initscripts/initscripts_1.0.bb
index f3dc852..829694b 100644
--- a/meta/recipes-core/initscripts/initscripts_1.0.bb
+++ b/meta/recipes-core/initscripts/initscripts_1.0.bb
@@ -3,7 +3,7 @@ DESCRIPTION = "Initscripts provide the basic system startup initialization scrip
 SECTION = "base"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-PR = "r133"
+PR = "r134"
 
 INHIBIT_DEFAULT_DEPS = "1"
 
-- 
1.7.5.4




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] initscripts: test whether /etc/init.d/hwclock.sh exists
  2012-03-13 19:14 [PATCH] initscripts: test whether /etc/init.d/hwclock.sh exists Andreas Oberritter
@ 2012-03-14  0:20 ` Saul Wold
  0 siblings, 0 replies; 2+ messages in thread
From: Saul Wold @ 2012-03-14  0:20 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On 03/13/2012 12:14 PM, Andreas Oberritter wrote:
> * bootmisc.sh executes /etc/init.d/hwclock.sh, which
>    is optional (depends on CONFIG_HWCLOCK in busybox).
>
> Signed-off-by: Andreas Oberritter<obi@opendreambox.org>
> ---
>   .../initscripts/initscripts-1.0/bootmisc.sh        |    4 ++--
>   meta/recipes-core/initscripts/initscripts_1.0.bb   |    2 +-
>   2 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh b/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
> index 5b86e79..4f76cb4 100755
> --- a/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
> +++ b/meta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh
> @@ -65,14 +65,14 @@ fi
>   # Set the system clock from hardware clock
>   # If the timestamp is more recent than the current time,
>   # use the timestamp instead.
> -/etc/init.d/hwclock.sh start
> +test -x /etc/init.d/hwclock.sh&&  /etc/init.d/hwclock.sh start
>   if test -e /etc/timestamp
>   then
>   	SYSTEMDATE=`date -u +%4Y%2m%2d%2H%2M`
>   	read TIMESTAMP<  /etc/timestamp
>   	if [ ${TIMESTAMP} -gt $SYSTEMDATE ]; then
>   		date -u ${TIMESTAMP#????}${TIMESTAMP%????????}
> -		/etc/init.d/hwclock.sh stop
> +		test -x /etc/init.d/hwclock.sh&&  /etc/init.d/hwclock.sh stop
>   	fi
>   fi
>   : exit 0
> diff --git a/meta/recipes-core/initscripts/initscripts_1.0.bb b/meta/recipes-core/initscripts/initscripts_1.0.bb
> index f3dc852..829694b 100644
> --- a/meta/recipes-core/initscripts/initscripts_1.0.bb
> +++ b/meta/recipes-core/initscripts/initscripts_1.0.bb
> @@ -3,7 +3,7 @@ DESCRIPTION = "Initscripts provide the basic system startup initialization scrip
>   SECTION = "base"
>   LICENSE = "GPLv2"
>   LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
> -PR = "r133"
> +PR = "r134"
>
>   INHIBIT_DEFAULT_DEPS = "1"
>

Merged into OE-Core

Thanks
	Sau!



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-03-14  0:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-13 19:14 [PATCH] initscripts: test whether /etc/init.d/hwclock.sh exists Andreas Oberritter
2012-03-14  0:20 ` Saul Wold

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.