1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-01 00:59:48 +00:00

image.bbclass/initscripts: Make /etc/timestamp usage consistent.

Timestamp is kept in UTC
 Remove superfluous 'create_etc_timestamp()' function
 - seems to be a duplicate of 'rootfs_update_timestamp()'
 Remove External function reference

[sgw@linux.intel.com: merged 2 patches and cleanup commit message]

Signed-off-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
This commit is contained in:
Gary Thomas
2010-11-04 05:34:12 -06:00
committed by Saul Wold
parent 85bd3d644a
commit 2078af333d
3 changed files with 8 additions and 12 deletions
@@ -65,13 +65,13 @@ fi
# If the timestamp is 1 day or more recent than the current time,
# use the timestamp instead.
/etc/init.d/hwclock.sh start
if test -e /etc/timestamp2
if test -e /etc/timestamp
then
SYSTEMDATE=`date "+%Y%m%d%2H%2M"`
read TIMESTAMP < /etc/timestamp2
SYSTEMDATE=`date -u +%2m%2d%2H%2M%4Y`
read TIMESTAMP < /etc/timestamp
NEEDUPDATE=`expr \( $TIMESTAMP \> $SYSTEMDATE + 10000 \)`
if [ $NEEDUPDATE -eq 1 ]; then
date -s $TIMESTAMP
date -u $TIMESTAMP
/etc/init.d/hwclock.sh stop
fi
fi