some fixes to make it work in the Xobni env