better build script for mac