OS X.10 support

@mandli this is for you.