diff options
author | ROUVREAU Vincent <vincent.rouvreau@inria.fr> | 2019-08-06 14:13:52 +0200 |
---|---|---|
committer | ROUVREAU Vincent <vincent.rouvreau@inria.fr> | 2019-08-06 14:13:52 +0200 |
commit | 48dfd910463c33e0e331f84e151ac7fe1f93dbe2 (patch) | |
tree | 2f9fb2b80a996cfb769e7b9de852ce650ff518e5 | |
parent | 003e9b3e127a3f34c03872b0cc314d0dcbc04bcf (diff) |
First version with only simplex tree that compiles. Cannot find how not to generate .cpp in sources
-rw-r--r-- | .gitignore | 3 | ||||
-rw-r--r-- | src/cython/gudhi/__init__.py | 1 | ||||
-rw-r--r-- | src/cython/gudhi/simplex_tree.pyx | 2 | ||||
-rw-r--r-- | src/cython/setup.py.in | 8 |
4 files changed, 9 insertions, 5 deletions
@@ -1,6 +1,9 @@ # Classical CMake build directory build/ +# Generated by Cython +src/cython/gudhi/simplex_tree.cpp + # Generated by tests data/points/COIL_database/lucky_cat.off_dist data/points/COIL_database/lucky_cat.off_sc.dot diff --git a/src/cython/gudhi/__init__.py b/src/cython/gudhi/__init__.py new file mode 100644 index 00000000..fde749eb --- /dev/null +++ b/src/cython/gudhi/__init__.py @@ -0,0 +1 @@ +# Fake empty __init__.py for cython to accept this directory as a Python package diff --git a/src/cython/gudhi/simplex_tree.pyx b/src/cython/gudhi/simplex_tree.pyx index 604328e9..51134681 100644 --- a/src/cython/gudhi/simplex_tree.pyx +++ b/src/cython/gudhi/simplex_tree.pyx @@ -1,6 +1,6 @@ from libc.stdint cimport intptr_t from numpy import array as np_array -from simplex_tree cimport * +cimport simplex_tree """ This file is part of the Gudhi Library - https://gudhi.inria.fr/ - which is released under MIT. See file LICENSE or go to https://gudhi.inria.fr/licensing/ for full license details. diff --git a/src/cython/setup.py.in b/src/cython/setup.py.in index f158f6cb..3c37664f 100644 --- a/src/cython/setup.py.in +++ b/src/cython/setup.py.in @@ -16,8 +16,8 @@ __author__ = "GUDHI Editorial Board" __copyright__ = "Copyright (C) 2016 Inria" __license__ = "MIT" -simplextree = Extension( - "gudhi.simplextree", +simplex_tree = Extension( + "gudhi.simplex_tree", sources = ['@CMAKE_CURRENT_SOURCE_DIR@/gudhi/simplex_tree.pyx',], language = 'c++', extra_compile_args=[@GUDHI_CYTHON_EXTRA_COMPILE_ARGS@], @@ -35,8 +35,8 @@ setup( author_email='gudhi-contact@lists.gforge.inria.fr', version='@GUDHI_VERSION@', url='http://gudhi.gforge.inria.fr/', - ext_modules = cythonize(simplextree), -# cmdclass = {'build_ext': build_ext}, + ext_modules = cythonize(simplex_tree), +# cmdclass={'build_ext': Cython.Build.build_ext}, install_requires = ['cython','numpy >= 1.9',], setup_requires = ['numpy >= 1.9',], ) |