[ccache] sharing a cache

Anders Furuhed anders.furuhed at pantor.com
Thu Apr 3 21:55:55 EST 2003

Enno Rehling wrote:

> we're considering using ccache and sharing the cache between 
> developers here. I've followed the instructions in the manpage, but 
> ccache doesn't seem to realize that the object file is already in the 
> cache, and compiles a new one for every user.
> - The output files have the same md5sum.
> - The input files have the same datestamp (I rsynced them)
> - I'm compiling from different home directories and machines
> Does any of this play into ccache's decision about whether two 
> compilations are equal? Apart from the command line, what parameters 
> go into the hash?
> When both developers use the same machine, they can share the cache. 
> If they are on separate machines, it seems that they can't. Is there a 
> way around this?
> Enno.
Hi Enno,

you get these misses only if different hosts are used?
In that case, have you verified that the same compiler (its size and 
modification time) is used on the separate machines?
It does not matter that the trees are not in the same place unless your 
code for instance uses #defines to compile the path into the 
preprocessed output.
The timestamp of the source code does not matter at all.

Don't give up, ccache and distcc are wonderful :)

Anders Furuhed

More information about the ccache mailing list