summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-01-24 18:11:41 +0000
committerKarl Berry <karl@freefriends.org>2018-01-24 18:11:41 +0000
commit70ef0d6846c2da4367cc9968ed84040d2462622e (patch)
tree822fc89c8d51592161ced643161c5e012ec05d93 /Master
parenta0e7279f5e56528d24f512e841c42649bfe4427e (diff)
save backup of tlpdb when building or pruning release image
git-svn-id: svn://tug.org/texlive/trunk@46428 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/tlpkg/bin/tl-prune-platforms19
-rwxr-xr-xMaster/tlpkg/bin/tl-update-images20
2 files changed, 25 insertions, 14 deletions
diff --git a/Master/tlpkg/bin/tl-prune-platforms b/Master/tlpkg/bin/tl-prune-platforms
index 0dd7462471d..bbc9fd458e6 100755
--- a/Master/tlpkg/bin/tl-prune-platforms
+++ b/Master/tlpkg/bin/tl-prune-platforms
@@ -1,5 +1,5 @@
#!/usr/bin/env perl
-# Copyright 2012-2016 Norbert Preining
+# Copyright 2012-2018 Norbert Preining
# This file is licensed under the GNU General Public License version 2
# or any later version.
#
@@ -41,8 +41,7 @@ if ($opt_version) { print "$vc_id\n"; exit 0; }
exit (&main());
-sub main
-{
+sub main {
# prune db in the same hierarchy from which we are being run.
chomp(my $Master = `cd $mydir/../.. && pwd`);
# necessary for TLUtils->platform
@@ -104,8 +103,13 @@ sub main
push @newarchs, $a if !TeXLive::TLUtils::member($a, @ARGV);
}
- $tlpdb->setting("available_architectures",@newarchs);
- $tlpdb->save unless $opt_dry;
+ $tlpdb->setting("available_architectures", @newarchs);
+
+ if (! $opt_dry) {
+ TeXLive::TLUtils::copy ("-f", $tlpdb->location,
+ $tlpdb->location . ".preprune");
+ $tlpdb->save;
+ }
return 0;
}
@@ -139,7 +143,7 @@ accepted; see the C<process_logging_options> function in
L<TeXLive::TLUtils> for details.
The format of the containers and the splitting of source and
-documentation files are controlled by the TLPDB options in the
+documentation files are controlled by the tlpdb options in the
pseudo-package C<00texlive.config>. See L<TeXLive::TLPDB>.
=head1 DESCRIPTION
@@ -151,6 +155,9 @@ the containers. (Any xz and wget binaries for the installer remain, though.)
It is used during DVD production to exclude certain platforms, and is
run from the L<tl-update-images> script.
+The pre-existing tlpdb file is saved with extension C<.preprune> before
+the modified version is written.
+
=head1 AUTHORS AND COPYRIGHT
This script and its documentation were written for the TeX Live
diff --git a/Master/tlpkg/bin/tl-update-images b/Master/tlpkg/bin/tl-update-images
index 5d019e1a78f..33046a1eaf8 100755
--- a/Master/tlpkg/bin/tl-update-images
+++ b/Master/tlpkg/bin/tl-update-images
@@ -36,6 +36,7 @@ tar_bin_only=false
tar_devsource_only=false
tar_extra_only=false
tar_source_only=false
+tlnet=/home/ftp/texlive/tlpretest
quiet= # for passing to mkisofs
while test $# -gt 0; do
@@ -52,6 +53,7 @@ while test $# -gt 0; do
--tar-devsource-only) tar_all=false; makeinst=false;tar_devsource_only=true;;
--tar-extra-only) tar_all=false; makeinst=false; tar_extra_only=true;;
--tar-source-only) tar_all=false; makeinst=false; tar_source_only=true;;
+ --tlnet=*) tlnet=`echo $1 | sed 's/.*=//'`;;
--version) echo "$0 for $NAME-$V ($D)"; exit 0;; # who cares ...
*) echo "$0: unknown option $1; try --help if you need it." >&2; exit 1;;
esac
@@ -97,7 +99,7 @@ MAKEINST ()
| (cd $imgdir/texlive-doc && tar xf -))
# files from network dist.
- cd /home/ftp/texlive/tlpretest || exit 1
+ cd $tlnet || exit 1
if $debug; then
echo "source = `pwd`"
fi
@@ -105,7 +107,12 @@ MAKEINST ()
echo "$0: no install-tl in `pwd`, goodbye." >&2
exit 1
fi
- cp -pr install-tl *.bat tlpkg archive $imgdir
+ cp -pr install-tl *.bat tlpkg archive $imgdir || exit 1
+ #
+ # Save all tlpdb files before pruning platforms.
+ preprune=/tmp/pruneimg.pre
+ rm -rf $preprune && mkdir $preprune
+ cp -r tlpkg/texlive.tlpdb $preprune || exit 1
# remove platforms to save space on the dvd.
# do this here so that they can be kept in the tree,
@@ -117,7 +124,7 @@ MAKEINST ()
echo "-- pruning platforms: $prune..."
mkdir $imgdir/tlpkg/bin
cp $mydir/tl-prune-platforms $imgdir/tlpkg/bin
- $imgdir/tlpkg/bin/tl-prune-platforms $prune >/tmp/imgprune
+ $imgdir/tlpkg/bin/tl-prune-platforms $prune >/tmp/pruneimg.out
# due to the pruning, must re-checksum and re-sign the tlpdb in the image.
md5sum $imgdir/tlpkg/texlive.tlpdb >$imgdir/tlpkg/texlive.tlpdb.md5 \
@@ -184,7 +191,7 @@ MAKEINST ()
# Make the tar files: the sources, the texmf trees, the binaries, the
# minor "extra" files. Each should unpack into its directory name. We
# use the GNU tar --transform option to avoid copying the whole
-# hierarchy to a temp directory. This auxiliary function takes that
+# hierarchy to a temp directory. The do_tar function takes that
# temp directory name as its first argument, and the files to archive as
# the rest.
#
@@ -206,9 +213,6 @@ do_tar ()
excludes="$excludes --exclude=Work --exclude=inst"
excludes="$excludes --exclude=autom4te.cache"
excludes="$excludes --exclude=asymptote/binaries" # also distclean asy
- for e in bibtex epstopdf jfontmaps; do # exclude "upstream" sources
- excludes="$excludes --exclude=extra/$e"
- done
fi
#
tar_common_opt="$verbose $compress $excludes"
@@ -248,7 +252,7 @@ MAKETAR ()
cd $master || exit 1
do_tar $NAME-$D-extra \
LICENSE* README* autorun.inf *.html install* re* tl-* \
- tlpkg/TeXLive tlpkg/translations tlpkg/tlpostcode
+ tlpkg/TeXLive tlpkg/texlive.tlpdb tlpkg/tlpostcode tlpkg/translations
$tar_extra_only && return # for debugging
fi