Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Gentoo Portage Developer (http://www.linux-archive.org/gentoo-portage-developer/)
-   -   Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled? (http://www.linux-archive.org/gentoo-portage-developer/611147-there-any-short-syntax-required_use-when-lot-use-flags-need-another-one-enabled.html)

Pacho Ramos 12-17-2011 09:24 AM

Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled?
 
I am referring in this case to abiword, it has a "plugins" USE flag that
enables some minimal set of plugins and, then, a lot of USE flags for
building extra plugins (with extra dependencies). All of this extra
plugins need "plugins" USE flag to be enabled. Is there any way to write
a REQUIRED_USE flag variable without needing to list all USE flags
depending on "plugins" to be set?

Thanks a lot for the info :)

Zac Medico 12-17-2011 03:50 PM

Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled?
 
On 12/17/2011 02:24 AM, Pacho Ramos wrote:
> I am referring in this case to abiword, it has a "plugins" USE flag that
> enables some minimal set of plugins and, then, a lot of USE flags for
> building extra plugins (with extra dependencies). All of this extra
> plugins need "plugins" USE flag to be enabled. Is there any way to write
> a REQUIRED_USE flag variable without needing to list all USE flags
> depending on "plugins" to be set?

I don't think so. You could file a PMS bug for an extension in the next
EAPI. I guess it could look something like this:

|| ( foo bar ) ? ( plugins )

> Thanks a lot for the info :)
--
Thanks,
Zac

Brian Harring 12-17-2011 07:12 PM

Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled?
 
On Sat, Dec 17, 2011 at 11:24:37AM +0100, Pacho Ramos wrote:
> I am referring in this case to abiword, it has a "plugins" USE flag that
> enables some minimal set of plugins and, then, a lot of USE flags for
> building extra plugins (with extra dependencies). All of this extra
> plugins need "plugins" USE flag to be enabled. Is there any way to write
> a REQUIRED_USE flag variable without needing to list all USE flags
> depending on "plugins" to be set?

I think the better question is why you have a plugin use flag if
the vast majority of interesting flags require it.

What's the gain of having plugin controllable, vs forced on by default
(or force on by one of the flags you referenced being enabled)?

~brian

Duncan 12-17-2011 07:55 PM

Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled?
 
Brian Harring posted on Sat, 17 Dec 2011 12:12:45 -0800 as excerpted:

> On Sat, Dec 17, 2011 at 11:24:37AM +0100, Pacho Ramos wrote:
>> I am referring in this case to abiword, it has a "plugins" USE flag
>> that enables some minimal set of plugins and, then, a lot of USE flags
>> for building extra plugins (with extra dependencies). All of this extra
>> plugins need "plugins" USE flag to be enabled. Is there any way to
>> write a REQUIRED_USE flag variable without needing to list all USE
>> flags depending on "plugins" to be set?
>
> I think the better question is why you have a plugin use flag if the
> vast majority of interesting flags require it.
>
> What's the gain of having plugin controllable, vs forced on by default
> (or force on by one of the flags you referenced being enabled)?

Indeed, that /is/ a good question. =:^)

What about adding USE=minimal to turn off plugins entirely, thus making
the default if it's not turned on the basic plugins?

That would kill the complicated dependencies for the individual plugin
flags and with a package specific description for USE=minimal that says
it builds without even the basic plugins, that functionality is preserved
for those who really want/need it.

--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman

Zac Medico 01-16-2012 04:53 PM

Is there any short syntax for REQUIRED_USE when a lot of USE flags need another one enabled?
 
On 12/17/2011 08:50 AM, Zac Medico wrote:
> On 12/17/2011 02:24 AM, Pacho Ramos wrote:
>> I am referring in this case to abiword, it has a "plugins" USE flag that
>> enables some minimal set of plugins and, then, a lot of USE flags for
>> building extra plugins (with extra dependencies). All of this extra
>> plugins need "plugins" USE flag to be enabled. Is there any way to write
>> a REQUIRED_USE flag variable without needing to list all USE flags
>> depending on "plugins" to be set?
>
> I don't think so. You could file a PMS bug for an extension in the next
> EAPI. I guess it could look something like this:
>
> || ( foo bar ) ? ( plugins )

It turns out that De Morgan's law allows it to be expressed with
existing syntax:

!plugins? ( !foo !bar )

Thanks to Ulrich Müller for pointing this out:

https://bugs.gentoo.org/show_bug.cgi?id=399069#c1

--
Thanks,
Zac


All times are GMT. The time now is 10:32 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.