[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Preview with TeX-output-dir and luatex

From: Braun, Michael
Subject: Preview with TeX-output-dir and luatex
Date: Sun, 12 Jun 2022 22:10:31 +0000

I just upgraded to AucTeX 13.1.3, and want to use the new feature of putting 
intermediate and preview files in a subdirectory.  So I set TeX-output-dir to 
“build”, and all works well for compiling pdf documents with the default and 
LuaTeX engines, and all preview functions with the default engine.  With 
luatex, preview-document also works.  But if TeX-engine is luatex, and I run  
preview-at-point or preview-buffer, I get the following error:

Running `Preview-LaTeX' on `~/Documents/build/_region_' with ``lualatex 
--jobname=build/_region_  -file-line-error  --output-directory="build/" 
 "\input" "\detokenize{" _region_.tex "}"''
This is LuaHBTeX, Version 1.15.0 (TeX Live 2022) 
 restricted system commands enabled.
LaTeX2e <2022-06-01> pre-release-0 (develop 2022-6-12 branch)
L3 programming layer <2022-06-02>
No auxiliary output files.

./build//_region_.tex:0: I can't write on file `build/_region_.log'.
Please type another transcript file name
./build//_region_.tex:0: Emergency stop
./build//_region_.tex:0:  ==> Fatal error occurred, no output PDF file produced!
TeX Output exited as expected with code 1 at Sun Jun 12 16:42:15
LaTeX: LaTeX found no preview images

There is a build subdirectory, and in it there is a _region_.tex file, but no 
_region_.log file is generated.  The error occurs whether or not I cache the 
preamble.  If TeX-output-dir is nil, everything works well, as expected.

Here’s a minimal working example that generates the error.


test $\alpha + \beta$.  %% preview should appear here.


% Local Variables: %
% TeX-engine: luatex  %.  
% TeX-output-dir: "build" %
% End: %

FWIW, I’m using Aquamacs 3.6 (based on emacs 25.3) on MacOS, with Ghostscript 

Any idea about what’s going on, and/or how to fix this?


Michael Braun, Ph.D.
Associate Professor of Marketing, and
  Corrigan Research Professor
Cox School of Business
Southern Methodist University
Dallas, TX 75275

reply via email to

[Prev in Thread] Current Thread [Next in Thread]