summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2015-10-04 19:28:50 +0000
committerDavid Robillard <d@drobilla.net>2015-10-04 19:28:50 +0000
commitdd1b7d0391ade4f07d66b67d108d0813fbc0f286 (patch)
treef8279fe47074594142e6614e07fda62c561d7a4d
parent07a9fc24e3ec2ad7788a9b27563c1b8acc3854a0 (diff)
downloadsratom-dd1b7d0391ade4f07d66b67d108d0813fbc0f286.tar.gz
sratom-dd1b7d0391ade4f07d66b67d108d0813fbc0f286.tar.bz2
sratom-dd1b7d0391ade4f07d66b67d108d0813fbc0f286.zip
Add option to avoid gcov
git-svn-id: http://svn.drobilla.net/lad/trunk/sratom@5743 a436a847-0d15-0410-975c-d299462d15a1
-rw-r--r--wscript9
1 files changed, 4 insertions, 5 deletions
diff --git a/wscript b/wscript
index de28592..8fd2a5c 100644
--- a/wscript
+++ b/wscript
@@ -22,6 +22,8 @@ def options(opt):
autowaf.set_options(opt)
opt.add_option('--test', action='store_true', dest='build_tests',
help="Build unit tests")
+ opt.add_option('--no-coverage', action='store_true', dest='no_coverage',
+ help='Do not use gcov for code coverage')
opt.add_option('--static', action='store_true', dest='static',
help="Build static library")
opt.add_option('--no-shared', action='store_true', dest='no_shared',
@@ -40,11 +42,8 @@ def configure(conf):
if not conf.env.BUILD_SHARED and not conf.env.BUILD_STATIC:
conf.fatal('Neither a shared nor a static build requested')
- # Check for gcov library (for test coverage)
- if conf.env.BUILD_TESTS:
- conf.check_cc(lib='gcov',
- define_name='HAVE_GCOV',
- mandatory=False)
+ if conf.env.BUILD_TESTS and not Options.options.no_coverage:
+ conf.check_cc(lib='gcov', define_name='HAVE_GCOV', mandatory=False)
autowaf.check_pkg(conf, 'lv2', uselib_store='LV2',
atleast_version='1.8.1', mandatory=True)