bootstrap: sync with upstream.

This revision fixes some small bugs, and is compatible with
non-gnu awk and non-gnu sed again.
* bootstrap: sync with upstream.