Hi! Preface. I have installed Gentoo on my PowerBook with 1GHz CPU. Problem. Compilation is darn slow! Solution: SMP PC from server room trash can, Gentoo's "crosdev -t" & distcc == magic ;-) Problem: Not all packages are correctly referring to host compiler by full name. Gentoo people seem to patch configuration systems as much as they can, but yet many packages (even if told implicitly to use compiler by full name) dumbly call "gcc" or "cc" or "g++". When that reaches my i686 gcc, it gets very confused by "-mcpu=G4". Worse part that it often sends compiled .o to client and it gets errors much later during linking - since .o is built for i686 not PowerPC. Solution: patch distccd to replace commands send from particular hosts to provided local commands.
Please review the (not tested) patch. (It is against 2.18.3 - but I
checked it against tla repository and see no conflicts.) It adds to
distccd command line option "--subst-rcmd [EMAIL PROTECTED]". When distccd
sees command RCMD from client with address IP it replaces the command
with LCMD. (Wildcards for RCMD/LCMD and IP are possible, though I'm
not yet sure are needed).
For my case it would look like that:
$ distccd --allow 1.1.1.0/24 \
--subst-rcmd [EMAIL PROTECTED] \
--subst-rcmd [EMAIL PROTECTED]
To tell distccd to run for client 1.1.1.2 commands prefixed with
powerpc-unknown-linux-gnu instead of plain local gcc/g++.
I had no chance to test it (but it compiles already) since I'm not
sure that I fix problem on right end. There are arguments in my head
for fix on both sides: distcc and distccd. But I'm not sure what is
better. Best is of course to fix broken build systems out there - what
isn't option due to vast number of them.
If anybody from distcc/d developers can provide any comments or
feedback or input on proposed command line option and/or proper way to
do that - it would be greatly appreciated.
I have time to test and make real patch for the change, If anybody
is really interested out there.
--
Don't walk behind me, I may not lead.
Don't walk in front of me, I may not follow.
Just walk beside me and be my friend.
-- Albert Camus (attributed to)
distcc-subst_rcmd-2.18.3.patch
Description: Binary data
__ distcc mailing list http://distcc.samba.org/ To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/distcc
