Skip to content
This repository has been archived by the owner on Sep 15, 2021. It is now read-only.

Commit

Permalink
Bug 1143013 - Ensure b2g_build passes number of cores to commands to …
Browse files Browse the repository at this point in the history
…workaround any previous -j settings r=catlee
  • Loading branch information
lightsofapollo committed Mar 13, 2015
1 parent ca37d5e commit 60b0bc1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion mozharness/mozilla/building/buildb2gbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ def checkout_sources(self):
self.run_command(cmd, cwd=dirs['work_dir'])

config_result = self.run_command([
'./config.sh', '-q', self.config['target'], manifest_filename,
'./config.sh', '-j100', '-q', self.config['target'], manifest_filename,
], cwd=dirs['work_dir'], output_timeout=55 * 60)

# TODO: Check return code from these? retry?
Expand Down
6 changes: 6 additions & 0 deletions scripts/b2g_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import tempfile
from datetime import datetime
import urlparse
import multiprocessing
import xml.dom.minidom

try:
Expand Down Expand Up @@ -545,6 +546,11 @@ def generate_build_command(self, target=None):
# Workaround bug 984061
if target == 'package-tests':
cmd.append('-j1')
else:
# Ensure we always utilize the correct number of cores
# regardless of the configuration which may be set by repo
# config changes...
cmd.append('-j{}'.format(multiprocessing.cpu_count()))
cmd.append(target)
return cmd

Expand Down

0 comments on commit 60b0bc1

Please sign in to comment.