[distcc] Corrupted object files when using ccache + distcc

Gavrie Philipson gavrie at disksites.com
Thu Aug 21 16:47:20 GMT 2003

I am using ccache (version 2.2) together with distcc (version 2.10) to
compile, on a Red Hat 9 machine.
The problem is that I get corrupted object files: a few of the object
files are simply comprised of null bytes. They do have the correct size,
and they are correctly cached, but somehow between distcc and ccache
they are corrupted.

I am using the directory shadowing method, with the following path:

The DISTCC_HOSTS variable points to one host only, which is a similarly
configured machine as the host I'm compiling on.
The steps are as follows:

1. Clean the cache with 'ccache -C'
2. Run 'make clean'
3. Run the make

At the linking stage, the corrupted object files are detected and the
make fails (main.o: File format not recognized). Looking at the object
file shows it's all null bytes.
Doing a 'make clean' and recompiling (this time the object files come
from the cache) works fine.

Compiling with ccache by itself works fine, as well as compiling with
distcc by itself. It's only when the two are combined that the problem
I have tested this by compiling some standard projects (cscope and the
Linux kernel) -- always with the same problem.

Any ideas? People who had a similar experience?

-- Gavrie. 

More information about the distcc mailing list