From c5e2cab7a6904295fa74ca3be42fc37e898c9c85 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Tue, 14 Sep 2010 17:20:08 -0700 Subject: [PATCH] In doebuild(), skip PORTAGE_BUILDDIR locking if it's already locked or returnpid is True. --- pym/portage/package/ebuild/doebuild.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package/ebuild/doebuild.py index 4c266222c..044d66590 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -617,9 +617,12 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, have_build_dirs = False if not parallel_fetchonly and \ mydo not in ('digest', 'fetch', 'help', 'manifest'): - builddir_lock = EbuildBuildDir( - scheduler=PollScheduler().sched_iface, settings=mysettings) - builddir_lock.lock() + if not returnpid and \ + 'PORTAGE_BUILDIR_LOCKED' not in mysettings: + builddir_lock = EbuildBuildDir( + scheduler=PollScheduler().sched_iface, + settings=mysettings) + builddir_lock.lock() mystatus = prepare_build_dirs(myroot, mysettings, cleanup) if mystatus: return mystatus -- 2.26.2