Subject: Re: pkgsrc vs mk.conf
To: Quentin Garnier <>
From: Johnny Lam <>
List: tech-pkg
Date: 03/24/2005 18:31:51
Quentin Garnier wrote:
> And, indeed, in NetBSD, what makes things go wrong is the fact that both
> pkgsrc and the system, which are distinct, use a common configuration
> file.

For any curious readers, the relevant PR here is pkg/15297.

> Wouldn't it make much more sense for pkgsrc to have its own
> configuration file, say pkgsrc.conf (or ${PKG_SYSCONFDIR}/pkgsrc.conf in
> the bootstrapped case)?
> Of course, there should also be a way to make sure the native make(1) is
> used, because as of now, unless the package plays with definining
> MAKEPROGRAM directly, bmake(1) is called, and on OtherBSD, to build a
> LKM, it is likely to fail.
> So, what do you guys think of making the system's make and pkgsrc's
> configuration separate?  And please remember that it is _not_ a matter of
> enclosing stuff in .ifdef BSD_PKG_MK.

I think this is a step in the right direction.  I would go farther and 
say that pkgsrc should just have a standalone set of *.mk files.  There 
is nothing magical about MAKECONF other than that it's checked and 
included within  From my recent reading of pkgsrc/mk/*, it 
appears that we only use to get some ${OPSYS}-related 
definitions that we can provide directly in some pkgsrc/mk file, and we 
use to provide some default values for CC, LD, AS, etc., that I 
also believe we should be providing directly in some pkgsrc/mk file.


	-- Johnny Lam <>