Subject: Re: CVS commit: pkgsrc/mk/buildlink3
To: Johnny C. Lam <jlam@NetBSD.org>
From: Thomas Klausner <wiz@NetBSD.org>
List: tech-pkg
Date: 03/11/2004 12:41:59
On Thu, Mar 11, 2004 at 09:41:14AM +0000, Johnny C. Lam wrote:
> On Thu, Mar 11, 2004 at 10:18:16AM +0100, Thomas Klausner wrote:
> > On Thu, Mar 11, 2004 at 05:13:31AM +0000, Johnny C. Lam wrote:
> > > Modified Files:
> > > 	pkgsrc/mk/buildlink3: bsd.buildlink3.mk
> > > 
> > > Log Message:
> > > Avoid build loops by ensuring that a package can never inadvertantly be
> > > a dependency for itself.  This is done by setting IGNORE_PKG.<pkg> if
> > > <pkg> is the current package and then appropriately checking its value.
> > 
> > So what will now happen in e.g. the gcc3-patch loop?
> > [when gcc3 is set as default compiler on a system that
> >  has no GNU patch, any package will depend on gcc3
> >  which will depend on the GNU patch package, which will
> >  depend on gcc3]
> > 
> > Will it compile patch with whatever the other cc is,
> > will it warn that there is a build loop, will it just
> > break in patch because gcc3 isn't available?
> 
> The changes I've put in don't address the situation you're describing.
> They only prevent dependency loops for packages pulled in via
> buildlink3.mk files.

Ok, so I chose an inappropriate example -- still, how is the loop handled?

> I'll look at improving the way that tools.mk and compiler.mk try to
> break dependency loops after the new branch is cut.

Thanks.
 Thomas