Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Unified Diff: parallel_emerge

Issue 3418001: Turn on --fast on official builds. (Closed) Base URL: http://git.chromium.org/git/crosutils.git
Patch Set: Typo fix -- thanks nsanders Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « common.sh ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: parallel_emerge
diff --git a/parallel_emerge b/parallel_emerge
index c912a115ac000207582caa693c4997e429764990..ce40be4b07a49a22ce31fd1bfe266f29ff102305 100755
--- a/parallel_emerge
+++ b/parallel_emerge
@@ -310,13 +310,6 @@ class DepGraphGenerator(object):
# will be going away soon as we migrate to CROS_WORKON_SRCROOT.
os.environ.setdefault("CHROMEOS_ROOT", os.environ["HOME"] + "/trunk")
- # Modify the environment to disable locking by default.
- # TODO(davidjames): This option can cause problems if packages muck
- # with each other during the post-install step. There are a few host
- # packages that do this, so we only do this environment modification for
- # board builds.
- os.environ.setdefault("PORTAGE_LOCKS", "false")
-
# Turn off interactive delays
os.environ["EBEEP_IGNORE"] = "1"
os.environ["EPAUSE_IGNORE"] = "1"
@@ -357,11 +350,17 @@ class DepGraphGenerator(object):
# TODO(davidjames): Look for a better solution.
features = os.environ.get("FEATURES", "") + " -collision-protect"
- # If we're cross-compiling, updating the environment every time we install
- # a package isn't necessary, and leads to race conditions when
- # PORTAGE_LOCKS is false. In this case, do environment updates at the end,
- # instead.
- if self.board and os.environ.get("PORTAGE_LOCKS") == "false":
+ # If we're installing packages to the board, and we're not using the
+ # official flag, we can enable the following optimizations:
+ # 1) Don't lock during install step. This allows multiple packages to be
+ # installed at once. This is safe because our board packages do not
+ # muck with each other during the post-install step.
+ # 2) Don't update the environment until the end of the build. This is
+ # safe because board packages don't need to run during the build --
+ # they're cross-compiled, so our CPU architecture doesn't support them
+ # anyway.
+ if self.board and os.environ.get("CHROMEOS_OFFICIAL") != "1":
+ os.environ.setdefault("PORTAGE_LOCKS", "false")
features = features + " no-env-update"
os.environ["FEATURES"] = features
« no previous file with comments | « common.sh ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698