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

Side by Side Diff: mojo/tools/mojob.sh

Issue 608313003: Mojo: mojob.sh -- limit GOMA builds to load average 100. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 # Copyright 2013 The Chromium Authors. All rights reserved. 2 # Copyright 2013 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 # This a simple script to make building/testing Mojo components easier (on 6 # This a simple script to make building/testing Mojo components easier (on
7 # Linux). 7 # Linux).
8 8
9 # TODO(vtl): Maybe make the test runner smart and not run unchanged test 9 # TODO(vtl): Maybe make the test runner smart and not run unchanged test
10 # binaries. 10 # binaries.
(...skipping 30 matching lines...) Expand all
41 --use-goma - Use goma if \$GOMA_DIR is set or \$HOME/goma exists (default). 41 --use-goma - Use goma if \$GOMA_DIR is set or \$HOME/goma exists (default).
42 --no-use-goma - Do not use goma. 42 --no-use-goma - Do not use goma.
43 43
44 Note: It will abort on the first failure (if any). 44 Note: It will abort on the first failure (if any).
45 EOF 45 EOF
46 } 46 }
47 47
48 do_build() { 48 do_build() {
49 echo "Building in out/$1 ..." 49 echo "Building in out/$1 ..."
50 if [ "$GOMA" = "auto" -a -v GOMA_DIR ]; then 50 if [ "$GOMA" = "auto" -a -v GOMA_DIR ]; then
51 ninja -j 1000 -C "out/$1" mojo || exit 1 51 ninja -j 1000 -l 100 -C "out/$1" mojo || exit 1
52 else 52 else
53 ninja -C "out/$1" mojo || exit 1 53 ninja -C "out/$1" mojo || exit 1
54 fi 54 fi
55 } 55 }
56 56
57 do_unittests() { 57 do_unittests() {
58 echo "Running unit tests in out/$1 ..." 58 echo "Running unit tests in out/$1 ..."
59 mojo/tools/test_runner.py mojo/tools/data/unittests "out/$1" \ 59 mojo/tools/test_runner.py mojo/tools/data/unittests "out/$1" \
60 mojob_test_successes || exit 1 60 mojob_test_successes || exit 1
61 } 61 }
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 ;; 229 ;;
230 --no-use-goma) 230 --no-use-goma)
231 GOMA=disabled 231 GOMA=disabled
232 ;; 232 ;;
233 *) 233 *)
234 echo "Unknown command \"${arg}\". Try \"$(basename "$0") help\"." 234 echo "Unknown command \"${arg}\". Try \"$(basename "$0") help\"."
235 exit 1 235 exit 1
236 ;; 236 ;;
237 esac 237 esac
238 done 238 done
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698