diff options
-rw-r--r-- | Master/tlpkg/installer/install-menu-perltk.pl | 6 | ||||
-rwxr-xr-x | Master/tlpkg/installer/install-menu-text.pl | 12 |
2 files changed, 16 insertions, 2 deletions
diff --git a/Master/tlpkg/installer/install-menu-perltk.pl b/Master/tlpkg/installer/install-menu-perltk.pl index 169b1388126..6e7fb965b7a 100644 --- a/Master/tlpkg/installer/install-menu-perltk.pl +++ b/Master/tlpkg/installer/install-menu-perltk.pl @@ -510,6 +510,12 @@ sub menu_select_symlink { } sub return_callback { if ($osym) { + my $home = getenv('HOME'); + $home = getenv('USERPROFILE') if (win32); + $home ||= '~'; + $lbin =~ s/^~/$home/; + $linfo =~ s/^~/$home/; + $lman =~ s/^~/$home/; $vars{'sys_bin'} = $lbin; $vars{'sys_info'} = $linfo; $vars{'sys_man'} = $lman; diff --git a/Master/tlpkg/installer/install-menu-text.pl b/Master/tlpkg/installer/install-menu-text.pl index c3d01a7a885..7bd49d79eb9 100755 --- a/Master/tlpkg/installer/install-menu-text.pl +++ b/Master/tlpkg/installer/install-menu-text.pl @@ -688,12 +688,16 @@ EOF if (unix) { if ("\u$answer" eq 'L') { + my $home = getenv('HOME'); + $home = getenv('USERPROFILE') if (win32); + $home ||= '~'; toggle 'option_symlinks'; if ($vars{'option_symlinks'}) { print "New value for binary directory [$sys_bin]: "; chomp($answer=<STDIN>); - $vars{'sys_bin'}="$answer" if (length $answer); - + $vars{'sys_bin'} = "$answer" if (length $answer); + $vars{'sys_bin'} =~ s@\\@/@g if (win32); + $vars{'sys_bin'} =~ s/^~/$home/; if ($vars{'sys_bin'}=~/^(.*)\/bin$/) { $vars{'sys_man'}="$1/man"; $vars{'sys_info'}="$1/info"; @@ -701,10 +705,14 @@ EOF print "New value for man directory [$vars{'sys_man'}]: "; chomp($answer=<STDIN>); $vars{'sys_man'}="$answer" if (length $answer); + $vars{'sys_man'} =~ s@\\@/@g if (win32); + $vars{'sys_man'} =~ s/^~/$home/; print "New value for info directory [$vars{'sys_info'}]: "; chomp($answer=<STDIN>); $vars{'sys_info'}="$answer" if (length $answer); + $vars{'sys_info'} =~ s@\\@/@g if (win32); + $vars{'sys_info'} =~ s/^~/$home/; } return $command{'self'}; } |