Gentoo Archives: gentoo-dev

From: "William L. Thomson Jr." <wlt-ml@××××××.com>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [patch] golang-vcs-snapshot.eclass: add vendoring of external dependencies
Date: Thu, 09 Mar 2017 19:00:25
Message-Id: assp.0241e73dd9.3132974.yaoWBZezWU@wlt
In Reply to: Re: [gentoo-dev] [patch] golang-vcs-snapshot.eclass: add vendoring of external dependencies by Michael Orlitzky
1 On Thursday, March 9, 2017 1:29:55 PM EST Michael Orlitzky wrote:
2 > On 03/09/2017 01:21 PM, William L. Thomson Jr. wrote:
3 > > Pretty sure no need for the ||die, rm -fr should never fail.
4 > >
5 > > rm -fr "${VENDOR_PATH}/${VENDORPN}" || die
6 >
7 > $ rm -rf /bin/cp || echo "it failed"
8 > rm: cannot remove '/bin/cp': Permission denied
9 > it failed
10
11 Under what circumstances?
12
13 It is possible, but not to likely, as the dirs are part of a package unpacked.
14 User would have permissions. If portage is not being run as root. If run as
15 root, only extended file attributions ( immutable ) can prevent root from
16 removing. Not likely set in a packaged unpacked.
17
18 This part of the eclass is handling sources from VC. I am not sure how they
19 can be pulled in with permissions that would prevent what ever user portage is
20 running under from removing a directory.
21
22 Seems like it is not possible to generate the above permission issue.
23
24 --
25 William L. Thomson Jr.

Attachments

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

Replies