Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Sparc install w/distcc
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc
View previous topic :: View next topic  
Author Message
ookabooka
n00b
n00b


Joined: 22 Jul 2003
Posts: 36
Location: root@localhost.localdomain

PostPosted: Thu Jul 24, 2003 5:43 pm    Post subject: Sparc install w/distcc Reply with quote

Ok. I've been looking through the archives, and I can't seem to get anything to work quite right. First off, I am confused as to what I should put for the CHOST setting in the make.conf file. Should it be Sun4u-unkown-linux-gnu? (for a Ultra10) or sparc64-unknown-linux-gnu. And can I substitute anything for unknown, like "Ultra10" for example? And for the CC flags. The only thin I need to have(for an uber optimized system) is -mcpu=ultrasparc(should be replaced with v9???) -O3 -pipe -M64. That would make everything 64 bit correct? Now, as far as distcc goes, I have 3 athlon 1800+ xp and above systems I would like to help this lil 333mhz out. I bootstrapped and emerged distcc(w/ all dependencies) all on the sparc. I then added "distcc" to FEATURES and DISTCC_HOSTS="Athlon1 Athlon2 Athlon3" to the make.conf file. When I did an emerge on the first dependency in "emerge system -p" (sparc-utils) it did it all locally(even though I didn't put localhost in the DISTCC_HOSTS). I then switched the CC and CXX in env to "distcc gcc" and "distcc g++" and it sucessfully sent the distcc requents, except it failed to compile on all machines. . . is there some sort of setting I need in order to get gcc or g++ to compile sparc binaries? Verbose mode wasn't helpful, just told me that it gave "exit code 1" whatever that means. . . Anyone have any ideas, or any good sparc w/distcc howto's. I got distcc to work with my athlons on another x86 system, compiled really fast, except for the occasion incompatable package, which i would just do locally. Sorry to make such a long post, I just wanted to make sure there was enough info. Anyone have any ideas on how to get distcc working? Is there some reason it won't compile things on my x86s? or why portage isn't using distcc even though its in the features?

edit: if I want to use ccache(who wouldn't) can I only put it on the athlons, or will it only work if I put it on the sparc(sparc has little hd space)? Is the problem that my athlon's don't have a cross compiler installed? how would I go about doing that?
_________________
CFLAGS="-march=i386 -m64"
from root (/) : mount -t proc proc proc
Back to top
View user's profile Send private message
adam613
n00b
n00b


Joined: 25 Jun 2003
Posts: 21
Location: The Big Apple

PostPosted: Sat Jul 26, 2003 3:27 pm    Post subject: Reply with quote

You asked several questions:

Quote:
First off, I am confused as to what I should put for the CHOST setting in the make.conf file.


Use "sparc-unknown-linux-gnu". Techinically "unknown" should be replaced by "sun4m", "sun4u", or whatever, but this reportedly breaks some builds. Using "sparc64-unknown-linux-gnu" also causes some packages to fail to compile (like scripts/bootstrap.sh, for example).

Quote:
And for the CC flags. The only thin I need to have(for an uber optimized system) is -mcpu=ultrasparc(should be replaced with v9???) -O3 -pipe -M64.


"-mcpu=ultrasparc -O3 -pipe" should work. Using "-O2" might give faster results under some circumstances, and "-O3" used to produce bad code on rare occasions on x86. Now, I'm not sure it makes any difference.

Do not use -m64. It will cause everything to fail to compile since you don't have a 64-bit glibc available. Only the kernel will compile in 64-bit, and that will happen by default.

Quote:
That would make everything 64 bit correct?


Making everything 64-bit is much much much much more complicated than that. I've been working on it for a couple weeks, and I'll let y'all know when I've figured out how to do it.

Quote:
is there some sort of setting I need in order to get gcc or g++ to compile sparc binaries?


You need to build a cross-compiler. There's no ebuild to do this (although there probably should be), so you'll need to do it by hand. Look for instructions here: https://forums.gentoo.org/viewtopic.php?t=29985&highlight=sparc64 Make sure you build a sparc-unknown-linux-gnu cross compiler; if you build one for sparc64, your binaries will fail to link.

The "exit code 1" probably means either you gave gcc an illegal command-line option or it couldn't find the correct gcc.

Also, you'll need to set CC="distcc sparc-unknown-linux-gnu-gcc".

Not sure what to do about ccache, as I haven't tried it yet. Hope this helps though.
Back to top
View user's profile Send private message
ookabooka
n00b
n00b


Joined: 22 Jul 2003
Posts: 36
Location: root@localhost.localdomain

PostPosted: Sat Jul 26, 2003 7:18 pm    Post subject: Reply with quote

yes, that answered many of my questions, thanks a lot. I have read some of the posts about a completely 64-bit build. I look forward to that, I will keep fidling here and see if I can get one, Seems to me if u can get a good 64-bit gcc and glib, the rest ought to be easy :). Keep me posted
_________________
CFLAGS="-march=i386 -m64"
from root (/) : mount -t proc proc proc
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum