diff options
author | Reinhard Kotucha <reinhard.kotucha@web.de> | 2007-12-03 02:25:51 +0000 |
---|---|---|
committer | Reinhard Kotucha <reinhard.kotucha@web.de> | 2007-12-03 02:25:51 +0000 |
commit | 1ebbc2dcd0006bc7029a2be1cc58460158f27abc (patch) | |
tree | 2eb72111da1a486397015060bb5d710b0559c6e9 | |
parent | 70291907e32cebd035f77ca6022ffb8afc61ffbe (diff) |
install-tl.pl: fixed TEXDIR for Windows in set_texlive_default_dirs()
git-svn-id: svn://tug.org/texlive/trunk@5687 c570f23f-e606-0410-a88d-b1316a301751
-rwxr-xr-x | Master/install-tl.pl | 22 |
1 files changed, 6 insertions, 16 deletions
diff --git a/Master/install-tl.pl b/Master/install-tl.pl index 77984d92dc3..e371d1b6cd5 100755 --- a/Master/install-tl.pl +++ b/Master/install-tl.pl @@ -230,10 +230,10 @@ sub set_texlive_default_dirs { $tex_prefix=getenv('TEXLIVE_INSTALL_PREFIX'); if (win32) { - if (-w getenv('CommonProgramFiles')) { - $tex_prefix||=getenv('CommonProgramFiles') . '/texlive'; - } else { + if (-w getenv('ProgramFiles')) { $tex_prefix||=getenv('ProgramFiles') . '/texlive'; + } else { + $tex_prefix||=getenv('USERPROFILE') . '/texlive'; } } else { $tex_prefix||='/usr/local/texlive'; @@ -258,14 +258,13 @@ sub set_texlive_default_dirs { } - sub calc_depends { my $size; # we have to reset the install hash EVERY TIME otherwise everything will # always be installed since the default is scheme-full which selects # all packages and never deselects it - %install = (); + %install=(); # First look for packages in the selected scheme. my $scheme=$tlpdb->get_package($vars{'selected_scheme'}); @@ -365,10 +364,8 @@ sub calc_depends { } $vars{'total_size'}= sprintf "%d", ($size * $TeXLive::TLConfig::BlockSize)/1024**2; -# printf "Total: %d MB\n", $size/1024**2; } - sub load_tlpdb { my $database; if (media eq 'NET') { @@ -443,7 +440,6 @@ sub set_install_platform { } } - sub create_profile { # The file "TLprofile" is created at the beginning of the # installation process and contains information about the current @@ -483,9 +479,6 @@ sub read_profile { } } - -# -# prepare_installation sub prepare_installation { my $infralocation="$TeXLive::TLConfig::InfraLocation"; my $localtlpdbfile="$vars{'TEXDIR'}/$infralocation/texlive.tlpdb"; @@ -498,7 +491,6 @@ sub prepare_installation { $localtlpdb->location("$localtlpdbfile"); } - sub do_install_packages { foreach my $package (sort keys %install) { print "INSTALL $package\n" if ($install{$package} == 1); @@ -565,12 +557,12 @@ sub parse_executes_and_create_files { } } } - # # updmap.cfg -> TEXMFSYSVAR/web2c my $updmapcfgpath = "$vars{'TEXMFSYSVAR'}/web2c/updmap.cfg"; open(UPDHDR,"<$vars{'TEXDIR'}/texmf/web2c/updmap-hdr.cfg") or die("Cannot find $vars{'TEXDIR'}/texmf/web2c/updmap-hdr.cfg!\n"); - open(UPDMAPCFG,">$updmapcfgpath") or die("Cannot open $updmapcfgpath for writing!\n"); + open(UPDMAPCFG,">$updmapcfgpath") + or die("Cannot open $updmapcfgpath for writing!\n"); foreach (<UPDHDR>) { print UPDMAPCFG ; } close(UPDHDR); foreach (sort keys %maps) { @@ -600,7 +592,6 @@ sub parse_executes_and_create_files { foreach (@formatlines) { print OUTFILE; } close(OUTFILE); } - # # hyphenation patterns my @languagelines = (); # we first have to add language.us @@ -626,7 +617,6 @@ sub parse_executes_and_create_files { } } -# # do_postinst_stuff has to fix up the texmf tree and install some missing # files. The things to do are taken from the install-live.sh installer # of former times, and should be critically checked. |