Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 340595 - Support for multiple distccd instances
Summary: Support for multiple distccd instances
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Gentoo Cluster Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-11 21:40 UTC by Simon Koch
Modified: 2013-02-03 12:57 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to the distcc init script (distccd_multi_instance.patch,885 bytes, patch)
2010-10-11 21:42 UTC, Simon Koch
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Koch 2010-10-11 21:40:30 UTC
I wanted to set up my server to be able to host distccd for both x86_64 and i686 clients.  In order for it to be able to do the right thing for ebuilds that invoke the compiler as just "gcc" instead of something like "i686-pc-linux-gnu-gcc", I decided to run one instance of distccd for each architecture.

Toward that end, I modified the distccd init.d script to support the DISTCCD_PATH environment variable, and to create new distccd instances by making a symlink to /etc/init.d/distccd.  This allows me to set up directories with wrapper scripts or symlinks from "gcc" to the appropriate compiler.  The main advantages of this are: 1) No need to create wrapper scripts on each client 2) works with both crossdev and scripts that wrap the native compiler (e.g. adding -m32 flag to compile i686 with an x86_64 compiler).

Reproducible: Always

Steps to Reproduce:
Comment 1 Simon Koch 2010-10-11 21:42:34 UTC
Created attachment 250277 [details, diff]
Patch to the distcc init script

I'm not sure if this is the preferred method of setting an environment variable for the daemon or if start-stop-daemon -e or env is better.
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2010-10-12 18:03:23 UTC
I could mark this as a duplicate of bug #243502, the ongoing effort to stop bad upstream programming practices: fixing packages that disrespect (the canonical quintuplet) CC is really what you want to achieve here. But I will let maintainers of distcc decide.
Comment 3 Simon Koch 2010-10-12 19:19:45 UTC
(In reply to comment #2)

Agreed.  Ideally, this wouldn't be needed.  But for now it seems like a practical workaround.