我正在努力学习狮身人面像文档创建工具。我能够生成html文档。现在,为了创建一个离线版本的(html)文档,我一直试图从我的项目生成pdf文件。
为了实现这个目标,到目前为止,我已经尝试了以下方法(使用网络上可用的资源,包括狮身人面像文档):
将以下内容添加到conf.py中
# conf.py options for Latex
latex_engine = 'pdflatex'
latex_elements = {
'papersize': 'a4paper',
'pointsize': '10pt',
}随后,在终端中使用了命令make latexpdf,因此我在终端中得到了以下消息:
/Users/.../.../.../.../.../urls.py:docstring of lead.urls:5: WARNING: Definition list ends without a blank line; unexpected unindent.
/Users/.../urls.py:docstring of lead.urls:7: WARNING: Unexpected indentation.
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
processing lead.tex... index modules/...
resolving references...
done
writing... done
copying TeX support files... copying TeX support files...
done
build succeeded, () warnings.
The LaTeX files are in _build/latex.
Run 'make' in that directory to run these through (pdf)latex
(use `make latexpdf' here to do that automatically).
latexmk -pdf -dvi- -ps- 'lead.tex'
make[1]: latexmk: No such file or directory
make[1]: *** [lead.pdf] Error 1
make: *** [latexpdf] Error 2创建了一个新文件夹latex,其中包含许多文件,其中一个文件名为<project_name>.tex (上面错误日志中的lead.tex)和一个批处理文件make.bat。
但是,运行命令make只会产生以下错误:
latexmk -pdf -dvi- -ps- 'lead.tex'
make: latexmk: No such file or directory
make: *** [lead.pdf] Error 1根据latexmk上的一些线索(网上提供的材料),尝试从Tex站点安装BasicTex包。
然而,可用的软件包只适用于macOs 10.13及更高版本。我在10.12.6上。
所以我卡住了。如果对我的困境有任何解决办法,谁能告诉我吗?
发布于 2020-08-11 05:15:44
https://www.tug.org/mactex/faq/3-4.html在macOS 10.12.6上为我工作。
https://stackoverflow.com/questions/63351571
复制相似问题