fix xcode can not compile
Merge pull request #7367 from geron-cn/chukongv2

fix xcode can not compile