Update version to 4.0.2.1.
Fix change-version.sh to work on mac and liux.