Subject: Re: gcc on Solaris 10
To: Steven Gurr <Steven.Gurr@Sun.COM>
From: None <>
List: tech-pkg
Date: 11/30/2005 00:59:52
On Tue, 29 Nov 2005 17:33:45 +0000
Steven Gurr <Steven.Gurr@Sun.COM> wrote:

> Hey,
> I'm using pkgsrc with Solaris 10, on an Ultra 10 (with a UltraSPARC-IIi 
> in it) and am quite impressed with it, on the whole. However, today I 
> found out that the gcc from pkgsrc is making me 32 bit binaries. If I 
> unset USE_PKGSRC_GCC=YES then it goes back to using the gcc that I've 
> got installed from Sun which works with the -m64 flag. However, I'd 
> rather be using the gcc from pkgsrc in keeping with everything else from 
> there.
> Is there anyway I can recompile gcc3 to allow me to build 64 bit 
> binaries in the future?
> Thanks
> Steven

Basically there is a way, BUT last time I tried it with gcc3, I got as far as
building C compiler, when building C++ compiler the configure script would go
into an infinite loop.

I think it would be better to build gcc4 instead, I've done it on Solaris 10
and managed to build C, C++, Objective-C, Fortran and Ada compilers. gcc4
automatically includes support for building 32-bit and 64-bit binaries.

I think gcc4 is not in pkgsrc yet, but I believe John Shannon is working on
porting gcc4. He has a beta lang/gcc4 package on his website (search pkgsrc
mailing list to find out web address). I think at some point that package needs
to be split up into lang/gcc-c, lang/gcc-c++, lang/gcc-ada, etc packages, so
that you could build pure C compiler with minimum dependancies, and then use
that compiler to build everything else (well except for ada, which needs a
bootstrap ada compiler)