[ccache] patch to avoid empty stderr cache files

Koblinger Egmont egmont at uhulinux.hu
Sat Jun 7 19:29:51 EST 2003


Hi,

> I noticed, however, that it generates a .stderr file in the cache
> directory for each compiled file, even if there is no output on stderr.
> This is a little bit wasteful -- we don't need the stderr file in the
> very common case of the compiler not producing any warnings.

Nice idea.

Just one comment. It seems to me that you place the output file in the
cache first and stderr later. This way if ccache is interrupted between
these two steps it will result in a syntactically valid but false cache
content (recompiling the same code will swallow stderr). So the stderr
file should be placed first in the cache and the output afterwards.


cheers,
Egmont




More information about the ccache mailing list