fixed Mac OSX build