Skip to content

Commit 303954e

Browse files
committed
separate temporary files (important for parallel scenarios)
1 parent 8896126 commit 303954e

1 file changed

Lines changed: 8 additions & 10 deletions

File tree

graphicscache.dtx

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@
438438
/GrayImageDict << /ColorTransform 1 /QFactor \graphicscache@qfactor\space /Blend 1 /HSamples [1 1 1 1] /VSamples [1 1 1 1] >>
439439
/GrayImageResolution \graphicscache@dpi\space
440440
>> setdistillerparams'
441-
-f \graphicscache@cachedir/graphicscacheout.pdf \string|\string| rm \graphicscache@output
441+
-f \graphicscache@output.raw.pdf \string|\string| rm \graphicscache@output
442442
}%
443443
\fi
444444
}
@@ -525,30 +525,28 @@
525525
% First, render the graphics.
526526
% \begin{macrocode}
527527
\ifwindows
528-
\graphicscache@ShellEscape{del /q \graphicscache@cachedir\string\graphicscacheout.pdf}%
528+
\graphicscache@ShellEscape{del /q \graphicscache@output.raw.pdf}%
529529
\graphicscache@ShellEscape{pdflatex
530-
-jobname graphicscacheout
530+
-jobname \graphicscache@output.raw
531531
-interaction nonstopmode
532-
-output-directory "\graphicscache@cachedir"
533532
"\string\documentclass{standalone}
534533
\string\usepackage{graphicx}
535534
\string\usepackage[export]{adjustbox}
536535
\string\begin{document}\string\includegraphics[\graphicscache@graphicsargs]{\graphicscache@fname}\string\end{document}"
537536
}%
538-
\IfFileExists{\graphicscache@cachedir/graphicscacheout.pdf}{}{%
537+
\IfFileExists{\graphicscache@output.raw.pdf}{}{%
539538
\PackageWarning{graphicscache}{External pdflatex call failed (see above)}%
540539
\def\graphicscache@output{}%
541540
}%
542541
\else
543542
\graphicscache@ShellEscape{pdflatex
544-
-jobname graphicscacheout
543+
-jobname \graphicscache@output.raw
545544
-interaction nonstopmode
546-
-output-directory "\graphicscache@cachedir"
547545
'\string\documentclass{standalone}
548546
\string\usepackage{graphicx}
549547
\string\usepackage[export]{adjustbox}
550548
\string\begin{document}\string\includegraphics[\graphicscache@graphicsargs]{\graphicscache@fname}\string\end{document}'
551-
> /dev/null \string|\string| rm "\graphicscache@cachedir/graphicscacheout.pdf"
549+
> /dev/null \string|\string| rm "\graphicscache@output.raw.pdf"
552550
}%
553551
\fi
554552
% \end{macrocode}
@@ -562,11 +560,11 @@
562560
\PackageInfo{graphicscache}{Direct}%
563561
\ifwindows
564562
\graphicscache@ShellEscape{
565-
copy \graphicscache@cachedir\string\graphicscacheout.pdf \graphicscache@output
563+
copy \graphicscache@output.raw.pdf \graphicscache@output
566564
}%
567565
\else
568566
\graphicscache@ShellEscape{
569-
cp \graphicscache@cachedir/graphicscacheout.pdf \graphicscache@output
567+
cp \graphicscache@output.raw.pdf \graphicscache@output
570568
}%
571569
\fi
572570
\fi

0 commit comments

Comments
 (0)