diff options
Diffstat (limited to 'Master/tlpkg/installer/install-menu-wizard.pl')
-rw-r--r-- | Master/tlpkg/installer/install-menu-wizard.pl | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/Master/tlpkg/installer/install-menu-wizard.pl b/Master/tlpkg/installer/install-menu-wizard.pl index 7403997ea0c..82f106ad28d 100644 --- a/Master/tlpkg/installer/install-menu-wizard.pl +++ b/Master/tlpkg/installer/install-menu-wizard.pl @@ -269,7 +269,7 @@ sub check_show_warning { $warning->configure(-text => ""); $nxt->configure(-state => "normal"); } else { - $warning->configure(-text => __('(default not writable - please change!)')); + $warning->configure(-text => __('(default not allowed or not writable - please change!)')); $nxt->configure(-state => "disabled"); } } @@ -298,6 +298,7 @@ sub change_path { sub callback_change_texdir { my ($val) = @_; my $home = getenv('HOME'); + my $texdirnoslash; if (win32()) { $home = getenv('USERPROFILE'); $home =~ s!\\!/!g; @@ -315,11 +316,21 @@ sub callback_change_texdir { $vars{'TEXMFSYSVAR'}="$1/$texlive_release/texmf-var"; $vars{'TEXMFSYSCONFIG'}="$1/$texlive_release/texmf-config"; } elsif ($vars{'TEXDIR'}=~/^(.*)$/) { - $vars{'TEXMFLOCAL'}="$1/texmf-local"; - $vars{'TEXMFSYSVAR'}="$1/texmf-var"; - $vars{'TEXMFSYSCONFIG'}="$1/texmf-config"; + $texdirnoslash = $1; + $texdirnoslash =~ s!/$!!; + $vars{'TEXMFLOCAL'}="$texdirnoslash/texmf-local"; + $vars{'TEXMFSYSVAR'}="$texdirnoslash/texmf-var"; + $vars{'TEXMFSYSCONFIG'}="$texdirnoslash/texmf-config"; + } + if ($vars{'TEXDIR'} =~ /:$/) { + # drive letter: add final slash + $vars{'TEXDIR'} = $vars{'TEXDIR'}."/"; + # note: main::do_installation will remove this final slash + } elsif ($vars{'TEXDIR'} =~ /\/$/ and $vars{'TEXDIR'} !~ /:\/$/) { + # remove final slash + $vars{'TEXDIR'} =~ s![\\/]$!!; } - $vars{'TEXDIRW'}=$vars{'TEXDIR'}; + #$vars{'TEXDIRW'}=$vars{'TEXDIR'}; $dest = $vars{'TEXDIR'}; $dest_display = native_slashify($dest); # useful as -textvar value in Labels check_show_warning(); |