PIL on Macbook Pro + 10.6 Snow Leopard + libjpeg FINALLY!
Posted On: June 30, 2011 at 11:49 a.m.
Download the latest libjpeg from http://www.ijg.org/files/ (I used jpegsrc.v8c.tar.gz.) Then download the latest PIL“). Note that since I wanted to be able to use a global install of PIL in any virtualenv I was working with I ran these instructions without a virtualenv active.
In terminal cd to the download directory and run the following to install libjpeg.
tar -zxvf jpegsrc.v8c.tar.gz
cd jpeg-8c/
export CC="gcc -arch i386"
./configure
make
sudo make install
Now install PIL. Just to make sure it picks up our libjpeg correctly we’ll edit setup.py with the path to libjpeg.
tar -zxvf Imaging-1.1.7.tar.gz
Edit setup.py and change the line
JPEG_ROOT = None
to below
JPEG_ROOT = libinclude( "/usr/local" )
Now lets install.
python setup.py build
sudo python setup.py install
That works for me on my new Macbook Pro 64bit running Snow Leopard. Finally!


Jordan Sept. 9, 2011 at 5:55 p.m.
This works great! Thanks for posting!