While upgrading python imaging library (PIL), it tells me “JPEG support not available”

前端 未结 3 1662
被撕碎了的回忆
被撕碎了的回忆 2021-01-16 02:06

Using ubuntu 13.10, python 2.7.5:

>>> import _imaging, Image
>>> from PIL import Image, ImageDraw, ImageFilter, ImageFont
>>> im =         


        
3条回答
  •  猫巷女王i
    2021-01-16 03:04


    Additional notes for Mac OS X

    On Mac OS X you will usually install additional software such as libjpeg or freetype with the "fink" tool, and then it ends up in "/sw". If you have installed the libraries elsewhere, you may have to tweak the "setup.py" file before building.


    Additional notes for Windows

    On Windows, you need to tweak the ROOT settings in the "setup.py" file, to make it find the external libraries. See comments in the file for details.

    Make sure to build PIL and the external libraries with the same runtime linking options as was used for the Python interpreter (usually /MD, under Visual Studio).

    Note that most Python distributions for Windows include libraries compiled for Microsoft Visual Studio. You can get the free Express edition of Visual Studio from:

    http://www.microsoft.com/Express/
    

    To build extensions using other tool chains, see the "Using non-Microsoft compilers on Windows" section in the distutils handbook:

    http://www.python.org/doc/current/inst/non-ms-compilers.html
    

    For additional information on how to build extensions using the popular MinGW compiler, see:

    http://mingw.org (compiler)
    http://sebsauvage.net/python/mingw.html (build instructions)
    http://sourceforge.net/projects/gnuwin32 (prebuilt libraries)
    

提交回复
热议问题