summaryrefslogtreecommitdiff
path: root/numpy/random/_examples/cython/setup.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/random/_examples/cython/setup.py')
-rw-r--r--numpy/random/_examples/cython/setup.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/numpy/random/_examples/cython/setup.py b/numpy/random/_examples/cython/setup.py
index 20cedc4e3..42425c2c1 100644
--- a/numpy/random/_examples/cython/setup.py
+++ b/numpy/random/_examples/cython/setup.py
@@ -12,7 +12,11 @@ from setuptools.extension import Extension
from os.path import join, dirname
path = dirname(__file__)
+src_dir = join(dirname(path), '..', 'src')
defs = [('NPY_NO_DEPRECATED_API', 0)]
+inc_path = np.get_include()
+# not so nice. We need the random/lib library from numpy
+lib_path = join(np.get_include(), '..', '..', 'random', 'lib')
extending = Extension("extending",
sources=[join(path, 'extending.pyx')],
@@ -24,7 +28,9 @@ extending = Extension("extending",
)
distributions = Extension("extending_distributions",
sources=[join(path, 'extending_distributions.pyx')],
- include_dirs=[np.get_include()],
+ include_dirs=[inc_path],
+ library_dirs=[lib_path],
+ libraries=['npyrandom'],
define_macros=defs,
)