summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Bettis <jbettis@google.com>2022-02-02 16:09:29 -0700
committerCommit Bot <commit-bot@chromium.org>2022-02-03 04:01:44 +0000
commitf54582cce7ca89f87d87bdb53778a709824f7eae (patch)
treebf783827ffcf7c3da9993053ac06503514df94bb
parentd6a4cb92db833a14375487e3ce4c9179f702afc1 (diff)
downloadchrome-ec-f54582cce7ca89f87d87bdb53778a709824f7eae.tar.gz
zmake: Fix configure --coverage --build on test
Running zmake configure --coverage --build on a non-test works great. It builds all the libs, and runs lcov to get a 0 lines covered report as a baseline. And the coverage enabled binary is too big to flash, so there is no reason to finish the build. However for tests, you really want the full binary, but there is no reason to run lcov until after you run the test once. Change configure --coverage --build to only do the partial build and lcov on non-tests. BRANCH=None BUG=None TEST=zmake configure --coverage --build zephyr/test/drivers && \ build/zephyr/test-drivers/output/zephyr.elf Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I0a4711da61d894ca39097a912de781e0f816be44 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3433631 Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org> Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
-rw-r--r--zephyr/zmake/zmake/zmake.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/zephyr/zmake/zmake/zmake.py b/zephyr/zmake/zmake/zmake.py
index f8583c3b85..748e9c8def 100644
--- a/zephyr/zmake/zmake/zmake.py
+++ b/zephyr/zmake/zmake/zmake.py
@@ -396,7 +396,7 @@ class Zmake:
coverage=coverage,
)
elif build_after_configure:
- if coverage:
+ if coverage and project.config.is_test:
return self._coverage_compile_only(
project=project,
build_dir=build_dir,