Help with installing PIL or Pillow or Image Module to python on an ApachePHP server



Hi, I have a php file that executes a python script. I would like the python script to create a new image on the server to be viewed from a different html page.

I cannot get Image or PIL or Pillow to install from the unix command line. I have tried lots of combinations of pip and sudo apt-get install python-PIL all with various combinations of module libraries.

From the command line I run: pip list and can see the available python modules.

Trying various combinations of the installers(pip, easy_install, sudo apt-get install) with the modules(PIL, and Pillow) give pages and pages of info and warnings and eventually fail.

Thanks for any and all help.


I learned that the image(1.5.5) library I was seeing with “pip list” is different from PIL.
I kept trying to install PIL, now known as Pillow.

These are the commands that I think finally got it to work:

sudo apt-get update
sudo apt-get build-dep python-imaging
sudo pip install Pillow