首页 > 解决方案 > 尽管启用了 shell 转义,但 Tikz externalize 不起作用

问题描述

我在我的论文中使用 TexStudio 和 Miktex,需要将所有创建的 tikz 图形外部化。我浏览了很多帖子,但无法弄清楚为什么我不能将我的代码外部化。我使用pdflatex.exe -synctex=1 -interaction=nonstopmode --shell-escape %.tex编译但也尝试使用 write18。

这是其中一个图形日志的输出:

The command '\includegraphics []{\AM@currentdocname }' has been     optimized away.
Use '/tikz/external/optimize=false' to disable this.
! Undefined control sequence.
\AM@getpagecount ...ource {\AM@currentdocname@fix 
                                              }\edef \AM@pagecount     {\the...
l.181 \vorspann

Here is how much of TeX's memory you used:
 46796 strings out of 492970
 976398 string characters out of 3126594
 1219813 words of memory out of 3000000
 49867 multiletter control sequences out of 15000+200000
 567782 words of font info for 61 fonts, out of 3000000 for 9000
 1141 hyphenation exceptions out of 8191
 72i,9n,84p,9134b,280s stack positions out of     5000i,500n,10000p,200000b,50000s

!  ==> Fatal error occurred, no output PDF file produced!

和主要的tex文件:

===== 'mode=convert with system call': Invoking 'pdflatex -shell-escape    -halt-on-error -interaction=batchmode -jobname "figures/Masterarbeit-figure87"    "\def\t    ikzexternalrealjob{Masterarbeit}\input{Masterarbeit}"' ========
\openout3 = `Masterarbeit.auxlock'.

runsystem(pdflatex -shell-escape -halt-on-error -interaction=batchmode    -jobname
"figures/Masterarbeit-figure87" "\def\tikzexternalrealjob{Masterarbeit}   \input{
Masterarbeit}")...executed.

\openout3 = `Masterarbeit.auxlock'.


! Package tikz Error: Sorry, the system call 'pdflatex -shell-escape    -halt-on-e
rror -interaction=batchmode -jobname "figures/Masterarbeit-figure87"    "\def\tikz
externalrealjob{Masterarbeit}\input{Masterarbeit}"' did NOT result in a    usable 
output file 'figures/Masterarbeit-figure87' (expected one of    .pdf:.jpg:.jpeg:.p
ng:). Please verify that you have enabled system calls. For pdflatex,    this is '
pdflatex -shell-escape'. Sometimes it is also named 'write 18' or    something lik
e that. Or maybe the command simply failed? Error messages can be found    in 'fig
ures/Masterarbeit-figure87.log'. If you continue now, I'll try to    typeset the p
icture.

See the tikz package documentation for explanation.

另外我可能会补充一点,我可以在我的 Windows 文件系统中看到 pdf 文件几分之一秒,然后它再次消失

标签: latexpdflatextikzmiktex

解决方案


推荐阅读