Fix compilation for Apple OSes.