当我将示例文档编译为 PDF 时,它可以在 Ubuntu 存储库版本的 TeXLive 上运行,但现在在我昨晚运行的安装中,一切都坏了。
这是我编译时得到的输出,下面列出了我正在编译的文件。你知道问题出在哪里吗?或者至少知道我该如何修复它?
\documentclass[12pt,letterpaper]{article}
\usepackage{mla}
\usepackage{setspace}
\usepackage{calc}
\begin{document}
\begin{mla}{Christopher}{Cooper}{Mrs.~Mills}{English 9 H}{27 October 2012}{An Exploration}
%body here
\end{mla}
\end{document}
给出日志
This is pdfTeX, Version 3.1415926-2.4-1.40.13 (TeX Live 2012)
restricted \write18 enabled.
entering extended mode
(./poem.tex
LaTeX2e <2011/06/27>
Babel <v3.8m> and hyphenation patterns for english, dumylang, nohyphenation, ge
rman-x-2012-05-30, ngerman-x-2012-05-30, afrikaans, ancientgreek, ibycus, arabi
c, armenian, basque, bulgarian, catalan, pinyin, coptic, croatian, czech, danis
h, dutch, ukenglish, usenglishmax, esperanto, estonian, ethiopic, farsi, finnis
h, french, friulan, galician, german, ngerman, swissgerman, monogreek, greek, h
ungarian, icelandic, assamese, bengali, gujarati, hindi, kannada, malayalam, ma
rathi, oriya, panjabi, tamil, telugu, indonesian, interlingua, irish, italian,
kurmanji, latin, latvian, lithuanian, mongolian, mongolianlmc, bokmal, nynorsk,
polish, portuguese, romanian, romansh, russian, sanskrit, serbian, serbianc, s
lovak, slovenian, spanish, swedish, turkish, turkmen, ukrainian, uppersorbian,
welsh, loaded.
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/size12.clo))
(/usr/local/texlive/2012/texmf-dist/tex/latex/mla-paper/mla.sty
MLA Package - by Ryan Aycock
! Undefined control sequence.
l.67 \ifpdf
% We're generating a pdf
?
答案1
看起来这个mla
包是有缺陷的,因为它\ifpdf
没有使用任何机制来定义它。然而,加载包的简单步骤ifpdf
似乎可以解决问题
\documentclass[12pt,letterpaper]{article}
\usepackage{ifpdf}
\usepackage{mla}
\usepackage{setspace}
\usepackage{calc}
\begin{document}
\begin{mla}{Christopher}{Cooper}{Mrs.~Mills}{English 9 H}{27 October 2012}{An Exploration}
%body here
\end{mla}
\end{document}
(我怀疑为什么 mla
正在测试 PDF 模式,但那是另一回事。)