无法获得PIL支持任何图像 [英] Can't get PIL to support any images

查看:101
本文介绍了无法获得PIL支持任何图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Ubuntu 11.10下使用pip install PIL安装PIL之后,摘要告诉我所有项目不可用".

After installing PIL with pip install PIL under Ubuntu 11.10, the summary tells me "not available" on all items.

我已经阅读了多个答案",例如 http://obroll.com/在ubuntu-11-10-oneiric上安装python-pil-python-image-library/

I've read through several "answers" like http://obroll.com/install-python-pil-python-image-library-on-ubuntu-11-10-oneiric/

从本质上讲,我知道这件事:在libjpeg之后安装PIL.

which essentially tells me the same thing: Install PIL after libjpeg.

我仍然无法正常工作. (我是ubuntu的新手)

I still can't get it to work. (I'm a novice with ubuntu)

有什么想法吗?

从摘要中复制/粘贴:

--------------------------------------------------------------------
PIL 1.1.7 SETUP SUMMARY
--------------------------------------------------------------------
version       1.1.7
platform      linux2 2.7.2+ (default, Oct  4 2011, 20:03:08)

              [GCC 4.6.1]
--------------------------------------------------------------------
*** TKINTER support not available
*** JPEG support not available
*** ZLIB (PNG/ZIP) support not available
*** FREETYPE2 support not available
*** LITTLECMS support not available
--------------------------------------------------------------------

推荐答案

Finaly正常运行了. 我的经验是,即使我以正确的顺序安装,PIL仍然找不到libjpeg.

Finaly got it working. My experience was that even though I installed in the correct order, PIL still could not find libjpeg.

我做了什么:

  1. 确保已安装libjpeg8和libjpeg8-dev,并使用"locate libjpeg"找出安装位置.
  2. pip install --no-install PIL"->下载安装文件
  3. 在虚拟环境的构建目录中编辑setup.py并设置JPEG_ROOT.就我而言:JPEG_ROOT ="/usr/lib/i386-linux-gnu/"
  4. "pip install PIL"->现在将使用修改后的setup.py安装PIL并找到libjpeg.

这篇关于无法获得PIL支持任何图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆