>>>>> On Wed, 12 Aug 2015, Ian Stakenvicius wrote: > On 12/08/15 11:08 AM, Ulrich Mueller wrote: >> I was thinking about some syntax like this: >> >> REQUIRED_USE="|| ( +foo bar ) ^^ ( +qt5 -qt4 )" >> >> The package manager would first evaluate each group in >> REQUIRED_USE with the original set of USE flags. If that doesn't >> evaluate to true, retry with flags changed as indicated by the + >> and - signs.
> Having the ability for REQUIRED_USE to provide a default resolution > path should definitely help with things; I assume this is meant to > do its work via --autounmask-write or similar, ie to help users > adjust their config files? Or was the thought to allow PMs to > override USE immediately? In fact, I was thinking about overriding it immediately. It is the same as the ebuild explicitly picking a working default from conflicting flags, where there is also no user interaction required. (The PM should emit a warning, though.) > Questions: > 1 - how does +foo in REQUIRED_USE relate to use-defaults set in > IUSE? Apart from the similar syntax, they are not related. > 2 - is there a particular reasoning for the - in front of qt4 here? > I only ask because it would seem that a single default-enable > should suffice in lists like this to indicate a resolution path, no? > That is, '^^ ( +flag1 -flag2 -flag3 -flag4 )' to me seems like it > would be the same as '^^ ( +flag1 flag2 flag3 flag4 )' If the user has both "qt4 qt5", then enabling qt5 alone won't help to resolve "^^ ( qt5 qt4 )". > 3 - will having REQUIRED_USE be able to force flags on (and others > off) likely result in abuse of profiles and other use defaults? It wouldn't look for the origin of a USE flag setting in its input data. So, yes. > I forsee this being a way, for instance, for a dev to get around > users setting USE="-*" in make.conf to ensure a default use flag > setting is honoured. > 4 - Will a change to which flag the '+' is on likely to require a > revbump for VDB updates? I don't think so. For Portage users, it would be handled by --newuse, I guess. > For something like '^^ ( +qt4 qt5 )' I could see maintainers wanting > to switch which flag is default across a bunch of packages at once > when, say, the qt team wants qt5 to become the de-facto default. Ulrich
pgpi4HeTmPlXu.pgp
Description: PGP signature
