Subject: Re: how to find perl with BUILD_DEPENDS
To: None <itojun@iijlab.net>
From: Johnny C. Lam <lamj@stat.cmu.edu>
List: tech-pkg
Date: 02/01/2001 17:04:30
	[Re-posted to tech-pkg@netbsd.org for relevance]

itojun@iijlab.net writes:
> 
> >Module Name:	pkgsrc
> >Committed By:	jlam
> >Date:		Thu Feb  1 21:52:22 UTC 2001
> >
> >Modified Files:
> >	pkgsrc/fonts/jisx0208fonts: Makefile
> >
> >Log Message:
> >Use ${PERL5} instead of perl.
> 
> 	do we really want to do this?
> 
> BUILD_DEPENDS+= ${PERL5}:../../lang/perl5-base
> 	by doing this, the Makefile will check /usr/pkg/bin/perl.
> 	if we try to build the package on a system with perl shipped by
> 	default (like /usr/bin/perl), it will pull unnecessary dependency.
> 
> 	===> Required file /usr/pkg/bin/perl: found
> 
> BUILD_DEPENDS+= perl:../../lang/perl5-base
> 	by doing this, it will try to find perl from the search path.
> 	it will build happy with /usr/bin/perl or something like that.
> 
> 	===> Required executable perl: /usr/pkg/bin/perl found

Unless /usr/bin/perl is perl4, and perl5 is required.  If we use the
pkgsrc version of perl, we eliminate a possible source of errors.
When I upgraded the pkgsrc perl to 5.6.0 a few months ago, I pointed
all of the existing packages to ${PERL5} for this reason.  I'd welcome
other opinions on the right thing to do here.

	Cheers,

     -- Johnny C. Lam <lamj@stat.cmu.edu>
        Department of Statistics, Carnegie Mellon University
        http://www.stat.cmu.edu/~lamj/