Re: gcc install
From: Neal A. Lucier (nlucier_at_math.purdue.edu)
Date: 06/26/05
- Next message: Rich Teer: "Re: How is the video on a v20z?"
- Previous message: Casper H.S. ***: "Re: Slow NFS Writes, Network Errors"
- In reply to: jimruth_at_adelphia.net: "gcc install"
- Next in thread: John D Groenveld: "Re: gcc install"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 26 Jun 2005 15:49:18 -0500
jimruth@adelphia.net wrote:
> Recently, I downloaded gcc from the GNU ftp site for the purpose of
> compiling sformat, a special disk formatting utility for Solaris. I got
> a good book on the topic of gcc and went about trying to set it up when
> what do you know, I need a previously installed c compiler to compile
> the gcc source code. I mean, the whole idea was to get the gcc compiler
> because I didn't already have one. Anybody got any suggestions on how
> to get a precompiled compiler to compile the compiler LOL. Sun sells a
> compiler for about $10,000 which is a little too rich for my blood.
>
You can download the Sun Studio 10 compiler suite with a 30 (or maybe
60) day evaluation period. I have always felt that seeing how well the
SUNWspro tools compile the first stage of gcc is an excellent way to
evaluate them.
If what you truely want to do is bootstrap gcc from source it's not that
hard, but here is the mini how-to.
- install the Sun Studio tools, they live in /opt/SUNWspro, modify
path as needed (you will need /usr/css/bin for things like the assembler
and the linker, and initially for 'make')
- compile GNU make using the make in /usr/ccs/bin and the compiler in
/opt/SUNWspro, once done modify your path as neccessary to put your
newly compiled gnu make before the /usr/css one
- do a configure and 'make bootstrap' in the gcc source directory
GCC bootstraps itself in a 3 stages; first stage is to compile a
non-optimzed gcc from the Sun cc, second stage is to compile an
optimized gcc from the non-optimized gcc, the third stage is to compile
a second optimized gcc from the stage two optimized gcc and make sure
that the stage 2 and stage 3 builds are the same. Finally the stage 2
gcc is installed if the stage 3 build checks out.
As some people have pointed out, Sun has gotten better at providing
GNU/gcc tools in the OS and a number of sites provide pre-compiled
binaries for Solaris. We always build from source cause we are always
waiting for bugs to be fixed in cvs, but if all you want to do is
compile 'sformat' then you can get by with some binaries. Some options
for precompiled gcc and make:
Solaris 9:
Companion CD - installs in /opt/sfw you can get a GNU make and a gcc
that is unsupported by Sun.
www.blastwave.org - installs in /opt/csw, I use their other packages,
never used their compilers
www.sunfreeware.com - never used their stuff, but they have stuff
Solaris 10:
Included - installed in /usr/sfw you have a 'gmake' and a 'gcc'
www.blastwave.org - see above
www.sunfreeware.com - see above
Neal
- Next message: Rich Teer: "Re: How is the video on a v20z?"
- Previous message: Casper H.S. ***: "Re: Slow NFS Writes, Network Errors"
- In reply to: jimruth_at_adelphia.net: "gcc install"
- Next in thread: John D Groenveld: "Re: gcc install"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]