fixed build in OS X