[distcc] how to make distcc work with make file and none-default location of g++ compiler?

dave woo dwu604250 at yahoo.com
Thu Feb 1 06:59:49 GMT 2007


Hmm.. I am not running the distccd using xinetd.d method. I am running it using --daemon mode. So there is no /etc/xinetd.d/distccd script. As I ran netstat -n. I do NOT see any connection using port 3632 either. I then change the order of the flag a little bit and also added the --port flag. My command become: "/home/local/distcc/bin/distccd --log-file=/var/log/distccd.log --port 8091 --allow 192.168.10.95 --daemon". As I check the log file, it seems the daemon started alright.

distccd[7780] (dcc_setup_daemon_path) daemon's PATH is /home/local/gcc-3.2.2/bin/:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin
distccd[7780] (dcc_listen_by_addr) listening on 0.0.0.0:8091
distccd[7780] (dcc_standalone_server) 1 CPU online on this server
distccd[7780] (dcc_standalone_server) allowing up to 3 active jobs
distccd[7781] (dcc_log_daemon_started) preforking daemon started (2.18.3 i686-pc-linux-gnu, built Jan 29 2007 16:24:04)

However, as I ran the 'netstat -n' to check on the listening port, I didn't see port 8091 in the list.

I then run a client machine using 
    make -j4 CXX='/home/local/distcc/bin/distcc g++'

The client mahcine has the ~/.distcc/hosts file set up as
    localhost 192.168.10.61

where 192.168.10.61 is the server machine that I just ran the distccd as described above. The compilation seems to run locally still....

Thanks again guys.

Dave Wu

----- Original Message ----
From: hgg <hgreig at bigpond.net.au>
To: distcc at lists.samba.org
Sent: Thursday, February 1, 2007 6:10:48 AM
Subject: Re: [distcc] how to make distcc work with make file and none-default location of g++ compiler?

dave woo wrote:
> Thnx to hgg's suggestion,
> 
> I have change the 127.0.0.1 to localhost in my ~/.distcc/hosts file now the local compiling is fine.
> Then I take a step further, I set up an server machine with the same g++ location, distcc location, same $PATH env. variable. I then start the distccd using "/home/local/distcc/bin/distccd --daemon --log-file=/var/log/distccd.log --listen 127.0.0.1 --allow 192.168.10.95" I then get the error in the log file:
> 
> distccd[7143] (dcc_setup_daemon_path) daemon's PATH is /home/local/gcc-3.2.2/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin
> distccd[7143] (dcc_listen_by_addr) ERROR: bind of 127.0.0.1:3632 failed: Address already in use
> distccd[7143] (dcc_exit) exit: code 102; self: 0.000000 user 0.001999 sys; children: 0.000000 user 0.000000 sys
> 
> or without the --listen flag, I still got the error:
> distccd[7028] (dcc_setup_daemon_path) daemon's PATH is /home/local/gcc-3.2.2FC3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin
> distccd[7028] (dcc_listen_by_addr) ERROR: bind of 0.0.0.0:3632 failed: Address already in use
> distccd[7028] (dcc_exit) exit: code 102; self: 0.000999 user 0.000999 sys; children: 0.000000 user 0.000000 sys
> 
> examining the top output, I see no distccd running either.....
> Getting closer...
> 
> Dave Woo
> 

check for /etc/xinetd.d/distccd or similar. inetd or xinetd could be 
"holding" that port for you but with incorrect flags to have distccd work.
alternatively some other program has misassigned that port to itself, 
try netstat -n to see if that port is listed.
hgg

> ----- Original Message ----
> From: dave woo <dwu604250 at yahoo.com>
> To: Michael Casadevall <sonicmctails at aol.com>
> Cc: distcc at lists.samba.org
> Sent: Wednesday, January 31, 2007 3:30:28 PM
> Subject: Re: [distcc] how to make distcc work with make file and none-default location of g++ compiler?
> 
> Hi guys,
> 
> GNU Make 3.80
> Linux kernel 2.6.1x
> 
> The g++ used use is installed at /home/local/gcc-3.2.2/bin, so 
> # /home/local/gcc-3.2.2/bin/g++ -v
> Reading specs from /home/local/gcc-3.2.2/lib/gcc-lib/i686-pc-linux-gnu/3.2.2/specs
> Configured with: ../gcc/configure --prefix=/home/local/gcc-3.2.2 --exec-prefix=/home/local/gcc-3.2.2 --enable-threads --disable-symvers --enable-shared
> Thread model: posix
> gcc version 3.2.2
> 
> The distcc version on the client machine is 
> # /home/local/distcc/bin/distcc -v
> Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.4/specs
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=i386-redhat-linux
> Thread model: posix
> gcc version 3.4.4 20050721 (Red Hat 3.4.4-2)
> 
> At this stage, I am simply trying to use distcc on the local machine, so I set the ~/.distcc/hosts with a single 127.0.0.1, which should means local host.
> # cat ~/.distcc/hosts 
> 127.0.0.1
> 
> Also now my $PATH environment variable is
> # echo $PATH
> /home/local/gcc-3.2.2/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin
> So like I said, the first search path is /home/local/gcc-3.2.2/bin.
> 
> I am not running distccd on the client machine and no server is specified so it should compile local by calling make -j2 CXX='distcc g++'
> 
> 
> 
> ----- Original Message ----
> From: Michael Casadevall <sonicmctails at aol.com>
> To: dave woo <dwu604250 at yahoo.com>
> Cc: distcc at lists.samba.org
> Sent: Wednesday, January 31, 2007 2:48:04 PM
> Subject: Re: [distcc] how to make distcc work with make file and none-default location of g++ compiler?
> 
> It sounds like its a having trouble working with the remote distcc  
> server. It looks like your compiling for a 64-bit platform - it would  
> greatly help if I can have more information on your full setup. I've  
> seen broken pipe if distcc bombs abnormally on either machine, or  
> your make is broken (possible with some older versions of BSD Make).  
> Also, if you manually run distcc (running each command by hand) does  
> it still bomb, and does make -n complete successfully. Some info  
> would really be useful; Namely:
> 
> Version of Make
> Build system (Linux/BSD/etc) on both the host/target
> gcc -v 's output
> Version of distcc on both machines,
> DISTCC_HOSTS
> Connection between the hosts
> Anything else that would be relevant.
> Michael
> 
> On Jan 30, 2007, at 11:22 PM, dave woo wrote:
> 
>> Thanks Michael,
>>
>> I am using a homebrew makefile. My makefile works fine without the  
>> using -j2 option and distcc.
>> I realize that since I have set the /home/local/gcc-3.2.2/bin/ to  
>> be the first search able directory path, I should be able to invoke  
>> distcc as "make -j2 distcc=g++". Then I am getting a different error.
>> /home/local/distcc/bin/distcc g++ -c -g -D_DEBUG -fasm -finline- 
>> functions -fno-rtti  -Wall -D_REENTRANT -D__int64="long long"  
>> ac3.cpp -o ac3.o
>> /home/local/distcc/bin/distcc g++ -c -g -D_DEBUG -fasm -finline- 
>> functions -fno-rtti  -Wall -D_REENTRANT -D__int64="long long"  
>> RegionBegin_3.cpp -o RegionBegin_3.o
>> distcc[5498] (dcc_writex) ERROR: failed to write: Connection refused
>> distcc[5497] (dcc_writex) ERROR: failed to write: Connection refused
>> ..............
>> distcc[5498] (dcc_writex) ERROR: failed to write: Broken pipe
>>
>> what does it mean failed to write: Connection refused?
>>
>> ----- Original Message ----
>> From: Michael Casadevall <sonicmctails at aol.com>
>> To: dave woo <dwu604250 at yahoo.com>
>> Cc: distcc at lists.samba.org
>> Sent: Tuesday, January 30, 2007 7:23:43 PM
>> Subject: Re: [distcc] how to make distcc work with make file and  
>> none-default location of g++ compiler?
>>
>> distcc should follow the system path looking for GCC. If the path is
>> set for 3.2 to be found by default (aka gcc --version shows the
>> compiler you want), distcc gcc should work. What looks like it seems
>> to be a bug in your makefile. Are you using a homebrew makefile, or
>> autoconf/cmake/scons/etc?
>> Michael
>>
>> On Jan 29, 2007, at 11:55 PM, dave woo wrote:
>>
>>> Hi guys,
>>>
>>> I have installed the distcc properly, and I havea simple makefile
>>> with two simple .cpp file that uses the default g++ compiler under
>>> the system path. I use the "make -j2 CXX=distcc" method to compile.
>>> This works fine.
>>>
>>> However, for my actual working project, I am using an older version
>>> of g++ compiler installed at specific location, ie, /home/local/
>>> gcc-3.2.2/bin/g++. I have set up the ~/.distcc/hosts file with one
>>> single entry of 127.0.0.1, so its simply running locally. I also
>>> set the system path to include "/home/local /home/local/gcc-3.2.2F/
>>> bin/" as the first path to be searched. Even though I thought this
>>> should not be necessary because I am using the absolute path to
>>> call the desired g++.  Anyways, when I try "make -j2 CXX='distcc /
>>> home/local/gcc-3.2.2/bin/g++', and examine the actual command
>>> actually run by the makefile, I get "/home/local/distcc/bin/distcc /
>>> home/local /home/local/gcc-3.2.2F/bin/g++ -CXXFLAGS filenames.cpp".
>>> Then the error is that the extra "/home/local" can not be found!
>>> where does this extra "/home/local" come from? So of course
>>> compilation fails.
>>> Any ideas guys?
>>>
>>> Thanks in advance!
>>>
>>> Dave.


__ 
distcc mailing list            http://distcc.samba.org/
To unsubscribe or change options: 
https://lists.samba.org/mailman/listinfo/distcc





 
____________________________________________________________________________________
Now that's room service!  Choose from over 150,000 hotels
in 45,000 destinations on Yahoo! Travel to find your fit.
http://farechase.yahoo.com/promo-generic-14795097


More information about the distcc mailing list