Add rule for building coverage summary using lcov.

Also modified a few tests to be more compatible with coverage information,
so that they use the same pb_encode/decode.c instead of making a copy.
This commit is contained in:
Petteri Aimonen
2014-04-05 13:26:37 +03:00
parent 7880f308ea
commit a8de6acf2d
6 changed files with 49 additions and 18 deletions

View File

@@ -91,9 +91,9 @@ if 'gcc' in env['CC']:
# GNU Compiler Collection
# Debug info, warnings as errors
env.Append(CFLAGS = '-ansi -pedantic -g -O0 -Wall -Werror --coverage -fstack-protector-all')
env.Append(CFLAGS = '-ansi -pedantic -g -O0 -Wall -Werror -fprofile-arcs -ftest-coverage -fstack-protector-all')
env.Append(CORECFLAGS = '-Wextra')
env.Append(LINKFLAGS = '--coverage')
env.Append(LINKFLAGS = '-g --coverage')
# We currently need uint64_t anyway, even though ANSI C90 otherwise..
env.Append(CFLAGS = '-Wno-long-long')