我正在尝试使用 make4ht 将 tex 文件转换为 HTML。pdflatex 成功输出 PDF,但 make4ht 失败。我有一个测试文件,如下所示
\documentclass{book}
\usepackage{tikz}
\usepackage{tkz-graph}
\begin{document}
Hello
\end{document}
tikz
当我评论或中的任何一个时tkz-graph
,make4ht 可以工作,但是当两者都存在时会失败。
以下是日志
[INFO] mkparams: Output dir:
[INFO] mkparams: Compiler: latex
[INFO] mkparams: Latex options: -jobname=test
[INFO] mkparams: tex4ht.sty: xhtml,
[INFO] mkparams: tex4ht:
[INFO] mkparams: build_file: test.mk4
[INFO] mkparams: Output format: html5
[STATUS] make4ht: Conversion started
[STATUS] make4ht: Input file: test.tex
[INFO] mkutils: Load extension common_domfilters
[INFO] mkutils: Cannot open config file test.mk4
[INFO] make4ht-lib: setting param correct_exit
[INFO] make4ht-lib: setting param correct_exit
[INFO] make4ht-lib: setting param correct_exit
[INFO] make4ht-lib: setting param ext
[INFO] make4ht-lib: Adding: ext dvi
[INFO] htlatex: LaTeX call: latex --interaction=errorstopmode -jobname=test '\makeatletter\def\HCode{\futurelet\HCode\HChar ....(so on)
...
...
(/usr/share/texlive/texmf-dist/tex/generic/pgf/libraries/pgflibraryplothandlers
.code.tex)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex
)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tik
zlibrarytopaths.code.tex)))
(/usr/share/texlive/texmf-dist/tex/latex/tkz-graph/tkz-graph.sty
(/usr/share/texlive/texmf-dist/tex/latex/base/ifthen.sty)
(/usr/share/texlive/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/share/texlive/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/share/texlive/texmf-dist/tex/generic/xkeyval/xkvutils.tex)))
(/usr/share/texlive/texmf-dist/tex/generic/tex4ht/usepackage.4ht)
! TeX capacity exceeded, sorry [input stack size=5000].
\use:tikzlibrary #1->\use:tikzlibrary {#1
}\find:externalize #1external\@nil
l.23 \usetikzlibrary{arrows}
No pages of output.
Transcript written on test.log.
[FATAL] make4ht-lib: Fatal error. Command htlatex returned exit code 1
(完整日志这里如果需要的话)
Latex 分布https://launchpad.net/~jonathonf/+archive/ubuntu/texlive在 Ubuntu Bionic 18.04.5 上
$ latex -v
pdfTeX 3.14159265-2.6-1.40.20 (TeX Live 2019/Debian)
kpathsea version 6.3.1
Copyright 2019 Han The Thanh (pdfTeX) et al.
There is NO warranty. Redistribution of this software is
covered by the terms of both the pdfTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pdfTeX source.
Primary author of pdfTeX: Han The Thanh (pdfTeX) et al.
Compiled with libpng 1.6.34; using libpng 1.6.34
Compiled with zlib 1.2.11; using zlib 1.2.11
Compiled with xpdf version 4.01