我想通过 pdftex 将一些 PDF 连接成一个,因此写入了如下 tex 文件:
% foo.tex
\documentclass[a4paper]{article}
\usepackage{pdfpages}
\begin{document}
\includepdf[nup=1x1, pages=-]{01-0_pp_i_iv_Frontmatter.pdf}
% and more
\end{document}
但是运行时出现错误pdflatex foo.tex
:
This is pdfTeX, Version 3.14159265-2.6-1.40.18 (TeX Live 2017) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
(./foo.tex
LaTeX2e <2017-04-15>
Babel <3.18> and hyphenation patterns for 84 language(s) loaded.
(/usr/local/texlive/2017/texmf-dist/tex/latex/base/article.cls
Document Class: article 2014/09/29 v1.4h Standard LaTeX document class
(/usr/local/texlive/2017/texmf-dist/tex/latex/base/size10.clo))
(/usr/local/texlive/2017/texmf-dist/tex/latex/pdfpages/pdfpages.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/base/ifthen.sty)
(/usr/local/texlive/2017/texmf-dist/tex/latex/tools/calc.sty)
(/usr/local/texlive/2017/texmf-dist/tex/latex/eso-pic/eso-pic.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/atbegshi.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/infwarerr.sty)
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/ltxcmds.sty)
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/ifpdf.sty))
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2017/texmf-dist/tex/latex/xcolor/xcolor.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics-cfg/color.cfg)
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics-def/pdftex.def)))
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics/graphicx.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics/graphics.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics/trig.sty)
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics-cfg/graphics.cfg)))
(/usr/local/texlive/2017/texmf-dist/tex/latex/pdfpages/pppdftex.def))
No file foo.aux.
(/usr/local/texlive/2017/texmf-dist/tex/context/base/mkii/supp-pdf.mkii
[Loading MPS to PDF converter (version 2006.09.02).]
) (/usr/local/texlive/2017/texmf-dist/tex/latex/oberdiek/epstopdf-base.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/oberdiek/grfext.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/kvdefinekeys.sty))
(/usr/local/texlive/2017/texmf-dist/tex/latex/oberdiek/kvoptions.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/kvsetkeys.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/etexcmds.sty
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/ifluatex.sty))))
(/usr/local/texlive/2017/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty)
(/usr/local/texlive/2017/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg))
(/usr/local/texlive/2017/texmf-dist/tex/latex/oberdiek/pdflscape.sty
(/usr/local/texlive/2017/texmf-dist/tex/latex/graphics/lscape.sty)
(/usr/local/texlive/2017/texmf-dist/tex/generic/ifxetex/ifxetex.sty))
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
[1 <./01-0_pp_i_iv_Frontmatter.pdf>]
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
[2 <./01-0_pp_i_iv_Frontmatter.pdf>]
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
[3 <./01-0_pp_i_iv_Frontmatter.pdf>]
pdfTeX warning: pdflatex (file ./01-0_pp_i_iv_Frontmatter.pdf): PDF inclusion:
found PDF version <1.6>, but at most version <1.5> allowed
[4 <./01-0_pp_i_iv_Frontmatter.pdf>]
...(Omitted)...
pdfTeX warning: pdflatex (file ./08-0_pp_45_70_Properties_of_extension_rings.pd
f): PDF inclusion: found PDF version <1.6>, but at most version <1.5> allowed
[83 <./08-0_pp_45_70_Properties_of_extension_rings.pdf>]
pdfTeX warning: pdflatex (file ./08-0_pp_45_70_Properties_of_extension_rings.pd
f): PDF inclusion: found PDF version <1.6>, but at most version <1.5> allowed
[84 <./08-0_pp_45_70_Properties_of_extension_rings.pdf>]Syntax Error: Couldn't read xref table
Syntax Warning: PDF file is damaged - attempting to reconstruct xref table...
Syntax Error: Couldn't find trailer dictionary
Syntax Error: Couldn't read xref table
!pdfTeX error: pdflatex (file ./09-0_pp_71_91_Valuation_rings.pdf): xpdf: readi
ng PDF image failed
==> Fatal error occurred, no output PDF file produced!
错误表明 PDF 已损坏,但是,据我在 PDF 查看器中看到的那样,PDF 似乎是正确的。
这个错误(特别是“无法读取外部参照表”)是什么意思?PDF 会损坏吗?或者,我该如何修复这样的错误?
答案1
当我将几张图片(eps 格式)插入 latex 文档时,我也遇到了同样的问题。在编译时,我不小心清除了所有辅助文件(使用 Tex-studio 中的“工具”->“清除辅助文件”选项)。我无法获取输出。然后我发现 eps 被转换为 Pdf 了一半(损坏状态)。我只是删除了那个 Pdf,你猜怎么着,编译成功了,我现在可以查看我的输出了。