summaryrefslogtreecommitdiffstats
path: root/perl-install/timezone.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>1999-09-20 12:36:37 +0000
committerPascal Rigaux <pixel@mandriva.com>1999-09-20 12:36:37 +0000
commit56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd (patch)
treeeb38202994e13fa1b45ad115db0d73ac7aaec88f /perl-install/timezone.pm
parent70c400f9a433cb7139c3c30e3cd8aaf350613483 (diff)
downloaddrakx-56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd.tar
drakx-56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd.tar.gz
drakx-56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd.tar.bz2
drakx-56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd.tar.xz
drakx-56c1b0d4fe9f5a9908827a51b22fa53dd0265bbd.zip
no_comment
Diffstat (limited to 'perl-install/timezone.pm')
-rw-r--r--perl-install/timezone.pm16
1 files changed, 15 insertions, 1 deletions
diff --git a/perl-install/timezone.pm b/perl-install/timezone.pm
index b6f9cb364..6330cb325 100644
--- a/perl-install/timezone.pm
+++ b/perl-install/timezone.pm
@@ -3,7 +3,9 @@ package timezone;
use diagnostics;
use strict;
-use common;
+use common qw(:common :system);
+use commands;
+use log;
sub getTimeZones {
@@ -15,6 +17,18 @@ sub getTimeZones {
@l;
}
+sub write($$$) {
+ my ($prefix, $t, $f) = @_;
+
+ eval { commands::cp("-f", "$prefix/usr/share/zoneinfo/$t->{timezone}", "$prefix/etc/localtime") };
+ $@ and log::l("installing /etc/localtime failed");
+ setVarsInSh($f, {
+ ZONE => $t->{timezone},
+ GMT => bool2text($t->{GMT}),
+ ARC => "false",
+ });
+}
+
my %l2t = (
'Danish (Denmark)' => 'Europe/Copenhagen',
'English (USA)' => 'America/New_York',