Fix OS X build