Integrate parallel_emerge with emerge, boosting performance.
Integrate parallel_emerge with emerge, boosting performance.

Instead of loosely wrapping emerge, parallel_emerge now integrates tightly with emerge. This boosts performance while allowing us to map dependencies more accurately.

With this change, build_image --fast can clock under 4 minutes, and build_packages --fast now clocks as low as 4:30. With the --rebuild option, build_packages takes 5:30, but it has the big benefit of producing actually-correct results.

Note that this change also depends on us updating the various build scripts to prefix
calls to parallel_emerge with sudo -E.

TEST=Ran several parallel_emerge test cases, build_packages --fast, and
     build_image --fast
BUG=none

Review URL: http://codereview.chromium.org/2891013

bcwaldon/coreos-scripts,zhang0137/scripts,bcwaldon/coreos-scripts,crawford/scripts,glevand/coreos--scripts,vmware/coreos-scripts,smilart/scripts,trnubo/scripts,endocode/scripts,mjg59/scripts,coreos/scripts,sigma/coreos-scripts,endocode/scripts,glevand/coreos--scripts,crawford/scripts,gtank/scripts,endocode/scripts,BugRoger/scripts,bcwaldon/coreos-scripts,zhang0137/scripts,mjg59/scripts,sigma/coreos-scripts,marineam/coreos-scripts,smilart/scripts,crawford/scripts,andrejro/coreos--scripts,andrejro/coreos--scripts,fivethreeo/scripts,gtank/scripts,fivethreeo/scripts,mischief/scripts,marineam/coreos-scripts,sigma/coreos-scripts,coreos/scripts,mischief/scripts,zhang0137/scripts,trnubo/scripts,vmware/coreos-scripts,vmware/coreos-scripts,nicescale/scripts,nicescale/scripts,smilart/scripts,BugRoger/scripts,andrejro/coreos--scripts,BugRoger/scripts,marineam/coreos-scripts,trnubo/scripts,mischief/scripts,gtank/scripts,fivethreeo/scripts,nicescale/scripts,mjg59/scripts