Fix build on MacOSX