Gentoo Archives: gentoo-dev

From: Duncan <1i5t5.duncan@×××.net>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Re: Things one could be upset about
Date: Wed, 21 Jan 2015 01:57:50
Message-Id: pan$74174$8d30b569$d8ce0e7b$c7419d34@cox.net
In Reply to: Re: [gentoo-dev] Things one could be upset about by "Róbert Čerňanský"
1 Róbert Čerňanský posted on Tue, 20 Jan 2015 06:51:01 +0100 as excerpted:
2
3 > On Mon, 19 Jan 2015 20:51:31 +0000 Ciaran McCreesh
4 > <ciaran.mccreesh@××××××××××.com> wrote:
5 >
6 >> On Mon, 19 Jan 2015 21:44:25 +0100 Róbert Čerňanský
7 >> <openhs@×××××××××.com> wrote:
8 >> > From my point of view it would do much help if portage resolves USE
9 >> > dependencies automatically instead of telling the user to change USE
10 >> > flags manually (I am talking about bug #258371).
11 >>
12 >> This is only possible in carefully selected circumstances, and to get
13 >> it to work more generally would require a lot of hinting from package
14 >> maintainers.
15 >
16 > But portage already knows that. It tells the user which USE flags needs
17 > to be changed in order to emerge a package. It should just go one step
18 > further - to make the proposed change happen by itself.
19
20 Actually, current portage (2.2.15 is what I have installed here ATM) does
21 exactly that, making changes to the appropriate package.* files as
22 necessary, mediated only by the usual CONFIG_PROTECT variables.
23
24 Since /etc/portage is CONFIG_PROTECTed by default, these changes normally
25 first appear in that feature's .* files, to be merged by the admin using
26 etc_update or whatever, but if you CONFIG_PROTECT_MASK /etc/portage,
27 portage will (I believe, I've never been stupid enough to try it) happily
28 write those changes without admin mediation.
29
30 And a number of users, including me, objected and still don't like that
31 feature, tho with the CONFIG_PROTECT mediation it's at least tolerable.
32 As others in-thread have stated, we don't believe that's something
33 portage should be messing with.
34
35 In particular, I have a specific scheme for my package.* directories and
36 the files under them, and portage always wants to write the changes to
37 the wrong one... based on my experience so far, apparently the last
38 existing file in the appropriate package.* directory, when it should go
39 in some other file.
40
41 Picking an example out of the air, I have USE=pdf set globally, with
42 USE=-pdf set for specific packages in a file named after the flag (not
43 the package it's set for) and to reflect the fact that I'm disabling it:
44
45 /etc/portage/package.use/0-pdf
46
47 But if portage were to need to set USE=-pdf on another package, instead
48 of writing the changes to apply to that file, it would write the changes
49 to apply to...
50
51 /etc/portage/package.use/zzpkg-ncmpc
52
53 ... which is there because ncmpc has several very specific USE flags that
54 will never apply to anything else and are best grouped together, and
55 which shouldn't contain a USE=-pdf setting for ANY package, INCLUDING
56 ncmpc, because that's a more generic USE flag, that belongs in the
57 previously mentioned /etc/portage/package.use/0-pdf file.
58
59 Of course in practice, no automated ruleset is ever going to make sense
60 of the way I have things organized, and I don't expect it to. Which is
61 my point. Portage shouldn't be editing those files AT ALL. It should
62 spit out the suggested change, and let me edit what I, as the *ADMIN*,
63 consider the appropriate file to make that change, assuming of course
64 that I actually agree with the changed flag in the first place, and don't
65 want to make some other adjustment that I consider more appropriate to
66 the specific situation.
67
68 At least with CONFIG_PROTECT, tho, portage doesn't just edit the file if
69 I accidentally hit an enter when I run my usual post-sync
70 emerge --ask --update --newuse ... @world. It simply creates a dot-file
71 which I have to delete later, after I've decided the appropriate action
72 and taken it. Which is why I characterize it as at least tolerable. But
73 were that feature to have never been merged, I'd be /much/ happier.
74
75
76 Meanwhile, if you're not seeing that feature yet, then you're not running
77 current portage, maybe because you're on stale^h^hble portage or
78 something. But it's certainly there, to my unhappiness if toleration
79 because at /least/ it obeys CONFIG_PROTECT.
80
81 So this subthread could go away... perhaps to be replaced with one
82 griping about portage trying to mess with its own config and screwing up
83 badly, with only CONFIG_PROTECT stopping it from /really/ screwing up an
84 admin's painstaking portage config.
85
86 --
87 Duncan - List replies preferred. No HTML msgs.
88 "Every nonfree program has a lord, a master --
89 and if you use the program, he is your master." Richard Stallman

Replies

Subject Author
Re: [gentoo-dev] Re: Things one could be upset about "Róbert Čerňanský" <openhs@×××××××××.com>