I tested it only with preview-latex. Suppose we have a LaTeX file: \documentclass[11pt,a4paper,oneside]{article} \usepackage{amsmath} \begin{document} The Euilers formula is: \begin{equation*} e^{ix} = \cos x + i \sin x \end{equation*} \end{document} I can compile and view it in emacs with AUCTeX package by C-cC-c and see that it's correct. But if we try to do a C-cC-pC-p with preview-latex package we get this log: Running `Preview-LaTeX' on `bug' with ``latex -ini -interaction=nonstopmode "&latex" prv_bug.ini "\nonstopmode\nofiles\PassOptionsToPackage{active,tightpage,auctex}{preview}\AtBeginDocument{\ifx\ifPreview\undefined\RequirePackage[displaymath,floats,graphics,textmath,sections,footnotes]{preview}[2004/11/05]\fi}" "\input" bug.tex'' This is pdfTeX, Version 3.1415926-1.40.11 (TeX Live 2010) (INITEX) restricted \write18 enabled. entering extended mode (./prv_bug.ini LaTeX2e <2009/09/24> Babel <v3.8l> and hyphenation patterns for english, dumylang, nohyphenation, bu lgarian, russian, ukrainian, ukenglish, usenglishmax, loaded. (/usr/share/texmf-dist/tex/latex/carlisle/mylatex.ltx) (/usr/share/texmf-dist/tex/latex/tools/.tex File ignored)) No auxiliary output files. (./bug.tex (/usr/share/texmf-dist/tex/latex/base/article.cls Document Class: article 2007/10/19 v1.4h Standard LaTeX document class (/usr/share/texmf-dist/tex/latex/base/size11.clo)) (/usr/share/texmf-dist/tex/latex/amsmath/amsmath.sty For additional information on amsmath, use the `?' option. (/usr/share/texmf-dist/tex/latex/amsmath/amstext.sty (/usr/share/texmf-dist/tex/latex/amsmath/amsgen.sty)) (/usr/share/texmf-dist/tex/latex/amsmath/amsbsy.sty) (/usr/share/texmf-dist/tex/latex/amsmath/amsopn.sty)) ) Beginning to dump on file prv_bug.fmt (format=prv_bug 2011.1.16) 6061 strings of total length 81386 56191 memory locations dumped; current usage is 273&54849 4092 multiletter control sequences \font\nullfont=nullfont \font\OMX/cmex/m/n/10=cmex10 \font\tenln=line10 \font\tenlnw=linew10 \font\tencirc=lcircle10 \font\tencircw=lcirclew10 \font\OT1/cmr/m/n/5=cmr5 \font\OT1/cmr/m/n/7=cmr7 \font\OT1/cmr/m/n/10=cmr10 \font\OML/cmm/m/it/5=cmmi5 \font\OML/cmm/m/it/7=cmmi7 \font\OML/cmm/m/it/10=cmmi10 \font\OMS/cmsy/m/n/5=cmsy5 \font\OMS/cmsy/m/n/7=cmsy7 \font\OMS/cmsy/m/n/10=cmsy10 \font\OT1/cmr/m/n/10.95=cmr10 at 10.95pt \font\OT1/cmr/m/n/8=cmr8 \font\OT1/cmr/m/n/6=cmr6 \font\OML/cmm/m/it/10.95=cmmi10 at 10.95pt \font\OML/cmm/m/it/8=cmmi8 \font\OML/cmm/m/it/6=cmmi6 \font\OMS/cmsy/m/n/10.95=cmsy10 at 10.95pt \font\OMS/cmsy/m/n/8=cmsy8 \font\OMS/cmsy/m/n/6=cmsy6 \font\OMX/cmex/m/n/10.95=cmex10 at 10.95pt \font\OMX/cmex/m/n/8=cmex8 \font\OMX/cmex/m/n/6=cmex7 at 6.0pt \font\OT1/cmr/m/n/12=cmr12 \font\OT1/cmr/m/n/9=cmr9 \font\OT1/cmr/bx/n/10.95=cmbx10 at 10.95pt \font\OT1/cmr/bx/it/10.95=cmbxti10 at 10.95pt \font\OT1/cmr/m/it/10.95=cmti10 at 10.95pt \font\OT1/cmtt/m/n/10.95=cmtt10 at 10.95pt \font\OT1/cmss/m/n/10.95=cmss10 at 10.95pt 9129 words of font info for 33 preloaded fonts 220 hyphenation exceptions Hyphenation trie of length 36449 has 1053 ops out of 35111 377 for language 7 224 for language 6 138 for language 5 119 for language 4 12 for language 3 2 for language 1 181 for language 0 0 words of pdfTeX memory 0 indirect objects No pages of output. Transcript written on prv_bug.log. Preview-LaTeX finished at Sun Jan 16 02:30:40 Running `Preview-LaTeX' on `_region_' with ``latex -interaction=nonstopmode "&prv_bug" _region_.tex'' This is pdfTeX, Version 3.1415926-1.40.11 (TeX Live 2010) restricted \write18 enabled. entering extended mode (./_region_.tex LaTeX2e <2009/09/24> Babel <v3.8l> and hyphenation patterns for english, dumylang, nohyphenation, bu lgarian, russian, ukrainian, ukenglish, usenglishmax, loaded. CUSTOMISED FORMAT. Preloaded files: . article.cls 2007/10/19 v1.4h Standard LaTeX document class size11.clo 2007/10/19 v1.4h Standard LaTeX file (size option) amsmath.sty 2000/07/18 v2.13 AMS math features amstext.sty 2000/06/29 v2.01 amsgen.sty 1999/11/30 v2.0 amsbsy.sty 1999/11/29 v1.2d amsopn.sty 1999/12/14 v2.01 operator names . No file _region_.aux. (/home/kravitz/.emacs.d/elpa/auctex-11.86/latex/preview.sty (/home/kravitz/.emacs.d/elpa/auctex-11.86/latex/prtightpage.def) (/home/kravitz/.emacs.d/elpa/auctex-11.86/latex/prauctex.def No auxiliary output files. (/home/kravitz/.emacs.d/elpa/auctex-11.86/latex/prauctex.cfg)) (/home/kravitz/.emacs.d/elpa/auctex-11.86/latex/prfootnotes.def) Preview: Fontsize 10.95pt ) !name(bug.tex) !offset(-3) ! Preview: Snippet 1 started. <-><-> l.8 \begin{equation*} Preview: Tightpage -32891 -32891 32891 32891 ! Preview: Snippet 1 ended.(702701+0x14782605). <-><-> l.10 \end{equation*} [1] ) (see the transcript file for additional information) Output written on _region_.dvi (1 page, 1732 bytes). Transcript written on _region_.log. Preview-LaTeX exited as expected with code 1 at Sun Jan 16 02:30:40 Running `Preview-DviPS' with ``dvips -Pwww _region_.dvi -o _region_.prv/tmp16611wuc/preview.ps'' This is dvips(k) 5.99 Copyright 2010 Radical Eye Software (www.radicaleye.com) ' TeX output 2011.01.16:0230' -> _region_.prv/tmp16611wuc/preview.ps </usr/share/texmf/dvips/base/tex.pro></usr/share/texmf/dvips/base/texps.pro> </usr/share/texmf/dvips/base/special.pro>. </usr/share/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb> </usr/share/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi8.pfb> </usr/share/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi10.pfb>[1] Preview-DviPS finished at Sun Jan 16 02:30:40 Running `Preview-Ghostscript' with ``gs -dOutputFile\=\(_region_.prv/tmp16611wuc/pr1-\%d.png\) -q -dSAFER -dNOPAUSE -DNOPLATFONTS -dPrinted -dTextAlphaBits\=4 -dGraphicsAlphaBits\=4 -sDEVICE\=png16m -r106.686x105.614'' Preview-Ghostscript finished at Sun Jan 16 02:30:40 No png images generated, I suppose that gs don't consider last command as correct. Downgrading the app-text/ghostscript by masking 9.00 version helps and all actions above work. Meanwhile the log looks same.
Created attachment 259933 [details] log for preview-latex
Created attachment 260026 [details, diff] auctex-11.86-ghostscript9.patch Thanks for the minimal example, this was helpful for reproducing the problem. Does attached patch fix the issue for you?
(In reply to comment #2) > Created an attachment (id=260026) [details] > auctex-11.86-ghostscript9.patch > > Thanks for the minimal example, this was helpful for reproducing the problem. > > Does attached patch fix the issue for you? > Thank you very much, yes this patch resolved the problem. Could you send your patch to the AUCTeX development mail list?
(In reply to comment #3) > Thank you very much, yes this patch resolved the problem. Fixed in -r1. Thank you for reporting. > Could you send your patch to the AUCTeX development mail list? It's taken from their CVS (see comment at beginning of the patch file): <http://cvs.savannah.gnu.org/viewvc/auctex/preview/preview.el?root=auctex&r1=1.284&r2=1.285>