1. 编译 .bib时出现 Can't open file name 'XXXXX.aux' 错误
解决方案:
来源:https://tex.stackexchange.com/questions/166831/cant-open-reference-aux
Let's suppose your references are written in a file called 'ref.bib' with entries like:
@article{latex1977,
title={How to use latex},
author={John Smith},
journal={Journal of Latex},
pages={1--50},
volume={39},
year={1977}
}
Now in your main file say 'main.tex' you have to have something like:
\documentclass{article}
\begin {document}
...
\cite{latex1977}
...
\bibliography{ref}
\bibliographystyle{plain}
\end{document}
To compile your document do this steps:
1. compile 'main.tex' using latex or pdflatex => this step will generate main.aux file
2. compile 'main.aux' (NOT 'ref.bib') using bibtex
3. compile twice 'main.tex' using latex or pdflatex
=========================================================
=========================================================
如果不好使,可以试试这个神奇方法试一下(我用的MacTex ,系统10.15.5)
补一个Mactex的下载地址:http://www.tug.org/mactex/
step1:确定已经建立了正确的.bib文件,路径也对(和.tex文件在一个路径下)
step2:检查下名字
\bibliography{XXX} 这条语句中的XXX和XXX.bib文件是不是一个名字
(应该是同一个名字,不是就调一下吧)
举例子:ref.bib
那么,语句应该是\bibliography{ref}
step3:打开.tex文件,先用LaTeX 执行下"排版"操作,生成.aux文件和一大沓子其他的(重要的是这个.aux)
如图
(第二个选项框选LaTeX,点 "排版" 按钮)
step4:还是这个.tex文件,第二个选项框选BibTeX,再次点“排版”按钮
如图
(第二个选项框选BibTeX,点 "排版" 按钮)
step5:还是这个.tex文件,第二个选项框选LaTeX,再次点“排版”按钮
然后就可以啦,那个引用就出来了! ^▽^ ~