不能不安装Distribute、zlib
起初,我只想使用python3.2安装feedparser,而它需要Distribute。当我安装 Distribute 时,
python3.2 setup.py install
我得到了
File "/usr/local/lib/python3.2/zipfile.py", line 687, in __init__
"Compression requires the (missing) zlib module")
RuntimeError: Compression requires the (missing) zlib module
然后我下载了 zlib 并安装了它
./configure --prefix=/usr/local/python3.2
make
sudo make install
安装后,并尝试安装 Distribute ,我遇到了同样的错误。
At first, I only want to use install feedparser with python3.2, while it need Distribute. When I install Distribute with
python3.2 setup.py install
I got
File "/usr/local/lib/python3.2/zipfile.py", line 687, in __init__
"Compression requires the (missing) zlib module")
RuntimeError: Compression requires the (missing) zlib module
Then I downloaded zlib and installed it with
./configure --prefix=/usr/local/python3.2
make
sudo make install
After the installation, and tried to install Distribute, I got the same error.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
最后,我通过用zlib重新安装python3.2解决了这个问题。
1 当然,你需要先安装zlib。你可以在 /usr/include
2
中找到 zlib.h http://www.1stbyte.com/2005/06/26/configure-and-compile-python-with-zlib/
Finally, I solved it by re-install python3.2 with zlib.
1 Of course, you need to install zlib first. and you can find zlib.h in /usr/include
2
from http://www.1stbyte.com/2005/06/26/configure-and-compile-python-with-zlib/