diff --git a/python/setup.py b/python/setup.py index 52407ee..788d7a6 100644 --- a/python/setup.py +++ b/python/setup.py @@ -27,7 +27,7 @@ project_path = os.path.split(__file__)[0] sys.path.append(os.path.join(project_path, 'fake_pyrex')) from setuptools import setup, find_packages, Extension -from Cython.Distutils import build_ext +from Cython.Build import cythonize import numpy as np libsharp = os.environ.get('LIBSHARP', None) @@ -64,8 +64,7 @@ if __name__ == "__main__": 'Intended Audience :: Science/Research', 'License :: OSI Approved :: GNU General Public License (GPL)', 'Topic :: Scientific/Engineering'], - cmdclass = {"build_ext": build_ext}, - ext_modules = [ + ext_modules = cythonize([ Extension("libsharp.libsharp", ["libsharp/libsharp.pyx"], libraries=["sharp", "fftpack", "c_utils"], @@ -80,5 +79,5 @@ if __name__ == "__main__": library_dirs=[libsharp_lib], extra_link_args=["-fopenmp"], ), - ], + ]), )