Hi,
I prefer xetex as my default tex engine. But this will cause a AucTeX
bug when the master filename contains a space.
The following is a minimal example. It contains only one master file "foo
bar.tex". Notice the filename contains a space. And the content of "foo
bar.tex" is just the following:
\documentclass{article}
\begin{document}
Hello world
\end{document}
%%% Local Variables:
%%% mode: latex
%%% TeX-master: t
%%% TeX-engine: xetex
%%% End:
Now if press C-c C-c to compile this file. AucTeX will return the
following error message:
Running `LaTeX' on `foo bar' with ``xelatex -file-line-error --synctex=1 -interaction=nonstopmode "\input" ^"\^"foo bar.tex\^"^"''
This is XeTeX, Version 3.14159265-2.6-0.99996 (TeX Live 2016/W32TeX) (preloaded format=xelatex)
restricted \write18 enabled.
entering extended mode
LaTeX2e <2016/03/31> patch level 3
Babel <3.9r> and hyphenation patterns for 83 language(s) loaded.
! I can't find file `'"foo bar.tex"''.
<*> \input '"foo bar.tex"'
(Press Enter to retry, or Control-Z to exit)
Please type another input file name
! Emergency stop.
<*> \input '"foo bar.tex"'
If I switch my tex engine to pdflatex, then this problem will
gone. Moreover, if run the following command in a terminal
xelatex --file-line-error --synctex=1 -interaction=nonstopmode "\input" "foo bar.tex"
Then it also works well. So I assume this is a AucTeX bug.
Best,