summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorAngelo Naselli <anaselli@linux.it>2015-02-15 12:54:28 +0100
committerAngelo Naselli <anaselli@linux.it>2015-02-15 12:54:28 +0100
commit9ff316b07c005c0e43e2a9f0546baa85a3abaaae (patch)
treeffa7fde31287be5377cb63d034ec6e1464450acd /perl-install
parentb26a69c7edbec529be9d325414e8cb47ca132182 (diff)
downloaddrakx-9ff316b07c005c0e43e2a9f0546baa85a3abaaae.tar
drakx-9ff316b07c005c0e43e2a9f0546baa85a3abaaae.tar.gz
drakx-9ff316b07c005c0e43e2a9f0546baa85a3abaaae.tar.bz2
drakx-9ff316b07c005c0e43e2a9f0546baa85a3abaaae.tar.xz
drakx-9ff316b07c005c0e43e2a9f0546baa85a3abaaae.zip
Fix timezone dir install prefix prepending (broken symlink during installer mga#14888)
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/timezone.pm8
1 files changed, 5 insertions, 3 deletions
diff --git a/perl-install/timezone.pm b/perl-install/timezone.pm
index ec252c603..cfbaf98a1 100644
--- a/perl-install/timezone.pm
+++ b/perl-install/timezone.pm
@@ -6,8 +6,10 @@ use strict;
use common;
use log;
-sub get_timezone_prefix() {
- my $prefix = $::testing ? '' : $::prefix;
+sub get_timezone_prefix {
+ my ($b_use_system_prefix) = @_;
+
+ my $prefix = ($::testing || $b_use_system_prefix) ? '' : $::prefix;
$prefix . "/usr/share/zoneinfo";
}
@@ -63,7 +65,7 @@ sub write {
set_ntp_server($t->{ntp});
- my $tz_prefix = get_timezone_prefix();
+ my $tz_prefix = get_timezone_prefix(1);
eval { symlinkf($tz_prefix . '/' . $t->{timezone}, "$::prefix/etc/localtime") };
$@ and log::l("installing /etc/localtime failed");
setVarsInSh("$::prefix/etc/sysconfig/clock", {