xaizek / uncov (License: AGPLv3+) (since 2018-12-07)
Uncov(er) is a tool that collects and processes code coverage reports.
Commit 0bae9ee70b2cc2e0a42f38ba39544287f3b382e7

Allow customizing g++ command for test coverage
This allows working around mismatched gcc and gcov versions that cause a
failure in tests due to incompatible formats.
Author: xaizek
Author date (UTC): 2025-11-26 13:01
Committer name: xaizek
Committer date (UTC): 2025-11-26 13:01
Parent(s): 3d7ab863e02678d7c1f1da329827f7ebf674cd8b
Signing key: 99DC5E4DB05F6BE2
Tree: 073db45a5d4f92af2c8b017e961a47db652823af
File Lines added Lines deleted
Makefile 6 1
scripts/appveyor/config.yml 1 0
File Makefile changed (mode: 100644) (index 2c88d09..529137b)
... ... CXXFLAGS += -Wno-non-template-friend -include config.h
3 3 LDFLAGS += $(ld_extra) -g -lsqlite3 -lgit2 -lsource-highlight -lz LDFLAGS += $(ld_extra) -g -lsqlite3 -lgit2 -lsource-highlight -lz
4 4 LDFLAGS += -lboost_filesystem -lboost_iostreams -lboost_program_options LDFLAGS += -lboost_filesystem -lboost_iostreams -lboost_program_options
5 5
6 # this allows customizing which g++ gets called to work around mismatch between
7 # gcc and gcov versions that cause a failure in tests due to incompatible
8 # formats
9 GXX ?= g++
10
6 11 INSTALL := install -D INSTALL := install -D
7 12
8 13 PREFIX := /usr PREFIX := /usr
 
... ... check: $(target) $(out_dir)/tests/tests tests/test-repo-gcno/test-repo-gcno \
189 194 tests/test-repo-gcno/test-repo-gcno: tests/test-repo-gcno/main.cpp tests/test-repo-gcno/test-repo-gcno: tests/test-repo-gcno/main.cpp
190 195 # this must always be compiled with GCC for gcov to be able to process # this must always be compiled with GCC for gcov to be able to process
191 196 # output files (need a separate variable for it?) # output files (need a separate variable for it?)
192 cd tests/test-repo-gcno/ && g++ --coverage -o test-repo-gcno main.cpp
197 cd tests/test-repo-gcno/ && $(GXX) --coverage -o test-repo-gcno main.cpp
193 198
194 199 install: release install: release
195 200 $(INSTALL) -t $(DESTDIR)$(PREFIX)/bin/ $(bin) $(webbin) uncov-gcov $(INSTALL) -t $(DESTDIR)$(PREFIX)/bin/ $(bin) $(webbin) uncov-gcov
File scripts/appveyor/config.yml changed (mode: 100644) (index c503759..b4b9608)
... ... environment:
21 21 CC: ccache clang CC: ccache clang
22 22 CXX: ccache clang++ CXX: ccache clang++
23 23 APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2204 APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2204
24 GXX: g++-11
24 25 - BUILDENV: ubuntu - BUILDENV: ubuntu
25 26 CC: ccache gcc CC: ccache gcc
26 27 CXX: ccache g++ CXX: ccache g++
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/uncov

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/uncov

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master