问题描述
我是Jython/Python世界的新手.我正在尝试在Jython中安装多处理程序包.但是我从easy_install
I'm new to Jython/Python world. I'm trying to install the multiprocessing package in Jython. However I'm getting following return message from the easy_install
Setup script exited with error: Compiling extensions is not supported on Jython
有什么办法可以在Jython中安装此软件包?
Is there any way I can install this package in Jython?
推荐答案
如果multiprocessing
需要C扩展名,即无法禁用它们并且未在Java/中为Jython重新实现模块,则不能使用它纯Python.自Python 2.6起,stdlib中包含了multiprocessing
模块.当前的Jython支持Python 2.5.
You can't use it if multiprocessing
requires C extensions i.e., if you can't disable them and the module was not reimplemented for Jython in Java/pure Python. multiprocessing
module is included in the stdlib since Python 2.6. Current Jython supports Python 2.5.
Jython中没有GIL,因此在很多情况下,您可以在CPython中使用multiprocessing
的情况下使用threading
.
There is no GIL in Jython so you can use threading
in many cases where you would use multiprocessing
in CPython.
这篇关于在Jython中使用多处理2.6.2.1程序包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!