From c926d7dc7c4df52c7d3c82c86bae9ac6e8a6b758 Mon Sep 17 00:00:00 2001 From: Daisuke Nojiri Date: Tue, 11 Oct 2016 17:39:14 -0700 Subject: cts: Fix back-to-back build Currently eCTS suites share the same directory (e.g. build/stm32l476g -eval) to put build artifacts even though some files (e.g. board.c) compile differently suite to suite. So, if cts-i2c-stm32l476g-eval is built, followed by cts-gpio-stm32l476g-eval, build fails or produces incorrect binary. This patch makes eCTS create different directories for each suite. As a bonus, we can now builds eCTS suites in parallel. BUG=chromium:654549 BRANCH=none TEST=make buildall -j (with uncommitted change) Change-Id: I4abedc917787be5f79b97e0e50d0d08e01bd5f9d Signed-off-by: Daisuke Nojiri Reviewed-on: https://chromium-review.googlesource.com/398281 --- cts/common/board.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'cts/common/board.py') diff --git a/cts/common/board.py b/cts/common/board.py index a36ca1a3a7..42479e6de3 100644 --- a/cts/common/board.py +++ b/cts/common/board.py @@ -109,8 +109,7 @@ class Board(object): '--directory=' + ec_dir, 'BOARD=' + self.board, 'CTS_MODULE=' + module, - '-j', - '-B'] + '-j'] if debug: cmds.append('CTS_DEBUG=TRUE') @@ -118,9 +117,8 @@ class Board(object): print ' '.join(cmds) return sp.call(cmds) - def flash(self): + def flash(self, image_path): """Flashes board with most recent build ec.bin""" - image_path = os.path.join('build', self.board, 'ec.bin') cmd = ['reset_config connect_assert_srst', 'init', 'reset init', -- cgit v1.2.1