1

我正在尝试将cwiid从 python 2.7 移植到 3.2。它使用了很多不推荐使用的东西,所以我必须更改很多东西才能让它与 3.2 一起使用。现在我因为加载错误而被卡住了。使用 python 3.2 环境和安装到包 repo 的库,我这样做:

prompt: echo "import cwiid" | python -
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: dynamic module does not define init function (PyInit_cwiid)

除了在源代码中盲目搜索之外,python 还期望 PyInit_cwiid方法在哪里?

例如,在源代码中,py_plugin.c其中包含一个py_init方法。

4

0 回答 0