diff options
author | Karl Berry <karl@freefriends.org> | 2016-04-19 21:36:08 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2016-04-19 21:36:08 +0000 |
commit | adbe3eb411d50490f1c17e55c82e29d63a1ecfe5 (patch) | |
tree | 0d7e9190324abe9ee2d3ef2c456c10065651c8bc /Build/source/texk | |
parent | ed28050639de6674b72251ecd15b4cce0133cb83 (diff) |
doc,sync,consistency
git-svn-id: svn://tug.org/texlive/trunk@40622 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk')
4 files changed, 95 insertions, 32 deletions
diff --git a/Build/source/texk/tests/TeXLive/TLConfig.pm b/Build/source/texk/tests/TeXLive/TLConfig.pm index 972f708f893..1435bbbf003 100644 --- a/Build/source/texk/tests/TeXLive/TLConfig.pm +++ b/Build/source/texk/tests/TeXLive/TLConfig.pm @@ -5,7 +5,7 @@ package TeXLive::TLConfig; -my $svnrev = '$Revision: 40475 $'; +my $svnrev = '$Revision: 40600 $'; my $_modulerevision; if ($svnrev =~ m/: ([0-9]+) /) { $_modulerevision = $1; @@ -107,7 +107,7 @@ our $RelocPrefix = "RELOC"; our @CriticalPackagesList = qw/texlive.infra/; our $CriticalPackagesRegexp = '^(texlive\.infra)'; -if ($^O =~ /^MSWin(32|64)$/i) { +if ($^O =~ /^MSWin/i) { push (@CriticalPackagesList, "tlperl.win32"); $CriticalPackagesRegexp = '^(texlive\.infra|tlperl\.win32$)'; } diff --git a/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl b/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl index 05b9022488b..33d72693f4b 100755 --- a/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl +++ b/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl @@ -1,5 +1,5 @@ #!/usr/bin/env perl -# $Id: fmtutil.pl 40475 2016-04-12 20:56:58Z karl $ +# $Id: fmtutil.pl 40581 2016-04-17 21:37:08Z siepo $ # fmtutil - utility to maintain format files. # (Maintained in TeX Live:Master/texmf-dist/scripts/texlive.) # @@ -24,11 +24,11 @@ BEGIN { TeX::Update->import(); } -my $svnid = '$Id: fmtutil.pl 40475 2016-04-12 20:56:58Z karl $'; -my $lastchdate = '$Date: 2016-04-12 22:56:58 +0200 (Tue, 12 Apr 2016) $'; +my $svnid = '$Id: fmtutil.pl 40581 2016-04-17 21:37:08Z siepo $'; +my $lastchdate = '$Date: 2016-04-17 23:37:08 +0200 (Sun, 17 Apr 2016) $'; $lastchdate =~ s/^\$Date:\s*//; $lastchdate =~ s/ \(.*$//; -my $svnrev = '$Revision: 40475 $'; +my $svnrev = '$Revision: 40581 $'; $svnrev =~ s/^\$Revision:\s*//; $svnrev =~ s/\s*\$$//; my $version = "r$svnrev ($lastchdate)"; @@ -37,6 +37,7 @@ use strict; use Getopt::Long qw(:config no_autoabbrev ignore_case_always); use File::Basename; use File::Copy; +use File::Spec; use Cwd; # don't import anything automatically, this requires us to explicitly @@ -44,6 +45,8 @@ use Cwd; # find and if necessary remove references to TLUtils use TeXLive::TLUtils qw(); +require TeXLive::TLWinGoo if TeXLive::TLUtils::win32; + # numerical constants my $FMT_NOTSELECTED = 0; my $FMT_DISABLED = 1; @@ -321,8 +324,11 @@ sub callback_build_formats { my $tmpdir; if (win32()) { my $foo; + my $tmp_deflt = File::Spec->tmpdir; for my $i (1..5) { - $foo = "$texmfvar/temp.$$." . int(rand(1000000)); + # $foo = "$texmfvar/temp.$$." . int(rand(1000000)); + $foo = (($texmfvar =~ m!^//!) ? $tmp_deflt : $texmfvar) + . "/temp.$$." . int(rand(1000000)); if (! -d $foo) { if (mkdir($foo)) { $tmpdir = $foo; @@ -333,6 +339,10 @@ sub callback_build_formats { if (! $tmpdir) { die "Cannot get a temporary directory after five iterations ... sorry!"; } + if ($texmfvar =~ m!^//!) { + # used File::Spec->tmpdir; fix permissions + TeXLive::TLWinGoo::maybe_make_ro ($tmpdir); + } } else { $tmpdir = File::Temp::tempdir(CLEANUP => 1); } @@ -349,7 +359,7 @@ sub callback_build_formats { # for safety, check again die "abs_path failed, strange: $!" if !$opts{'fmtdir'}; print_info("writing formats under $opts{fmtdir}\n"); # report - + # code taken over from the original shell script for KPSE_DOT etc my $thisdir = cwd(); $ENV{'KPSE_DOT'} = $thisdir; diff --git a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl index 4acb2998709..66ed99bd78b 100755 --- a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl +++ b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl @@ -1,13 +1,13 @@ #!/usr/bin/env perl -# $Id: tlmgr.pl 40467 2016-04-12 06:14:51Z preining $ +# $Id: tlmgr.pl 40615 2016-04-19 07:41:55Z preining $ # # Copyright 2008-2016 Norbert Preining # This file is licensed under the GNU General Public License version 2 # or any later version. # -my $svnrev = '$Revision: 40467 $'; -my $datrev = '$Date: 2016-04-12 08:14:51 +0200 (Tue, 12 Apr 2016) $'; +my $svnrev = '$Revision: 40615 $'; +my $datrev = '$Date: 2016-04-19 09:41:55 +0200 (Tue, 19 Apr 2016) $'; my $tlmgrrevision; my $prg; if ($svnrev =~ m/: ([0-9]+) /) { @@ -622,21 +622,6 @@ for the full story.\n"; } } - # - # setup gpg if available - # first line: --(no-)verify-downloads was passed in (opts defined) - # second line: not passed in but in config - if ((defined($opts{"verify-downloads"}) && $opts{"verify-downloads"}) - || - (!defined($opts{"verify-downloads"}) && $config{"verify-downloads"})) { - if (TeXLive::TLUtils::setup_gpg($Master)) { - log("Trying to verify cryptographic signatures!\n") - } else { - tlwarn("Setting up gpg did not succeed!\n"); - } - } - - my $ret = execute_action($action, @ARGV); # F_ERROR stops processing immediately, and prevents postactions from @@ -4323,7 +4308,7 @@ sub action_platform { my @extra_w32_packs = qw/tlperl.win32 tlgs.win32 tlpsv.win32 collection-wintools dviout.win32 wintools.win32/; - if ($^O=~/^MSWin(32|64)$/i) { + if ($^O =~ /^MSWin/i) { warn("action `platform' not supported on Windows\n"); return ($F_WARNING); } @@ -4637,7 +4622,7 @@ sub action_gui { $tkmissing = 1; } if ($tkmissing) { - if ($^O=~/^MSWin(32|64)$/i) { + if ($^O =~ /^MSWin/i) { # that should not happen, we are shipping Tk!! require Win32; my $msg = "Cannot load Tk, that should not happen as we ship it!\nHow did you start tlmgrgui??\n(Error message: $@)\n"; @@ -5709,6 +5694,53 @@ sub init_local_db { } } +sub handle_gpg_config_settings { + # setup gpg if available + # by default we setup gpg + # default value + my $do_setup_gpg = 1; + # the value is set in the config file + if (defined($config{'verify-downloads'})) { + $do_setup_gpg = $config{'verify-downloads'}; + } + # command line + if (defined($opts{'verify-downloads'})) { + $do_setup_gpg = $opts{'verify-downloads'}; + } + # now we know whether we setup gpg or not + if ($do_setup_gpg) { + if (TeXLive::TLUtils::setup_gpg($Master)) { + log("will verify cryptographic signatures\n") + } else { + my $prefix = "$prg: No gpg found"; # just to shorten the strings + if ($opts{'verify-downloads'}) { + # verification was requested on the command line, but did not succeed, die + tldie("$prefix, verification explicitly requested on command line, quitting.\n"); + } + if ($config{'verify-downloads'}) { + # verification explicitely requested in config file, but not gpg, die + tldie("$prefix, verification explicitly requested in config file, quitting.\n"); + } + # it was requested via the default setting, so just warn + info ("$prefix, verification implicitly requested, " + . "continuing without verification\n"); + } + } else { + # we do not setup gpg: when explicitly requested, be silent, otherwise info + my $prefix = "$prg: not setting up gpg"; + if (defined($opts{'verify-downloads'})) { + # log normally is *NOT* logged to a file + # tlmgr does by default *NOT* set up a log file (cmd line option) + # user requested it, so don't bother with output + log("$prefix, requested on command line\n"); + } elsif (defined($config{'verify-downloads'})) { + log("$prefix, requested in config file\n"); + } else { + tldie("$prg: how could this happen? gpg setup.\n"); + } + } +} + # initialize the global $remotetlpdb object, or die. # uses the global $location. @@ -5734,6 +5766,9 @@ sub init_tlmedia { $localtlpdb->save; %repos = repository_to_array($location); } + # do the gpg stuff only when loading the remote tlpdb + handle_gpg_config_settings(); + # check if we are only one tag/repo if ($#tags == 0) { # go to normal mode @@ -6025,7 +6060,9 @@ sub load_config_file { # by default we remove packages $config{"auto-remove"} = 1; # - $config{"verify-downloads"} = 1; + # do NOT set this here, we distinguish between explicitly set in the config file + # or implicitly true + # $config{"verify-downloads"} = 1; # loads system config file, this cannot be changes with tlmgr chomp (my $TEXMFSYSCONFIG = `kpsewhich -var-value=TEXMFSYSCONFIG`); @@ -7520,7 +7557,8 @@ a different hash), it's harmless to delete them. =head1 CRYPTOGRAPHIC VERIFICATION -If a working GnuPG binary (C<gpg>) is found, by default verification of +If a working GnuPG binary (C<gpg>) is found (see below for how it is +searched), by default verification of downloaded files is performed. This can be supressed by specifying C<--no-verify-downloads> on the command line, or adding an entry C<verify-downloads = 0> to a tlmgr config file. @@ -7537,6 +7575,18 @@ the TeX Live Distribution GPG key 0x06BAB6BC, which in turn is signed by Karl Berry's key 0x9DEB46C0 and Norbert Preining's key 0x6CACA448. All of these keys are obtainable from the standard key servers. +=head2 Configuration of GnuPG invocation + +The executable used for GnuPG is searched as follows: If the environment +variable C<TL_GNUPG> is set, it is tested and used. Otherwise C<gpg> is +checked, and finally C<gpg2>. + +Further adaption of the invocation of C<gpg> can be done using the +two enviroment variables C<TL_GNUPGHOME>, which is passed to +C<gpg> with C<--homedir>, and C<TL_GNUPGARGS>, which replaces the +default arguments C<--no-secmem-warning --no-permission-warning>. + + =head1 USER MODE C<tlmgr> provides a restricted way, called ``user mode'', to manage diff --git a/Build/source/texk/texlive/tl_scripts/fmtutil.cnf b/Build/source/texk/texlive/tl_scripts/fmtutil.cnf index c8a809eaf4a..885096479d7 100644 --- a/Build/source/texk/texlive/tl_scripts/fmtutil.cnf +++ b/Build/source/texk/texlive/tl_scripts/fmtutil.cnf @@ -1,4 +1,4 @@ -# Generated by /home/texlive/karl/Master/bin/i386-linux/tlmgr on Thu Apr 7 00:50:35 2016 +# Generated by /home/texlive/karl/Master/bin/i386-linux/tlmgr on Tue Apr 19 03:16:09 2016 # Originally written by Thomas Esser, 1998. Public domain. # # As of TeX Live 2015, fmtutil reads *all* fmtutil.cnf files found. @@ -77,8 +77,8 @@ lualatex luatex language.dat,language.dat.lua lualatex.ini # # from lollipop: lollipop pdftex - -translate-file=cp227.tcx *lollipop.ini +lualollipop luatex - lualollipop.ini xelollipop xetex - -etex xelollipop.ini -#! dvilollipop pdftex - -translate-file=cp227.tcx *lollipop.ini # # from luatex: luatex luatex language.def,language.dat.lua luatex.ini @@ -93,6 +93,9 @@ mex pdftex mexconf.tex -translate-file=cp227.tcx *mex.ini pdfmex pdftex mexconf.tex -translate-file=cp227.tcx *pdfmex.ini utf8mex pdftex mexconf.tex -enc *utf8mex.ini # +# from mflua: +#! mflua mflua-nowin - mf.ini +# # from mltex: mllatex pdftex language.dat -translate-file=cp227.tcx -mltex *mllatex.ini mltex pdftex - -translate-file=cp227.tcx -mltex mltex.ini |