summaryrefslogtreecommitdiff
path: root/Master/install-tl.pl
diff options
context:
space:
mode:
authorReinhard Kotucha <reinhard.kotucha@web.de>2007-11-25 17:46:52 +0000
committerReinhard Kotucha <reinhard.kotucha@web.de>2007-11-25 17:46:52 +0000
commit66f8f0f14a9a647ff62f26002f868e9e90f1ca86 (patch)
treefb10669f04f374456f4c2bb5bc316005696b5001 /Master/install-tl.pl
parent488c66de644e3776a4574a7c791503ef0923cbc0 (diff)
install-tl.pl prepare_installation
git-svn-id: svn://tug.org/texlive/trunk@5592 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/install-tl.pl')
-rwxr-xr-xMaster/install-tl.pl35
1 files changed, 20 insertions, 15 deletions
diff --git a/Master/install-tl.pl b/Master/install-tl.pl
index 56023f9d240..c326702a6ef 100755
--- a/Master/install-tl.pl
+++ b/Master/install-tl.pl
@@ -19,7 +19,8 @@ BEGIN {
use TeXLive::TLUtils qw(initialize_installer media platform platform_desc
debug which getenv win32 unix program_exists architectures_available
- additional_architectures_available_from_net get_system_tmpdir member);
+ additional_architectures_available_from_net get_system_tmpdir member
+ mkdirhier make_var_skeleton make_local_skeleton);
use TeXLive::TLPOBJ;
use TeXLive::TLPDB;
use TeXLive::TLConfig;
@@ -76,7 +77,6 @@ sub set_platforms_supported {
}
}
-
# Environment variables and default values on UNIX:
# TEXLIVE_INSTALL_PREFIX /usr/local/texlive => $tex_prefix
# TEXLIVE_INSTALL_TEXDIR $tex_prefix/2007 => $TEXDIR
@@ -250,7 +250,7 @@ sub calc_depends {
sub clear_screen {
-# return 0;
+# return 0;
(unix)? system 'clear':system 'cls';
}
@@ -1008,7 +1008,9 @@ sub create_profile {
foreach my $key (keys %vars) {
print PROFILE "$key $vars{$key}\n"
if $key=~/^collection/ and $vars{$key}==1;
+ print PROFILE "$key $vars{$key}\n" if $key=~/^option_letter/;
print PROFILE "$key $vars{$key}\n" if $key=~/^option_doc/;
+ print PROFILE "$key $vars{$key}\n" if $key=~/^option_fmt/;
print PROFILE "$key $vars{$key}\n" if $key=~/^option_src/;
print PROFILE "$key $vars{$key}\n" if $key=~/^option_symlinks/;
}
@@ -1018,16 +1020,18 @@ sub create_profile {
#
# prepare_installation
sub prepare_installation {
- my $destdir = $vars{"TEXDIR"};
- my $texmfvar = $vars{"TEXMFSYSVAR"};
- `mkdir -p "$destdir"`;
- `mkdir -p "$destdir/$TeXLive::TLConfig::InfraLocation"`;
- `mkdir -p "$texmfvar"`;
- my $localtlpdbpath = "$destdir/$TeXLive::TLConfig::InfraLocation/texlive.tlpdb";
- $::localtlpdb = new TeXLive::TLPDB;
- $::localtlpdb->location("$localtlpdbpath");
+ my $infralocation="$TeXLive::TLConfig::InfraLocation";
+ my $localtlpdbfile="$vars{'TEXDIR'}/$infralocation/texlive.tlpdb";
+
+ mkdirhier "$vars{'TEXDIR'}/$infralocation";
+ make_var_skeleton "$vars{'TEXMFSYSVAR'}";
+ make_local_skeleton "$vars{'TEXMFLOCAL'}";
+
+ $::localtlpdb=new TeXLive::TLPDB;
+ $::localtlpdb->location("$localtlpdbfile");
}
+
sub add_tlpcontainer {
my ($package, $ziplocation, $dest) = @_;
my $unpackprog;
@@ -1054,6 +1058,7 @@ sub add_tlpcontainer {
}
# warn "Huuu, this needs testing and error checking!\n";
# warn "Should we use -a -- adapt line endings etc?\n";
+# No! Always use binmode.
`$unpackprog`;
my $tlpobj=$::tlpdb->get_package($package);
$::localtlpdb->add_tlpobj($tlpobj);
@@ -1077,10 +1082,10 @@ sub install_files {
my @archs;
foreach (keys %vars) {
if (m/^diskbin_(.*)$/ ) {
- if ($vars{$_}) { push @archs, $1; }
+ if ($vars{$_}) {push @archs, $1;}
}
if (m/^netbin_(.*)$/ ) {
- if ($vars{$_}) { push @archs, $1; }
+ if ($vars{$_}) {push @archs, $1;}
}
}
my $destination="$vars{TEXDIR}";
@@ -1109,13 +1114,12 @@ sub parse_executes_and_create_files {
} elsif ($e =~ m/BuildLanguageDat (.*)$/) {
$hypcnffiles{$1} = 1;
} else {
- die "Unknown execute for package $p: $e\n";
+# die "Unknown execute for package $p: $e\n";
}
}
}
#
# updmap.cfg -> TEXMFSYSVAR/web2c
- `mkdir -p $vars{'TEXMFSYSVAR'}/web2c`;
my $updmapcfgpath = "$vars{'TEXMFSYSVAR'}/web2c/updmap.cfg";
open(UPDMAPCFG,">$updmapcfgpath") or die("Cannot open $updmapcfgpath for writing!\n");
foreach (sort keys %maps) {
@@ -1176,6 +1180,7 @@ run_menu;
calc_depends;
prepare_installation;
install_files;
+
parse_executes_and_create_files;
#
# what more has to be done: