I have a single master file and several other .tex files are included in this master file.

TeX-source-correlate mode is enabled for forward search.

For the master file forward search is working but when I do it on some other .tex files, Emacs raises an error that says that the corresponding PDF file is not found.

I have included the master file name at the end of every included .tex file.

  • How exactly is the master added in the other files?
    – daleif
    Jun 25, 2014 at 5:50
  • @daleif %%%TeX-master : "/path/to/master.tex"
    – Shahzad
    Jun 25, 2014 at 5:52
  • 1
    Remove the extension.
    – giordano
    Jun 25, 2014 at 5:54
  • 1
    Did you write that data manually? You should not, use C-c _ to set the master
    – daleif
    Jun 25, 2014 at 6:46

1 Answer 1


TeX-master requires the path of the master file but without the extension (.tex is hardcoded). You can easily specify the master file in secondary files with C-C _ (or M-x TeX-master-file-ask RET or, from the menu bar, LaTeX > Multifile/Parsing > Set Master File), as suggested by daleif.

In addition, I'd suggest you to add

(setq-default TeX-master nil)

to your .emacs file, as suggested in the very first lines of the AUCTeX manual, so every time you open a new *TeX you will be automatically prompted to select the master file.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .