Subject: Re: [PATCH 1/8] Support coverage testing with GCC/gcov

From: Thomas Rast <[email-masked]>
Date: Mon, 16 Feb 2009 12:09:28 +0100

Matthieu Moy wrote:
> detail:
> 
> Thomas Rast <[email-masked]> writes:
> 
> > With gcc's --coverage option, we can perform automatic coverage data
> 
> I don't think gcc has a --coverage ...

Mine does:

  --coverage
    This option is used to compile and link code instrumented for
    coverage analysis.  The option is a synonym for -fprofile-arcs
    -ftest-coverage (when compiling) and -lgcov (when linking).  See
    the documentation for those options for more details.

> > +COVERAGE_CFLAGS = $(CFLAGS) -O0 -ftest-coverage -fprofile-arcs
> > +COVERAGE_LDFLAGS = $(CFLAGS)  -O0 -lgcov
> 
> ... and this is not the one you are using anyway.

Indeed, I guess the log message is somewhat misleading.

-- 
Thomas Rast
trast@{inf,student}.ethz.ch