Subject: Solaris 10 bootstrapping (Was: solaris pkgsrc, gcc, and bulk builds)
To: None <>
From: Eric Boutilier <Eric.Boutilier@Sun.COM>
List: tech-pkg
Date: 02/11/2005 07:57:02
On Tue, 8 Feb 2005, Eric Boutilier wrote:
> On Tue, 8 Feb 2005, Jan Schaumann wrote:
>> ...
>>> ...
>>>   4. Temporarily set: LD_LIBRARY_PATH=/opt/sfw/lib
>>>   5. a. Go to pkgsrc/devel/libtool-base and do `bmake install'
>>>      b. Go to pkgsrc/converters/libiconv and do `bmake install'
>>>      c. Go to pkgsrc/devel/gettext-lib and do `bmake install'
>>>      d. Go to pkgsrc/devel/gmake and do `bmake install'
>>>      e. Go to pkgsrc/lang/gcc3-c and do `bmake install'
>> Shouldn't 5.e. by itself be sufficient?  Ie, it should pull in all the
>> required packages without the user having to know which they are and
>> manually adding them.
> Yes, absolutely. But I couldn't get that to work. So because it was
> Saturday and I didn't want to bother Gavan, I searched the list
> archives and googled the web for a solution. What I found was two
> people who had discovered a work-around (the only workaround
> AFAICT), and one of them described how to do it in nice detail. So
> I decided go with their advice.
> Having said that however -- I hear there's good news! The error
> messages I was getting had to do with va_end already being defined,
> and I heard from Gavan that that bug was *just* fixed. :-) :-)
> I'll give it whirl and let you know.


So take my "10-steps-to-building-pkgsrc-from-scratch-on Solaris 10"
message, send it to /dev/null, and replace it with this:

 - After running bootstrap, add the following to /usr/pkg/etc/mk.conf:
 - Add this to $PATH:
   (along with your pkgsrc bin and sbin paths of course)
 - Go bmake gcc3

In fact that last step could say: "Go bmake anything" because the
system will DTRT. That is, it will first use /usr/sfw/bin/gcc to
build pkgsrc's gcc, and then because USER_PKGSRC_GCC=yes, it'll use
pkgsrc's gcc for the rest of that build (and all builds after that
of course). Gavan and I have tested this by starting from scratch a
few different times with different packages.

Note also that the need to temporarily set LD_LIBRARY_PATH
has gone away too. :-)

Thank you pkgsrc team!


P.S. The reason /usr/ccs/bin is needed in $PATH
     is because thats' where ar(1) lives on Solaris.