tags:

views:

32

answers:

3

Where do I download the python PIL module from? I found some sites but not sure if they can be trusted.

This is for my macbookpro.

Is effbot the sourcE?

+1  A: 

Google App Engine uses PIL, and suggests these sites:

http://code.google.com/appengine/docs/python/images/installingPIL.html

Steve
that is for python 2.5, I have 2.6
Blankman
Be aware though that the PIL installer for OS X from pythonmac.org referenced on that page is rather old.
Ned Deily
A: 

Yes, Effbot is a reputable source. The official source appears to be PythonWare. On a mac, you might want to just use pip, homebrew or macports to install it.

easel
Note that the download links on that page are actually links to effbot.org.
Ned Deily
+2  A: 

effbot.org is the website of PIL's author and maintainer, Fredrik Lundh, so http://effbot.org/downloads/ can be considered an authoritative source. There have been a number of forks of earlier versions, and unfortunately, the Python Package Index (normally reliable) entry for PIL is a bit out of date.

Installing PIL on OS X can be problematic because it requires 3rd-party C libraries, like libjpeg, that are not shipped with OS X. While you can fairly easily install those libraries with the popular open-source package distributors, like MacPorts, Homebrew, or Fink, it is often difficult to get all the options correct to match the Python in use. For that reason, I recommend using a complete solution, that is 3rd-party libs, PIL, and Python 2.6 all built and installed using the same distribution package manager. While there may be some first time gotchas, it will usually save a lot of headaches over time. For instance, using MacPorts, one command will install everything:

$ sudo port install py26-pil

But check other postings for possible gotchas and variants to use for MacPorts.

Ned Deily
I can't seem to find one that works with my Mac OS and python 2.6
Blankman
sudo port install py26-pil will definitely work so long as your macports is set up right.
easel
MacPorts will work (I use it and recommend it) but there are a few potential gotchas if you are not careful. Possibly the biggest: last time I checked the MacPorts Tk port on 10.6 defaults to an X11 one (ugh!). It has a +quartz variant but that doesn't work on 10.6 64-bit. So you either have to live without Tkinter by selecting the +no_tkinter variant when installing python26 or watch as MacPorts builds all of the X11 client stuff.
Ned Deily