I have installed MacTex and GNU Emacs on my iMac. I have created a simple tex file (the one suggested here) and tried to run LaTeX on it by hitting C-c C-c, but the following message appeared:
ERROR: AUCTeX cannot find a working TeX distribution.
Make sure you have one and that TeX binaries are in PATH environment variable.
If you are using OS X El Capitan or later
remember to add /Library/TeX/texbin/ to your PATH
Opening Terminal and running
echo $PATH
yields
/Library/Frameworks/Python.framework/Versions/3.4/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin
Operating system: macOS Sierra, Version 10.12.4
Emacs version: 25.1.1
AUCTeX version: 11.90.0
MacTex distribution: MacTeX-2016
(getenv "PATH")
in the scratch buffer to check.