Gentoo Archives: gentoo-dev

From: Ciaran McCreesh <ciaranm@×××××××.org>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] RFC: Package Manager Specification: configuration protection
Date: Tue, 12 Sep 2006 09:34:00
Message-Id: 20060912103130.092c3033@snowdrop.home
In Reply to: Re: [gentoo-dev] RFC: Package Manager Specification: configuration protection by Simon Stelling
1 On Tue, 12 Sep 2006 10:19:40 +0200 Simon Stelling <blubb@g.o>
2 wrote:
3 | > Protected Locations
4 | > ===================
5 | >
6 | > Protected locations are determined by the ``CONFIG_PROTECT``
7 | > environment variable, which is defined in the profiles and which
8 | > may be augmented or overridden by the current environment and user
9 | > configuration files. This variable contains a space separated list
10 | > of values which are matched against the beginning of a full file
11 | > path and name of files to be installed.
12 |
13 | "which are matched against the beginning of a full file path" would
14 | mean that e.g. CONFIG_PROTECT="/etc/foo" would protect the following:
15 |
16 | /etc/foobar/doh
17 | /etc/foo
18 | /etc/foobaz
19 |
20 | .. or did I misunderstand something here? I don't know whether that is
21 | the current behaviour of portage, but IMO it certainly shouldn't be.
22 | It should rather be
23 |
24 | /etc/foo (file)
25 | or, if /etc/foo is a dir:
26 | /etc/foo/*
27
28 Mm. I had a play with this. I'd like someone else to do independent
29 tests, because I'm seeing something weird here. But it looks like
30 Portage's current behaviour is:
31
32 with CONFIG_PROTECT="/foo":
33 * if /foo is a file, it's not protected
34 * if /foo is a directory, its contents (including subdirectories) are
35 protected
36 * /foofoo (file) is not protected
37 * /foobar/baz is not protected
38
39 and weirdly, with CONFIG_PROTECT="/foo/"
40 * if /foo/ is a directory, its contents are protected during unmerge
41 but not during merge
42
43 All of this is rather weird, and doesn't match up to what I've been
44 told by Portage people that Portage is supposed to do...
45
46 --
47 Ciaran McCreesh
48 Mail : ciaranm at ciaranm.org

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies