Installing AUCTeX in EmacsW32

I’m posting this mainly to remind myself how I did it, when the time comes to do it again. I added some detailed instructions (like where to cd to and so on) in case somebody else is interested in these instructions. So let’s see:

  • I downloaded AUCTeX 11.84 from http://www.gnu.org/software/auctex/download-for-windows.html
  • I also downloaded and installed MSYS, but in the end I didn’t use it because my existing cygwin environment did the job nicely
  • I already had EmacsW32 (version GNU Emacs 22.0.990.1 (i386-mingw-nt6.0.6000) of 2007-05-23 on LENNART-69DE564 (patched))installed, as well as MiKTeX 2.7 beta (freshly downloaded on August 31 2007) and Ghostscript (8.53). I think these are all the relevant packages.
  • I unpacked the AUCTeX zip file in c:tempauctex-11.84
  • I ran the cygwin bash shell (I did this as administrator, although that would probably not have been necessary until the installation step) and cd’d to c:/temp/auctex-11.84
  • I made sure that the paths to the Emacs binary, the MiKTeX binaries and the Ghostscript binaries were part of my Windows PATH environment variable.
  • I ran the following configure command: ./configure --prefix='c:/Program Files/Emacs' --with-texmf-dir='c:/ProgramData/MiKTeX/2.7' --with-lispdir='c:/Program Files/Emacs/site-lisp'
    The first two parameters are taken from the installation readme – well, to some degree. I’m not really clear why the prefix is apparently correct this way, because on Windows this prefix does not lead to the “standard” Emacs directory hierarchy. The texmf dir is specific to MiXTeX, and if you’re using a version of MiXTeX older than (I think) 2.5, you’d probably have to use something like c:/localtexmf instead. Finally, I had to use the lispdir option because configure wouldn’t find the site-lisp directory without it – even though it’s right there in the prefix directory. Go figure.
  • I did not use the –disable-preview option, which I should probably have done. According to the docs, the preview package doesn’t currently work with this version of Emacs, and sure enough, it doesn’t seem to work although I didn’t have any trouble building and installing it.
  • I executed make
  • I executed make install (this is the step that actually requires administrator privileges, so you might be fine running everything up to this point as a non-privileged user)
  • Finally I edited the file site-start.el in my site-lisp directory and added these lines (collected from various places in the docs):
    (load "auctex.el" nil t t)
    (load "preview-latex.el" nil t t)
    (require 'tex-mik)
    (eval-after-load 'info
           '(add-to-list 'Info-directory-list "c:/Program Files/Emacs/share/info"))
    (setq TeX-auto-save t)
    (setq TeX-parse-self t)

And that’s it. So far I’m not having any trouble with this installation. Have fun!

2 Comments on Installing AUCTeX in EmacsW32

  1. "Have fun!" Hm, an odd concept of fun šŸ˜‰

    Like

  2. Thank you for your tip! It works for me

    Like

Leave a Comment

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s