Updated to work on non-precise ubuntu versions