Lean Emacs mode requires Emacs version 24.3 (or greater). This version is not available by default in Ubuntu 12.04. You have to execute the following commands to install it.
Use the following commands to install Lean using PPA:
Once installed via PPA, you can use the standard
sudo apt-get upgrade to get the latest version of Lean.
leanemacs starts Emacs with the Lean mode automatically configured for you.
If you prefer you can manually configure the Lean Emacs mode using the instructions available here.