Gentoo Archives: gentoo-commits

From: Fabian Groffen <grobian@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:prefix commit in: bin/ebuild-helpers/
Date: Sun, 29 May 2011 08:12:30
Message-Id: 696ac3204469b03291b6e2c051d685ee6d24f5c2.grobian@gentoo
1 commit: 696ac3204469b03291b6e2c051d685ee6d24f5c2
2 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
3 AuthorDate: Sun May 29 08:10:22 2011 +0000
4 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
5 CommitDate: Sun May 29 08:10:22 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=696ac320
7
8 fowners: disable in Prefix
9
10 Make fowners return success and emit a warning for Prefix users, like
11 enewuser etc. do.
12
13 ---
14 bin/ebuild-helpers/fowners | 5 +++++
15 1 files changed, 5 insertions(+), 0 deletions(-)
16
17 diff --git a/bin/ebuild-helpers/fowners b/bin/ebuild-helpers/fowners
18 index b949164..0c5295b 100755
19 --- a/bin/ebuild-helpers/fowners
20 +++ b/bin/ebuild-helpers/fowners
21 @@ -4,6 +4,11 @@
22
23 source "${PORTAGE_BIN_PATH:-@PORTAGE_BASE@/bin}"/isolated-functions.sh
24
25 +if hasq prefix ${USE} && [[ $EUID != 0 ]] ; then
26 + ewarn "fowners ignored in Prefix with non-privileged user"
27 + exit 0
28 +fi
29 +
30 # we can't prefix all arguments because
31 # chown takes random options
32 slash="/"