[evolution-data-server] build: Add an --enable-code-coverage configure option to enable gcov support
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] build: Add an --enable-code-coverage configure option to enable gcov support
- Date: Mon, 26 Mar 2012 10:30:07 +0000 (UTC)
commit 3bc3fa26e53895b14eadabe2ed617e67e18fab96
Author: Philip Withnall <philip tecnocode co uk>
Date: Tue Jan 24 20:06:03 2012 +0000
build: Add an --enable-code-coverage configure option to enable gcov support
When enabled, this will compile all the EDS libraries (but not test programs)
with the necessary GCC and ld flags to enable code coverage support using
gcov.
Closes: https://bugzilla.gnome.org/show_bug.cgi?id=668608
addressbook/backends/file/Makefile.am | 8 ++++++--
addressbook/backends/google/Makefile.am | 8 ++++++--
addressbook/backends/ldap/Makefile.am | 8 ++++++--
addressbook/backends/vcf/Makefile.am | 8 ++++++--
addressbook/backends/webdav/Makefile.am | 8 ++++++--
addressbook/libebook/Makefile.am | 8 ++++++--
addressbook/libedata-book/Makefile.am | 8 ++++++--
addressbook/libegdbus/Makefile.am | 8 ++++++--
calendar/backends/caldav/Makefile.am | 8 ++++++--
calendar/backends/contacts/Makefile.am | 8 ++++++--
calendar/backends/file/Makefile.am | 8 ++++++--
calendar/backends/http/Makefile.am | 8 ++++++--
calendar/backends/weather/Makefile.am | 8 ++++++--
calendar/libecal/Makefile.am | 8 ++++++--
calendar/libedata-cal/Makefile.am | 8 ++++++--
calendar/libegdbus/Makefile.am | 8 ++++++--
camel/Makefile.am | 8 ++++++--
camel/providers/imap/Makefile.am | 8 ++++++--
camel/providers/imapx/Makefile.am | 8 ++++++--
camel/providers/local/Makefile.am | 8 ++++++--
camel/providers/nntp/Makefile.am | 8 ++++++--
camel/providers/pop3/Makefile.am | 8 ++++++--
camel/providers/sendmail/Makefile.am | 8 ++++++--
camel/providers/smtp/Makefile.am | 8 ++++++--
configure.ac | 19 +++++++++++++++++++
libebackend/Makefile.am | 8 ++++++--
libedataserver/Makefile.am | 8 ++++++--
libedataserverui/Makefile.am | 9 +++++++--
services/evolution-addressbook-factory/Makefile.am | 6 ++++++
services/evolution-calendar-factory/Makefile.am | 6 ++++++
30 files changed, 194 insertions(+), 54 deletions(-)
---
diff --git a/addressbook/backends/file/Makefile.am b/addressbook/backends/file/Makefile.am
index 08cf58f..ebb13f4 100644
--- a/addressbook/backends/file/Makefile.am
+++ b/addressbook/backends/file/Makefile.am
@@ -8,7 +8,9 @@ libebookbackendfile_la_CPPFLAGS = \
-I$(top_srcdir)/addressbook \
-I$(top_builddir)/addressbook \
$(DB_CFLAGS) \
- $(EVOLUTION_ADDRESSBOOK_CFLAGS)
+ $(EVOLUTION_ADDRESSBOOK_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebookbackendfile_la_SOURCES = \
e-book-backend-file.c \
@@ -23,6 +25,8 @@ libebookbackendfile_la_LIBADD = \
$(DB_LIBS) \
$(EVOLUTION_ADDRESSBOOK_LIBS)
-libebookbackendfile_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED)
+libebookbackendfile_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/addressbook/backends/google/Makefile.am b/addressbook/backends/google/Makefile.am
index c4a4684..88c3aac 100644
--- a/addressbook/backends/google/Makefile.am
+++ b/addressbook/backends/google/Makefile.am
@@ -17,7 +17,9 @@ libebookbackendgoogle_la_CPPFLAGS = \
$(SOUP_CFLAGS) \
$(GDATA_CFLAGS) \
$(GOA_CFLAGS) \
- $(OAUTH_CFLAGS)
+ $(OAUTH_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebookbackendgoogle_la_SOURCES = \
e-book-backend-google-factory.c \
@@ -37,6 +39,8 @@ libebookbackendgoogle_la_LIBADD = \
$(OAUTH_LIBS)
libebookbackendgoogle_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/addressbook/backends/ldap/Makefile.am b/addressbook/backends/ldap/Makefile.am
index 5b563c6..05ea08f 100644
--- a/addressbook/backends/ldap/Makefile.am
+++ b/addressbook/backends/ldap/Makefile.am
@@ -8,7 +8,9 @@ libebookbackendldap_la_CPPFLAGS = \
-I$(top_srcdir)/addressbook \
-I$(top_builddir)/addressbook \
$(LDAP_CFLAGS) \
- $(EVOLUTION_ADDRESSBOOK_CFLAGS)
+ $(EVOLUTION_ADDRESSBOOK_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebookbackendldap_la_SOURCES = \
e-book-backend-ldap.c \
@@ -23,7 +25,9 @@ libebookbackendldap_la_LIBADD = \
$(EVOLUTION_ADDRESSBOOK_LIBS) \
$(LDAP_LIBS)
-libebookbackendldap_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED)
+libebookbackendldap_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
LDAP_SCHEMA = \
evolutionperson.schema
diff --git a/addressbook/backends/vcf/Makefile.am b/addressbook/backends/vcf/Makefile.am
index d8159ae..0f0266b 100644
--- a/addressbook/backends/vcf/Makefile.am
+++ b/addressbook/backends/vcf/Makefile.am
@@ -7,7 +7,9 @@ libebookbackendvcf_la_CPPFLAGS = \
-I$(top_builddir) \
-I$(top_srcdir)/addressbook \
-I$(top_builddir)/addressbook \
- $(EVOLUTION_ADDRESSBOOK_CFLAGS)
+ $(EVOLUTION_ADDRESSBOOK_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebookbackendvcf_la_SOURCES = \
e-book-backend-vcf.c \
@@ -22,6 +24,8 @@ libebookbackendvcf_la_LIBADD = \
$(EVOLUTION_ADDRESSBOOK_LIBS)
libebookbackendvcf_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/addressbook/backends/webdav/Makefile.am b/addressbook/backends/webdav/Makefile.am
index e5f2a74..9a4aee5 100644
--- a/addressbook/backends/webdav/Makefile.am
+++ b/addressbook/backends/webdav/Makefile.am
@@ -8,7 +8,9 @@ libebookbackendwebdav_la_CPPFLAGS = \
-I$(top_srcdir)/addressbook \
-I$(top_builddir)/addressbook \
$(SOUP_CFLAGS) \
- $(EVOLUTION_ADDRESSBOOK_CFLAGS)
+ $(EVOLUTION_ADDRESSBOOK_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebookbackendwebdav_la_SOURCES = \
e-book-backend-webdav-factory.c \
@@ -23,6 +25,8 @@ libebookbackendwebdav_la_LIBADD = \
$(SOUP_LIBS) \
$(EVOLUTION_ADDRESSBOOK_LIBS)
-libebookbackendwebdav_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED)
+libebookbackendwebdav_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/addressbook/libebook/Makefile.am b/addressbook/libebook/Makefile.am
index 602fbe0..801f8ed 100644
--- a/addressbook/libebook/Makefile.am
+++ b/addressbook/libebook/Makefile.am
@@ -19,7 +19,9 @@ libebook_1_2_la_CPPFLAGS = \
-I$(top_builddir)/addressbook/libegdbus \
-I$(top_builddir)/addressbook/libebook \
$(EVOLUTION_ADDRESSBOOK_CFLAGS) \
- $(CAMEL_CFLAGS)
+ $(CAMEL_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebook_1_2_la_SOURCES = \
$(MARSHAL_GENERATED) \
@@ -46,7 +48,9 @@ libebook_1_2_la_LIBADD = \
$(CAMEL_LIBS)
libebook_1_2_la_LDFLAGS = \
- -version-info $(LIBEBOOK_CURRENT):$(LIBEBOOK_REVISION):$(LIBEBOOK_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEBOOK_CURRENT):$(LIBEBOOK_REVISION):$(LIBEBOOK_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libebookincludedir = $(privincludedir)/libebook
diff --git a/addressbook/libedata-book/Makefile.am b/addressbook/libedata-book/Makefile.am
index 756d182..4b99fe6 100644
--- a/addressbook/libedata-book/Makefile.am
+++ b/addressbook/libedata-book/Makefile.am
@@ -21,7 +21,9 @@ libedata_book_1_2_la_CPPFLAGS = \
$(DB_CFLAGS) \
$(SQLITE3_CFLAGS) \
$(GOA_CFLAGS) \
- $(EVOLUTION_ADDRESSBOOK_CFLAGS)
+ $(EVOLUTION_ADDRESSBOOK_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libedata_book_1_2_la_SOURCES = \
$(ENUM_GENERATED) \
@@ -49,7 +51,9 @@ libedata_book_1_2_la_LIBADD = \
$(EVOLUTION_ADDRESSBOOK_LIBS)
libedata_book_1_2_la_LDFLAGS = \
- -version-info $(LIBEDATABOOK_CURRENT):$(LIBEDATABOOK_REVISION):$(LIBEDATABOOK_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEDATABOOK_CURRENT):$(LIBEDATABOOK_REVISION):$(LIBEDATABOOK_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libedata_bookincludedir = $(privincludedir)/libedata-book
diff --git a/addressbook/libegdbus/Makefile.am b/addressbook/libegdbus/Makefile.am
index f564535..d176dac 100644
--- a/addressbook/libegdbus/Makefile.am
+++ b/addressbook/libegdbus/Makefile.am
@@ -6,7 +6,9 @@ libegdbus_book_la_CPPFLAGS = \
-DG_LOG_DOMAIN=\"libegdbus-book\" \
-I$(top_srcdir) \
-I$(top_srcdir)/addressbook \
- $(E_DATA_SERVER_CFLAGS)
+ $(E_DATA_SERVER_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libegdbus_book_la_SOURCES = \
e-gdbus-book.h \
@@ -20,6 +22,8 @@ libegdbus_book_la_LIBADD = \
$(top_builddir)/libedataserver/libedataserver-1.2.la \
$(E_DATA_SERVER_LIBS)
-libegdbus_book_la_LDFLAGS = $(NO_UNDEFINED)
+libegdbus_book_la_LDFLAGS = $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/calendar/backends/caldav/Makefile.am b/calendar/backends/caldav/Makefile.am
index fad450b..5ecd526 100644
--- a/calendar/backends/caldav/Makefile.am
+++ b/calendar/backends/caldav/Makefile.am
@@ -7,7 +7,9 @@ libecalbackendcaldav_la_CPPFLAGS = \
-I$(top_builddir)/calendar \
$(EVOLUTION_CALENDAR_CFLAGS) \
$(SOUP_CFLAGS) \
- -DG_LOG_DOMAIN=\"e-cal-backend-caldav\"
+ -DG_LOG_DOMAIN=\"e-cal-backend-caldav\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libecalbackendcaldav_la_SOURCES = \
e-cal-backend-caldav-factory.c \
@@ -23,6 +25,8 @@ libecalbackendcaldav_la_LIBADD = \
$(SOUP_LIBS)
libecalbackendcaldav_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/calendar/backends/contacts/Makefile.am b/calendar/backends/contacts/Makefile.am
index b589e92..bb2d290 100644
--- a/calendar/backends/contacts/Makefile.am
+++ b/calendar/backends/contacts/Makefile.am
@@ -10,7 +10,9 @@ libecalbackendcontacts_la_CPPFLAGS = \
-I$(top_srcdir)/addressbook \
-I$(top_builddir)/addressbook \
$(EVOLUTION_CALENDAR_CFLAGS) \
- $(SOUP_CFLAGS)
+ $(SOUP_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libecalbackendcontacts_la_SOURCES = \
e-cal-backend-contacts-factory.c \
@@ -27,6 +29,8 @@ libecalbackendcontacts_la_LIBADD = \
$(SOUP_LIBS)
libecalbackendcontacts_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/calendar/backends/file/Makefile.am b/calendar/backends/file/Makefile.am
index d4b14e0..c6553c3 100644
--- a/calendar/backends/file/Makefile.am
+++ b/calendar/backends/file/Makefile.am
@@ -7,7 +7,9 @@ libecalbackendfile_la_CPPFLAGS = \
-I$(top_builddir) \
-I$(top_srcdir)/calendar \
-I$(top_builddir)/calendar \
- $(EVOLUTION_CALENDAR_CFLAGS)
+ $(EVOLUTION_CALENDAR_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
noinst_PROGRAMS = test-interval-searches
@@ -30,7 +32,9 @@ libecalbackendfile_la_LIBADD = \
$(EVOLUTION_CALENDAR_LIBS)
libecalbackendfile_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
test_interval_searches_SOURCES = e-cal-backend-file.c
diff --git a/calendar/backends/http/Makefile.am b/calendar/backends/http/Makefile.am
index a7a367a..2d331df 100644
--- a/calendar/backends/http/Makefile.am
+++ b/calendar/backends/http/Makefile.am
@@ -8,7 +8,9 @@ libecalbackendhttp_la_CPPFLAGS = \
-I$(top_srcdir)/calendar \
-I$(top_builddir)/calendar \
$(EVOLUTION_CALENDAR_CFLAGS) \
- $(SOUP_CFLAGS)
+ $(SOUP_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libecalbackendhttp_la_SOURCES = \
e-cal-backend-http-factory.c \
@@ -24,6 +26,8 @@ libecalbackendhttp_la_LIBADD = \
$(SOUP_LIBS)
libecalbackendhttp_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/calendar/backends/weather/Makefile.am b/calendar/backends/weather/Makefile.am
index fd20e3d..5b0afa4 100644
--- a/calendar/backends/weather/Makefile.am
+++ b/calendar/backends/weather/Makefile.am
@@ -13,7 +13,9 @@ libecalbackendweather_la_CPPFLAGS = \
-DWEATHER_DATADIR=\""$(weatherdatadir)"\" \
$(EVOLUTION_CALENDAR_CFLAGS) \
$(SOUP_CFLAGS) \
- $(LIBGWEATHER_CFLAGS)
+ $(LIBGWEATHER_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libecalbackendweather_la_SOURCES = \
e-cal-backend-weather-factory.c \
@@ -34,6 +36,8 @@ libecalbackendweather_la_LIBADD = \
$(LIBGWEATHER_LIBS)
libecalbackendweather_la_LDFLAGS = \
- -module -avoid-version $(NO_UNDEFINED)
+ -module -avoid-version $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/calendar/libecal/Makefile.am b/calendar/libecal/Makefile.am
index de74a1e..68e6e43 100644
--- a/calendar/libecal/Makefile.am
+++ b/calendar/libecal/Makefile.am
@@ -18,7 +18,9 @@ libecal_1_2_la_CPPFLAGS = \
$(libecal_INCLUDES) \
-DG_LOG_DOMAIN=\"libecal\" \
$(LIBICAL_CFLAGS) \
- $(EVOLUTION_CALENDAR_CFLAGS)
+ $(EVOLUTION_CALENDAR_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libecal_1_2_la_SOURCES = \
$(MARSHAL_GENERATED) \
@@ -43,7 +45,9 @@ libecal_1_2_la_LIBADD = \
$(EVOLUTION_CALENDAR_LIBS)
libecal_1_2_la_LDFLAGS = \
- -version-info $(LIBECAL_CURRENT):$(LIBECAL_REVISION):$(LIBECAL_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBECAL_CURRENT):$(LIBECAL_REVISION):$(LIBECAL_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libecalincludedir = $(privincludedir)/libecal
diff --git a/calendar/libedata-cal/Makefile.am b/calendar/libedata-cal/Makefile.am
index c540d9b..56cd4f2 100644
--- a/calendar/libedata-cal/Makefile.am
+++ b/calendar/libedata-cal/Makefile.am
@@ -19,7 +19,9 @@ libedata_cal_1_2_la_CPPFLAGS = \
-I$(top_builddir) \
-I$(top_builddir)/calendar \
$(LIBICAL_CFLAGS) \
- $(EVOLUTION_CALENDAR_CFLAGS)
+ $(EVOLUTION_CALENDAR_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libedata_cal_1_2_la_SOURCES = \
$(ENUM_GENERATED) \
@@ -45,7 +47,9 @@ libedata_cal_1_2_la_LIBADD = \
$(EVOLUTION_CALENDAR_LIBS)
libedata_cal_1_2_la_LDFLAGS = \
- -version-info $(LIBEDATACAL_CURRENT):$(LIBEDATACAL_REVISION):$(LIBEDATACAL_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEDATACAL_CURRENT):$(LIBEDATACAL_REVISION):$(LIBEDATACAL_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libedata_calincludedir = $(privincludedir)/libedata-cal
diff --git a/calendar/libegdbus/Makefile.am b/calendar/libegdbus/Makefile.am
index e29a27c..6d354c5 100644
--- a/calendar/libegdbus/Makefile.am
+++ b/calendar/libegdbus/Makefile.am
@@ -6,7 +6,9 @@ libegdbus_cal_la_CPPFLAGS = \
-DG_LOG_DOMAIN=\"libegdbus-cal\" \
-I$(top_srcdir) \
-I$(top_srcdir)/calendar \
- $(E_DATA_SERVER_CFLAGS)
+ $(E_DATA_SERVER_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libegdbus_cal_la_SOURCES = \
e-gdbus-cal.h \
@@ -19,6 +21,8 @@ libegdbus_cal_la_SOURCES = \
libegdbus_cal_la_LIBADD = \
$(E_DATA_SERVER_LIBS)
-libegdbus_cal_la_LDFLAGS = $(NO_UNDEFINED)
+libegdbus_cal_la_LDFLAGS = $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
-include $(top_srcdir)/git.mk
diff --git a/camel/Makefile.am b/camel/Makefile.am
index c4a8f83..d0b98d6 100644
--- a/camel/Makefile.am
+++ b/camel/Makefile.am
@@ -48,7 +48,9 @@ libcamel_1_2_la_CPPFLAGS = \
-DE_DATA_SERVER_PREFIX=\"$(prefix)\" \
-DLOCALEDIR=\""$(localedir)"\" \
-DCAMEL_COMPILATION \
- $(CAMEL_CFLAGS)
+ $(CAMEL_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamel_1_2_la_SOURCES = \
$(ENUM_GENERATED) \
@@ -294,7 +296,9 @@ libcamelinclude_HEADERS = \
camel-vtrash-folder.h \
camel.h
-libcamel_1_2_la_LDFLAGS = -version-info $(LIBCAMEL_CURRENT):$(LIBCAMEL_REVISION):$(LIBCAMEL_AGE) $(NO_UNDEFINED)
+libcamel_1_2_la_LDFLAGS = -version-info $(LIBCAMEL_CURRENT):$(LIBCAMEL_REVISION):$(LIBCAMEL_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamel_1_2_la_LIBADD = \
$(CAMEL_LIBS) \
diff --git a/camel/providers/imap/Makefile.am b/camel/providers/imap/Makefile.am
index 3b400e3..85b8917 100644
--- a/camel/providers/imap/Makefile.am
+++ b/camel/providers/imap/Makefile.am
@@ -10,7 +10,9 @@ libcamelimap_la_CPPFLAGS = \
$(CAMEL_CFLAGS) \
$(GNOME_INCLUDEDIR) \
$(GTK_INCLUDEDIR) \
- -DG_LOG_DOMAIN=\"camel-imap-provider\"
+ -DG_LOG_DOMAIN=\"camel-imap-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelimap_la_SOURCES = \
camel-imap-command.c \
@@ -40,7 +42,9 @@ noinst_HEADERS = \
camel-imap-wrapper.h \
camel-imap-private.h
-libcamelimap_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamelimap_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamelimap_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/camel/providers/imapx/Makefile.am b/camel/providers/imapx/Makefile.am
index 8d76c5a..3e6567f 100644
--- a/camel/providers/imapx/Makefile.am
+++ b/camel/providers/imapx/Makefile.am
@@ -8,7 +8,9 @@ libcamelimapx_la_CPPFLAGS = \
-I$(top_srcdir)/camel \
-I$(top_srcdir) \
$(CAMEL_CFLAGS) \
- -DG_LOG_DOMAIN=\"camel-imapx\"
+ -DG_LOG_DOMAIN=\"camel-imapx\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelimapx_la_SOURCES = \
camel-imapx-command.c \
@@ -44,7 +46,9 @@ libcamelimapx_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
$(CAMEL_LIBS)
-libcamelimapx_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamelimapx_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
noinst_PROGRAMS = test-imapx
diff --git a/camel/providers/local/Makefile.am b/camel/providers/local/Makefile.am
index 41e83a1..b4c9cbd 100644
--- a/camel/providers/local/Makefile.am
+++ b/camel/providers/local/Makefile.am
@@ -16,7 +16,9 @@ libcamellocal_la_CPPFLAGS = \
-I$(top_srcdir)/camel \
-I$(top_srcdir) \
$(CAMEL_CFLAGS) \
- -DG_LOG_DOMAIN=\"camel-local-provider\"
+ -DG_LOG_DOMAIN=\"camel-local-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamellocal_la_SOURCES = \
camel-local-folder.c \
@@ -56,7 +58,9 @@ noinst_HEADERS = \
camel-spool-summary.h \
camel-local-private.h
-libcamellocal_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamellocal_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamellocal_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/camel/providers/nntp/Makefile.am b/camel/providers/nntp/Makefile.am
index fe08475..7d3078d 100644
--- a/camel/providers/nntp/Makefile.am
+++ b/camel/providers/nntp/Makefile.am
@@ -10,7 +10,9 @@ libcamelnntp_la_CPPFLAGS = \
$(CAMEL_CFLAGS) \
$(GNOME_INCLUDEDIR) \
$(GTK_INCLUDEDIR) \
- -DG_LOG_DOMAIN=\"camel-nntp-provider\"
+ -DG_LOG_DOMAIN=\"camel-nntp-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelnntp_la_SOURCES = \
camel-nntp-folder.c \
@@ -31,7 +33,9 @@ noinst_HEADERS = \
camel-nntp-stream.h \
camel-nntp-summary.h
-libcamelnntp_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamelnntp_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamelnntp_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/camel/providers/pop3/Makefile.am b/camel/providers/pop3/Makefile.am
index 71f9879..e5fd3c0 100644
--- a/camel/providers/pop3/Makefile.am
+++ b/camel/providers/pop3/Makefile.am
@@ -6,7 +6,9 @@ libcamelpop3_la_CPPFLAGS = \
-I$(top_srcdir) \
-I$(top_srcdir)/camel \
$(CAMEL_CFLAGS) \
- -DG_LOG_DOMAIN=\"camel-pop3-provider\"
+ -DG_LOG_DOMAIN=\"camel-pop3-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelpop3_la_SOURCES = \
camel-pop3-engine.c \
@@ -23,7 +25,9 @@ noinst_HEADERS = \
camel-pop3-stream.h \
camel-pop3-store.h
-libcamelpop3_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamelpop3_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamelpop3_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/camel/providers/sendmail/Makefile.am b/camel/providers/sendmail/Makefile.am
index 61c93f8..8466eb0 100644
--- a/camel/providers/sendmail/Makefile.am
+++ b/camel/providers/sendmail/Makefile.am
@@ -10,7 +10,9 @@ libcamelsendmail_la_CPPFLAGS = \
$(CAMEL_CFLAGS) \
$(GNOME_INCLUDEDIR) \
$(GTK_INCLUDEDIR) \
- -DG_LOG_DOMAIN=\"camel-sendmail-provider\"
+ -DG_LOG_DOMAIN=\"camel-sendmail-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelsendmail_la_SOURCES = \
camel-sendmail-provider.c \
@@ -19,7 +21,9 @@ libcamelsendmail_la_SOURCES = \
noinst_HEADERS = \
camel-sendmail-transport.h
-libcamelsendmail_la_LDFLAGS = -avoid-version -module
+libcamelsendmail_la_LDFLAGS = -avoid-version -module \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamelsendmail_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/camel/providers/smtp/Makefile.am b/camel/providers/smtp/Makefile.am
index 338a735..299f4fa 100644
--- a/camel/providers/smtp/Makefile.am
+++ b/camel/providers/smtp/Makefile.am
@@ -6,7 +6,9 @@ libcamelsmtp_la_CPPFLAGS = \
-I$(top_srcdir) \
-I$(top_srcdir)/camel \
$(CAMEL_CFLAGS) \
- -DG_LOG_DOMAIN=\"camel-smtp-provider\"
+ -DG_LOG_DOMAIN=\"camel-smtp-provider\" \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libcamelsmtp_la_SOURCES = \
camel-smtp-provider.c \
@@ -17,7 +19,9 @@ libcamelsmtp_la_SOURCES = \
noinst_HEADERS = \
camel-smtp-transport.h
-libcamelsmtp_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED)
+libcamelsmtp_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libcamelsmtp_la_LIBADD = \
$(top_builddir)/camel/libcamel-1.2.la \
diff --git a/configure.ac b/configure.ac
index abcda3d..3b1fd66 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1249,6 +1249,24 @@ EVO_MARSHAL_RULE=$srcdir/marshal.mk
AC_SUBST_FILE(EVO_MARSHAL_RULE)
dnl ******************************
+dnl Code coverage flags
+dnl ******************************
+
+AC_ARG_ENABLE([code-coverage],
+ AS_HELP_STRING([--enable-code-coverage], [compile with code coverage code]),
+ [enable_code_coverage=$enableval], [enable_code_coverage=no])
+
+if test "x$GCC" = "xyes"; then
+ if test "x$enable_code_coverage" = "xyes"; then
+ CODE_COVERAGE_CFLAGS="-fprofile-arcs -ftest-coverage -O0 -ggdb"
+ CODE_COVERAGE_LDFLAGS="-lgcov"
+ fi
+fi
+
+AC_SUBST([CODE_COVERAGE_CFLAGS])
+AC_SUBST([CODE_COVERAGE_LDFLAGS])
+
+dnl ******************************
dnl Utility macro to set compiler flags for a specific lib.
dnl EVO_SET_COMPILE_FLAGS(VAR-PREFIX, DEPS, EXTRA-CFLAGS, EXTRA-LIBS)
dnl ******************************
@@ -1628,4 +1646,5 @@ echo "
Introspection: $enable_introspection
Vala bindings: $enable_vala_bindings
GNOME Online Accounts $enable_goa
+ Code coverage (gcov): $enable_code_coverage
"
diff --git a/libebackend/Makefile.am b/libebackend/Makefile.am
index c32c7cf..3e2de98 100644
--- a/libebackend/Makefile.am
+++ b/libebackend/Makefile.am
@@ -7,7 +7,9 @@ libebackend_1_2_la_CPPFLAGS = \
$(DB_CFLAGS) \
$(SQLITE3_CFLAGS) \
$(E_BACKEND_CFLAGS) \
- $(GIO_UNIX_CFLAGS)
+ $(GIO_UNIX_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libebackend_1_2_la_SOURCES = \
e-backend.c \
@@ -31,7 +33,9 @@ libebackend_1_2_la_LIBADD = \
$(DB_LIBS)
libebackend_1_2_la_LDFLAGS = \
- -version-info $(LIBEBACKEND_CURRENT):$(LIBEBACKEND_REVISION):$(LIBEBACKEND_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEBACKEND_CURRENT):$(LIBEBACKEND_REVISION):$(LIBEBACKEND_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libebackendincludedir = $(privincludedir)/libebackend
diff --git a/libedataserver/Makefile.am b/libedataserver/Makefile.am
index d931303..5b23112 100644
--- a/libedataserver/Makefile.am
+++ b/libedataserver/Makefile.am
@@ -15,7 +15,9 @@ libedataserver_1_2_la_CPPFLAGS = \
-DE_DATA_SERVER_UI_UIDIR=\""$(uidir)"\" \
-DDEFAULT_EDS_DBUS_TIMEOUT=$(DEFAULT_EDS_DBUS_TIMEOUT) \
$(E_DATA_SERVER_CFLAGS) \
- $(SOUP_CFLAGS)
+ $(SOUP_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libedataserver_1_2_la_SOURCES = \
$(MARSHAL_GENERATED) \
@@ -55,7 +57,9 @@ libedataserver_1_2_la_LIBADD = \
$(LIBDWFL_LIBS)
libedataserver_1_2_la_LDFLAGS = \
- -version-info $(LIBEDATASERVER_CURRENT):$(LIBEDATASERVER_REVISION):$(LIBEDATASERVER_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEDATASERVER_CURRENT):$(LIBEDATASERVER_REVISION):$(LIBEDATASERVER_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libedataserverincludedir = $(privincludedir)/libedataserver
diff --git a/libedataserverui/Makefile.am b/libedataserverui/Makefile.am
index 478b790..b608ff0 100644
--- a/libedataserverui/Makefile.am
+++ b/libedataserverui/Makefile.am
@@ -71,7 +71,10 @@ libedataserverui_3_0_la_SOURCES = \
e-tree-model-generator.c \
e-cell-renderer-color.c
-libedataserverui_3_0_la_CPPFLAGS = $(CPPFLAGS)
+libedataserverui_3_0_la_CPPFLAGS = \
+ $(CPPFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
+ $(NULL)
libedataserverui_3_0_la_LIBADD = \
$(top_builddir)/addressbook/libebook/libebook-1.2.la \
@@ -84,7 +87,9 @@ libedataserverui_3_0_la_LIBADD = \
$(SOUP_LIBS)
libedataserverui_3_0_la_LDFLAGS = \
- -version-info $(LIBEDATASERVERUI_CURRENT):$(LIBEDATASERVERUI_REVISION):$(LIBEDATASERVERUI_AGE) $(NO_UNDEFINED)
+ -version-info $(LIBEDATASERVERUI_CURRENT):$(LIBEDATASERVERUI_REVISION):$(LIBEDATASERVERUI_AGE) $(NO_UNDEFINED) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
libedataserveruiincludedir = $(privincludedir)/libedataserverui
diff --git a/services/evolution-addressbook-factory/Makefile.am b/services/evolution-addressbook-factory/Makefile.am
index 99d2d61..0bc4a6f 100644
--- a/services/evolution-addressbook-factory/Makefile.am
+++ b/services/evolution-addressbook-factory/Makefile.am
@@ -22,6 +22,7 @@ evolution_addressbook_factory_CPPFLAGS = \
$(FACTORY_GTK_CFLAGS) \
$(DBUS_GLIB_CFLAGS) \
$(GOA_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
$(NULL)
evolution_addressbook_factory_SOURCES = \
@@ -39,4 +40,9 @@ evolution_addressbook_factory_LDADD = \
$(GOA_LIBS) \
$(NULL)
+evolution_addressbook_factory_LDFLAGS = \
+ $(AM_LDFLAGS) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
+
-include $(top_srcdir)/git.mk
diff --git a/services/evolution-calendar-factory/Makefile.am b/services/evolution-calendar-factory/Makefile.am
index cff7f70..991191c 100644
--- a/services/evolution-calendar-factory/Makefile.am
+++ b/services/evolution-calendar-factory/Makefile.am
@@ -21,6 +21,7 @@ evolution_calendar_factory_CPPFLAGS = \
$(EVOLUTION_CALENDAR_CFLAGS) \
$(FACTORY_GTK_CFLAGS) \
$(DBUS_GLIB_CFLAGS) \
+ $(CODE_COVERAGE_CFLAGS) \
$(NULL)
evolution_calendar_factory_SOURCES = \
@@ -37,4 +38,9 @@ evolution_calendar_factory_LDADD = \
$(DBUS_GLIB_LIBS) \
$(NULL)
+evolution_calendar_factory_LDFLAGS = \
+ $(AM_LDFLAGS) \
+ $(CODE_COVERAGE_LDFLAGS) \
+ $(NULL)
+
-include $(top_srcdir)/git.mk
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]