From da3107c5f8bce2f3219a43f2ca3972a1bb094ceb Mon Sep 17 00:00:00 2001
From: Nicolas Werner <nicolas.werner@hotmail.de>
Date: Wed, 11 Dec 2019 22:26:16 +0100
Subject: [PATCH] Use lcov instead of gcov

---
 .ci/script.sh | 2 ++
 .travis.yml   | 2 +-
 Dockerfile    | 2 ++
 3 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/.ci/script.sh b/.ci/script.sh
index 3e5cd18cd..f2fe09816 100755
--- a/.ci/script.sh
+++ b/.ci/script.sh
@@ -8,9 +8,11 @@ if [ $TRAVIS_OS_NAME == linux ]; then
 
     sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/${CC_VERSION} 10
     sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/${CXX_VERSION} 10
+    sudo update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-8 10
 
     sudo update-alternatives --set gcc "/usr/bin/${CC_VERSION}"
     sudo update-alternatives --set g++ "/usr/bin/${CXX_VERSION}"
+    sudo update-alternatives --set gcov "/usr/bin/gcov-8"
 
     # Build the library.
     cmake -H. -Bbuild -DCMAKE_BUILD_TYPE=Debug \
diff --git a/.travis.yml b/.travis.yml
index 166129111..390a58258 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -68,6 +68,6 @@ after_success:
     if [ $COVERAGE == ON ]; then
       docker run -v `pwd`:/build \
         --net=host nheko-reborn/mtxclient \
-        /bin/bash -c "make -C build -j1 test_coverage && ./.ci/coverage.sh" && \
+        /bin/bash -c "make -C build -j1 test && ./.ci/coverage.sh" && \
       bash <(curl -s https://codecov.io/bash) -f "!*tests*" || echo "Codecov failed"
     fi
diff --git a/Dockerfile b/Dockerfile
index b87283c07..2510ec0d7 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -34,8 +34,10 @@ RUN \
         openssl && \
     sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 10 && \
     sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 10 && \
+    sudo update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-8 10 && \
     sudo update-alternatives --set gcc "/usr/bin/gcc-8" && \
     sudo update-alternatives --set g++ "/usr/bin/g++-8" && \
+    sudo update-alternatives --set gcov "/usr/bin/gcov-8" && \
     # libsodium
     mkdir -p /build/libsodium && cd /build/libsodium && \
     curl -L https://download.libsodium.org/libsodium/releases/libsodium-${LIBSODIUM_VERSION}.tar.gz -o libsodium-${LIBSODIUM_VERSION}.tar.gz && \
-- 
GitLab