When the root cache is not writable use home_cache

The home_cache is `~/Library/Caches/Homebrew` on MacOS and
`~/.cache/Homebrew` on other systems.
Closes Homebrew/linuxbrew#17.