Small changes in the file to fix some bugs when outside mac environments