章立てのエラー

章立てのエラー

章ごとの参考文献を作成しようとしています。chapterbib パッケージを使用し、rsc 参考文献スタイルを使用しています。問題は、最後にコンパイルされないことです。以下は私が使用している前文の一部です。

\documentclass[12pt,a4paper]{book}
\usepackage[utf8]{inputenc}
\usepackage[greek,francais]{babel}
\usepackage[T1]{fontenc}
\usepackage[left=2cm,right=2cm,top=3cm,bottom=3cm]{geometry}
\usepackage{chapterbib}
\usepackage{rsc}
\usepackage{fancyhdr}
\pagestyle{fancy}
\usepackage[numbers]{natbib}
\usepackage{hyperref}
\hypersetup{colorlinks=true, linkcolor=blue,citecolor=blue}

\begin{document}

\include{partie_1}
\include{annexe_1}

\end{document}

各パートの最後には以下が含まれます:

\blibliographystyle{angew}
\bibliography{biblio.bib}

次のエラーメッセージのみが表示されます:

This is BibTeX, Version 0.99d (TeX Live 2012) The top-level auxiliary file:
maitre.aux A level-1 auxiliary file: partie_1.aux The style file: angew.bst
A level-1 auxiliary file: annexe_1.aux Illegal, another \bibstyle
command---line 5 of file annexe_1.aux : \bibstyle : {angew} I'm skipping
whatever remains of this command Illegal, another \bibdata command---line 6 
of file annexe_1.aux : \bibdata : {rsc-maitre,biblio} I'm skipping whatever
remains of this command Database file #1: rsc-maitre.bib Database file #2:
biblio.bib (There were 2 error messages)

chapterbib を使用しなくても、問題なく動作します。

編集: 他の投稿を見た後、pdflatex -> bibtex -> pdflatex (x2) -> view pdf の順にソースファイルを起動する前に、各ファイルで bibteX を起動したことを明確にしたいと思います。

答え1

これを行うには、またはスクリプトを作成できますMakefile。スクリプトは、TexMaker または他のエディターから呼び出すことができます。

Linux では、Makefileこの目的のために を使用します。実行するだけmakeですべてがコンパイルされます! :)

またはMakefileスクリプトは、エディターの設定に「固執」する必要がないため便利です。ターミナルから実行することもできるので、好きなエディターを使用できます。

次にMakefile例を示します。

# Main project filename (without .tex extention)
FILE=main

all:
    $(MAKE) latex
    $(MAKE) bibperchapter
    $(MAKE) latex
    $(MAKE) latex
    dvipdf \
        -dPDFSETTINGS=/prepress \
        -dGrayImageResolution=600 \
        -dColorImageResolution=600 \
        -dMonoImageResolution=600 \
        -dSubsetFonts=true \
        -dEmbedAllFonts=true \
        -dMaxSubsetPct=100 \
        -dCompatibilityLevel=1.5 \
        -sPAPERSIZE=a4 $(FILE).dvi

bibperchapter:
    for auxfile in text/ch*.aux ; do \
        bibtex $(basename $$auxfile .aux) ; \
    done

latex:
    latex -interaction batchmode $(FILE)

これは各章ごとに(pdftex)Makefileを実行し、dviファイルをpdfに変換します(私はdvipsドライバを使用しています)。ターゲットに注意してください。章の場所に応じて編集する必要があります。この場合、章はlatexbibtexbibperchapter文章/フォルダとすべてのファイル名はch-

必要に応じて変更できます。使用するプラットフォーム (Windows、Linux、MacOS) に簡単に適応できます。

答え2

わかりました。メイン ファイルを pdflatex で手動でコンパイルし、含まれている部分ごとに bibtex を 1 回ずつ実行し、メイン ファイルで pdflatex を 2 回実行するだけでよかったようです...

TexMaker を使って高速コンパイルすることは可能でしょうか?...

関連情報