0

我在我的 Python/Django 站点上上传图像时出错,因此安装了 PIL 库(在带有 CentOS 的 python 2.4 上为 1.1.6),并且还使用 $ sudo yum install freetype freetype-devel jpeg jpeg-devel libpng libpng 安装了 jpeg 库-devel 和使用 wget 的 pil 库http://effbot.org/downloads/Imaging-1.1.6.tar.gz

解压后运行:python setup.py build_ext -i 和 sudo python setup.py install

我收到一长串错误,但它们以(以前的都是关于错误:预期属性等...):

_imaging.c:3041: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before        âfunctionsâ
_imaging.c:3138: warning: return type defaults to âintâ
_imaging.c: In function âDL_EXPORTâ:
_imaging.c:3138: error: expected declaration specifiers before âinit_imagingâ
_imaging.c:3149: error: expected â{â at end of input
error: command 'gcc' failed with exit status 1

请让我知道是否需要更多错误消息才能正确排除故障。

4

0 回答 0