summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-12-01 23:59:15 +0000
committerKarl Berry <karl@freefriends.org>2009-12-01 23:59:15 +0000
commit131deb0cf31b15c4961cb831a662d127d3237e67 (patch)
treed19f8ddafd0af1df6a08b125590a51d5e96dac6d /Master
parentefe1314da0fab691249b38434cb969f8a076fa77 (diff)
epstopdf 2.12 (1dec09)
git-svn-id: svn://tug.org/texlive/trunk@16262 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/epstopdf/README8
-rwxr-xr-xMaster/texmf-dist/scripts/epstopdf/epstopdf.pl84
-rw-r--r--Master/texmf/doc/man/man1/epstopdf.14
-rw-r--r--Master/texmf/doc/man/man1/epstopdf.man1.pdfbin6455 -> 6385 bytes
4 files changed, 50 insertions, 46 deletions
diff --git a/Master/texmf-dist/doc/latex/epstopdf/README b/Master/texmf-dist/doc/latex/epstopdf/README
index 7ffd326a1f8..0338f4fada1 100644
--- a/Master/texmf-dist/doc/latex/epstopdf/README
+++ b/Master/texmf-dist/doc/latex/epstopdf/README
@@ -1,4 +1,4 @@
-$Id: README 15532 2009-09-28 15:55:43Z karl $
+$Id: README 15641 2009-10-04 16:42:16Z karl $
This file is public domain. (Originally written by Karl Berry, 2009.)
This is the README for the epstopdf script distribution.
@@ -13,12 +13,12 @@ When reporting bugs, please include an input file and command line
options so the problem can be reproduced.
-------------------------------------------------------------------------
-The test-binary file was supplied by Akira Kakuto. It contains binary
-data. It is public domain.
+The test-binary and test-bin2 files were supplied by Akira Kakuto and
+Reinhard Kotucha. They contain binary data. They are public domain.
The test-binhdr* files were supplied by Martin von Gagern, constructed
as follows. They contain binary junk before the EPS starts. We also
-use this to test different line endings. These files are public domain.
+use these to test different line endings. These files are public domain.
{ echo -e '%Some\000binary\001comment'; dot -Tps <<< 'digraph{a->b}'; }
> test-binhdr-lf.eps
diff --git a/Master/texmf-dist/scripts/epstopdf/epstopdf.pl b/Master/texmf-dist/scripts/epstopdf/epstopdf.pl
index 9e80225d665..a312a9b7f90 100755
--- a/Master/texmf-dist/scripts/epstopdf/epstopdf.pl
+++ b/Master/texmf-dist/scripts/epstopdf/epstopdf.pl
@@ -2,7 +2,7 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' && eval 'exec perl -S $0 $
if 0;
use strict;
-# $Id: epstopdf.pl 15843 2009-10-19 23:14:41Z karl $
+# $Id: epstopdf.pl 16244 2009-11-30 01:36:08Z karl $
# (Copyright lines below.)
#
# Redistribution and use in source and binary forms, with or without
@@ -47,12 +47,16 @@ use strict;
#
# emacs-page
# History
-# 2009/10/18 v2.13 (Manuel P\'egouri\'e-Gonnard)
-# * Better argument validation, from Alexander Cherepanov.
-# * Use the list form of pipe open() (resp. system()) to prevent injection.
+# 2009/11/27 v2.12 (Karl Berry)
+# * Make --filter work again
+# 2009/11/25 (Manuel P\'egouri\'e-Gonnard)
+# * Better extension detection, suggested by A. Cherepanov.
+# 2009/10/18 (Manuel P\'egouri\'e-Gonnard)
+# * Better argument validation (Alexander Cherepanov).
+# * Use list form of pipe open() (resp. system()) to prevent injection.
# Since Perl's fork() emulation doesn't work on Windows with Perl 5.8.8 from
# TeX Live 2009, use a temporary file instead of a pipe on Windows.
-# 2009/10/14 v2.12 (Manuel P\'egouri\'e-Gonnard)
+# 2009/10/14 (Manuel P\'egouri\'e-Gonnard)
# * Added restricted mode.
# 2009/09/27 v2.11 (Karl Berry)
# * Fixed two bugs in the (atend) handling code (Martin von Gagern)
@@ -129,11 +133,11 @@ use strict;
### program identification
my $program = "epstopdf";
-my $ident = '($Id: epstopdf.pl 15843 2009-10-19 23:14:41Z karl $) 2.11';
+my $ident = '($Id: epstopdf.pl 16244 2009-11-30 01:36:08Z karl $) 2.12';
my $copyright = <<END_COPYRIGHT ;
-Copyright 1998-2001 Sebastian Rahtz et al.
-Copyright 2002-2009 Gerben Wierda et al.
Copyright 2009 Karl Berry et al.
+Copyright 2002-2009 Gerben Wierda et al.
+Copyright 1998-2001 Sebastian Rahtz et al.
License RBSD: Revised BSD <http://www.xfree86.org/3.3.6/COPYRIGHT2.html#5>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
@@ -258,10 +262,8 @@ my $InputFilename = "";
if ($::opt_filter) {
@ARGV == 0 or
die errorUsage "Input file cannot be used with filter option";
- $InputFilename = "-";
- debug "Input file: standard input";
-}
-else {
+ debug "Filtering: will read standard input";
+} else {
@ARGV > 0 or die errorUsage "Input filename missing";
@ARGV < 2 or die errorUsage "Unknown option or too many input files";
$InputFilename = $ARGV[0];
@@ -285,6 +287,28 @@ if ($::opt_gscmd) {
my @GS = ($GS);
push @GS, qw(-q -dNOPAUSE -dSAFER -sDEVICE=pdfwrite);
+### option outfile
+my $OutputFilename = $::opt_outfile;
+if ($OutputFilename eq "") {
+ if ($::opt_gs) {
+ $OutputFilename = $InputFilename;
+ if (!$::opt_filter) {
+ my $ds = ($^O eq "MSWin32" || $^O eq "cygwin") ? '\\/' : '/';
+ $OutputFilename =~ s/\.[^\.$ds]*$//;
+ $OutputFilename .= ".pdf";
+ }
+ } else {
+ $OutputFilename = "-"; # no ghostscript, write to standard output
+ }
+}
+if ($::opt_filter) {
+ debug "Filtering: will write standard output";
+ $OutputFilename = "-";
+} else {
+ debug "Output filename:", $OutputFilename;
+}
+push @GS, "-sOutputFile=$OutputFilename";
+
### options compress, embed, res, autorotate
push @GS, ('-dPDFSETTINGS=/prepress', '-dMaxSubsetPct=100',
'-dSubsetFonts=true', '-dEmbedAllFonts=true') if $::opt_embed;
@@ -307,28 +331,6 @@ $BBName = "%%HiResBoundingBox:" if $::opt_hires;
$BBName = "%%ExactBoundingBox:" if $::opt_exact;
debug "BoundingBox comment:", $BBName;
-### option outfile
-my $OutputFilename = $::opt_outfile;
-if ($OutputFilename eq "") {
- if ($::opt_gs) {
- $OutputFilename = $InputFilename;
- if (!$::opt_filter) {
- $OutputFilename =~ s/\.[^\.]*$//;
- $OutputFilename .= ".pdf";
- }
- }
- else {
- $OutputFilename = "-"; # standard output
- }
-}
-if ($::opt_filter) {
- debug "Output file: standard output";
-}
-else {
- debug "Output filename:", $OutputFilename;
-}
-push @GS, "-sOutputFile=$OutputFilename";
-
### validate output file name in restricted mode \label{openout_any}
use File::Spec::Functions qw(splitpath file_name_is_absolute);
if ($restricted) {
@@ -367,8 +369,11 @@ if ($::opt_gs) {
### emacs-page
### open input file
-open(IN, '<', $InputFilename) or error "Cannot open",
- ($::opt_filter) ? "standard input" : "\"$InputFilename\": $!";
+if ($::opt_filter) {
+ open(IN, '<-') || error("Cannot open stdin: $!");
+} else {
+ open(IN, '<', $InputFilename) || error("Cannot open $InputFilename: $!");
+}
binmode IN;
### open output file
@@ -378,11 +383,10 @@ my $OUT; # filehandle for output (GS pipe or temporary file)
use File::Temp 'tempfile';
if ($::opt_gs) {
unless ($^O eq 'MSWin32' || $^O eq 'cygwin') { # list piped open works
- push @GS, qw(- -c -quit);
+ push @GS, qw(- -c quit);
debug "Ghostscript pipe:", join(' ', @GS);
open($OUT, '|-', @GS) or error "Cannot open Ghostscript for piped input";
- }
- else { # use a temporary file
+ } else { # use a temporary file on Windows/Cygwin.
($OUT, $tmp_filename) = tempfile(UNLINK => 1);
debug "Using temporary file '$tmp_filename'";
}
@@ -579,4 +583,4 @@ if ($? & 127) {
}
warning "BoundingBox not found" unless $BBCorrected;
-debug "Ready.";
+debug "Done.";
diff --git a/Master/texmf/doc/man/man1/epstopdf.1 b/Master/texmf/doc/man/man1/epstopdf.1
index fe95f676100..7243280bafb 100644
--- a/Master/texmf/doc/man/man1/epstopdf.1
+++ b/Master/texmf/doc/man/man1/epstopdf.1
@@ -1,5 +1,5 @@
-.TH EPSTOPDF 1 "15 October 2009"
-.\" $Id: epstopdf.1 15532 2009-09-28 15:55:43Z karl $
+.TH EPSTOPDF 1 "30 November 2009"
+.\" $Id: epstopdf.1 16245 2009-11-30 01:37:26Z karl $
.\" man page originally by Jim Van Zandt
.SH NAME
epstopdf, repstopdf \- convert an EPS file to PDF
diff --git a/Master/texmf/doc/man/man1/epstopdf.man1.pdf b/Master/texmf/doc/man/man1/epstopdf.man1.pdf
index eb46c5c1ea2..9afe8d20713 100644
--- a/Master/texmf/doc/man/man1/epstopdf.man1.pdf
+++ b/Master/texmf/doc/man/man1/epstopdf.man1.pdf
Binary files differ