summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2016-04-26 21:42:20 +0000
committerNorbert Preining <preining@logic.at>2016-04-26 21:42:20 +0000
commit9bfdbea37230c6402a3a6f9f286f6e886a7d46e4 (patch)
tree0e494f36e210ae59b285aea0b496e2acd969ba32 /Master/texmf-dist/scripts
parentfb53a4c736958f65b497088c7550feacc775620d (diff)
tlmgr/tlcrypto: allow for different sha512 computation methods
git-svn-id: svn://tug.org/texlive/trunk@40770 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts')
-rwxr-xr-xMaster/texmf-dist/scripts/texlive/tlmgr.pl26
1 files changed, 24 insertions, 2 deletions
diff --git a/Master/texmf-dist/scripts/texlive/tlmgr.pl b/Master/texmf-dist/scripts/texlive/tlmgr.pl
index dd3fe7d4de6..ef190a6d7d3 100755
--- a/Master/texmf-dist/scripts/texlive/tlmgr.pl
+++ b/Master/texmf-dist/scripts/texlive/tlmgr.pl
@@ -5773,8 +5773,21 @@ sub init_tlmedia {
$localtlpdb->save;
%repos = repository_to_array($location);
}
- # do the gpg stuff only when loading the remote tlpdb
- handle_gpg_config_settings();
+
+ # checksums and gpg stuff
+ if (TeXLive::TLCrypto::setup_checksum_method()) {
+ # it is only possible to do gpg verification if we can
+ # find a checksum method
+ # do the gpg stuff only when loading the remote tlpdb
+ handle_gpg_config_settings();
+ } else {
+ if (!$config{'no-checksums'}) {
+ tlwarn("Cannot determine a checksum method!\n");
+ tlwarn("Please install either Digest::SHA, openssl, or sha512sum.\n");
+ tlwarn("To silence this warning, set 'no-checksums' to 1 in the\n");
+ tlwarn("tlmgr configuration file.\n");
+ }
+ }
# check if we are only one tag/repo
if ($#tags == 0) {
@@ -6153,6 +6166,15 @@ sub load_options_from_config {
tlwarn("$prg: $fn: Unknown value for verify-downloads: $val\n");
}
+ } elsif ($key eq "no-checksums") {
+ if ($val eq "1") {
+ $config{"no-checksums"} = 1;
+ } elsif ($val eq "0") {
+ $config{"no-checksums"} = 0;
+ } else {
+ tlwarn("$prg: $fn: Unknown value for no-checksums: $val\n");
+ }
+
} elsif ($sysmode) {
# keys here are only allowed in sys mode
if ($key eq "allowed-actions") {