Subject: Re: Bad definition of USE_LIBTOOL in bsd.pkg.mk
To: Todd Vierling <tv@wasabisystems.com>
From: Alistair Crooks <agc@pkgsrc.org>
List: tech-pkg
Date: 01/29/2001 11:36:24
On Fri, Jan 26, 2001 at 03:15:09PM -0500, Todd Vierling wrote:
> On Fri, 26 Jan 2001, Frederick Bruckman wrote:
> 
> : > .if make(install-run-depends) || make(fetch-list-recursive) ||
> : > make(show-depends-dirs)
> : > DEPENDS+=               libtool>=1.3.5nb9:../../devel/libtool
> : > .endif
> 
> : I don't do it, but notice that the ".if make(...)"'s prevent the
> : dependency from being registered at install or package time, so it's
> : not so bad.
> 
> We have to avoid using ".if make()" in bsd.pkg.mk.  There are outstanding
> complaints as to the ultra-recursion nature of bsd.pkg.mk.  We need to
> eliminate spots where the "target being made" is referenced, so that
> changing some of those recursions into dependencies will be possible.
> 
> sigh....
> 
> -- 
> -- Todd Vierling <tv@wasabisystems.com>  *  Wasabi NetBSD:  Run with it.
> -- NetBSD 1.5 now available on CD-ROM  --  http://www.wasabisystems.com/
> 

It's well-known that there are a number of ways to speed up pkgsrc, the most
popular of which seem to be (in order)

1. avoid using != command expansion where possible, passing any results
down through the environment
2. cut down on the number of `cmd` invocations
3. split bsd.pkg.mk itself into sub-files, and include only the sub-parts
of it which need to be included
4. lots more radical micro-optimisations

and I'd include your optimisation in (4), in lieu of any direct benchmarked
numbers.

Not that you're wrong, just that there are many other things to do,
and I'm not as gung-ho as you are about an optimisation's efficacy
without some real evidence.

Regards,
Alistair