Best way to package a Python library that includes a C shared library?

后端 未结 3 1499
名媛妹妹
名媛妹妹 2021-02-04 05:00

I have written a library whose main functionality is implemented in C (speed is critical), with a thin Python layer around it to deal with the ctypes nastiness.

3条回答
  •  失恋的感觉
    2021-02-04 05:44

    I'd consider building the python module as a subproject of a normal shared library build. So, use automake, autoconf or something like that to build the shared library, have a python_bindings directory with a setup.py and your python module.

提交回复
热议问题