change to rst for PyPI

This commit is contained in:
Heng Li
2017-09-16 22:29:52 -04:00
parent 7e98b18ba2
commit ddc2c6f279
3 changed files with 78 additions and 45 deletions
+20 -8
View File
@@ -4,9 +4,17 @@ except ImportError:
from distutils.core import setup
from distutils.extension import Extension
from Cython.Build import cythonize
import sys
cmdclass = {}
try:
from Cython.Build import build_ext
except ImportError: # without Cython
module_src = 'python/minimap2.c'
else: # with Cython
module_src = 'python/minimap2.pyx'
cmdclass['build_ext'] = build_ext
import sys
sys.path.append('python')
setup(
@@ -16,12 +24,16 @@ setup(
description = 'Minimap2 python binding',
author = 'Heng Li',
author_email = 'lh3@me.com',
license = 'MIT',
keywords = ['bioinformatics', 'sequence-alignment'],
ext_modules = cythonize([Extension('minimap2',
['python/minimap2.pyx', 'align.c', 'bseq.c', 'chain.c', 'format.c', 'hit.c', 'index.c', 'kalloc.c',
'ksw2_extd2_sse.c', 'ksw2_exts2_sse.c', 'ksw2_extz2_sse.c', 'ksw2_ll_sse.c', 'kthread.c', 'map.c',
'misc.c', 'sdust.c', 'sketch.c'],
ext_modules = [Extension('minimap2',
sources = [module_src, 'align.c', 'bseq.c', 'chain.c', 'format.c', 'hit.c', 'index.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'],
depends = ['minimap.h', 'bseq.h', 'kalloc.h', 'kdq.h', 'khash.h', 'kseq.h', 'ksort.h',
'ksw2.h', 'kthread.h', 'kvec.h', 'mmpriv.h', 'sdust.h',
'python/cminimap2.h', 'python/cminimap2.pxd'],
extra_compile_args = ['-msse4'], # WARNING: ancient x86_64 CPUs don't have SSE4
include_dirs = ['.'],
libraries = ['z', 'm', 'pthread'])])
)
libraries = ['z', 'm', 'pthread'])],
cmdclass = cmdclass)