Chinaunix首页 | 论坛 | 博客
  • 博客访问: 190029
  • 博文数量: 31
  • 博客积分: 2510
  • 博客等级: 少校
  • 技术积分: 981
  • 用 户 组: 普通用户
  • 注册时间: 2006-07-20 09:18
文章分类
文章存档

2011年(3)

2010年(8)

2009年(1)

2008年(19)

我的朋友

分类: Python/Ruby

2010-01-04 17:22:03

My python 2.6 can’t import zlib but no problem on another almost identical machine. Then I thought I could resolve it by cp some file from that machine into my PYTHONPATH. However, when I manually checked all directories contained in sys.path, nothing called ‘zlib.pyc’ is found. Then where dose python find packages exactly? FML

I remember when I was installing python, I got some errors (see http://blog.chinaunix.net/u/21990/showart.php?id=2139228) that contains zlib. Googled it and find this post which works for me brilliantly. Just run ‘apt-get build-dep python2.5’ before make! Depends on the network, this will take a very long time.

Now import zlib runs successfully.
阅读(537) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~