I was wondering if anyone could help me with this problem. Well,
actually, I have hordes of errors in my LaTeX file, so I am trying to
narrow them down using \includeonly. But I really don't understand
what TeX is doing. I still get tons of errors from the parts of my
project that I have [i]deleted[/i], which TeX shouldn't be reading at
all.
Here is my main file, Test.tex:
\documentclass[a4paper,12pt,openany,oneside]{book}
\includeonly{Utilities/UsePackages}
\include{Utilities/UsePackages}
\begin{document}
\include{Utilities/InputFiles}
\end{document}
It includes two files. "Utilities/UsePackages" looks like this:
\usepackage[english]{babel}
\usepackage[latin1]{inputenc}
\usepackage{cuted}
\usepackage{graphicx}
\usepackage{makeidx}
\usepackage{marvosym}
\usepackage{tipa}
\usepackage{verbatim}
%\usepackage{showidx}
\usepackage[pdftex,colorlinks,pdfstartview=FitH]{hyperref}
And "Utilities/InputFiles" is [i]empty[/i].
When I try to compile Test.tex, I get this:
[PDFLaTeX] Test.tex => Test.pdf (pdflatex)
[PDFLaTeX] finished with exit status 1
./Test.tex:5:No counter 'IC' defined. \include{Utilities/InputFiles}
./Test.tex:5:No counter 'Founding of Irokas' defined.
\include{Utilities/InputFiles}
./Test.tex:5:No counter 'Fall of Nom' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'Founding of Nom' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'First Dragons' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'Founding of the Vaimon Empire' defined.
\include{Utilities/InputFiles}
./Test.tex:5:No counter 'Darkfall' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'Carz' defined. \include{Utilities/InputFiles}
./Test.tex:5:No counter 'Founding of Imetrium' defined.
\include{Utilities/InputFiles}
./Test.tex:5:No counter 'Fall of Belkade' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'Founding of Belkade' defined.
\include{Utilities/InputFiles}
./Test.tex:5:No counter 'Siege of Fendor' defined. \include{Utilities/
InputFiles}
./Test.tex:5:No counter 'Runger war' defined. \include{Utilities/
InputFiles}
[PDFLaTeX] 13 errors, 0 warnings, 0 badboxes
All these errors made sense in my original, big project. But now I
have deleted everything except the lines I showed above. And still the
error messages persist.
Can someone please help me: What is TeX doing? Where do these errors
come from?
Many thanks in advance. :)
PS: I am using Kile under Linux.
That actually is clear! The errors will come from the auxilliary
files, which you can delete.
(When a file is skipped due to \includeonly, LaTeX uses the counter
settings saved in the .aux file to keep track of sectioning and pages.
Donald Arseneau as...@triumf.ca
> Hello.
>
> I was wondering if anyone could help me with this problem. Well,
> actually, I have hordes of errors in my LaTeX file, so I am trying to
> narrow them down using \includeonly. But I really don't understand what
> TeX is doing. I still get tons of errors from the parts of my project
> that I have [i]deleted[/i], which TeX shouldn't be reading at all.
Delete the .aux files. \include will not read the .tex files when you use
\includeonly, but it _will_ read the .aux files (for example, to see how
many pages the skipped chapter had so that the page numbers still are
right.)
> Here is my main file, Test.tex:
> \documentclass[a4paper,12pt,openany,oneside]{book}
> \includeonly{Utilities/UsePackages}
> \include{Utilities/UsePackages}
You should use \input here rather than \include. (\include is designed
with separate chapters in mind, not generic read-external-file, and very
much not for use in the preamble.)
HTH
Ulrich