pythongoogle-app-enginemacospython-imaging-libraryosx-leopard

How to install PIL on Mac OSX 10.5.8 for Google App Engine?


I need to get PIL installed locally to test GAE's images api in my local environment.

I grabbed the PIL 1.1.6 installer for Mac, and when I go to select the destination (when installing), I get the error:

You cannot install PIL 1.1.6 on this volume. 
PIL requires System Python 2.5 to install.

I have Python 2.5.x on this machine.

NOTE:

Added a bounty. I am in real need of a way to test the image API locally on my Mac.


Solution

  • That's quite easy:

    1. Install MacPorts
    2. Install Python 2.5 with sudo port install python25
    3. Install Pil for Python 2.5 with sudo port install py25-pil
    4. In the Google App Engine launcher Preferences set /opt/local/bin/python2.5 as Python Path *
    5. Restart the Google App Engine launcher
    6. Happy coding

    * be sure to confirm it with an ENTER or it will not persist