diff options
author | Karl Berry <karl@freefriends.org> | 2008-11-09 01:26:54 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2008-11-09 01:26:54 +0000 |
commit | 647511a520b626523dd73ed9fab7e32ecc627b45 (patch) | |
tree | 8f9c6f91c961014796296b399fa4767fe64c055c /Master/tlpkg/TeXLive/TLPDB.pm | |
parent | f72dd4a227f24ea0f17ee451389c17d62557cb8c (diff) |
* TeXLive/TLPDB.tpm: debugging text, comments.
* TeXLive/TLMedia.pm: debugging text, remove unused use Cwd.
* TeXLive/ TLUtils.pm (download_file, give_ctan_mirror): insert our
desired custom wget overrides here (--timeout=60 for both and
--tries=8 for the former).
* installer/wgetrc: remove this file, so people's personal settings
(e.g., for proxies) will take effect.
* install-tl (WGETRC): do not set this in the environment.
(main): run give_ctan_mirror if the TeXLiveServerUrl or literal "ctan" is
given, a la tlmgr; update doc.
git-svn-id: svn://tug.org/texlive/trunk@11228 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/TeXLive/TLPDB.pm')
-rw-r--r-- | Master/tlpkg/TeXLive/TLPDB.pm | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/Master/tlpkg/TeXLive/TLPDB.pm b/Master/tlpkg/TeXLive/TLPDB.pm index 1ff426e7833..d7ca2818eb0 100644 --- a/Master/tlpkg/TeXLive/TLPDB.pm +++ b/Master/tlpkg/TeXLive/TLPDB.pm @@ -184,10 +184,8 @@ sub remove_package { =item C<< $tlpdb->from_file($filename) >> -The C<from_file> function initializes the C<TLPDB> in case the -root was not given at generation time. If C<$filename> begins -with C<http://> or C<ftp://>, the program C<wget> is used to download -the file. The prefix C<file:/> is treated the expected way. +The C<from_file> function initializes the C<TLPDB> if the root was not +given at generation time. See L<TLPDB::new> for more information. It returns the actual number of packages (TLPOBJs) read from C<$filename>. @@ -233,19 +231,19 @@ sub from_file { # better to check both, the return value AND the existence of the file if ($ret && (-r "$lzmafile")) { # ok, let the fun begin - debug("Un-lzmaing $lzmafile to $tlpdbfile\n"); + debug("un-lzmaing $lzmafile to $tlpdbfile\n"); # lzmadec *hopefully* returns 0 on success and anything else on failure # we don't have to negate since not zero means error in the shell # and thus in perl true - if (system("$::progs{'lzmadec'} < $lzmafile_quote > $tlpdbfile_quote")) { - debug("Un-lzmaing $lzmafile did not succeed, try normally\n"); + if (system("$::progs{'lzmadec'} <$lzmafile_quote >$tlpdbfile_quote")) { + debug("un-lzmaing $lzmafile failed, tryin gplain file\n"); # to be sure we unlink the lzma file and the tlpdbfile unlink($lzmafile); unlink($tlpdbfile); } else { unlink($lzmafile); - open $retfh, "<$tlpdbfile" or die"Cannot open $tlpdbfile!"; - debug("Ok, found the uncompressed lzma file!\n"); + open $retfh, "<$tlpdbfile" or die "open($tlpdbfile) failed: $!"; + debug("found the uncompressed lzma file\n"); } } } else { @@ -267,7 +265,7 @@ sub from_file { my $ret = 0; do { my $tlp = TeXLive::TLPOBJ->new; - debug("creating tlp from $path...\n"); + ddebug("creating tlp from $path...\n"); $ret = $tlp->from_fh($retfh,1); if ($ret) { $self->add_tlpobj($tlp); |