summaryrefslogtreecommitdiff
path: root/Master/tlpkg
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2008-10-25 20:28:07 +0000
committerKarl Berry <karl@freefriends.org>2008-10-25 20:28:07 +0000
commita69e3c69ff0fbe4eee2457f83975abd9ea09ac67 (patch)
tree633849bc818b131a1b62671074e208045446a47f /Master/tlpkg
parenta2f57c5caa10e6804603e0a0ff16b3da2411a78c (diff)
attempt to implement Norbert's advice to account
for the texlive.infra / bin-texlive changes, by checking if there is any texlive.infra.win32 package. git-svn-id: svn://tug.org/texlive/trunk@11055 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg')
-rwxr-xr-xMaster/tlpkg/bin/tl-update-nsis28
1 files changed, 17 insertions, 11 deletions
diff --git a/Master/tlpkg/bin/tl-update-nsis b/Master/tlpkg/bin/tl-update-nsis
index 0f3f5862473..1fa0b3b15f4 100755
--- a/Master/tlpkg/bin/tl-update-nsis
+++ b/Master/tlpkg/bin/tl-update-nsis
@@ -37,25 +37,28 @@ exit (&main ());
sub main
{
# get the db.
- chomp (my $Master = `cd $mydir/../.. && pwd`); # xx TLPDB should default
- my $tlpdb = TeXLive::TLPDB->new ("root" => "$Master");
- die("Cannot find tlpdb in $Master!\n") unless defined($tlpdb);
+ chomp (my $Master = `cd $mydir/../.. && pwd`);
+ my $tlpdb = TeXLive::TLPDB->new ("root" => $Master);
+ die("Cannot find tlpdb in $Master\n") unless defined($tlpdb);
my $bintexlive = $tlpdb->get_package("bin-texlive");
my $bintexlivew32 = $tlpdb->get_package("bin-texlive.win32");
my $texliveinfra = $tlpdb->get_package("texlive.infra");
my $texliveinfraw32 = $tlpdb->get_package("texlive.infra.win32");
- my %dirtofiles;
- my @allfiles;
+ my @allfiles = ();
push @allfiles, $bintexlive->all_files;
push @allfiles, $bintexlivew32->all_files if defined $bintexlivew32;
push @allfiles, $texliveinfra->all_files;
- push @allfiles, $texliveinfraw32->all_files;
+ push @allfiles, $texliveinfraw32->all_files if defined $texliveinfraw32;
+
+ # get highest rev of all these packages.
my $rev = $bintexlive->revision;
if (defined($bintexlivew32)) {
- $rev = ( $rev > $bintexlivew32->revision ? $rev : $bintexlivew32->revision );
+ $rev = $bintexlivew32->revision if $rev > $bintexlivew32->revision;
+ }
+ $rev = $texliveinfra->revision if $rev > $texliveinfra->revision;
+ if (defined($texliveinfraw32)) {
+ $rev = $texliveinfraw32->revision if $rev > $texliveinfraw32->revision;
}
- $rev = ( $rev > $texliveinfra->revision ? $rev : $texliveinfra->revision );
- $rev = ( $rev > $texliveinfraw32->revision ? $rev : $texliveinfraw32->revision );
# we have to create the tlpobj files, too
my $tlpobjdir = "$InfraLocation/tlpobj";
my $removetlpobjdir = 0;
@@ -71,6 +74,8 @@ sub main
push @allfiles, "$tlpobjdir/$p->{'name'}.tlpobj";
}
}
+
+ my %dirtofiles;
for my $f (@allfiles) {
if ($f !~ m!/!) {
$f = "./$f";
@@ -163,8 +168,9 @@ function in L<TeXLive::TLUtils> for details.
=head1 DESCRIPTION
-Creates a .nsi file that can be used with NSIS to create an update package
-for Win32.
+Creates a C<.nsi> file that can be used with NSIS to create an update
+executable for Windows, to work around Windows' inability to overwrite
+open files.
=head1 AUTHORS AND COPYRIGHT