Necessary changes to realize OSX packaging

Changes necessary to make successfull packaging possible on OSX with
py2app.