From c8f732a84d7eed2d49fdc6d67606ab7cacb69b15 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Thu, 11 Aug 2011 17:05:58 +0000 Subject: thumbpdf 3.13c (10aug11) git-svn-id: svn://tug.org/texlive/trunk@23497 c570f23f-e606-0410-a88d-b1316a301751 --- .../texk/texlive/linked_scripts/texlive/tlmgr.pl | 48 ++++++++++- .../texlive/linked_scripts/thumbpdf/thumbpdf.pl | 22 +++-- Master/bin/i386-linux/pdftex | Bin 1368768 -> 3464097 bytes Master/texmf-dist/doc/generic/thumbpdf/readme.txt | 18 ++-- Master/texmf-dist/scripts/thumbpdf/thumbpdf.pl | 22 +++-- .../texmf-dist/tex/generic/thumbpdf/thumbpdf.sty | 94 ++++++++++++++++++++- .../texmf-dist/tex/generic/thumbpdf/thumbpdf.tex | 8 +- Master/tlpkg/bin/tlpkg-ctan-check | 3 +- Master/tlpkg/libexec/ctan2tds | 2 + Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc | 1 + Master/tlpkg/tlpsrc/pagecolor.tlpsrc | 0 11 files changed, 183 insertions(+), 35 deletions(-) create mode 100644 Master/tlpkg/tlpsrc/pagecolor.tlpsrc diff --git a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl index 411c774bb4a..8f0065442c8 100755 --- a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl +++ b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl @@ -1,12 +1,12 @@ #!/usr/bin/env perl -# $Id: tlmgr.pl 23271 2011-07-29 23:20:41Z preining $ +# $Id: tlmgr.pl 23420 2011-08-05 06:27:04Z preining $ # # Copyright 2008, 2009, 2010, 2011 Norbert Preining # This file is licensed under the GNU General Public License version 2 # or any later version. -my $svnrev = '$Revision: 23271 $'; -my $datrev = '$Date: 2011-07-30 01:20:41 +0200 (Sat, 30 Jul 2011) $'; +my $svnrev = '$Revision: 23420 $'; +my $datrev = '$Date: 2011-08-05 08:27:04 +0200 (Fri, 05 Aug 2011) $'; my $tlmgrrevision; if ($svnrev =~ m/: ([0-9]+) /) { $tlmgrrevision = $1; @@ -555,7 +555,13 @@ sub do_cmd_and_check # tlmgr front ends (MacOSX's TeX Live Utility) can read it # and show it to the user before the possibly long delay. info("running $cmd ...\n"); - my ($out, $ret) = TeXLive::TLUtils::run_cmd("$cmd 2>&1"); + my ($out, $ret); + if ($opts{"dry-run"}) { + $ret = 0; + $out = ""; + } else { + ($out, $ret) = TeXLive::TLUtils::run_cmd("$cmd 2>&1"); + } if ($ret == 0) { info("done running $cmd.\n"); log("--output of $cmd:\n$out\n--end of output of $cmd."); @@ -665,6 +671,32 @@ sub handle_execute_actions } } + # + # check if *depending* formats have been changed + # we are currently only caring for package "latex" and "tex". If + # one of these has changed, we search for all packages *depending* + # on latex/tex and regenerate all formats in these packages. + # + # do this only if we are not in --list or --dry-run mode + if (!$opts{"list"}) { + my @check_indirect_formats; + # TODO: + # in case that hyphenation patterns are changed, ie $regenerate_language + # then maybe we don't need to update latex based ones? + push @check_indirect_formats, $localtlpdb->needed_by("latex") + if ($::latex_updated); + push @check_indirect_formats, $localtlpdb->needed_by("tex") + if ($::tex_updated); + for my $p (@check_indirect_formats) { + my $tlp = $localtlpdb->get_package($p); + if (!defined($tlp)) { + tlwarn("$p mentioned but not found in local tlpdb, strange!\n"); + next; + } + TeXLive::TLUtils::announce_execute_actions("enable", $tlp, "format"); + } + } + # format-regenerate is used when the paper size changes. In that # case, if option("create_formats") is set, we simply want to generate # all formats @@ -2832,6 +2864,14 @@ sub action_update { } } + # + # special check for depending format updates: + # if one of latex or tex has been updated, we rebuild the formats + # defined in packages *depending* on these packages. + if (!$opts{"list"}) { + TeXLive::TLUtils::announce_execute_actions("latex-updated") if ($updated{"latex"}); + TeXLive::TLUtils::announce_execute_actions("tex-updated") if ($updated{"tex"}); + } print "end-of-updates\n" if $::machinereadable; diff --git a/Build/source/texk/texlive/linked_scripts/thumbpdf/thumbpdf.pl b/Build/source/texk/texlive/linked_scripts/thumbpdf/thumbpdf.pl index 9dc544b77e8..c18e50262ba 100755 --- a/Build/source/texk/texlive/linked_scripts/thumbpdf/thumbpdf.pl +++ b/Build/source/texk/texlive/linked_scripts/thumbpdf/thumbpdf.pl @@ -5,7 +5,7 @@ $^W=1; # turn warning on # # thumbpdf.pl # -# Copyright (C) 1999-2008 Heiko Oberdiek. +# Copyright (C) 1999-2011 Heiko Oberdiek. # # This work may be distributed and/or modified under the # conditions of the LaTeX Project Public License, either version 1.3 @@ -26,10 +26,10 @@ $^W=1; # turn warning on # my $file = "thumbpdf.pl"; my $program = uc($&) if $file =~ /^\w+/; -my $version = "3.11"; -my $date = "2010/07/07"; +my $version = "3.13"; +my $date = "2011/08/10"; my $author = "Heiko Oberdiek"; -my $copyright = "Copyright (c) 1999-2010 by $author."; +my $copyright = "Copyright (c) 1999-2011 by $author."; # # Reqirements: Perl5, Ghostscript # History: @@ -147,6 +147,8 @@ my $copyright = "Copyright (c) 1999-2010 by $author."; # 2008/04/16 v3.10 # 2010/07/07 v3.11 # * \input is used with file name extension for "thumbpdf.tex". +# 2011/08/10 v3.13 +# * Use gswin64c in Windows with 64 bits. # ### program identification @@ -160,7 +162,12 @@ my $Error = "!!! Error:"; # error prefix my $GS = "gs"; $GS = "gs386" if $^O =~ /dos/i; $GS = "gsos2" if $^O =~ /os2/i; -$GS = "gswin32c" if $^O =~ /mswin32/i; +if ($^O =~ /mswin32c/i) { + # http://perldoc.perl.org/perlport.html#DOS-and-Derivatives + use Config; + $GS = "gswin32c"; + $GS = "gswin64c" if $Config{'archname'} =~ /mswin32-x64/i; +} # Windows detection (no SIGHUP) my $Win = 0; @@ -236,6 +243,7 @@ Options: (defaults:) --(no)useps `makepng' uses `.ps' instead of `.pdf' file ($bool[$::opt_useps]) --(no)level2 `.tpm' with ps level 2 features ($bool[$::opt_level2]) --(no)greek text in greek style (experimental) ($bool[$::opt_greek]) + --gscmd call of ghostscript ($GS) --antialias [num2] anti-aliasing, 0 = disable, 4 = max ($::opt_antialias) --device|png [png] Ghostscript device for thumbnails, dev = mono, gray, 16, 256, 16m ($::opt_device) @@ -243,7 +251,7 @@ Options: (defaults:) --compress thumbnail compress level, n = 0..10 ($::opt_compress) --modes [,mode] mode=pdftex|pdfmark|dvips|ps2pdf| vtexpdfmark|all ($::opt_modes) - --password apassword for an encrypted pdf file ($::opt_password) + --password for an encrypted pdf file ($::opt_password) END_OF_USAGE ### environment variable THUMBPDF @@ -378,7 +386,7 @@ my $MaxThumb = 0; if ($::opt_makepng) { print "*** make png files / run Ghostscript ***\n" - unless $::opt_quiet or $::opt_printgscmd; + unless $::opt_quiet or $::opt_printgscmd; if ($::opt_useps) { print "* ps file: $jobfile\n" if $::opt_verbose; diff --git a/Master/bin/i386-linux/pdftex b/Master/bin/i386-linux/pdftex index e0905257738..e759ef0ac05 100755 Binary files a/Master/bin/i386-linux/pdftex and b/Master/bin/i386-linux/pdftex differ diff --git a/Master/texmf-dist/doc/generic/thumbpdf/readme.txt b/Master/texmf-dist/doc/generic/thumbpdf/readme.txt index 48acbcd02c3..a81967dd2fa 100644 --- a/Master/texmf-dist/doc/generic/thumbpdf/readme.txt +++ b/Master/texmf-dist/doc/generic/thumbpdf/readme.txt @@ -1,4 +1,4 @@ -readme.txt for project thumbpdf 2010/07/07 v3.11 +readme.txt for project thumbpdf 2011/08/10 v3.13 TABLE OF CONTENTS ================= @@ -50,7 +50,7 @@ In the following the user TeX file is called `.tex'. B. COPYRIGHT, DISCLAIMER, LICENSE ================================= -Copyright (C) 1999-2010 Heiko Oberdiek. +Copyright (C) 1999-2011 Heiko Oberdiek. This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either version 1.3 @@ -221,6 +221,7 @@ F. USER INTERFACE Configuration options for --makepng: --useps: Use the PostScript file `.ps' instead of the pdf file `.pdf' for generating the thumbnails. + --gscmd : Name of the ghostscript command. --device|png [png]: (dev = mono, gray, 16, 256, 16m) Ghostscript device for producing the thumbnails, e.g.: --device=mono, --device=pnggray, --png=256 @@ -409,14 +410,6 @@ If you have questions, problems with `thumbpdf', error reports, if you have improvements or want to have additional features, please send them to the author. -My environment for developing and testing: -* linux, SuSE 7.3 -* perl v5.6.0 -* pdfTeX 3.14159-1.00a-pretest-20010806 -* Ghostscript 5.50, 6.51, 7.x -* dvips 5.86 -* VTeX 7.53 - Other ps->pdf routes: * pstill: I did not succeed. It seems that the used pdfmark specials are not supported. @@ -607,3 +600,8 @@ J. HISTORY * \pdfcompresslevel=0 and \pdfminorversion=4 added for thumbpdf.tex. * \input is used with file name extension for "thumbpdf.tex". * Warning if \pdfobjcompresslevel>0. +2011/08/09 v3.12: + * Support for LuaTeX added. +2011/08/10 v3.13: + * Use gswin64c in Windows with 64 bits. + * Fix of version date of thumbpdf.sty. diff --git a/Master/texmf-dist/scripts/thumbpdf/thumbpdf.pl b/Master/texmf-dist/scripts/thumbpdf/thumbpdf.pl index 9dc544b77e8..c18e50262ba 100755 --- a/Master/texmf-dist/scripts/thumbpdf/thumbpdf.pl +++ b/Master/texmf-dist/scripts/thumbpdf/thumbpdf.pl @@ -5,7 +5,7 @@ $^W=1; # turn warning on # # thumbpdf.pl # -# Copyright (C) 1999-2008 Heiko Oberdiek. +# Copyright (C) 1999-2011 Heiko Oberdiek. # # This work may be distributed and/or modified under the # conditions of the LaTeX Project Public License, either version 1.3 @@ -26,10 +26,10 @@ $^W=1; # turn warning on # my $file = "thumbpdf.pl"; my $program = uc($&) if $file =~ /^\w+/; -my $version = "3.11"; -my $date = "2010/07/07"; +my $version = "3.13"; +my $date = "2011/08/10"; my $author = "Heiko Oberdiek"; -my $copyright = "Copyright (c) 1999-2010 by $author."; +my $copyright = "Copyright (c) 1999-2011 by $author."; # # Reqirements: Perl5, Ghostscript # History: @@ -147,6 +147,8 @@ my $copyright = "Copyright (c) 1999-2010 by $author."; # 2008/04/16 v3.10 # 2010/07/07 v3.11 # * \input is used with file name extension for "thumbpdf.tex". +# 2011/08/10 v3.13 +# * Use gswin64c in Windows with 64 bits. # ### program identification @@ -160,7 +162,12 @@ my $Error = "!!! Error:"; # error prefix my $GS = "gs"; $GS = "gs386" if $^O =~ /dos/i; $GS = "gsos2" if $^O =~ /os2/i; -$GS = "gswin32c" if $^O =~ /mswin32/i; +if ($^O =~ /mswin32c/i) { + # http://perldoc.perl.org/perlport.html#DOS-and-Derivatives + use Config; + $GS = "gswin32c"; + $GS = "gswin64c" if $Config{'archname'} =~ /mswin32-x64/i; +} # Windows detection (no SIGHUP) my $Win = 0; @@ -236,6 +243,7 @@ Options: (defaults:) --(no)useps `makepng' uses `.ps' instead of `.pdf' file ($bool[$::opt_useps]) --(no)level2 `.tpm' with ps level 2 features ($bool[$::opt_level2]) --(no)greek text in greek style (experimental) ($bool[$::opt_greek]) + --gscmd call of ghostscript ($GS) --antialias [num2] anti-aliasing, 0 = disable, 4 = max ($::opt_antialias) --device|png [png] Ghostscript device for thumbnails, dev = mono, gray, 16, 256, 16m ($::opt_device) @@ -243,7 +251,7 @@ Options: (defaults:) --compress thumbnail compress level, n = 0..10 ($::opt_compress) --modes [,mode] mode=pdftex|pdfmark|dvips|ps2pdf| vtexpdfmark|all ($::opt_modes) - --password apassword for an encrypted pdf file ($::opt_password) + --password for an encrypted pdf file ($::opt_password) END_OF_USAGE ### environment variable THUMBPDF @@ -378,7 +386,7 @@ my $MaxThumb = 0; if ($::opt_makepng) { print "*** make png files / run Ghostscript ***\n" - unless $::opt_quiet or $::opt_printgscmd; + unless $::opt_quiet or $::opt_printgscmd; if ($::opt_useps) { print "* ps file: $jobfile\n" if $::opt_verbose; diff --git a/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.sty b/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.sty index 2c925afbd7e..c97bf33b238 100644 --- a/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.sty +++ b/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.sty @@ -1,11 +1,11 @@ % File: thumbpdf.sty % Project: thumbpdf -% Version: 2010/07/07 v3.11 +% Version: 2011/08/10 v3.13 % Author: Heiko Oberdiek % % Function: Inclusion of thumbnails % -% Copyright: Copyright (C) 1999-2010 Heiko Oberdiek. +% Copyright: Copyright (C) 1999-2011 Heiko Oberdiek. % % This work may be distributed and/or modified under % the conditions of the LaTeX Project Public License, @@ -96,6 +96,8 @@ % 2007/11/07 v3.9 % 2008/04/16 v3.10 % 2010/07/07 v3.11: Warning if \pdfobjcompresslevel>0. +% 2011/08/09 v3.12: Support for LuaTeX added. +% 2011/08/10 v3.13: Version date fixed. % % \THB@ is the prefix for internal command names. % @@ -116,7 +118,7 @@ \def\x{\endgroup\ProvidesPackage{thumbpdf}}% \fi \fi -\x[2010/07/07 v3.11 Inclusion of thumbnails (HO)]% +\x[2011/08/10 v3.13 Inclusion of thumbnails (HO)]% % Dummy for \thisthumb and \DeclareThumbs. It is overwritten, % if the checks succeed and the whole package is loaded. @@ -481,6 +483,70 @@ \fi } +\RequirePackage{ifluatex}[2010/03/01] +\ifluatex + \def\THB@InitLua{% + \catcode39=12 % ' + \catcode40=12 % ( + \catcode41=12 % ) + \catcode43=12 % + + \catcode45=12 % - + \catcode46=12 % . + \catcode60=12 % < + \catcode95=12 % _ + \escapechar=-1 % + \edef\\{\string\\}% + \edef\%{\string\%}% + \escapechar=92 % + \newlinechar=13 % + \catcode13=12 % + \endlinechar=13 % + }% + \ifnum\luatexversion<36 % + \def\THB@directlua#{\directlua0}% + \else + \let\THB@directlua\directlua + \fi + \begingroup + \THB@InitLua % + \THB@directlua{% + thumbpdf = {} + thumbpdf.callback = callback.find('process_input_buffer') +% if thumbpdf.callback then +% texio.write_nl('log', 'Package thumbpdf Info: Callback saved.') +% texio.write_nl('log', '') +% end + function thumbpdf.process_input_buffer(buffer) + return string.gsub(buffer, '[\\100-\\255]', + function (s) + local num = string.byte(s) + if num < 128 then + return s + else + return unicode.utf8.char(num + 1114112) + end + end + ) + end + thumbpdf.id, thumbpdf.error = + callback.register('process_input_buffer', + thumbpdf.process_input_buffer) + if thumbpdf.id == nil then + tex.print(string.format( + '\\\\endgroup\\\\begingroup% + \\\\PackageError{thumbpdf}% + {\%s:\\\\MessageBreak \%s}\\\\@ehc', + 'Setting process_input_buffer failed', + string.gsub(thumbpdf.error, '\\.$', ''))) +% else +% texio.write_nl('log', +% 'Package thumbpdf Info: Setting process_input_buffer.') +% texio.write_nl('log', '') + end + }% + \endgroup% +\fi + % Many commands and catcode changes are only necessary to read % the data file, so we do this in a group. \begingroup @@ -551,6 +617,28 @@ \input{\THB@datafile}% \fi \endgroup + +\ifluatex + \begingroup + \THB@InitLua % + \THB@directlua{% + thumbpdf.id, thumbpdf.error = + callback.register('process_input_buffer', thumbpdf.callback) + if thumbpdf.id == nil then + tex.print(string.format( + '\\\\endgroup\\\\begingroup% + \\\\PackageError{thumbpdf}% + {\%s:\\\\MessageBreak \%s}\\\\@ehc', + 'Restoring process_input_buffer failed', + string.gsub(thumbpdf.error, '\\.$', ''))) +% else +% texio.write_nl('log', 'Package thumbpdf Info: Callback restored.') +% texio.write_nl('log', '') + end + }% + \endgroup +\fi + % restore catcode of `@'. \catcode`\@=\THB@AtCode\relax \endinput diff --git a/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.tex b/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.tex index 148edbed8e2..14ffd6203ca 100644 --- a/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.tex +++ b/Master/texmf-dist/tex/generic/thumbpdf/thumbpdf.tex @@ -1,9 +1,9 @@ % File: thumbpdf.tex % Project: thumbpdf -% Version: 2010/07/07 v3.11 +% Version: 2011/08/10 v3.13 % Author: Heiko Oberdiek % -% Copyright: Copyright (C) 1999-2010 Heiko Oberdiek. +% Copyright: Copyright (C) 1999-2011 Heiko Oberdiek. % % This work may be distributed and/or modified under % the conditions of the LaTeX Project Public License, @@ -90,9 +90,11 @@ % 2008/04/16 v3.10 % 2010/07/07 v3.11: \pdfcompresslevel=0 and % \pdfminorversion=4 added. +% 2011/08/09 v3.12 +% 2011/08/10 v3.13 \immediate\write16{% - File: thumbpdf.tex 2010/07/07 v3.11 % + File: thumbpdf.tex 2011/08/10 v3.13 % Including thumbnails as images (HO)% } \immediate\write16{% diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index 2288d02064e..569db23b1ec 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -269,7 +269,8 @@ my @TLP_working = qw( onlyamsmath onrannual opcit optional ordinalpt orkhun ot-tableau othello othelloboard oubraces outline outliner overpic - pagecont pagenote pagerange pagesLTS paper papercdcase papermas papertex + pagecolor pagecont pagenote pagerange pagesLTS + paper papercdcase papermas papertex paralist parallel paratype paresse parrun parselines parskip passivetex patch patchcmd patgen2-tutorial path pauldoc pawpict pax pbox pb-diagram pdf14 pdf-forms-tutorial-de pdf-forms-tutorial-en diff --git a/Master/tlpkg/libexec/ctan2tds b/Master/tlpkg/libexec/ctan2tds index b054f560bea..25518f5db05 100755 --- a/Master/tlpkg/libexec/ctan2tds +++ b/Master/tlpkg/libexec/ctan2tds @@ -477,6 +477,7 @@ chomp ($Build = `cd $Master/../Build/source && pwd`); 'lshort-vietnamese', '&MAKElshort', 'lshort-zh-cn', "die 'skipping, use lshort-chinese'", 'ltablex', "die 'skipping, unknown license'", + 'ltnews', "die 'skipping, nonfree doc'", 'ltt', "&MAKEltt", 'ltxbase', "&MAKEbase", 'ltxfileinfo', "die 'skipping, Ruby, not self-locating'", @@ -1977,6 +1978,7 @@ $standardxmt='\.xmt'; 'texdiff' => 'texdiff$', 'texdirflatten' => 'texdirflatten$', 'texloganalyser' => 'texloganalyser', + 'thumbpdf' => '\.pl$', 'ulqda' => '\.pl$', 'urlbst' => 'urlbst$', 'vpe' => '\.pl$', diff --git a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc index 4b1d68f7d98..614eecd625d 100644 --- a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc +++ b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc @@ -474,6 +474,7 @@ depend optional depend outline depend outliner depend overpic +depend pagecolor depend pagecont depend pagenote depend pagerange diff --git a/Master/tlpkg/tlpsrc/pagecolor.tlpsrc b/Master/tlpkg/tlpsrc/pagecolor.tlpsrc new file mode 100644 index 00000000000..e69de29bb2d -- cgit v1.2.3