Patch from Alvaro Herrera This won't work with MSVC until we fix up src/tools/msvc.
For some reason we are getting intermittent failures, so this sets it explicitly in the frozen config sent to the server.
This was broken way back at commit ecca968. It's now of largely historical interest, so I'm not going to push a release just to push the bug fix.
There have been suspicions in the past that ccache can be a bit less than robust on failure, and so we have long removed the cache in such cases. However, this results in less than optimal use of ccache, so this behaviour is disabled unless there is a specific config setting to enable it. Per gripe from Tom Lane.
It turns out that setting up the build directory with aname that includes the pid almost entirely defeats ccache when used with vpath builds (although it's fine for use with non-vpath builds). We actually don't need that, and we can quite happily use a hardcoded name, so now the build dir is "$target.build" instead of "$target.$$". It's true we might get a collision if there has been a bad crash, but then that's also true of the hardcoded "inst" directory, so using the pid in the name doesn't protect us anyway. The locking code is quite enough to make sure we won't actually have two live runs colliding in the same directory, so the only thing we could possibly collide with are the remnants of a dead run that has not exited cleanly. We also abandon the idea of a per branch ccache. That turns out to have been quite misguided, and simply results in an unnecessary extra use of disk space.
msysGit treats a path that starts with a / as relative to its own directory, rather than relative to the root directory on the current drive. We therefore use abs_path to make sure the directory for the mirror we're trying to clone has a drive specifier.
Commit 61ace80 changed to only add the .log suffix if the name didn't contain a dot. I'm not at all sure why that was done, and it seems completely wrong, since the tar command only picks up .log files. SO make sure there is a .log suffix on every log file written. Per report from Tomas Vondra.
It can't run installcheck because it requires a special wal_level. Still some work to do, but it runs on Unix.