Fixing error compiling on macosx