From 5291386bd20d5ba2b879c74dc1e6255bd53530e3 Mon Sep 17 00:00:00 2001 From: Jürgen Knödlseder Date: Tue, 15 Mar 2016 10:34:39 +0100 Subject: [PATCH] Correctly pass --coverage option to Python extension module. --- pyext/setup.py.in | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pyext/setup.py.in b/pyext/setup.py.in index a208baa..3315fb5 100644 --- a/pyext/setup.py.in +++ b/pyext/setup.py.in @@ -108,12 +108,17 @@ data_files=[('@prefix@/share/ctools/swig', install_files)] # Optionally enable OpenMP if '@OPENMP_TRUE@' != '#': - extra_compile_args = ['@OPENMP_CXXFLAGS@','@COVERAGE_CXXFLAGS@'] + extra_compile_args = ['@OPENMP_CXXFLAGS@'] extra_link_args = ['@OPENMP_CXXFLAGS@'] else: - extra_compile_args = ['@COVERAGE_CXXFLAGS@'] + extra_compile_args = [] extra_link_args = [] +# Append coverage CXXFLAGS +if len('@COVERAGE_CXXFLAGS@') > 0: + extra_compile_args.append('@COVERAGE_CXXFLAGS@') + extra_link_args.append('@COVERAGE_CXXFLAGS@') + # Optionally add link flag for El Capitan post-processing of modules if '@IS_ELCAPITAN_TRUE@' != '#': extra_link_args.append('-headerpad_max_install_names') -- libgit2 0.21.4