Convert python install from build_ext to setuptools setup_requires.
This commit is contained in:
parent
0b41dd26a2
commit
7db2e8d21a
14
setup.py
14
setup.py
|
|
@ -4,16 +4,6 @@ except ImportError:
|
||||||
from distutils.core import setup
|
from distutils.core import setup
|
||||||
from distutils.extension import Extension
|
from distutils.extension import Extension
|
||||||
|
|
||||||
cmdclass = {}
|
|
||||||
|
|
||||||
try:
|
|
||||||
from Cython.Build import build_ext
|
|
||||||
except ImportError: # without Cython
|
|
||||||
module_src = 'python/mappy.c'
|
|
||||||
else: # with Cython
|
|
||||||
module_src = 'python/mappy.pyx'
|
|
||||||
cmdclass['build_ext'] = build_ext
|
|
||||||
|
|
||||||
import sys, platform
|
import sys, platform
|
||||||
|
|
||||||
sys.path.append('python')
|
sys.path.append('python')
|
||||||
|
|
@ -43,7 +33,7 @@ setup(
|
||||||
keywords = 'sequence-alignment',
|
keywords = 'sequence-alignment',
|
||||||
scripts = ['python/minimap2.py'],
|
scripts = ['python/minimap2.py'],
|
||||||
ext_modules = [Extension('mappy',
|
ext_modules = [Extension('mappy',
|
||||||
sources = [module_src, 'align.c', 'bseq.c', 'chain.c', 'format.c', 'hit.c', 'index.c', 'pe.c', 'options.c',
|
sources = ['python/mappy.pyx', 'align.c', 'bseq.c', 'chain.c', 'format.c', 'hit.c', 'index.c', 'pe.c', 'options.c',
|
||||||
'ksw2_extd2_sse.c', 'ksw2_exts2_sse.c', 'ksw2_extz2_sse.c', 'ksw2_ll_sse.c',
|
'ksw2_extd2_sse.c', 'ksw2_exts2_sse.c', 'ksw2_extz2_sse.c', 'ksw2_ll_sse.c',
|
||||||
'kalloc.c', 'kthread.c', 'map.c', 'misc.c', 'sdust.c', 'sketch.c', 'esterr.c', 'splitidx.c'],
|
'kalloc.c', 'kthread.c', 'map.c', 'misc.c', 'sdust.c', 'sketch.c', 'esterr.c', 'splitidx.c'],
|
||||||
depends = ['minimap.h', 'bseq.h', 'kalloc.h', 'kdq.h', 'khash.h', 'kseq.h', 'ksort.h',
|
depends = ['minimap.h', 'bseq.h', 'kalloc.h', 'kdq.h', 'khash.h', 'kseq.h', 'ksort.h',
|
||||||
|
|
@ -62,4 +52,4 @@ setup(
|
||||||
'Programming Language :: Python :: 3',
|
'Programming Language :: Python :: 3',
|
||||||
'Intended Audience :: Science/Research',
|
'Intended Audience :: Science/Research',
|
||||||
'Topic :: Scientific/Engineering :: Bio-Informatics'],
|
'Topic :: Scientific/Engineering :: Bio-Informatics'],
|
||||||
cmdclass = cmdclass)
|
setup_requires=["cython"])
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue