aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2018-05-03 16:00:35 -0700
committerZac Medico <zmedico@gentoo.org>2018-05-03 16:08:47 -0700
commitb69a756099973abbf9719717ea3726519b32ce60 (patch)
treed756b64078c509021fdb89995e110e18a5f71543
parentUpdates for portage-2.3.34 release (diff)
downloadportage-b69a7560.tar.gz
portage-b69a7560.tar.bz2
portage-b69a7560.zip
LocationsManager: fix SYSROOT normalization to handle empty SYSROOT
This issue was exposed when building portage-2.3.34 with USE="epydoc" enabled, since epydoc triggers instantiation of portage.settings. The empty SYSROOT change for bug 654600 (in commit 1b5110557d1dd725f7c12bbed4b7ceaaec29f2a3) triggered incorrect normalization behavior here. Fixes: a41dacf7926c ("Export SYSROOT and ESYSROOT in ebuild env in EAPI 7")
-rw-r--r--pym/portage/package/ebuild/_config/LocationsManager.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/pym/portage/package/ebuild/_config/LocationsManager.py b/pym/portage/package/ebuild/_config/LocationsManager.py
index b57443ba7..f7d7209ff 100644
--- a/pym/portage/package/ebuild/_config/LocationsManager.py
+++ b/pym/portage/package/ebuild/_config/LocationsManager.py
@@ -1,4 +1,4 @@
-# Copyright 2010-2014 Gentoo Foundation
+# Copyright 2010-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
from __future__ import unicode_literals
@@ -69,7 +69,7 @@ class LocationsManager(object):
if self.sysroot is None:
self.sysroot = "/"
else:
- self.sysroot = normalize_path(os.path.abspath(self.sysroot)).rstrip(os.sep) + os.sep
+ self.sysroot = normalize_path(os.path.abspath(self.sysroot or os.sep)).rstrip(os.sep) + os.sep
self.esysroot = self.sysroot.rstrip(os.sep) + self.eprefix + os.sep