Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
New Gentoo system & question
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
spam_
Tux's lil' helper
Tux's lil' helper


Joined: 14 Jan 2004
Posts: 105
Location: /dev/null

PostPosted: Wed Jan 14, 2004 10:24 pm    Post subject: New Gentoo system & question Reply with quote

I installed Gentoo on my Sun Ultra 1-170 (167MHz), 160MB RAM, CG6, 3x2GB HDDs in a software RAID-0. I have an external 6-CD changer (a Pioneer DRM-604X) which luckily has the 2048/512 byte selector switch on the back, so it's bootable from the OBP. I also have an external 4x/8x CD-R drive on it.

The root fs is on the RAID, it's ext3, I also have a /boot using ext3, size 60MB. Currently using around 1.4GB on root :)

Compiled with CFLAGS="-Os -mcpu=ultrasparc -pipe". Took me a week to get to this point, running almost every night. Would have been done 3 days earlier but I screwed up the RAID last time by partitioning onto cylinder 0 for the non-boot partitions, which trashed my partition tables. After I fixed the partition tables, this destroyed the ext3 FS beyond repair. Might be something worth explicitly noting in the install guide, I don't remember seeing any warning although I have to admit that the example partition setup avoids cylinder 0. :oops:

It runs pretty sweet, even in X although the 256 color dithering and colormapping looks nasty. The whole system is much better and faster than the previous modified Splack install, which took up 3GB. 8) Running a vanilla 2.4.24 kernel, as 2.6.x doesn't compile nicely for me. AFAIK sound will work fine, since I compiled kernels for Splack which had no trouble with sound, but I haven't tested that in Gentoo yet.

Kudos to all the Gentoo devs and contributors for creating such a nice system. My Slackware 9.x boxes will be running Gentoo on the next reinstall.

OK now the question: I might be able to get ahold of a SparcStation 10 with at least 4GB worth of HD space and a pair of SM41 or 51 CPUs (SMP). Would this be fast enough to be bearable, or would it just plod like an old 486 with no cache? How about the speed of X?
Back to top
View user's profile Send private message
Crimson Rider
Guru
Guru


Joined: 23 Jun 2003
Posts: 462
Location: Delft, the Netherlands

PostPosted: Thu Jan 15, 2004 8:35 am    Post subject: Reply with quote

Hmm, I wouldn't dare to predict it. A mate of mine has such a kind of sparc station on it works pretty sweetly.

It would probably work and be prefectly bearable for things such as browsing and word proccessing, firewalling etc. Wouldn't want to develop on it tough.

You could check out DISTCC to find out about distributed compiling for gentoo.

This post was answered in accordance with "the adopt an unanswered post initiative today"
_________________
Code, justify, code - Pitr Dubovich
Back to top
View user's profile Send private message
IWBCMAN
Guru
Guru


Joined: 25 Jun 2002
Posts: 474

PostPosted: Thu Jan 15, 2004 10:51 am    Post subject: Reply with quote

Don't forget that you might be able to use crossdev with distcc and use you other pc'sto help with the compilation work...I don't have a psarc system so I can't verify it will work-but the files with crossdev(ie. emerge crossdev) state that they do support sparc cross compilation....

look here for more info http://forums.gentoo.org/viewtopic.php?t=115784&start=0&postdays=0&postorder=asc&highlight=cross+distcc
Back to top
View user's profile Send private message
spam_
Tux's lil' helper
Tux's lil' helper


Joined: 14 Jan 2004
Posts: 105
Location: /dev/null

PostPosted: Thu Jan 15, 2004 4:02 pm    Post subject: Reply with quote

DistCC would probably be a good idea since light dev work is what I plan to do on it, along with text editing in X and maybe mozilla if it's fast enough. A remote X session is good enough for running mozilla if the system is too underpowered.

I have the cross-compiler toolchain and DistCC all set up on my other (x86) hosts, it works for compiling to both x86 linux and sparc/sparc64 linux. The 2.4 kernel compiles cleanly in 17 minutes (time make -j6 dep vmlinux modules) using only my K6-2 and the Sparc, versus well over an hour for the Sparc alone. I have a P4-3.06 laptop also running DistCC and the sparc compilers, but I haven't benchmarked with that in the mix yet. I can certainly pull some serious compile power out of this setup, the only bottleneck is the abysmal 10 Mbit hub that I have - all my NICs are 10/100. I really need to shell out the $30 US for an 8-port 10/100 switch, this is getting ridiculous.

How about the stability of Sparc32 SMP? I've read about problems on this board which are severe enough that I don't want to deal with them. Anyone have a sun4m SMP box running around here?
Back to top
View user's profile Send private message
buckyball
n00b
n00b


Joined: 28 Oct 2002
Posts: 14
Location: Fremont, CA

PostPosted: Tue Jan 20, 2004 10:14 pm    Post subject: Reply with quote

spam_ A couple of questions:

- Did you use 'crossdev' to set up your toolchain?

- If you used 'crossdev', did you use stable or unstable sources?

- Would you post the settings you used on the x86 machines to get DISTCC to correctly invoke the cross-compiled gcc?

TIA!
_________________
Buckyball
If it doesn't fit, force it --
if it breaks, it needed fixing anyway!
Back to top
View user's profile Send private message
spam_
Tux's lil' helper
Tux's lil' helper


Joined: 14 Jan 2004
Posts: 105
Location: /dev/null

PostPosted: Wed Jan 21, 2004 12:13 am    Post subject: Reply with quote

Quote:

spam_ A couple of questions:

- Did you use 'crossdev' to set up your toolchain?

- If you used 'crossdev', did you use stable or unstable sources?

- Would you post the settings you used on the x86 machines to get DISTCC to correctly invoke the cross-compiled gcc?

TIA!


I didn't use crossdev, I don't even know what it is although it sounds like a script for setting up cross-compilers :lol: .

The DistCC host boxes were running a combination of OSs. One was running Slackware 9.0 (a K6-2 500), another Slackware 9.1 (a P4 3.06), the third Windows 2000 with Cygwin (a P4 1.4). I manually compiled binutils and GCC-3.2.3 on each machine like so (as root):

Code:

tar xjvf binutils-2.14.tar.bz2
cd binutils-2.14
mkdir build
cd build
CFLAGS="-O3 -march=<cpu type> -fomit-frame-pointer -pipe" ../configure --target=sparc-unknown-linux-gnu --prefix=/usr/local/sparc && make all install

cd ../..
tar xvzf gcc-3.2.3.tar.gz
cd gcc-3.2.3
mkdir build
cd build
CFLAGS="-O3 -march=<cpu type> -fomit-frame-pointer -pipe" ../configure --target=sparc-unknown-linux-gnu --prefix=/usr/local/sparc --with-newlib --without-headers --disable-shared --disable-threads --enable-languages="c c++" --disable-multilib --with-gnu-as --with-gnu-ld && make all install


Repeating this with --target=sparc64-unknown-linux-gnu since I wanted to compile kernels as well, and was not sure if either target would give me both the 32 and 64-bit compilers.

After this (which didn't take long on any of the machines, a couple hours or so tops on the K6-2 and about 20 minutes on the fast P4) I then added /usr/local/sparc/bin to the path. This directory contains the toolchain executables with the target prefix - sparc-unknown-linux-gnu-gcc, etc.


The next step was DistCC, which was easy on all three systems because Slackware 9.x has packages as well as Cygwin. After it was installed I started distccd --daemon on all the machines.

I then went to the Sparc and emerged distcc. I did nothing to make.conf as I did not want distcc to be used by default for all compilations, only when I specify.

Now as most sources like to use gcc or cc to compile (I've had problems with CC=sparc-unknown-linux-gnu-gcc make -jN blah), I made a few symlinks in /usr/lib/distcc/bin.

Code:

cc->sparc-unknown-linux-gnu-gcc
gcc->sparc-unknown-linux-gnu-gcc
c++->sparc-unknown-linux-gnu-g++
g++->sparc-unknown-linux-gnu-g++
sparc-unknown-linux-gnu-gcc->distcc
sparc-unknown-linux-gnu-g++->distcc

Of course, all that is repeated with sparc64 but I'll omit that to save a few lines. A bit messy, but now this is all you have to do when you're compiling:

Code:

export DISTCC_HOSTS="localhost host1 host2 host3 ..."
PATH=/usr/lib/distcc/bin:$PATH MAKEOPTS="-j8" emerge <package>


In fact I put this all into a shell script that takes the package name and stuffs it into the <package> on the command line above.

What this does is turn gcc, cc, c++, g++ into calls to the fully qualified compiler names before passing the call to distcc. This of course turns the remote command lines into the same, which causes the x86 boxes to use the sparc cross compiler :D

^-- Whew that was a bit long. Hope that answers your questions!
Back to top
View user's profile Send private message
buckyball
n00b
n00b


Joined: 28 Oct 2002
Posts: 14
Location: Fremont, CA

PostPosted: Wed Jan 21, 2004 2:41 am    Post subject: Reply with quote

Yep, 'crossdev' is a Gentoo package designed to facilitate setting up cross-compile toolchains.

Thank you for the clear and detailed explanation. I'll give this a try tomorrow.

Regards,
buckyball
_________________
Buckyball
If it doesn't fit, force it --
if it breaks, it needed fixing anyway!
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