1 |
On Mon, Jan 3, 2022 at 12:16 PM Alec Warner <antarus@g.o> wrote: |
2 |
> |
3 |
> On Sat, Jan 1, 2022 at 2:22 PM Piotr Karbowski <slashbeast@g.o> wrote: |
4 |
> > |
5 |
> > Hi, |
6 |
> > |
7 |
> > I'd like to get some insight how others see the concept of narrowing the |
8 |
> > scope of USE flags in Gentoo. |
9 |
> > |
10 |
> > Taking a quote from devmanual: |
11 |
> > |
12 |
> > > USE flags are to control optional dependencies and settings which |
13 |
> > the user may reasonably want to select. |
14 |
> > |
15 |
> > I'd like to focus on the 'reasonably want' here. While it is commonly |
16 |
> > agreed on that we interface as USE flags only things that make sense to |
17 |
> > be togglable, it is not always the case. It is not uncommon to see |
18 |
> > packages that puts every possible option as USE flag which hardly |
19 |
> > benefit anyone in some cases. |
20 |
> > |
21 |
> > It creates artificial choice of USE flag that makes as much sense as |
22 |
> > building and trying to use solar-powered night vision googles. Possible |
23 |
> > to be engineered, but makes absolute no sense to exist, yet, there will |
24 |
> > be someone who will go with it and then things will not work in desired |
25 |
> > way, bugs will be reported, effort will be wasted on investigation and |
26 |
> > patching things up. |
27 |
> > |
28 |
> > As example I'd like to use 'ipv6' USE flag, at the moment of writing |
29 |
> > this email there's 351 ebuilds in tree that expose ipv6 as USE flag, |
30 |
> > allow it to be disabled. |
31 |
> > |
32 |
> > The thing is, it's 2022, and it does not make any sense to *not* support |
33 |
> > IPv6, even if one does not connect to any network with IPv6, there's no |
34 |
> > harm to just have it there. |
35 |
> > |
36 |
> > While I am all for choice, I am for choice on things that do make sense. |
37 |
> > For instance, Linux kernel can be built with CONFIG_MULTIUSER=n, someone |
38 |
> > could argue that since Linux kernel, that is user-configured in Gentoo, |
39 |
> > can be built without support for other than UID 0, then Gentoo should |
40 |
> > support it. One of the extreme examples of not supporting something that |
41 |
> > does not make sense to be supported. |
42 |
> > |
43 |
> > Beside 'ipv6', there are other USE flags that I have on mind. 'pam' |
44 |
> > being another of them. |
45 |
> > |
46 |
> > Whats your view on it? |
47 |
> |
48 |
> I'm trying to understand your principles here. Like on what basis do |
49 |
> you remove or add flags (in general). |
50 |
> |
51 |
> I want to remove: |
52 |
> - bash-completion |
53 |
> - acl |
54 |
> - ldap |
55 |
> - policykit |
56 |
> - readline |
57 |
> - sound |
58 |
> |
59 |
> (Part of this is just to have a meta discussion so we settle on some |
60 |
> driving principles on why we keep one flag over the other.) |
61 |
> |
62 |
> I can easily craft a narrative for getting rid of ipv6, for example, |
63 |
> but I cannot really craft a good narrative for getting rid of pam, or |
64 |
> policykit, or ldap as flags. So why do we keep some and remove others? |
65 |
|
66 |
The devmanual has a section on this topic: |
67 |
|
68 |
https://devmanual.gentoo.org/general-concepts/use-flags/index.html#when-not-to-use-use-flags |
69 |
|
70 |
Personally, I use the following principles: |
71 |
|
72 |
Is there an optional build time dependency, and is the package still |
73 |
useful without said dependency? If so, a USE flag is warranted. |
74 |
|
75 |
Is there some optional feature/behavior that can only be toggled at |
76 |
build time? If so, a USE flag is probably warranted. |
77 |
|
78 |
Is there some optional feature/behavior that can be toggled at run |
79 |
time (via config)? Does disabling it at build time have a minimal |
80 |
effect on the installed size? If so, I will NOT add a USE flag. |