More OS X build fixes