diff options
author | Norbert Preining <preining@logic.at> | 2007-12-06 07:11:23 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2007-12-06 07:11:23 +0000 |
commit | f005d3e8beb95c816ff71b659b5fdc2f1e3eee27 (patch) | |
tree | ba370fc8ee10995bb43486f2b9fdda9a07e25fe3 /Master | |
parent | 031ef4477e8603c0b75065b338eca0da4ce5ab65 (diff) |
make installer reasonable - hopefully it runs on windows, too
git-svn-id: svn://tug.org/texlive/trunk@5717 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-x | Master/install-tl.pl | 36 |
1 files changed, 31 insertions, 5 deletions
diff --git a/Master/install-tl.pl b/Master/install-tl.pl index aa8a6051915..3dca5d87116 100755 --- a/Master/install-tl.pl +++ b/Master/install-tl.pl @@ -558,11 +558,37 @@ sub do_postinst_stuff { # MISSING # we need to run mktexlsr and updmap-sys .... - # quick and dirty for now - # we need to set the path correct!!!! - `$vars{'TEXDIR'}/bin/$vars{'this_platform'}/mktexlsr $vars{'TEXDIR'}/texmf-dist $vars{'TEXDIR'}/texmf $vars{'TEXDIR'}/texmf-local`; - `$vars{'TEXDIR'}/bin/$vars{'this_platform'}/updmap-sys --nohash --cnffile=$vars{'TEXMFSYSVAR'}/web2c/updmap.cfg --dvipsoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/dvips/updmap \ --dvipdfmoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/dvipdfm/updmap --pdftexoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/pdftex/updmap `; - `$vars{'TEXDIR'}/bin/$vars{'this_platform'}/mktexlsr $vars{'TEXMFSYSVAR'}`; + # final program execution + # we have to do several things: + # - clean the environment from spurious TEXMF related variables + # - add the bin dir to the PATH + # - run the programs + # + # Step 1: Clean the environment + my @TMFVARS = qw(VARTEXFONTS TEXMFMAIN TEXMFDIST TEXMFLOCAL TEXMFSYSVAR + TEXMFSYSCONFIG TEXMFHOME TEXMFVAR TEXMFCONFIG TEXMF SYSTEXMF VARTEXFONTS + TEXMFDBS WEB2C TEXINPUTS TEXFORMATS MFBASES MPMEMS TEXPOOL MFPOOL MPPOOL + PSHEADERS TEXFONTMAPS TEXPSHEADERS TEXCONFIG TEXMFCNF); + foreach my $tmv (@TMFVARS) { + $ENV{$tmv} = undef if (defined($ENV{$tmv})); + } + # Step 2: Setup the PATH + my $path = ""; + if (defined($ENV{'PATH'})) { + $path = $ENV{'PATH'}; + } + if (win32()) { + $path = "$vars{'TEXDIR'}/bin/$vars{'this_platform'};$path"; + } else { + $path = "$vars{'TEXDIR'}/bin/$vars{'this_platform'}:$path"; + } + $ENV{'PATH'} = "$path"; + # Step 3: run the programs + my $mktexlsr = (win32() ? "mktexlsr.exe" : "mktexlsr"); + my $updmap = (win32() ? "updmap.exe" : "updmap-sys"); + `$mktexlsr $vars{'TEXDIR'}/texmf-dist $vars{'TEXDIR'}/texmf $vars{'TEXDIR'}/texmf-local`; + `$updmap --nohash --cnffile=$vars{'TEXMFSYSVAR'}/web2c/updmap.cfg --dvipsoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/dvips/updmap \ --dvipdfmoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/dvipdfm/updmap --pdftexoutputdir=$vars{'TEXMFSYSVAR'}/fonts/map/pdftex/updmap `; + `$mktexlsr $vars{'TEXMFSYSVAR'}`; # old installer: #$config && texconfig-sys init |