diff --git a/setupext.py b/setupext.py index 006bb582af2..59110fd6d21 100644 --- a/setupext.py +++ b/setupext.py @@ -409,6 +409,12 @@ def finalize_options(self): self.include_dirs.append(numpy.get_include()) self.include_dirs.append(ewah_bool_utils.get_include()) + define_macros = [("NPY_NO_DEPRECATED_API", "NPY_1_7_API_VERSION")] + if self.define is None: + self.define = define_macros + else: + self.define.extend(define_macros) + def build_extensions(self): self.check_extensions_list(self.extensions)