enter image description here

I installed the latest version of MacTex, and I am sure the latex is in the Libray/TeX/texbin/, I just don't know how to set the PATH variable, also I cannot install the AUCtex, I assume these two are the same PATH problem. I have no idea how to solve these.

enter image description here

  • Can you compile a LaTeX document from the command line? How did you install AUCTeX? – giordano Oct 15 '16 at 8:13
  • I could use LaTex and pdflatex to compile and get the output PDF file, even I got some warning like Underfull \hbox (badness 10000) in paragraph at lines 12--22. The problem is I could not directly use latex or pdflatex in the commend line to do it, I need give the full path (such as '/Library/TeX/texbin/latex blabla.tex`), I think the problem is I don't have PATH variable to locate the executable. – bagMan Oct 15 '16 at 14:10
  • What does this question have to do with Emacs? Yes, AUCTex is in Emacs, but this is a question about your OS PATH value, no? – Drew Oct 15 '16 at 15:50
  • 1
    I'm voting to close this question as off-topic because it doesn't seem to be about Emacs. – Drew Oct 15 '16 at 15:50
  • Ok, where should I change the PATH value, I am new with the shell and command line interface. I've looked up some similar problem, but I still don't know how to solve it. – bagMan Oct 15 '16 at 15:56

Try adding (setenv "PATH" "/usr/local/bin:/Library/TeX/texbin/:$PATH" t) to your .emacs :)

| improve this answer | |
  • 1
    Welcome to Emacs.SE! In general, please add a little bit more explanation to your answers. This specific question is off-topic, though, so it's not necessarily worth it this time around. – Dan Apr 9 '18 at 8:44

Not the answer you're looking for? Browse other questions tagged or ask your own question.