Gentoo Archives: gentoo-catalyst

From: Ben Kohler <bkohler@×××××.com>
To: gentoo-catalyst@l.g.o
Subject: [gentoo-catalyst] [PATCH 1/2] stagebase.py: strip leading slash from /etc/portage in pjoin
Date: Thu, 28 Dec 2017 20:33:13
Message-Id: CANSUr=KaVcg5iKVfO7T66SN_VaKimxKEX5iqh1=sqOzFDSLKGA@mail.gmail.com
1 Only the first component passed to pjoin can have a leading slash,
2 otherwise the component will be treated as an absolute path and all
3 preceding components are discarded.
4 ---
5 catalyst/base/stagebase.py | 2 +-
6 1 file changed, 1 insertion(+), 1 deletion(-)
7
8 diff --git a/catalyst/base/stagebase.py b/catalyst/base/stagebase.py
9 index a6a32f5a..999bf8df 100644
10 --- a/catalyst/base/stagebase.py
11 +++ b/catalyst/base/stagebase.py
12 @@ -1219,7 +1219,7 @@ class StageBase(TargetBase, ClearBase, GenBase):
13 "sticky-config" not in self.settings["options"]):
14 for _dir in "keywords", "mask", "unmask", "use":
15 target = pjoin([self.settings['chroot_path'],
16 - "/etc/portage/package.%s" % _dir,
17 + "etc/portage/package.%s" % _dir,
18 self.settings["portage_prefix"]])
19 clear_path(target)
20
21 --
22 2.13.6
23
24 ~