fix building fail on Mac Platform