commit: 28ab348d318e26b32073eb910756ec9c0727042b
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 27 08:53:59 2018 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Jan 27 10:19:30 2018 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=28ab348d
prepare_build_dirs: Fix duplicate override of DISTDIR for 'ebuild'
Fix the duplicate override of DISTDIR that happens when using
the 'ebuild' tool to run ebuilds. In this case, both the 'config'
code and the 'prepare_build_dirs' code attempt to replace DISTDIR,
and the shadow distdir symlinks end up pointing to themselves.
As suggested by Zac Medico, after removing this override DISTDIR
in settings will always be the real directory, so there is no need
for a PORTAGE_ACTUAL_DISTDIR check here.
Reviewed-by: Zac Medico <zmedico <AT> gentoo.org>
pym/portage/package/ebuild/prepare_build_dirs.py | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/pym/portage/package/ebuild/prepare_build_dirs.py
b/pym/portage/package/ebuild/prepare_build_dirs.py
index 16afc3f98..21e2aa87c 100644
--- a/pym/portage/package/ebuild/prepare_build_dirs.py
+++ b/pym/portage/package/ebuild/prepare_build_dirs.py
@@ -412,9 +412,7 @@ def _prepare_fake_filesdir(settings):
def _prepare_fake_distdir(settings, alist):
orig_distdir = settings["DISTDIR"]
- settings["PORTAGE_ACTUAL_DISTDIR"] = orig_distdir
- edpath = settings["DISTDIR"] = \
- os.path.join(settings["PORTAGE_BUILDDIR"], "distdir")
+ edpath = os.path.join(settings["PORTAGE_BUILDDIR"], "distdir")
portage.util.ensure_dirs(edpath, gid=portage_gid, mode=0o755)
# Remove any unexpected files or directories.