[OS X Emacs] Re: [Aquamacs-bugs] latex error continued...
david.reitter at gmail.com
Thu Sep 18 18:29:05 EDT 2008
to inspect a variable in Emacs, type C-h v variablename RET.
Please inspect the variable `TeX-command-list' after loading your TeX
file. For me, it has an element like this:
("LaTeX" "%`%l%(mode)%' %t" TeX-run-TeX nil
:help "Run LaTeX")
Now inspect `TeX-expand-list'.
This should have an entry
("%`" (lambda nil
(setq TeX-command-pos t TeX-command-text "")))
Also, please check `LaTeX-command', which should simply be "latex".
Finally, please have a look at `buffer-file-name', called from within
the buffer that you're compiling.
The next thing to do would be to create a new buffer, paste the code
below (a new definition of the AUCTeX function TeX-command) and then
do M-x eval-buffer RET.
This will add a debug output.
When you then attempt to compile your LaTeX file, you should get some
additional information in your *Messages* buffer, beginning with
"executing latex command".
This line is something we would want to see to help you fix this
Finally, I presume that you're trying this with a new, minimal LaTeX
document without much content.
http://aquamacs.org -- Aquamacs: Emacs on Mac OS X
http://aquamacs.org/donate -- Could we help you? Return the favor and
support the Aquamacs Project!
(defun TeX-command (name file &optional override-confirm)
"Run command NAME on the file returned by calling FILE.
FILE is the symbol of a function returning a file name. The
function has one optional argument, the extension to use on the
Use the information in `TeX-command-list' to determine how to run
If OVERRIDE-CONFIRM is a prefix argument, confirmation will be
asked if it is positive, and suppressed if it is not."
(cond ((eq file 'TeX-region-file)
(setq TeX-current-process-region-p t))
((eq file 'TeX-master-file)
(setq TeX-current-process-region-p nil)))
(let ((command (TeX-command-expand (nth 1 (assoc name TeX-command-
(hook (nth 2 (assoc name TeX-command-list)))
(confirm (if override-confirm
(> (prefix-numeric-value override-confirm) 0)
(nth 3 (assoc name TeX-command-list)))))
;; Verify the expanded command
(read-from-minibuffer (concat name " command: ") command
;; Now start the process
(setq file (funcall file))
(TeX-process-set-variable file 'TeX-command-next TeX-command-Show)
(message "executing latex command: %s" command)
(funcall hook name command file)))
On 18 Sep 2008, at 11:09, Jesper Ryge wrote:
> Enter your bug report here.
> error when attempting compile latex document:
> Running `LaTeX' on `cv-long-jr' with ``%`pdflatex \nonstopmode%' cv-
> /bin/sh: -c: line 1: unexpected EOF while looking for matching ``'
> /bin/sh: -c: line 2: syntax error: unexpected end of file
> LaTeX exited abnormally with code 2 at Thu Sep 18 17:02:47
> persist in:
> /Applications/Aquamacs\ Emacs.app/Contents/MacOS/Aquamacs\ Emacs -q &
> but not in
> /Applications/Aquamacs\ Emacs.app/Contents/MacOS/Aquamacs\ Emacs -Q &
> in -Q it runs the pdflatex on the open *.tex file as in a terminal
> window - as far as i can tell.
> In GNU Emacs
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 2193 bytes
Desc: not available
More information about the MacOSX-Emacs