Fixing OS X compilation