Package only binary compiled .so files of a python library compiled with Cython

前端 未结 4 1008
说谎
说谎 2020-12-14 03:47

I have a package named mypack which inside has a module mymod.py, and the __init__.py. For some reason that is not in debate, I need

4条回答
  •  感动是毒
    2020-12-14 04:37

    I suggest you use the wheel format (as suggested by fish2000). Then, in your setup.py, set the packages argument to []. Your Cython extension will still build and the resulting .so files will be included in the resulting wheel package.

    If your __init__.py is not included in the wheel, you can override the run method of build_ext class shipped by Cython and copy the file from your source tree to the build folder (the path can be found in self.build_lib).

提交回复
热议问题