diff options
author | Richard Purdie <richard@openedhand.com> | 2008-08-19 20:02:31 +0000 |
---|---|---|
committer | Richard Purdie <richard@openedhand.com> | 2008-08-19 20:02:31 +0000 |
commit | e80d0ca6b67dfed845cb8e21d942c3452dfe76f1 (patch) | |
tree | 946a0517832c806d4359b158443b843a7f08d014 | |
parent | 88213327d85e2c8f8df9a64c0c0cc9bfd42268f7 (diff) | |
download | poky-e80d0ca6b67dfed845cb8e21d942c3452dfe76f1.tar.gz |
initscripts: Remove pointless forks from timestamp code
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5079 311d38ba-8fff-0310-9ca6-ca027cbcb966
-rwxr-xr-x | meta/packages/initscripts/initscripts-1.0/bootmisc.sh | 10 | ||||
-rw-r--r-- | meta/packages/initscripts/initscripts-1.0/save-rtc.sh | 2 | ||||
-rw-r--r-- | meta/packages/initscripts/initscripts_1.0.bb | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/meta/packages/initscripts/initscripts-1.0/bootmisc.sh b/meta/packages/initscripts/initscripts-1.0/bootmisc.sh index deced6aadf..bd11f9a2fc 100755 --- a/meta/packages/initscripts/initscripts-1.0/bootmisc.sh +++ b/meta/packages/initscripts/initscripts-1.0/bootmisc.sh | |||
@@ -65,13 +65,13 @@ fi | |||
65 | # If the timestamp is 1 day or more recent than the current time, | 65 | # If the timestamp is 1 day or more recent than the current time, |
66 | # use the timestamp instead. | 66 | # use the timestamp instead. |
67 | /etc/init.d/hwclock.sh start | 67 | /etc/init.d/hwclock.sh start |
68 | if test -e /etc/timestamp | 68 | if test -e /etc/timestamp2 |
69 | then | 69 | then |
70 | SYSTEMDATE=`date "+%Y%m%d"` | 70 | SYSTEMDATE=`date "+%Y%m%d%2H%2M"` |
71 | TIMESTAMP=`cat /etc/timestamp | awk '{ print substr($0,9,4) substr($0,1,4);}'` | 71 | read TIMESTAMP < /etc/timestamp2 |
72 | NEEDUPDATE=`expr \( $TIMESTAMP \> $SYSTEMDATE \)` | 72 | NEEDUPDATE=`expr \( $TIMESTAMP \> $SYSTEMDATE + 10000 \)` |
73 | if [ $NEEDUPDATE -eq 1 ]; then | 73 | if [ $NEEDUPDATE -eq 1 ]; then |
74 | date `cat /etc/timestamp` | 74 | date $TIMESTAMP |
75 | /etc/init.d/hwclock.sh stop | 75 | /etc/init.d/hwclock.sh stop |
76 | fi | 76 | fi |
77 | fi | 77 | fi |
diff --git a/meta/packages/initscripts/initscripts-1.0/save-rtc.sh b/meta/packages/initscripts/initscripts-1.0/save-rtc.sh index bf1737f506..75e43001b8 100644 --- a/meta/packages/initscripts/initscripts-1.0/save-rtc.sh +++ b/meta/packages/initscripts/initscripts-1.0/save-rtc.sh | |||
@@ -10,4 +10,4 @@ | |||
10 | ### END INIT INFO | 10 | ### END INIT INFO |
11 | 11 | ||
12 | # Update the timestamp | 12 | # Update the timestamp |
13 | date +%2m%2d%2H%2M%Y > /etc/timestamp | 13 | date +%Y%m%d%2H%2M > /etc/timestamp2 |
diff --git a/meta/packages/initscripts/initscripts_1.0.bb b/meta/packages/initscripts/initscripts_1.0.bb index 377cc14102..2a0f60dd15 100644 --- a/meta/packages/initscripts/initscripts_1.0.bb +++ b/meta/packages/initscripts/initscripts_1.0.bb | |||
@@ -4,7 +4,7 @@ PRIORITY = "required" | |||
4 | DEPENDS = "makedevs" | 4 | DEPENDS = "makedevs" |
5 | RDEPENDS = "makedevs" | 5 | RDEPENDS = "makedevs" |
6 | LICENSE = "GPL" | 6 | LICENSE = "GPL" |
7 | PR = "r117" | 7 | PR = "r118" |
8 | 8 | ||
9 | SRC_URI = "file://functions \ | 9 | SRC_URI = "file://functions \ |
10 | file://halt \ | 10 | file://halt \ |