I built and installed PIL on my CentOS 6.2 with Python 2.7 by executing build, build_ext -i and install. I had to change the library paths so that all supports are given. When I run the selftest.py it says that everything is ok and all supports are given (especially JPEG).
When running my program which opens a jpeg, adds something, and saves it I get the error:
File "/opt/python2.7.2/lib/python2.7/site-packages/PIL/Image.py", line 401, in _getencoder
raise IOError("encoder %s not available" % encoder_name)
IOError: encoder jpeg not available
My program works fine on other systems and it runs on the centOS machine fine when I change it to png. I ran all commands with python2.7, and I already tried to reinstall PIL.
So in short: before installing PIL it runs within the selftest successfully, but after installing it it does not work any more.