diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2009-03-25 18:55:59 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2009-03-25 18:55:59 +0000 |
commit | 0f8ba9b85c9b9d1e7878aea90add271b6b3b93bf (patch) | |
tree | 8271745d8fc31bf62c5fd9dda0030c817641c79d /makefiles/Makefile.tools | |
parent | d8cc5b45452644f0212a2a2689f8398b266c2847 (diff) | |
download | buildsystem-0f8ba9b85c9b9d1e7878aea90add271b6b3b93bf.tar.gz buildsystem-0f8ba9b85c9b9d1e7878aea90add271b6b3b93bf.tar.bz2 |
Coverage and profile targets no longer recursively invoke make.
svn path=/trunk/tools/buildsystem/; revision=6879
Diffstat (limited to 'makefiles/Makefile.tools')
-rw-r--r-- | makefiles/Makefile.tools | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/makefiles/Makefile.tools b/makefiles/Makefile.tools index af91036..a1e91fa 100644 --- a/makefiles/Makefile.tools +++ b/makefiles/Makefile.tools @@ -138,6 +138,24 @@ endif CFLAGS := $(CFLAGS) $(OPTCFLAGS) LDFLAGS := $(LDFLAGS) $(OPTLDFLAGS) +# Extensions for coverage target +ifeq ($(MAKECMDGOALS),coverage) + COVCFLAGS ?= -fprofile-arcs -ftest-coverage + COVLDFLAGS ?= -lgcov + + CFLAGS := $(CFLAGS) $(COVCFLAGS) + LDFLAGS := $(LDFLAGS) $(COVLDFLAGS) +endif + +# Extensions for profile target +ifeq ($(MAKECMDGOALS),profile) + PROFCFLAGS ?= -pg + PROFLDFLAGS ?= -pg + + CFLAGS := $(CFLAGS) $(PROFCFLAGS) + LDFLAGS := $(LDFLAGS) $(PROFLDFLAGS) +endif + ############################################################################### # lib-shared defaults ############################################################################### |