diff options
author | Zac Medico <zmedico@gentoo.org> | 2012-10-05 22:20:07 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2012-10-05 22:20:07 -0700 |
commit | e9ea4bc74f16e6c120fdf9c1926dfcb7de7bd135 (patch) | |
tree | a18dc9f2e936f799bf91afcf3d554b453f7ac4e4 /pym/portage/package | |
parent | 14230dd467c4f0136cb99e83f2d610de166b772b (diff) | |
download | portage-e9ea4bc74f16e6c120fdf9c1926dfcb7de7bd135.tar.gz portage-e9ea4bc74f16e6c120fdf9c1926dfcb7de7bd135.tar.bz2 portage-e9ea4bc74f16e6c120fdf9c1926dfcb7de7bd135.zip |
Substitute EventLoop for PollScheduler.
EventLoop suffices for all of these cases. EventLoop(main=False) is
used for thread safety where API consumers may be using threads.
Diffstat (limited to 'pym/portage/package')
-rw-r--r-- | pym/portage/package/ebuild/doebuild.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package/ebuild/doebuild.py index 9deed98d7..39cd22824 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -29,6 +29,7 @@ portage.proxy.lazyimport.lazyimport(globals(), 'portage.dep._slot_operator:evaluate_slot_operator_equal_deps', 'portage.package.ebuild._spawn_nofetch:spawn_nofetch', 'portage.util._desktop_entry:validate_desktop_entry', + 'portage.util._eventloop.EventLoop:EventLoop', 'portage.util.ExtractKernelVersion:ExtractKernelVersion' ) @@ -691,7 +692,7 @@ def doebuild(myebuild, mydo, _unused=None, settings=None, debug=0, listonly=0, if not returnpid and \ 'PORTAGE_BUILDIR_LOCKED' not in mysettings: builddir_lock = EbuildBuildDir( - scheduler=PollScheduler().sched_iface, + scheduler=EventLoop(main=False), settings=mysettings) builddir_lock.lock() try: @@ -833,7 +834,7 @@ def doebuild(myebuild, mydo, _unused=None, settings=None, debug=0, listonly=0, if builddir_lock is None and \ 'PORTAGE_BUILDIR_LOCKED' not in mysettings: builddir_lock = EbuildBuildDir( - scheduler=PollScheduler().sched_iface, + scheduler=EventLoop(main=False), settings=mysettings) builddir_lock.lock() try: @@ -856,7 +857,7 @@ def doebuild(myebuild, mydo, _unused=None, settings=None, debug=0, listonly=0, if not returnpid and \ 'PORTAGE_BUILDIR_LOCKED' not in mysettings: builddir_lock = EbuildBuildDir( - scheduler=PollScheduler().sched_iface, + scheduler=EventLoop(main=False), settings=mysettings) builddir_lock.lock() mystatus = prepare_build_dirs(myroot, mysettings, cleanup) @@ -1197,7 +1198,7 @@ def _prepare_env_file(settings): """ env_extractor = BinpkgEnvExtractor(background=False, - scheduler=PollScheduler().sched_iface, settings=settings) + scheduler=EventLoop(main=False), settings=settings) if env_extractor.dest_env_exists(): # There are lots of possible states when doebuild() |