texlive[43832] Master/install-tl: dd backward compatibility when
commits+preining at tug.org
commits+preining at tug.org
Sun Apr 16 04:14:13 CEST 2017
Revision: 43832
http://tug.org/svn/texlive?view=revision&revision=43832
Author: preining
Date: 2017-04-16 04:14:13 +0200 (Sun, 16 Apr 2017)
Log Message:
-----------
dd backward compatibility when reading profiles
Modified Paths:
--------------
trunk/Master/install-tl
Modified: trunk/Master/install-tl
===================================================================
--- trunk/Master/install-tl 2017-04-16 02:14:07 UTC (rev 43831)
+++ trunk/Master/install-tl 2017-04-16 02:14:13 UTC (rev 43832)
@@ -1794,6 +1794,19 @@
sub read_profile {
my $profilepath = shift;
my %opts = @_;
+ my %keyrename = (
+ 'option_sys_bin' => 'tlpdbopt_sys_bin',
+ 'option_sys_man' => 'tlpdbopt_sys_man',
+ 'option_sys_info' => 'tlpdbopt_sys_info',
+ 'option_doc' => 'tlpdbopt_install_docfiles',
+ 'option_src' => 'tlpdbopt_install_srcfiles',
+ 'option_fmt' => 'tlpdbopt_create_formats',
+ 'option_path' => 'instopt_path',
+ 'option_letter' => 'instopt_letter',
+ 'option_adjustrepo' => 'instopt_adjustrepo',
+ 'portable' => 'instopt_portable',
+ );
+
open PROFILE, "<$profilepath"
or die "$0: Cannot open profile $profilepath for reading.\n";
# %pro is used to see whether there are non-recognized keys,
@@ -1805,6 +1818,8 @@
next if m/^[[:space:]]*$/; # skip empty lines
next if m/^[[:space:]]*#/; # skip comment lines
my ($k,$v) = split (" ", $_, 2); # value might have spaces
+ # convert old keys to new keys
+ $k = $keyrename{$k} if ($keyrename{$k});
$pro{$k} = $v;
$profiledata{$k} = $v;
}
@@ -1843,10 +1858,6 @@
}
}
#
- # TODO
- # for backward compatibility, check for name changes of options
- #
- #
# if there are still keys in the %pro array, some unknown keys have
# been written in the profile, bail out
if (my @foo = keys(%pro)) {
More information about the tex-live-commits
mailing list