Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 17243 - xfree-4.3.0-r1 compile failed with distcc crosscompile
Summary: xfree-4.3.0-r1 compile failed with distcc crosscompile
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-03-10 13:31 UTC by Tom Ward
Modified: 2003-09-06 17:52 UTC (History)
6 users (show)

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


Attachments
patch to current stable ebuild to inherit CC preference in xfree build (xfree-4.3.0-r2.ebuild.patch,441 bytes, patch)
2003-07-25 07:40 UTC, Francois Guimond
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Ward 2003-03-10 13:31:38 UTC
to use a cross compiler on distcc servers, it is necessary to fully qualify the compiler 
name (ie. powerpc-unknown-linux-gcc rather than cc). The Makefile for xfree-4.3.0-r1 
uses cc, so the compile fails.
Comment 1 Martin Schlemmer (RETIRED) gentoo-dev 2003-03-10 21:37:47 UTC
And I assume you tested this withouth distcc/cross compile as well ?
Comment 2 Seemant Kulleen (RETIRED) gentoo-dev 2003-04-11 12:04:51 UTC
well, tom?
Comment 3 Tom Ward 2003-04-11 12:46:05 UTC
Yes, sorry, compiles fine without using distcc. Same problem as a host of other ebuilds 
Martin was looking at for me. I changed my mind about upgrading from 4.2.0 until the 
DRI mach64 patches are quite ready... Anyway, to rephrase this as Martin prefers:  
 
ACCEPT_KEYWORDS="~ppc" CC=powerpc-unknown-linux-gnu-gcc emerge 
=xfree-4.3.0-r1  
 
ignores CC, and uses gcc instead. (This goes for most of the other xfree ebuilds btw...) 
 
I'm not sure where the root of this is coming from, but at least it seems to manifest 
itself in the allegedly autogenerated (but not at my end....?) 
work/xc/config/imake/Makefile  
 
The Xfree build process looks a little too involved for me to sus out right now - good 
luck and thanks. 
Comment 4 Martin Schlemmer (RETIRED) gentoo-dev 2003-04-12 15:30:23 UTC
I just do not really get the time to sit down and have a look at it.  Will
try to get to it real soon.
Comment 5 Seemant Kulleen (RETIRED) gentoo-dev 2003-05-29 04:53:46 UTC
zach -- got any input?
Comment 6 Seemant Kulleen (RETIRED) gentoo-dev 2003-06-30 08:29:57 UTC
lisa, got ideas?
Comment 7 Lisa Seelye (RETIRED) gentoo-dev 2003-06-30 10:22:36 UTC
What type of architectures are you trying to mix and which one is the powerpc-unknown-linux-gnu-gcc? (what are the other(s)? )

What arch is issuing the emerge command?
Comment 8 Tom Ward 2003-06-30 13:20:04 UTC
The ppc arch is doing the emerge, an x86 (athlon) is running the distcc server and ppc 
crosscompiler. But that's irrelevant - the problem isn't the mix of architectures, it's 
that the Makefile ignores CC=x-gcc in the environment. 
Comment 9 Francois Guimond 2003-07-25 07:40:01 UTC
Created attachment 14999 [details, diff]
patch to current stable ebuild to inherit CC preference in xfree build


The problem is that xfree build defines its own CC variable through "#define
CcCmd gcc" in its config files.  In order to inherit the
CC=powerpc-unknown-linux-gnu-gcc needed for distcc to work (I tried this on a
powerpc, with a pentium2 helping it through distcc), this patch makes the
ebuild add "#define CcCmd ${CC}" to host.def when building.

I'm not sure if this will break anything for others though, perhaps it would be
best to put this in a test where it is only set if the CC env variable is NOT
equal to "gcc".
Comment 10 John Steele Scott 2003-07-25 19:15:44 UTC
Francois' patch works for me.

If there is any doubt about whether it might break things for some people (which I don't think it will, unless perhaps Intel's CC can't build XFree?), could this perhaps be put into the snapshot ebuilds for testing?

Now my complaint is that the get_number_of_jobs() function in the ebuild reduces the my MAKEOPTS from -j5 to -j2, which is a pain since I want the job to run over three distcc hosts. But that's a whole nother story (see bug 25294).
Comment 11 Donnie Berkholz (RETIRED) gentoo-dev 2003-07-31 14:19:23 UTC
If no one has any objections I'll add this to 4.3.99.9 and 4.3.0-r3 a few days later.
Comment 12 Donnie Berkholz (RETIRED) gentoo-dev 2003-08-03 01:56:11 UTC
Added to 4.3.99.9. Give it a try.
Comment 13 Donnie Berkholz (RETIRED) gentoo-dev 2003-09-06 17:52:23 UTC
Added to 4.3.0-r2 and 4.3.0-r3.