summaryrefslogtreecommitdiff
path: root/Master/tlpkg/bin
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-02-02 00:55:02 +0000
committerKarl Berry <karl@freefriends.org>2009-02-02 00:55:02 +0000
commit4a340a58f35afae2ab843388c3840cd44386b64b (patch)
treefde1c0a7730f56780f5c750db78a76dba0b66cdc /Master/tlpkg/bin
parent2e3b87b9aa46735ad071e17c110b30f152e2839c (diff)
make sha256sums
git-svn-id: svn://tug.org/texlive/trunk@12047 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/bin')
-rwxr-xr-xMaster/tlpkg/bin/tl-update-install-pkg18
1 files changed, 12 insertions, 6 deletions
diff --git a/Master/tlpkg/bin/tl-update-install-pkg b/Master/tlpkg/bin/tl-update-install-pkg
index 9e1f429165e..cd01a7ec912 100755
--- a/Master/tlpkg/bin/tl-update-install-pkg
+++ b/Master/tlpkg/bin/tl-update-install-pkg
@@ -1,7 +1,7 @@
#!/usr/bin/env perl
# $Id$
#
-# Copyright 2008 Reinhard Kotucha, Norbert Preining
+# Copyright 2008, 2009 Reinhard Kotucha, Norbert Preining, Karl Berry
# This file is licensed under the GNU General Public License version 2
# or any later version.
@@ -22,6 +22,8 @@ BEGIN {
$installerdir=`pwd`;
chomp ($installerdir);
unshift (@INC, "$::installerdir/tlpkg");
+ #
+ $ENV{"PATH"} = "/usr/local/gnu/bin:$ENV{PATH}"; # for sha256sum
}
use Cwd qw(abs_path);
@@ -165,7 +167,8 @@ cleanup ();
# copy files from the repository to tmpdir.
#
-sub copy_files {
+sub copy_files
+{
my ($dir, $file);
for (@_) {
if ($_ !~ m!/!) {
@@ -202,10 +205,11 @@ sub install_files
{
$outputdir = abs_path ($outputdir);
info ("$0: Installing to $outputdir\n");
- copy ("$tmpdir/install-tl-unx.tar.gz", $outputdir);
- system ('ls', '-l', "$outputdir/install-tl-unx.tar.gz");
- copy ("$tmpdir/install-tl.zip", $outputdir);
- system ('ls', '-l', "$outputdir/install-tl.zip");
+ for my $f ("install-tl-unx.tar.gz", "install-tl.zip") {
+ copy ("$tmpdir/$f", $outputdir);
+ system ("cd $outputdir && sha256sum $f >$f.sha256");
+ system ('ls', '-l', "$outputdir/$f");
+ }
# create unpacked installer that can run in that directory,
# for the sake of people mirroring.
@@ -223,6 +227,8 @@ sub install_files
xsystem ("cd $junkdir && unzip -q $outputdir/install-tl.zip");
# move what we want (corresponds to the mv into savedir) and erase the rest.
+ -d "tlpkg" || mkdir ("tlpkg", 0777)
+ || die "mkdir(tlpkg) failed in $outputdir: $!";
xsystem ("mv $junkdir/install-tl/install-tl* .");
xsystem ("rm -rf tlpkg/TeXLive tlpkg/installer");
xsystem ("mv $junkdir/install-tl/tlpkg/* tlpkg/");