build.sh: pushd/popd are not POSIX

If /bin/sh is not bash, pushd/popd may be missing.