bibtopic 与 latexmk

bibtopic 与 latexmk

当尝试使用 latexmk 编译以下文档时,我收到以下警告:

latexmk -cd -f -pdf -interaction=nonstopmode -synctex=1 minimal.tex

Package bibtopic Warning: Please (re)run BibTeX on the file(s):
(bibtopic)                minimal1
(bibtopic)                and after that rerun LaTeX.

我如何告诉 latexmk 我希望它在生成的文件上运行 bibtex书目主题

\documentclass{article}
\usepackage{bibtopic}
\usepackage{natbib}

\begin{document}
\citet{GTG}

\bibliographystyle{plainnat}
\begin{btSect}{reports}
    \section{Reports}
    \btPrintCited
\end{btSect}


\end{document}

编辑

我按照@john-collins 的建议添加了参考书目样式,但仍然收到相同的警告,并且除了节标题外没有参考书目输出。我的 .bib 文件很好,因为我已经将它与其他几个 LaTeX 文档一起使用,没有任何问题。

bibtopic 为不同的参考书目创建单独的 .bbl 和 .aux 文件,从不同的 .bib 文件中读取(这是我想要的,这就是我尝试使用该包的原因)。在本例中,它创建了以下文件:

--- minimal1.aux ---
%% Info from `bibtopic.sty': natbib loaded.
\bibstyle{plainnat}
\citation{*}
\bibdata{reports}

--- minimal1.bbl ---
%%% produced automatically by bibtopic.sty v1.1
%%% produced automatically by bibtopic.sty v1.1
\csname bt@warn@outdated\endcsname{minimal1}

这是它提供的日志输出,只是为了完整起见(我在我的系统上隐藏了路径minimal.tex):

This is pdfTeX, Version 3.14159265-2.6-1.40.18 (TeX Live 2017/Debian) (preloaded format=pdflatex 2019.6.15)  2 FEB 2020 20:22
entering extended mode
 \write18 enabled.
 %&-line parsing enabled.
**minimal.tex
(<some path>/minimal.tex
LaTeX2e <2017-04-15>
Babel <3.18> and hyphenation patterns for 33 language(s) loaded.
(/usr/share/texlive/texmf-dist/tex/latex/base/article.cls
Document Class: article 2014/09/29 v1.4h Standard LaTeX document class
(/usr/share/texlive/texmf-dist/tex/latex/base/size10.clo
File: size10.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
)
\c@part=\count79
\c@section=\count80
\c@subsection=\count81
\c@subsubsection=\count82
\c@paragraph=\count83
\c@subparagraph=\count84
\c@figure=\count85
\c@table=\count86
\abovecaptionskip=\skip41
\belowcaptionskip=\skip42
\bibindent=\dimen102
)
(/usr/share/texlive/texmf-dist/tex/latex/bibtopic/bibtopic.sty
Package: bibtopic 2006/09/08 v1.1a Sectioned Bibliographies

(/usr/share/texlive/texmf-dist/tex/latex/base/ifthen.sty
Package: ifthen 2014/09/29 v1.1c Standard LaTeX ifthen package (DPC)
)
\c@btauxfile=\count87
\bt@infilea=\read1
\bt@infileb=\read2
\bt@outfile=\write3
\bt@tempboxa=\box26
)
(/usr/share/texlive/texmf-dist/tex/latex/natbib/natbib.sty
Package: natbib 2010/09/13 8.31b (PWD, AO)
\bibhang=\skip43
\bibsep=\skip44
LaTeX Info: Redefining \cite on input line 694.
\c@NAT@ctr=\count88
)
(<some path>/minimal.aux)
\openout1 = `minimal.aux'.

LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 5.
LaTeX Font Info:    ... okay on input line 5.
LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 5.
LaTeX Font Info:    ... okay on input line 5.
LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 5.
LaTeX Font Info:    ... okay on input line 5.
LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 5.
LaTeX Font Info:    ... okay on input line 5.
LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 5.
LaTeX Font Info:    ... okay on input line 5.
LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 5.
LaTeX Font Info:    ... okay on input line 5.


Package natbib Warning: Citation `GTG' on page 1 undefined on input line 6.

\openout3 = `btaux.aux'.

\openout3 = `minimal1.aux'.

(<some path>/minimal1.bbl)

Package bibtopic Warning: Please (re)run BibTeX on the file(s):
(bibtopic)                minimal1
(bibtopic)                and after that rerun LaTeX.


Package natbib Warning: There were undefined citations.

[1

{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}]
(<some path>/minimal.aux) ) 
Here is how much of TeX's memory you used:
 840 strings out of 494267
 10764 string characters out of 6162828
 64391 words of memory out of 5000000
 4264 multiletter control sequences out of 15000+600000
 4553 words of font info for 17 fonts, out of 8000000 for 9000
 395 hyphenation exceptions out of 8191
 23i,4n,22p,136b,116s stack positions out of 5000i,500n,10000p,200000b,80000s
</usr/sha
re/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmbx10.pfb></usr/share/tex
live/texmf-dist/fonts/type1/public/amsfonts/cm/cmbx12.pfb></usr/share/texlive/t
exmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb>
Output written on "<some path>/minim
al.pdf" (1 page, 25638 bytes).
PDF statistics:
 20 PDF objects out of 1000 (max. 8388607)
 13 compressed objects within 1 object stream
 0 named destinations out of 1000 (max. 500000)
 1 words of extra memory for PDF output out of 10000 (max. 10000000)

相关内容