diff options
Diffstat (limited to 'pym')
-rw-r--r-- | pym/_emerge/EbuildPhase.py | 13 | ||||
-rw-r--r-- | pym/portage/const.py | 4 |
2 files changed, 10 insertions, 7 deletions
diff --git a/pym/_emerge/EbuildPhase.py b/pym/_emerge/EbuildPhase.py index 77b3a4d88..e75673c7c 100644 --- a/pym/_emerge/EbuildPhase.py +++ b/pym/_emerge/EbuildPhase.py @@ -30,7 +30,8 @@ from portage import _unicode_encode class EbuildPhase(CompositeTask): - __slots__ = ("actionmap", "ebuild_lock", "phase", "settings") + __slots__ = ("actionmap", "phase", "settings") + \ + ("_ebuild_lock",) # FEATURES displayed prior to setup phase _features_display = ("ccache", "distcc", "fakeroot", @@ -144,16 +145,18 @@ class EbuildPhase(CompositeTask): settings=self.settings) if (self.phase in self._locked_phases and - "no-ebuild-locks" not in self.settings.features): + "ebuild-locks" in self.settings.features): root = self.settings["ROOT"] lock_path = os.path.join(root, portage.VDB_PATH + "-ebuild") - self.ebuild_lock = lockdir(lock_path) + if os.access(os.path.dirname(lock_path), os.W_OK): + self._ebuild_lock = lockdir(lock_path) self._start_task(ebuild_process, self._ebuild_exit) def _ebuild_exit(self, ebuild_process): - if self.ebuild_lock: - unlockdir(self.ebuild_lock) + if self._ebuild_lock is not None: + unlockdir(self._ebuild_lock) + self._ebuild_lock = None fail = False if self._default_exit(ebuild_process) != os.EX_OK: diff --git a/pym/portage/const.py b/pym/portage/const.py index dbbaa3e86..0bd56b20f 100644 --- a/pym/portage/const.py +++ b/pym/portage/const.py @@ -88,11 +88,11 @@ EBUILD_PHASES = ("pretend", "setup", "unpack", "prepare", "configure" SUPPORTED_FEATURES = frozenset([ "assume-digests", "binpkg-logs", "buildpkg", "buildsyspkg", "candy", "ccache", "chflags", "collision-protect", "compress-build-logs", - "digest", "distcc", "distlocks", "fakeroot", + "digest", "distcc", "distlocks", "ebuild-locks", "fakeroot", "fail-clean", "fixpackages", "force-mirror", "getbinpkg", "installsources", "keeptemp", "keepwork", "fixlafiles", "lmirror", "metadata-transfer", "mirror", "multilib-strict", "news", - "no-ebuild-locks", "noauto", "noclean", "nodoc", "noinfo", "noman", + "noauto", "noclean", "nodoc", "noinfo", "noman", "nostrip", "notitles", "parallel-fetch", "parse-eapi-ebuild-head", "prelink-checksums", "preserve-libs", "protect-owned", "python-trace", "sandbox", |