Fix compilation with OSX 10.8 SDK