[Image-SIG] PIL on a Mac
janssen at parc.com
Tue Apr 24 17:36:37 CEST 2007
> If it isn't too difficult, would you be able to tell me how I
> could put the PIL in my computer so I can just play around with Python and
> images. I am currently in a introductory course to computer science and we
> are using Python. I am running it on a MacBook Pro right now.
You could do it the way that I do it.
> I guess I
> had to download a MacPython in order to make Python work on my system.
First of all, Python comes pre-installed on your Mac. No need to
download more MacPython. All you have to do is install PIL.
> not too sure, but it does seem to work. The problem that I'm having now
> seems to be stemming from his "Imaging-1.1.6" folder that I just
> downloaded. What should I do with it? I was looking at the ReadMe (that's
> where I got this e-mail) and it says that I'll need to download more
> things (correct?).
Doubt it. Here's what I do:
1. Open a Terminal window.
2. Set my working directory to "/tmp".
3. Download the PIL sources with "curl".
4. Set my working directory to the top of the unpacked PIL sources.
5. Use "python setup.py build" to build it.
6. Use "python setup.py install" to install it.
7. Start using it.
Here's a transcript:
% cd /tmp
% curl http://effbot.org/downloads/Imaging-1.1.6.tar.gz | tar xvfz -
% cd Imaging-1.1.6
% python setup.py build
% sudo python setup.py install
This way I can avoid getting tangled up with Fink or DarwinPorts or
one of the other systems that purport to make it "easier" to install
software on a Mac. Those systems were useful a few years ago, but the
state of open source software, and the state of OS X, has advanced to
the point where they've outlived their purpose (IMO).
More information about the Image-SIG