[Re: SPECS: rc-scripts.spec - rel 2; package /etc/localtime]

Przemysław Sztoch jnavy1 at navy.main.pl
Mon Feb 5 19:36:22 CET 2007


Może dodaj też tego patch'a jak z "czasem" kombinujesz...

Andrzej Krzysztofowicz napisał(a):
> arekm wrote:
>> +%ghost /etc/localtime
> 
> /me sie zastanawia, czy to aby dobre miejsce.
> 
> Jesli w chroocie zainstaluje a potem wywale rc-scripts (bo po co one tam?)
> to mi wczesniej ustawiony /etc/localtime tez wywali...
> 
> Niemniej, nie mam w tej chwili pojecia jakie miejsce byloby lepsze.
> Moze setup ? Moze tzdata ?
> 

-- 
Przemysław Sztoch <przemyslaw{aT}sztoch.pl>
Mobile +48 (502) 400 239, GG 569973, Jabber psztoch{aT}finn.pl
-------------- next part --------------
Index: rc-scripts/rc.d/rc.sysinit
===================================================================
--- rc-scripts/rc.d/rc.sysinit	(revision 8219)
+++ rc-scripts/rc.d/rc.sysinit	(working copy)
@@ -217,13 +217,17 @@
 		CLOCKDEF="$CLOCKDEF (srm)"
 	fi
 
-	# Check if timezone definition is available
-	if [ -e /etc/localtime ] ; then
-		if run_cmd "$(nls 'Setting clock')$CLOCKDEF" /sbin/hwclock $CLOCKFLAGS; then
-			show "$(nls 'Today`s date:') $(LC_CTYPE=C date)"; ok
+	# Check if real clock is available (xen hasn't got rtc).
+	if [ -e /dev/rtc ] ; then
+
+		# Check if timezone definition is available
+		if [ -e /etc/localtime ] ; then
+			if run_cmd "$(nls 'Setting clock')$CLOCKDEF" /sbin/hwclock $CLOCKFLAGS; then
+				show "$(nls 'Today`s date:') $(LC_CTYPE=C date)"; ok
+			fi
+		else
+			TIME_SETUP_DELAYED=yes
 		fi
-	else
-		TIME_SETUP_DELAYED=yes
 	fi
 
 	# Start up swapping



More information about the pld-devel-pl mailing list