update pin build script for mac