Alcides Fonseca

40.197958, -8.408312

PIL on SnowLeopard

Package Install

Nuno Lourenço created a PIL package for Python 2.6 on OS X.

Compilation

How to install PIL (Python Image Library) in Snow Leopard with freetype2 and libjpg support.

Libjpg

brew install jpeg Or download source and compile.

Freetype2

wget http://mirrors.fe.up.pt/pub/nongnu/freetype/freetype-2.1.10.tar.gz

tar -zxvf freetype-2.1.10.tar.gz && cd freetype-2.1.10

./configure && make && sudo make install

PIL

wget http://effbot.org/downloads/Imaging-1.1.6.tar.gz

tar -zxvf Imaging-1.1.6.tar.gz && cd Imaging-1.1.6/

Open setup.py and change JPEG_ROOT and FREETYPE_ROOT to:

FREETYPE_ROOT = libinclude("/usr/local")

JPEG_ROOT = libinclude("/Users/alcides/Code/Support/homebrew/Cellar/jpeg/7")

Finally, sudo python setup.py install