fix macosx compilcation