-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.py
26 lines (23 loc) · 834 Bytes
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# Builds the Cython modules, good examples at https://github.com/cython/cython/tree/master/Demos
from distutils.core import setup
from distutils.extension import Extension
try:
from Cython.Build import cythonize
USE_CYTHON=True
except ImportError:
USE_CYTHON=False
extensions = [ Extension('cy_laplace',['cy_laplace.pyx'],
extra_compile_args=['-fopenmp'],
extra_link_args=['-fopenmp']
),
Extension('cy_wrap_claplace',['cy_wrap_claplace.pyx', 'claplace.c'],
extra_compile_args=['-fopenmp'],
extra_link_args=['-fopenmp']
)
]
if USE_CYTHON:
extensions = cythonize(extensions)
setup(
name = 'Demos',
ext_modules = extensions,
)