Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: Michael Orlitzky <mjo@g.o>
Cc: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [RFC] New GLEP: file installation masks
Date: Fri, 20 May 2016 15:22:12
Message-Id: 20160520172159.6bacf04a@pomiocik
In Reply to: Re: [gentoo-dev] [RFC] New GLEP: file installation masks by Michael Orlitzky
1 On Fri, 20 May 2016 11:12:02 -0400
2 Michael Orlitzky <mjo@g.o> wrote:
3
4 > On 05/20/2016 10:01 AM, Michał Górny wrote:
5 > >
6 > > Please review the specification provided. The basic goal is to provide
7 > > an ability to use INSTALL_MASK alike USE flags -- with path groups that
8 > > are well-defined and described in the repository.
9 > >
10 > > [1]:https://wiki.gentoo.org/wiki/User:MGorny/GLEP:INSTALL_MASK
11 > >
12 >
13 > I like the idea. INSTALL_MASK is currently pretty flaky, and that's what
14 > we tell people to use to block e.g. systemd units. Here's what I gather:
15 >
16 > 1. The INSTALL_MASK-like feature should support fnmatch() wildcards.
17 >
18 > 2. Binary packages are not be affected (there's another feature for
19 > that)
20 >
21 > 3. We can define groups of paths to make certain things (bash
22 > completions, locales, etc.) easy to mask.
23 >
24 > All of those are good, but are the details of what actually goes in
25 > INSTALL_MASK left up to the implementation? How would I mask all bash
26 > completions (the bash-completion group) using INSTALL_MASK?
27
28 Yes. Configuration and implementation is left to implementation.
29 The spec only says that it should be possible to somehow enable
30 inclusive/exclusive filtering of specific files, and the end result
31 should be as if they weren't installed in the first place.
32
33 Getting into implementation details, I'd probably go for:
34
35 INSTALL_MASK="@bash-completion"
36
37 but the exact syntax is left for various package managers. Paludis
38 and pkgcore would probably prefer a proper configuration file.
39
40 > Can you make the spec say that we should be able to mask files whose
41 > names contain spaces? Or is that implicit in the fnmatch() clause?
42
43 Well, this should be implicit in fnmatch() for repo-defined paths.
44 However, we leave this undefined for INSTALL_MASK itself, so custom
45 paths will probably have to be declared in install-mask.conf-alike
46 in /etc/portage.
47
48 > For the portage implementation, it may be time to ditch the variable and
49 > move to something like /etc/portage/install.mask:
50 >
51 > $ cat /etc/portage/install.mask
52 > [bash-completion]
53 > /etc/logrotate.d
54 > read me.txt
55 >
56 > With one pattern per line, the spaces thing is easy to deal with. But
57 > this makes me wonder, how is portage supposed to know I want to block
58 > the bash-completion group and not all files named "[bash-completion]"?
59
60 I'd leave this for Portage people to decide. Though I'd prefer
61 if /etc/portage had file with the same or similar syntax to repo file.
62
63 --
64 Best regards,
65 Michał Górny

Replies

Subject Author
Re: [gentoo-dev] [RFC] New GLEP: file installation masks Michael Orlitzky <mjo@g.o>