fix build on os x