Subject: Re: A way to get more consistency with *USE_* variables
To: Quentin Garnier <>
From: Juan RP <>
List: tech-pkg
Date: 05/02/2004 20:25:25
Content-Type: text/plain; charset=US-ASCII
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

On Sun, 2 May 2004 01:26:36 +0200
Quentin Garnier <> wrote:

> Hi,
> I find it rather annoying the way we are unconsistently making
> features optional inside packages.  I already made a change
> recently for the OpenLDAP case, but I'd like to go a step
> further and have a generalized way of handling this.
> The issue with having USE_<FEATURE> gloablly set is that
> sometimes, for a given package, you don't want to enable
> that feature, or you want it only for one package.
> I suggest the following:  having a set of optional features,
> that get actived with USE_<feature>=YES globally, but can
> also be set on a per-package basis, using:
> USE_<feature>.<package>=YES
> I've made a quick patch that does this for OpenLDAP.  It
> defines a variable in, GLOBAL_FEATURES
> that defines every USE_* variable that can be defined on a
> per-package basis.  Right now it only contains OPENLDAP.
> The only big change it needs is moving away the defintion of
> PKGNAME and PKGBASE (and associated) into,
> because we need them way before inclusion of in the
> packages Makefile.
> The patch also adds a small message about how you got the
> value of the BUILD_DEFS variable and that tells the user she
> can set the specific variable USE_<FEATURE>.<package>.
> It might be implemented in another way, a bit like
> PREFER_PKGSRC/PRFER_NATIVE, where the user would give a list
> of package in USE_<FEATURE> defition, and also we could use
> along an AVOID_<FEATURE> variable.  I prefer the .<package>
> way, even if it means more lines in mk.conf.
> Comments?

This is a great idea/feature to have in pkgsrc.

I prefer .<package> too.

	Juan RP <>

Content-Type: application/pgp-signature

Version: GnuPG v1.2.4 (NetBSD)