Add more log messages.

Also, add more O_CLOEXEC flags.
Don't discard current environment when running a forked process.
Allow to use absolute input path in the direct cache.
Fix bug with a wrong order of members' destruction in |FileCache|.

Explicitly destroy the thread pool before the database.
Improve the parsing deps facility.

To support a llvm build.
Enable sync writing to cache by default.

To lower a memory footprint.