我正在使用来自 openSUSE buildservice 发布存储库的 TexLive 2012,使用 TeXLive 2011 编译的文档现在会出现如下错误消息:
包 PGF 数学错误:函数“add”已存在。
包 PGF 数学错误:函数“subtract”已存在。
等等。
这是由todonotes
和引起的chemfig
,因为两者都加载tikz
。有没有办法解决这个冲突?
根据要求举个例子:
\documentclass[a4paper]{scrbook}
\usepackage{hyperref}
\usepackage{todonotes}
\begin{document}
test
\end{document}
texlive 2011 日志的相关摘录:
(/usr/share/texmf/tex/latex/pgf/compatibility/pgfcomp-version-1-18.sty
Package: pgfcomp-version-1-18 2007/07/23 v2.10 (rcs-revision 1.1)
))
(/usr/share/texmf/tex/latex/pgf/utilities/pgffor.sty
(/usr/share/texmf/tex/latex/pgf/utilities/pgfkeys.sty
(/usr/share/texmf/tex/generic/pgf/utilities/pgfkeys.code.tex))
(/usr/share/texmf/tex/generic/pgf/utilities/pgffor.code.tex
Package: pgffor 2010/03/23 v2.10 (rcs-revision 1.18)
以及来自 texlive 2012 的日志:
(/usr/share/texmf/tex/latex/pgf/compatibility/pgfcomp-version-1-18.sty
Package: pgfcomp-version-1-18 2007/07/23 v2.10 (rcs-revision 1.1)
))
(/usr/share/texmf/tex/latex/pgf/utilities/pgffor.sty
(/usr/share/texmf/tex/latex/pgf/utilities/pgfkeys.sty
(/usr/share/texmf/tex/generic/pgf/utilities/pgfkeys.code.tex))
(/usr/share/texmf/tex/latex/pgf/math/pgfmath.sty
(/usr/share/texmf/tex/generic/pgf/math/pgfmath.code.tex
(/usr/share/texmf/tex/generic/pgf/math/pgfmathcalc.code.tex
(/usr/share/texmf/tex/generic/pgf/math/pgfmathutil.code.tex)
(/usr/share/texmf/tex/generic/pgf/math/pgfmathparser.code.tex
\pgfmath@dimen=\dimen142
\pgfmath@count=\count113
\pgfmath@box=\box35
\pgfmath@toks=\toks24
\pgfmath@stack@operand=\toks25
\pgfmath@stack@operation=\toks26
)
(/usr/share/texmf/tex/generic/pgf/math/pgfmathfunctions.code.tex
(/usr/share/texmf/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex