Fixed build on OSX