From c323a4ae268d20d293351dc5e195e34d19ed28e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20B=C3=A4chler?= Date: Mon, 18 Dec 2006 21:54:53 +0000 Subject: upgpkg: initscripts 0.8-2 finally fixed 5445 --- rc.sysinit | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'rc.sysinit') diff --git a/rc.sysinit b/rc.sysinit index c637d99..2401a71 100755 --- a/rc.sysinit +++ b/rc.sysinit @@ -153,9 +153,9 @@ status "Mounting Root Read-only" /bin/mount -n -o remount,ro / # Clock is set again later to match rc.conf if [ -f /etc/localtime ]; then if [ "$HARDWARECLOCK" = "UTC" ]; then - /sbin/hwclock --directisa --utc --hctosys + /sbin/hwclock --directisa --utc --hctosys --noadjfile else - /sbin/hwclock --directisa --localtime --hctosys + /sbin/hwclock --directisa --localtime --hctosys --noadjfile fi fi @@ -229,17 +229,18 @@ stat_done status "Activating Swap" /sbin/swapon -a stat_busy "Configuring System Clock" -if [ "$TIMEZONE" != "" ]; then - /bin/ln -sf /usr/share/zoneinfo/$TIMEZONE /etc/localtime +if [ ! -f /var/lib/hwclock/adjtime ]; then + echo "0.0 0 0.0" > /var/lib/hwclock/adjtime +fi +if [ "$TIMEZONE" != "" -a -e /usr/share/zoneinfo/$TIMEZONE ]; then + /bin/rm -f /etc/localtime + /bin/cp /usr/share/zoneinfo/$TIMEZONE /etc/localtime fi if [ "$HARDWARECLOCK" = "UTC" ]; then /sbin/hwclock --directisa --utc --hctosys else /sbin/hwclock --directisa --localtime --hctosys fi -if [ ! -f /var/lib/hwclock/adjtime ]; then - echo "0.0 0 0.0" > /var/lib/hwclock/adjtime -fi stat_done if [ -f /var/run/random-seed ]; then -- cgit v1.2.3