The pgplot packages shipped with ubuntu are not consistently compiled using -fPIC, which results
in an unusable cpgplot wrapper-lib on AMD64 machines. This is the reason for tempo2 failing to compile.
The following pgplot5-package fixes this problem, install using 'dpkg -i pgplot5_5.2.2-8.1_amd64.deb'
/pub/ATLAS/CompilingTempo2OnUbuntuAMD64/Pgplot5_5.2.2-8.1_amd64.deb.bz2