summaryrefslogtreecommitdiffstats
path: root/extras/autowaf.py
diff options
context:
space:
mode:
Diffstat (limited to 'extras/autowaf.py')
-rw-r--r--extras/autowaf.py16
1 files changed, 10 insertions, 6 deletions
diff --git a/extras/autowaf.py b/extras/autowaf.py
index 16c2ddf..93aea69 100644
--- a/extras/autowaf.py
+++ b/extras/autowaf.py
@@ -612,12 +612,16 @@ def configure(conf):
if conf.find_program(cov, var='LLVM_COV', mandatory=False):
break
else:
- check_func = (conf.check_cc if 'CC' in conf.env
- else conf.check_cxx)
- if check_func(cflags=check_flags(conf),
- lib='gcov',
- mandatory=False):
- conf.env.HAVE_GCOV = True
+ if 'CC' in conf.env:
+ if check_cc(cflags=check_flags(conf, conf.env.CFLAGS),
+ lib='gcov',
+ mandatory=False):
+ conf.env.HAVE_GCOV = True
+ else:
+ if check_cxx(cflags=check_flags(conf, conf.env.CXXFLAGS),
+ lib='gcov',
+ mandatory=False):
+ conf.env.HAVE_GCOV = True
except Exception:
pass # Test options do not exist