Ah.
I added the flags to 2 files, listed below, and rebuild. It builds now. I'm not too sure if the edits below are entirely placed in the right way or in the right place, but it does make the build work ;)
external/liborcus/ExternalProject_liborcus.mk
external/expat/ExternalProject_expat.mk
Thanks. Now onward to the lcov/gcov html reports !
Sincerely,
Maarten
diff --git a/external/liborcus/ExternalProject_liborcus.mk b/external/liborcus/ExternalProject_liborcus.mk
index e7f929a28b4c..bb9ca3841b65 100644
--- a/external/liborcus/ExternalProject_liborcus.mk
+++ b/external/liborcus/ExternalProject_liborcus.mk
@@ -49,7 +49,7 @@ endif
liborcus_CPPCLAGS=$(CPPFLAGS)
ifeq ($(SYSTEM_ZLIB),)
-liborcus_CPPFLAGS+=$(ZLIB_CFLAGS)
+liborcus_CPPFLAGS+=$(ZLIB_CFLAGS) -fprofile-arcs -ftest-coverage
endif
#
# OSes that use the GNU C++ library need to use -D_GLIBCXX_DEBUG in
@@ -60,10 +60,10 @@ endif
#
liborcus_CPPFLAGS+=$(gb_COMPILERDEFS_STDLIB_DEBUG)
-liborcus_CXXFLAGS=$(CXXFLAGS) $(gb_VISIBILITY_FLAGS) $(gb_VISIBILITY_FLAGS_CXX) $(CXXFLAGS_CXX11) -DBOOST_SYSTEM_NO_DEPRECATED
+liborcus_CXXFLAGS=$(CXXFLAGS) $(gb_VISIBILITY_FLAGS) $(gb_VISIBILITY_FLAGS_CXX) $(CXXFLAGS_CXX11) -DBOOST_SYSTEM_NO_DEPRECATED -fprofile-arcs -ftest-coverage
liborcus_LDFLAGS=$(LDFLAGS) $(gb_LTOFLAGS)
liborcus_CXXFLAGS+=$(call gb_ExternalProject_get_build_flags,liborcus)
-liborcus_LDFLAGS+=$(call gb_ExternalProject_get_link_flags,liborcus)
+liborcus_LDFLAGS+=$(call gb_ExternalProject_get_link_flags,liborcus) -fprofile-arcs -lgcov
ifeq ($(COM),MSC)
liborcus_CXXFLAGS+=$(BOOST_CXXFLAGS)
endif
diff --git a/external/expat/ExternalProject_expat.mk b/external/expat/ExternalProject_expat.mk
index 1e9609a4aff8..f14ef12d0aba 100644
--- a/external/expat/ExternalProject_expat.mk
+++ b/external/expat/ExternalProject_expat.mk
@@ -22,4 +22,10 @@ $(call gb_ExternalProject_get_state_target,expat,configure) :
,,expat_configure.log)
$(call gb_Trace_EndRange,expat,EXTERNAL)
+CFLAGS += -fprofile-arcs -ftest-coverage
+CXXFLAGS += -fprofile-arcs -ftest-coverage
+LDFLAGS += -fprofile-arcs -lgcov
+
+
+
I added the flags to 2 files, listed below, and rebuild. It builds now. I'm not too sure if the edits below are entirely placed in the right way or in the right place, but it does make the build work ;)
external/liborcus/ExternalProject_liborcus.mk
external/expat/ExternalProject_expat.mk
Thanks. Now onward to the lcov/gcov html reports !
Sincerely,
Maarten
diff --git a/external/liborcus/ExternalProject_liborcus.mk b/external/liborcus/ExternalProject_liborcus.mk
index e7f929a28b4c..bb9ca3841b65 100644
--- a/external/liborcus/ExternalProject_liborcus.mk
+++ b/external/liborcus/ExternalProject_liborcus.mk
@@ -49,7 +49,7 @@ endif
liborcus_CPPCLAGS=$(CPPFLAGS)
ifeq ($(SYSTEM_ZLIB),)
-liborcus_CPPFLAGS+=$(ZLIB_CFLAGS)
+liborcus_CPPFLAGS+=$(ZLIB_CFLAGS) -fprofile-arcs -ftest-coverage
endif
#
# OSes that use the GNU C++ library need to use -D_GLIBCXX_DEBUG in
@@ -60,10 +60,10 @@ endif
#
liborcus_CPPFLAGS+=$(gb_COMPILERDEFS_STDLIB_DEBUG)
-liborcus_CXXFLAGS=$(CXXFLAGS) $(gb_VISIBILITY_FLAGS) $(gb_VISIBILITY_FLAGS_CXX) $(CXXFLAGS_CXX11) -DBOOST_SYSTEM_NO_DEPRECATED
+liborcus_CXXFLAGS=$(CXXFLAGS) $(gb_VISIBILITY_FLAGS) $(gb_VISIBILITY_FLAGS_CXX) $(CXXFLAGS_CXX11) -DBOOST_SYSTEM_NO_DEPRECATED -fprofile-arcs -ftest-coverage
liborcus_LDFLAGS=$(LDFLAGS) $(gb_LTOFLAGS)
liborcus_CXXFLAGS+=$(call gb_ExternalProject_get_build_flags,liborcus)
-liborcus_LDFLAGS+=$(call gb_ExternalProject_get_link_flags,liborcus)
+liborcus_LDFLAGS+=$(call gb_ExternalProject_get_link_flags,liborcus) -fprofile-arcs -lgcov
ifeq ($(COM),MSC)
liborcus_CXXFLAGS+=$(BOOST_CXXFLAGS)
endif
diff --git a/external/expat/ExternalProject_expat.mk b/external/expat/ExternalProject_expat.mk
index 1e9609a4aff8..f14ef12d0aba 100644
--- a/external/expat/ExternalProject_expat.mk
+++ b/external/expat/ExternalProject_expat.mk
@@ -22,4 +22,10 @@ $(call gb_ExternalProject_get_state_target,expat,configure) :
,,expat_configure.log)
$(call gb_Trace_EndRange,expat,EXTERNAL)
+CFLAGS += -fprofile-arcs -ftest-coverage
+CXXFLAGS += -fprofile-arcs -ftest-coverage
+LDFLAGS += -fprofile-arcs -lgcov
+
+
+
On Wed, May 11, 2022 at 9:35 PM Luboš Luňák <l.lunak@xxxxxxxxxxxxx> wrote:
Not those makefiles. I meant external/*/*.mk (and solenv/gbuild/*.mk).
--
Luboš Luňák
l.lunak@xxxxxxxxxxxxx