From eaad036407c9546be0de27f61745fef4b6856e56 Mon Sep 17 00:00:00 2001 From: johannst Date: Mon, 29 May 2023 20:34:16 +0000 Subject: deploy: d2013ee5952bbcf88906a832748783e372f3a939 --- development/gcov/Makefile | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 development/gcov/Makefile (limited to 'development/gcov/Makefile') diff --git a/development/gcov/Makefile b/development/gcov/Makefile new file mode 100644 index 0000000..f27f8d8 --- /dev/null +++ b/development/gcov/Makefile @@ -0,0 +1,24 @@ +# Copyright (C) 2023 johannst + +CXXFLAGS = -fprofile-arcs -ftest-coverage +# or the alias +#CXXFLAGS = --coverage + +cov-gcc: clean + g++ $(CXXFLAGS) -c -o cov.o cov.cc + g++ $(CXXFLAGS) -o $@ cov.o + ./$@ + gcov --demangled-names cov.cc + cat cov.cc.gcov +.PHONY: cov-gcc + +cov-clang: clean + clang++ $(CXXFLAGS) -c -o cov.o cov.cc + clang++ $(CXXFLAGS) -o $@ cov.o + ./$@ + llvm-cov gcov --demangled-names cov.cc + cat cov.cc.gcov +.PHONY: cov-clang + +clean: + $(RM) *.gcov *.gcno *.gcda *.o cov-* -- cgit v1.2.3