[CRIU] [PATCH 21/23] CI: move GCOV flag to travis.yml
Kir Kolyshkin
kir at openvz.org
Tue Oct 11 18:46:59 PDT 2016
Move GCOV to travis environment, so now we can change it easily
on a per-build basis.
Signed-off-by: Kir Kolyshkin <kir at openvz.org>
---
.travis.yml | 12 ++++++------
scripts/travis/travis-after_success | 3 +++
scripts/travis/travis-tests | 2 +-
3 files changed, 10 insertions(+), 7 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 98a99d0..8b8a41a 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -4,12 +4,12 @@ dist: trusty
services:
- docker
env:
- - TR_ARCH=local
- - TR_ARCH=x86_64
- - TR_ARCH=armv7hf
- - TR_ARCH=aarch64
- - TR_ARCH=ppc64le
- - TR_ARCH=alpine
+ - TR_ARCH=local GCOV=1
+ - TR_ARCH=x86_64 GCOV=1
+ - TR_ARCH=armv7hf GCOV=1
+ - TR_ARCH=aarch64 GCOV=1
+ - TR_ARCH=ppc64le GCOV=1
+ - TR_ARCH=alpine GCOV=1
script:
- sudo make -C scripts/travis $TR_ARCH
after_success:
diff --git a/scripts/travis/travis-after_success b/scripts/travis/travis-after_success
index 4ba2bd7..05322ef 100755
--- a/scripts/travis/travis-after_success
+++ b/scripts/travis/travis-after_success
@@ -1,6 +1,9 @@
#!/bin/sh
set -x -e
+# We only need to run the below for gcov-enabled builds
+[ "$GCOV" = "1" ] || exit 0
+
sudo apt-get install -qq -y lcov
gem install coveralls-lcov
sudo lcov --directory ../.. --capture --output-file coverage.info
diff --git a/scripts/travis/travis-tests b/scripts/travis/travis-tests
index fceeb63..2a16711 100755
--- a/scripts/travis/travis-tests
+++ b/scripts/travis/travis-tests
@@ -20,7 +20,7 @@ travis_prep
ulimit -c unlimited
echo "|`pwd`/test/abrt.sh %P %p %s %e" > /proc/sys/kernel/core_pattern
-export GCOV=1
+export GCOV
make
make -C test/zdtm
--
2.7.4
More information about the CRIU
mailing list