], libraries=[], include_dirs=['C-software/src'])) # Cython is a dependency for building extensions, iff we don't have stamped # up pyx and c files. build_ext, need_cython = cyproc_exts(EXTS, info.CYTHON_MIN_VERSION, 'pyx-stamps') # Add numpy includes when building extension. build_ext = make_np_ext_builder(build_ext) # Check dependencies, maybe add to setuptools lists if need_cython: SetupDependency('Cython', info.CYTHON_MIN_VERSION, req_type='install_requires', heavy=False).check_fill(extra_setuptools_args) SetupDependency('numpy', info.NUMPY_MIN_VERSION, req_type='install_requires', heavy=True).check_fill(extra_setuptools_args) SetupDependency('scipy', info.SCIPY_MIN_VERSION, req_type='install_requires', heavy=True).check_fill(extra_setuptools_args) cmdclass = versioneer.get_cmdclass() cmdclass.update(dict(build_ext=build_ext, sdist=get_pyx_sdist())) # get long_description
# Define extensions EXTS = [] for modulename, other_sources in (('regreg.atoms.projl1_cython', []), ('regreg.atoms.mixed_lasso_cython', []), ('regreg.atoms.piecewise_linear', [])): pyx_src = pjoin(*modulename.split('.')) + '.pyx' EXTS.append( Extension(modulename, [pyx_src] + other_sources, include_dirs=[np.get_include(), "src"])) extbuilder, needs_cython = cyproc_exts(EXTS, info.CYTHON_MIN_VERSION, 'pyx-stamps') cython_dep = SetupDependency('Cython', info.CYTHON_MIN_VERSION, req_type='setup_requires', heavy=False) numpy_dep = SetupDependency('numpy', info.NUMPY_MIN_VERSION, req_type='setup_requires', heavy=True) scipy_dep = SetupDependency('scipy', info.SCIPY_MIN_VERSION, req_type='install_requires', heavy=True) process_deps((cython_dep, ) if needs_cython else () + (numpy_dep, scipy_dep), extra_setuptools_args) cmdclass = dict(build_ext=extbuilder, sdist=get_pyx_sdist())