Subject: solaris pkgsrc, gcc, and bulk builds
To: None <>
From: Dan McMahill <>
List: tech-pkg
Date: 02/04/2005 09:05:50
I seem to be having a bit of a problem trying to do a bulk pkgsrc build
under solaris.  I have an older gcc-3.something that I'm using for the
bootstrap.  Thats installed in /opt/sfw/gcc3/bin.  This is at the very
end of my PATH.

In my mk.conf I have

.ifdef BSD_PKG_MK       # begin pkgsrc settings


.endif                  # end pkgsrc settings

.sinclude "/usr/pkg/share/mk/"

# use gcc

# force the use of the pkgsrc gcc

# and don't bother installing gcc-2.95.*
GCC_REQD=       3.0

# set cpu optimization flags
BULK_PREREQ+=   devel/cpuflags

# don't nuke this, we always need it
BULK_PREREQ+=   lang/gcc3-c
BULK_PREREQ+=   lang/gcc3-c++
BULK_PREREQ+=   lang/gcc3-f77

Before running the bulk build I tried to build binary packages for lang/gcc3-c and 
for some reason it did not build and install the gmake dependency first.  Not
sure why because 'bmake show-var VARNAME=BUILD_DEPENDS' shows the dependency.

So I built and installed the gmake package and then the binary pkgs for gcc3-{c,c++,f77}.

Now I start the build and almost first thing it decides that gcc3-c is out of
date so it tries to rebuild but fails because of the gmake thing.

So now I'm wondering if perhaps we need another variable, something like

BOOTSTRAP_PKGS+=	lang/gcc3-c
BOOTSTRAP_PKGS+=	lang/gcc3-c++
BOOTSTRAP_PKGS+=	lang/gcc3-f77

and they would 

1) be preserved like some of the other bootstrap stuff during the pre-build big
   cleanout of all installed pkgs.

2) be removed from the list of pkgs to be built

3) somehow always be marked as up to date so nothing else tries to go and
   rebuild them.

Thoughts?  Am I missing something basic here?