Update build.sh to detect brew's bsdtar on Mac OS X.