From 544816659bc2cc69c06a755aa3f8f9e94f94454e Mon Sep 17 00:00:00 2001 From: spo Date: Mon, 28 Dec 2015 12:28:04 +0300 Subject: [PATCH] Improve lcov scripts for Linux --- lcov-reset.sh | 5 ++++- lcov-run.sh | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lcov-reset.sh b/lcov-reset.sh index 542419c7e..bb4847ada 100755 --- a/lcov-reset.sh +++ b/lcov-reset.sh @@ -3,5 +3,8 @@ source env.sh source ${TOOLS_DIR}/env_linux.sh +export GCOV_DIR=${GCOV_DIR:-${BUILD_DIR}} + echo "Reset coverage data..." -lcov --zerocounters --directory $(cd ../; pwd) +lcov --zerocounters --directory ${GCOV_DIR} + diff --git a/lcov-run.sh b/lcov-run.sh index ef450e0a5..b1a0c5f82 100755 --- a/lcov-run.sh +++ b/lcov-run.sh @@ -3,8 +3,10 @@ source env.sh source ${TOOLS_DIR}/env_linux.sh +export GCOV_DIR=${GCOV_DIR:-${BUILD_DIR}} + echo "Collect coverage data..." -lcov --capture --directory ${BUILD_DIR} --output-file coverage.info +lcov --capture --directory ${GCOV_DIR} --output-file coverage.info echo "Generate HTML for coverage data..." genhtml coverage.info --output-directory ${1:-lcov_html} -- 2.39.2