Skip to content

Commit ca14591

Browse files
authored
Update setup.py
On running pip install adaptive, adaptive.triangulation will also be set up.
1 parent d39e319 commit ca14591

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

setup.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#!/usr/bin/env python3
22

33
import sys
4+
import numpy as np
45

56
from setuptools import find_packages, setup
67

@@ -43,6 +44,8 @@ def get_version_and_cmdclass(package_name):
4344
]
4445
}
4546

47+
triangulation_module = Extension("adaptive.triangulation", sources=['./adaptive/learner/triangulation.c'],
48+
include_dirs=[np.get_include()])
4649

4750
setup(
4851
name="adaptive",
@@ -63,4 +66,5 @@ def get_version_and_cmdclass(package_name):
6366
install_requires=install_requires,
6467
extras_require=extras_require,
6568
cmdclass=cmdclass,
69+
ext_modules=[triangulation_module])
6670
)

0 commit comments

Comments
 (0)