参考链接:
官方文档:https://cython.readthedocs.io/en/latest/
中文文档:https://www.bookstack.cn/read/cython-doc-zh/docs-29.md
多个库编译成一个库:https://paper.seebug.org/1139/
https://stackoverflow.com/questions/30157363/collapse-multiple-submodules-to-one-cython-extension

python setup.py build_ext --inplace

from distutils.core import setup
from distutils.extension import Extension
from Cython.Build import cythonize

extensions = [
    Extension(
        "mesh_net.network", ["network.py"]
    ),
    Extension(
        "mesh_net.mesh", ["mesh.py"]
    ),
    Extension(
        "mesh_net.mesh_process", ["mesh_process.py"]
    ),
    Extension(
        "mesh_net.mesh_union", ["mesh_union.py"]
    )
]

setup(
    name="mesh_net",
    ext_modules=cythonize(extensions)
)

相关文章:

  • 2022-02-01
  • 2021-10-06
  • 2021-09-07
  • 2022-02-21
  • 2022-12-23
  • 2022-12-23
  • 2021-08-20
  • 2021-09-29
猜你喜欢
  • 2022-02-19
  • 2021-12-23
  • 2021-11-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-19
相关资源
相似解决方案