我在 TL 2016 下使用 lualatex 时遇到了问题。datetime
感谢回答datetime-package-不适用于 tl-2016 中的 lualatex该解决方案解决了使用 lualatex 进行编译时的问题。但现在使用 tex4ht 时失败了。所以我认为最好就此提出新问题,因为这是不同的系统。
这是 MWE
\documentclass[11pt]{scrbook}%ext
\IfFileExists{luatex85.sty}%only do this when TL 2016
{
\usepackage{luatex85}
\edef\pdfcreationdate{\pdffeedback creationdate}
}
{}
\usepackage[us,12hr]{datetime}
\begin{document}
\currenttime
\end{document}
使用 TL 2016 时,上述代码编译成功,没有错误,但在使用 lualatex 的选项下lualatex
会出现错误。make4ht
lua
make4ht --lua foo.tex
......
(/usr/local/texlive/2016/texmf-dist/tex/generic/luatex85/luatex85.sty)
! unexpected use of \pdffeedback.
\reserved@a ...def \pdfcreationdate {\pdffeedback
creationdate}
l.7 {}
?
我使用 lualatex 和 tex4ht 编译了所有 latex 文件。上述软件包在 TL 2015 中均能顺利运行。
这是今天安装的新 TL 2016。
这是文件列表
File List*
scrbook.cls 2016/05/10 v3.20 KOMA-Script document class (book)
scrkbase.sty 2016/05/10 v3.20 KOMA-Script package (KOMA-Script-dependent bas
ics and keyval usage)
scrbase.sty 2016/05/10 v3.20 KOMA-Script package (KOMA-Script-independent b
asics and keyval usage)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
scrlfile.sty 2016/05/10 v3.20 KOMA-Script package (loading files)
tocbasic.sty 2016/05/10 v3.20 KOMA-Script package (handling toc-files)
scrsize11pt.clo 2016/05/10 v3.20 KOMA-Script font size class option (11pt)
typearea.sty 2016/05/10 v3.20 KOMA-Script package (type area)
luatex85.sty 2016/05/23 v1.2 pdftex aliases for luatex
datetime.sty 2015/03/20 v2.60 Date Time Package
etoolbox.sty 2015/08/02 v2.2a e-TeX tools for LaTeX (JAW)
fmtcount.sty 2015/05/05 v3.01
ifthen.sty 2014/09/29 v1.1c Standard LaTeX ifthen package (DPC)
xkeyval.sty 2014/12/03 v2.7a package option processing (HA)
xkeyval.tex 2014/12/03 v2.7a key=value parser (HA)
fcprefix.sty 2012/09/28
fcnumparser.sty 2012/09/28
ifxetex.sty 2010/09/12 v0.6 Provides ifxetex conditional
amsgen.sty 1999/11/30 v2.0 generic functions
fc-english.def 2013/08/17
datetime-defaults.sty 2013/09/10
完整控制台列表:
make4ht --lua foo.tex
Output dir:
Compiler: dvilualatex
Latex options: -jobname=foo
tex4ht.sty : xhtml,
tex4ht
build_file foo.mk4
Cannot open config file foo.mk4
setting param correct_exit
setting param correct_exit
setting param correct_exit
setting param ext
Adding: ext dvi
LaTeX call: dvilualatex -jobname=foo '\makeatletter\def\HCode{\futurelet\HCode\HChar}\def\HChar{\ifx"\HCode\def\HCode"##1"{\Link##1}\expandafter\HCode\else\expandafter\Link\fi}\def\Link#1.a.b.c.{\g@addto@macro\@documentclasshook{\RequirePackage[#1,html]{tex4ht}}\let\HCode\documentstyle\def\documentstyle{\let\documentstyle\HCode\expandafter\def\csname tex4ht\endcsname{#1,html}\def\HCode####1{\documentstyle[tex4ht,}\@ifnextchar[{\HCode}{\documentstyle[tex4ht]}}}\makeatother\HCode xhtml,.a.b.c.\input foo'
This is LuaTeX, Version 0.95.0 (TeX Live 2016)
restricted system commands enabled.
LaTeX2e <2016/03/31>
Babel <3.9r> and hyphenation patterns for 1 language(s) loaded.
(./foo.tex
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrbook.cls
Document Class: scrbook 2016/05/10 v3.20 KOMA-Script document class (book)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrkbase.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrbase.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrlfile.sty
Package scrlfile, 2016/05/10 v3.20 KOMA-Script package (loading files)
Copyright (C) Markus Kohm
))) (/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/tocbasic.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrsize11pt.clo)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/typearea.sty
Package typearea, 2016/05/10 v3.20 KOMA-Script package (type area)
Copyright (C) Frank Neukam, 1992-1994
Copyright (C) Markus Kohm, 1994-
)) (/usr/local/texlive/2016/texmf-dist/tex/generic/tex4ht/tex4ht.sty)
(/usr/local/texlive/2016/texmf-dist/tex/generic/tex4ht/usepackage.4ht)
(/usr/local/texlive/2016/texmf-dist/tex/generic/luatex85/luatex85.sty)
! unexpected use of \pdffeedback.
\reserved@a ...def \pdfcreationdate {\pdffeedback
creationdate}
l.7 {}
?
这是完整的控制台输出lualatex
,没有错误:
lualatex foo.tex
This is LuaTeX, Version 0.95.0 (TeX Live 2016)
restricted system commands enabled.
(./foo.tex
LaTeX2e <2016/03/31>
Babel <3.9r> and hyphenation patterns for 1 language(s) loaded.
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrbook.cls
Document Class: scrbook 2016/05/10 v3.20 KOMA-Script document class (book)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrkbase.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrbase.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrlfile.sty
Package scrlfile, 2016/05/10 v3.20 KOMA-Script package (loading files)
Copyright (C) Markus Kohm
))) (/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/tocbasic.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/scrsize11pt.clo)
(/usr/local/texlive/2016/texmf-dist/tex/latex/koma-script/typearea.sty
Package typearea, 2016/05/10 v3.20 KOMA-Script package (type area)
Copyright (C) Frank Neukam, 1992-1994
Copyright (C) Markus Kohm, 1994-
)) (/usr/local/texlive/2016/texmf-dist/tex/generic/luatex85/luatex85.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/datetime/datetime.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/etoolbox/etoolbox.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/fmtcount/fmtcount.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/base/ifthen.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/local/texlive/2016/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/local/texlive/2016/texmf-dist/tex/generic/xkeyval/xkvutils.tex)))
(/usr/local/texlive/2016/texmf-dist/tex/latex/fmtcount/fcprefix.sty
(/usr/local/texlive/2016/texmf-dist/tex/latex/fmtcount/fcnumparser.sty))
(/usr/local/texlive/2016/texmf-dist/tex/generic/ifxetex/ifxetex.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/amsmath/amsgen.sty)
(/usr/local/texlive/2016/texmf-dist/tex/latex/fmtcount/fc-english.def))
(/usr/local/texlive/2016/texmf-dist/tex/latex/datetime/datetime-defaults.sty))
(./foo.aux) [1{/usr/local/texlive/2016/texmf-var/fonts/map/pdftex/updmap/pdftex
.map}] (./foo.aux))
364 words of node memory still in use:
2 hlist, 1 vlist, 1 rule, 6 glue, 44 glue_spec, 1 write nodes
avail lists: 1:2,2:28,3:2,4:1,5:13,6:29,7:23,8:2,9:12,11:3
</usr/local/texlive/2016/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb>
Output written on foo.pdf (1 page, 11263 bytes).
Transcript written on foo.log.
答案1
只需更新到最新版本的luatex85
软件包并删除:
\edef\pdfcreationdate{\pdffeedback creationdate}
\pdfcreationdate
(现在)以与 兼容的方式定义dviluatex
。