UPDATE: I think the current (as of 20/10/2014) AUCTeX through Macports works as intended and the below is not required.
How to get them to play nicely. If using the Macports emacs-app version of emacs there are couple of things to do to get AUCTeX to work properly with your TeXLive installation.
This assumes you are starting with no emacs and no AUCTeX, but with a working TexLive install.
- Install emacs-app using Macports
- Make a local port repository for MacPorts in your home dir following the instructions here.
- Add a local Portfile for Auctex by copying the existing one from your existing repository (following the guide to make the parent directories – in this case “local port repository”/editors/auctex)
- Edit the following line (41 in my file) to:
The original line points to a directory that doesn’t exist…
- Install Auctex using:
sudo port install auctex +emacs_app +mactex
- Edit your .emacs file to include the following line:
(setenv "PATH" (concat "/usr/texbin:" (getenv "PATH")))
That should be it to get C-C C-C to invoke latex and xdvi.