khikashika
Posts: 2
Joined: Mon Jan 20, 2014 5:15 pm

Python Imagin Library installing error

Mon Jan 20, 2014 5:28 pm

Hello help me please!!!How i can instal Python imaging library on raspbian, when i was trying to install it via pip

Code: Select all

sudo pip install pil
I have this error:

Code: Select all

copying PIL/ImageGL.py -> build/lib.linux-armv6l-2.7

copying PIL/BufrStubImagePlugin.py -> build/lib.linux-armv6l-2.7

running build_ext

building '_imaging' extension

creating build/temp.linux-armv6l-2.7

creating build/temp.linux-armv6l-2.7/libImaging

gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -IlibImaging -I/usr/include -I/usr/local/include -I/usr/include/python2.7 -c _imaging.c -o build/temp.linux-armv6l-2.7/_imaging.o

_imaging.c:75:20: fatal error: Python.h: No such file or directory

compilation terminated.

error: command 'gcc' failed with exit status 1

----------------------------------------
Cleaning up...
Command /usr/bin/python -c "import setuptools;__file__='/tmp/pip_build_root/pil/setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-5mFH3b-record/install-record.txt --single-version-externally-managed failed with error code 1 in /tmp/pip_build_root/pil
Storing complete log in /root/.pip/pip.log
please help me anyone....thank you

KenT
Posts: 758
Joined: Tue Jan 24, 2012 9:30 am
Location: Hertfordshire, UK
Contact: Website

Re: Python Imagin Library installing error

Mon Jan 20, 2014 5:40 pm

sudo apt-get update
sudo apt-get install python-imaging
sudo apt-get install python-imaging-tk if you want tkinter interface
Pi Presents - A toolkit to produce multi-media interactive display applications for museums, visitor centres, and more
Download from http://pipresents.wordpress.com

khikashika
Posts: 2
Joined: Mon Jan 20, 2014 5:15 pm

Re: Python Imagin Library installing error

Mon Jan 20, 2014 5:54 pm

Thanks but it does not work too:

Code: Select all

[email protected] /etc $ sudo apt-get install python-imaging
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 python-imaging : Depends: python-pil but it is not going to be installed
 python-pkg-resources : Depends: python:any (>= 2.7)
                        Depends: python:any (< 2.8)
 python-setuptools : Depends: python:any (>= 2.7)
                     Depends: python:any (< 2.8)
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
[email protected] /etc $

Return to “Python”