I know this does not really answer your question but I would re-install Ubuntu with Ubuntu 12.04 LTS and you will have zero issues to install Postgresql 9.3. Rule of thumb is: if you get stuck with installation tasks you are asking for way more trouble when in production.
Just my oppinion but followed this advice with everything I install. Running dozens of clustered postgresql servers myself.