From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1Ieygo-000525-6P for garchives@archives.gentoo.org; Mon, 08 Oct 2007 19:54:54 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.14.1/8.14.0) with SMTP id l98JiV9E014659; Mon, 8 Oct 2007 19:44:31 GMT Received: from mail.genone.homeip.net (dslc-082-082-182-082.pools.arcor-ip.net [82.82.182.82]) by robin.gentoo.org (8.14.1/8.14.0) with ESMTP id l98JgGif011729 for ; Mon, 8 Oct 2007 19:42:16 GMT Received: by mail.genone.homeip.net (Postfix, from userid 460) id 637672814E; Mon, 8 Oct 2007 21:41:49 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.1.8-gr0-genone_0.7 (2007-02-13) on lyta.genone.homeip.net X-Spam-Level: X-Spam-Status: No, score=-2.5 required=7.0 tests=ALL_TRUSTED,BAYES_20 autolearn=ham version=3.1.8-gr0-genone_0.7 Received: from sheridan (sheridan.genone.homeip.net [192.168.0.40]) by mail.genone.homeip.net (Postfix) with SMTP id 69EDD2814E for ; Mon, 8 Oct 2007 21:41:42 +0200 (CEST) Date: Mon, 8 Oct 2007 21:40:58 +0200 From: Marius Mauch To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] Re: use flags -> use options Message-Id: <20071008214058.3d647e4e.genone@gentoo.org> In-Reply-To: <470A1840.10505@gentoo.org> References: <47090820.7060506@gentoo.org> <20071007200938.7e1cebb3@gentoo.org> <20071007191225.GB10856@eric.schwarzvogel.de> <20071008044348.a5fc3297.genone@gentoo.org> <470A1840.10505@gentoo.org> X-Mailer: Sylpheed 2.4.1 (GTK+ 2.10.11; i686-pc-mingw32) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Archives-Salt: fae7660a-a516-45ab-8c1b-ce36c4b3f9ce X-Archives-Hash: a8e61bfff9562f96bfe3017d13162815 On Mon, 08 Oct 2007 13:45:04 +0200 "Marijn Schouten (hkBst)" wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Marius Mauch wrote: > >>> "Marijn Schouten (hkBst)" : > >>>> I imagine there are a lot more cases where the simple on/off > >>>> system we have now is suboptimal. I could be wrong of course. > >>>> Please comment. > >>> This key=value systems sounds interesting. Another use could be > >>> the choice between xulrunner, seamonkey, firefox. > > > > We already have this with USE_EXPAND. Not exactly the same syntax, > > but I don't see a terrible problem in that, and we don't have to > > fix all three trillion related tools to handle it. Unless you can > > come up with a case that can't be handled with USE_EXPAND. > > No, USE_EXPAND is only a way to abbreviate use flags with a common > substring in their name, such as "impl_guile impl_sbcl impl_clisp" > which could be encoded interchangeably as either > > # without USE_EXPAND > IUSE="impl_guile impl_sbcl impl_clisp" > > or > > # with USE_EXPAND > for impl in IMPL; do IUSE+="impl_${impl}"; done > > but the effect is that there are 3 use flags with a total of 2^3=8 > combinations, while really something with exactly 3 combinations is > needed: > > IUSE="impl" > > case ${impl} in > guile) #use guile as backend > sbcl) #use sbcl as backend > clisp) #use clisp as backend So what you want is a USE_EXPAND version that only allows one value per variable. That wouldn't be terribly difficult to do. As for your idea (ignoring implementation issues), I'd expect that sooner or later people will request multivalue functionality as well, so we'd have the same situation there. Also in the given example, how would the user/package manager actually know what values were valid/available for "impl"? Marius -- gentoo-dev@gentoo.org mailing list