Fixes for running on ubuntu