Bonjour,
J'ai besoin d'utiliser le package python reportlab. J'ai lu qu'il fallait installer PIL (un peu dans l'urgence hier soir ...). J'ai donc téléchargé "Python Imaging Library 1.1.7 Source Kit (all platforms) (November 15, 2009)" a partir de
http://www.pythonware.com/products/pil/.
Cela permet de télécharger le fichier.tar.gz : Imaging-1.1.7.tar.gz.
Puis j'ai suivi la procédure décrit, c'est a dire :
[root@localhost Python_Imaging-1.1.7]# tar xvfz Imaging-1.1.7.tar.gz
Imaging-1.1.7/README
Imaging-1.1.7/CHANGES
Imaging-1.1.7/CONTENTS
Imaging-1.1.7/MANIFEST
Imaging-1.1.7/BUILDME
Imaging-1.1.7/setup.py
Imaging-1.1.7/selftest.py
Imaging-1.1.7/doctest.py
Imaging-1.1.7/libImaging/Imaging.h
Imaging-1.1.7/libImaging/ImDib.h
Imaging-1.1.7/libImaging/ImPlatform.h
Imaging-1.1.7/libImaging/Quant.h
Imaging-1.1.7/libImaging/QuantHash.h
Imaging-1.1.7/libImaging/QuantHeap.h
Imaging-1.1.7/libImaging/QuantDefines.h
Imaging-1.1.7/libImaging/QuantTypes.h
Imaging-1.1.7/libImaging/Access.c
Imaging-1.1.7/libImaging/Antialias.c
Imaging-1.1.7/libImaging/Bands.c
Imaging-1.1.7/libImaging/Blend.c
Imaging-1.1.7/libImaging/Chops.c
Imaging-1.1.7/libImaging/Convert.c
Imaging-1.1.7/libImaging/ConvertYCbCr.c
Imaging-1.1.7/libImaging/Copy.c
Imaging-1.1.7/libImaging/Crc32.c
Imaging-1.1.7/libImaging/Crop.c
Imaging-1.1.7/libImaging/Dib.c
Imaging-1.1.7/libImaging/Draw.c
Imaging-1.1.7/libImaging/Effects.c
Imaging-1.1.7/libImaging/Except.c
Imaging-1.1.7/libImaging/File.c
Imaging-1.1.7/libImaging/Fill.c
Imaging-1.1.7/libImaging/Filter.c
Imaging-1.1.7/libImaging/Geometry.c
Imaging-1.1.7/libImaging/GetBBox.c
Imaging-1.1.7/libImaging/Histo.c
Imaging-1.1.7/libImaging/Matrix.c
Imaging-1.1.7/libImaging/ModeFilter.c
Imaging-1.1.7/libImaging/Negative.c
Imaging-1.1.7/libImaging/Offset.c
Imaging-1.1.7/libImaging/Pack.c
Imaging-1.1.7/libImaging/Palette.c
Imaging-1.1.7/libImaging/Paste.c
Imaging-1.1.7/libImaging/Point.c
Imaging-1.1.7/libImaging/Quant.c
Imaging-1.1.7/libImaging/QuantHash.c
Imaging-1.1.7/libImaging/QuantHeap.c
Imaging-1.1.7/libImaging/RankFilter.c
Imaging-1.1.7/libImaging/Storage.c
Imaging-1.1.7/libImaging/Unpack.c
Imaging-1.1.7/libImaging/UnpackYCC.c
Imaging-1.1.7/libImaging/UnsharpMask.c
Imaging-1.1.7/libImaging/Bit.h
Imaging-1.1.7/libImaging/Gif.h
Imaging-1.1.7/libImaging/Jpeg.h
Imaging-1.1.7/libImaging/Lzw.h
Imaging-1.1.7/libImaging/Raw.h
Imaging-1.1.7/libImaging/Zip.h
Imaging-1.1.7/libImaging/BitDecode.c
Imaging-1.1.7/libImaging/EpsEncode.c
Imaging-1.1.7/libImaging/FliDecode.c
Imaging-1.1.7/libImaging/GifDecode.c
Imaging-1.1.7/libImaging/GifEncode.c
Imaging-1.1.7/libImaging/HexDecode.c
Imaging-1.1.7/libImaging/JpegDecode.c
Imaging-1.1.7/libImaging/JpegEncode.c
Imaging-1.1.7/libImaging/LzwDecode.c
Imaging-1.1.7/libImaging/MspDecode.c
Imaging-1.1.7/libImaging/PackDecode.c
Imaging-1.1.7/libImaging/PcdDecode.c
Imaging-1.1.7/libImaging/PcxEncode.c
Imaging-1.1.7/libImaging/PcxDecode.c
Imaging-1.1.7/libImaging/RawDecode.c
Imaging-1.1.7/libImaging/RawEncode.c
Imaging-1.1.7/libImaging/SunRleDecode.c
Imaging-1.1.7/libImaging/TgaRleDecode.c
Imaging-1.1.7/libImaging/XbmDecode.c
Imaging-1.1.7/libImaging/XbmEncode.c
Imaging-1.1.7/libImaging/ZipDecode.c
Imaging-1.1.7/libImaging/ZipEncode.c
Imaging-1.1.7/_imaging.c
Imaging-1.1.7/decode.c
Imaging-1.1.7/encode.c
Imaging-1.1.7/display.c
Imaging-1.1.7/map.c
Imaging-1.1.7/outline.c
Imaging-1.1.7/path.c
Imaging-1.1.7/_imagingtk.c
Imaging-1.1.7/_imagingft.c
Imaging-1.1.7/_imagingcms.c
Imaging-1.1.7/_imagingmath.c
Imaging-1.1.7/PIL.pth
Imaging-1.1.7/PIL/__init__.py
Imaging-1.1.7/PIL/ArgImagePlugin.py
Imaging-1.1.7/PIL/BdfFontFile.py
Imaging-1.1.7/PIL/BmpImagePlugin.py
Imaging-1.1.7/PIL/BufrStubImagePlugin.py
Imaging-1.1.7/PIL/ContainerIO.py
Imaging-1.1.7/PIL/CurImagePlugin.py
Imaging-1.1.7/PIL/DcxImagePlugin.py
Imaging-1.1.7/PIL/EpsImagePlugin.py
Imaging-1.1.7/PIL/ExifTags.py
Imaging-1.1.7/PIL/FitsStubImagePlugin.py
Imaging-1.1.7/PIL/FliImagePlugin.py
Imaging-1.1.7/PIL/FontFile.py
Imaging-1.1.7/PIL/FpxImagePlugin.py
Imaging-1.1.7/PIL/GbrImagePlugin.py
Imaging-1.1.7/PIL/GdImageFile.py
Imaging-1.1.7/PIL/GifImagePlugin.py
Imaging-1.1.7/PIL/GimpGradientFile.py
Imaging-1.1.7/PIL/GimpPaletteFile.py
Imaging-1.1.7/PIL/GribStubImagePlugin.py
Imaging-1.1.7/PIL/Hdf5StubImagePlugin.py
Imaging-1.1.7/PIL/IcoImagePlugin.py
Imaging-1.1.7/PIL/IcnsImagePlugin.py
Imaging-1.1.7/PIL/Image.py
Imaging-1.1.7/PIL/ImageChops.py
Imaging-1.1.7/PIL/ImageCms.py
Imaging-1.1.7/PIL/ImageColor.py
Imaging-1.1.7/PIL/ImageDraw.py
Imaging-1.1.7/PIL/ImageDraw2.py
Imaging-1.1.7/PIL/ImageEnhance.py
Imaging-1.1.7/PIL/ImageFile.py
Imaging-1.1.7/PIL/ImageFileIO.py
Imaging-1.1.7/PIL/ImageFilter.py
Imaging-1.1.7/PIL/ImageFont.py
Imaging-1.1.7/PIL/ImageGL.py
Imaging-1.1.7/PIL/ImageGrab.py
Imaging-1.1.7/PIL/ImageMath.py
Imaging-1.1.7/PIL/ImageMode.py
Imaging-1.1.7/PIL/ImageOps.py
Imaging-1.1.7/PIL/ImagePalette.py
Imaging-1.1.7/PIL/ImagePath.py
Imaging-1.1.7/PIL/ImageQt.py
Imaging-1.1.7/PIL/ImageSequence.py
Imaging-1.1.7/PIL/ImageShow.py
Imaging-1.1.7/PIL/ImageStat.py
Imaging-1.1.7/PIL/ImageTk.py
Imaging-1.1.7/PIL/ImageTransform.py
Imaging-1.1.7/PIL/ImageWin.py
Imaging-1.1.7/PIL/ImImagePlugin.py
Imaging-1.1.7/PIL/ImtImagePlugin.py
Imaging-1.1.7/PIL/IptcImagePlugin.py
Imaging-1.1.7/PIL/JpegImagePlugin.py
Imaging-1.1.7/PIL/McIdasImagePlugin.py
Imaging-1.1.7/PIL/MicImagePlugin.py
Imaging-1.1.7/PIL/MpegImagePlugin.py
Imaging-1.1.7/PIL/MspImagePlugin.py
Imaging-1.1.7/PIL/OleFileIO.py
Imaging-1.1.7/PIL/PaletteFile.py
Imaging-1.1.7/PIL/PalmImagePlugin.py
Imaging-1.1.7/PIL/PcdImagePlugin.py
Imaging-1.1.7/PIL/PcfFontFile.py
Imaging-1.1.7/PIL/PcxImagePlugin.py
Imaging-1.1.7/PIL/PdfImagePlugin.py
Imaging-1.1.7/PIL/PixarImagePlugin.py
Imaging-1.1.7/PIL/PngImagePlugin.py
Imaging-1.1.7/PIL/PpmImagePlugin.py
Imaging-1.1.7/PIL/PsdImagePlugin.py
Imaging-1.1.7/PIL/PSDraw.py
Imaging-1.1.7/PIL/SgiImagePlugin.py
Imaging-1.1.7/PIL/SpiderImagePlugin.py
Imaging-1.1.7/PIL/SunImagePlugin.py
Imaging-1.1.7/PIL/TarIO.py
Imaging-1.1.7/PIL/TgaImagePlugin.py
Imaging-1.1.7/PIL/TiffImagePlugin.py
Imaging-1.1.7/PIL/TiffTags.py
Imaging-1.1.7/PIL/WalImageFile.py
Imaging-1.1.7/PIL/WmfImagePlugin.py
Imaging-1.1.7/PIL/XbmImagePlugin.py
Imaging-1.1.7/PIL/XpmImagePlugin.py
Imaging-1.1.7/PIL/XVThumbImagePlugin.py
Imaging-1.1.7/Docs/index.html
Imaging-1.1.7/Docs/effbot.css
Imaging-1.1.7/Docs/pythondoc-PIL.ArgImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.BdfFontFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.BmpImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.BufrStubImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.ContainerIO.html
Imaging-1.1.7/Docs/pythondoc-PIL.CurImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.DcxImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.EpsImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.ExifTags.html
Imaging-1.1.7/Docs/pythondoc-PIL.FitsStubImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.FliImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.FontFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.FpxImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.GbrImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.GdImageFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.GifImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.GimpGradientFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.GimpPaletteFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.GribStubImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.Hdf5StubImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.IcoImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.IcnsImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.Image.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageChops.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageColor.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageDraw.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageEnhance.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageFileIO.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageFilter.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageFont.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageGL.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageGrab.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageOps.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImagePalette.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImagePath.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageSequence.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageStat.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageTk.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageTransform.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImageWin.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.ImtImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.IptcImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.JpegImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.McIdasImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.MicImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.MpegImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.MspImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.OleFileIO.html
Imaging-1.1.7/Docs/pythondoc-PIL.PaletteFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.PalmImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PcdImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PcfFontFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.PcxImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PdfImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PixarImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PngImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PpmImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PsdImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.PSDraw.html
Imaging-1.1.7/Docs/pythondoc-PIL.SgiImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.SpiderImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.SunImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.TarIO.html
Imaging-1.1.7/Docs/pythondoc-PIL.TgaImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.TiffImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.TiffTags.html
Imaging-1.1.7/Docs/pythondoc-PIL.WalImageFile.html
Imaging-1.1.7/Docs/pythondoc-PIL.WmfImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.XbmImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.XpmImagePlugin.html
Imaging-1.1.7/Docs/pythondoc-PIL.XVThumbImagePlugin.html
Imaging-1.1.7/Scripts/pilconvert.py
Imaging-1.1.7/Scripts/pildriver.py
Imaging-1.1.7/Scripts/pilfile.py
Imaging-1.1.7/Scripts/pilfont.py
Imaging-1.1.7/Scripts/pilprint.py
Imaging-1.1.7/Images/lena.gif
Imaging-1.1.7/Images/lena.png
Imaging-1.1.7/Images/lena.ppm
Imaging-1.1.7/Images/lena.jpg
Imaging-1.1.7/Images/courB08.bdf
Imaging-1.1.7/Images/courB08.pbm
Imaging-1.1.7/Images/courB08.pil
Imaging-1.1.7/Sane/README
Imaging-1.1.7/Sane/CHANGES
Imaging-1.1.7/Sane/setup.py
Imaging-1.1.7/Sane/sanedoc.txt
Imaging-1.1.7/Sane/_sane.c
Imaging-1.1.7/Sane/sane.py
Imaging-1.1.7/Sane/demo_numarray.py
Imaging-1.1.7/Sane/demo_pil.py
Imaging-1.1.7/Scripts/README
Imaging-1.1.7/Scripts/enhancer.py
Imaging-1.1.7/Scripts/explode.py
Imaging-1.1.7/Scripts/gifmaker.py
Imaging-1.1.7/Scripts/painter.py
Imaging-1.1.7/Scripts/player.py
Imaging-1.1.7/Scripts/viewer.py
Imaging-1.1.7/Scripts/thresholder.py
Imaging-1.1.7/Tk/tkImaging.c
Imaging-1.1.7/Tk/install.txt
Imaging-1.1.7/Tk/booster.txt
Imaging-1.1.7/Tk/pilbitmap.txt
[root@localhost Python_Imaging-1.1.7]# cd Imaging-1.1.7
[root@localhost Imaging-1.1.7]# python setup.py install
running install
running build
running build_py
running build_ext
--------------------------------------------------------------------
PIL 1.1.7 SETUP SUMMARY
--------------------------------------------------------------------
version 1.1.7
platform linux2 2.7.5 (default, Nov 3 2014, 14:26:24)
[GCC 4.8.3 20140911 (Red Hat 4.8.3-7)]
--------------------------------------------------------------------
*** TKINTER support not available (Tcl/Tk 8.5 libraries needed)
*** JPEG support not available
--- ZLIB (PNG/ZIP) support available
--- FREETYPE2 support available
*** LITTLECMS support not available
--------------------------------------------------------------------
To add a missing option, make sure you have the required
library, and set the corresponding ROOT variable in the
setup.py script.
To check the build, run the selftest.py script.
running build_scripts
running install_lib
running install_scripts
changing mode of /usr/bin/pilfile.py to 755
changing mode of /usr/bin/pilconvert.py to 755
changing mode of /usr/bin/pilprint.py to 755
changing mode of /usr/bin/pildriver.py to 755
changing mode of /usr/bin/pilfont.py to 755
running install_egg_info
Removing /usr/lib64/python2.7/site-packages/PIL/PIL-1.1.7-py2.7.egg-info
Writing /usr/lib64/python2.7/site-packages/PIL/PIL-1.1.7-py2.7.egg-info
creating /usr/lib64/python2.7/site-packages/PIL.pth
Or si je test dans python , y a comme un probleme:
Python 2.7.5 (default, Nov 3 2014, 14:26:24)
[GCC 4.8.3 20140911 (Red Hat 4.8.3-7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import Image
/usr/lib64/python2.7/site-packages/PIL/Image.py:71: RuntimeWarning: The _imaging extension was built for another version of Pillow or PIL
warnings.warn(str(v), RuntimeWarning)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib64/python2.7/site-packages/PIL/Image.py", line 55, in <module>
raise ImportError("The _imaging extension was built for another "
ImportError: The _imaging extension was built for another version of Pillow or PIL
Si je test avec selftest :
[root@localhost Imaging-1.1.7]# python selftest.py
--------------------------------------------------------------------
PIL 1.1.7 TEST SUMMARY
--------------------------------------------------------------------
Python modules loaded from ./PIL
Binary modules loaded from /usr/lib64/python2.7/site-packages/PIL
--------------------------------------------------------------------
*** PIL CORE support not installed
*** TKINTER support not installed
*** JPEG support not installed
--- ZLIB (PNG/ZIP) support ok
*** FREETYPE2 support not installed
*** LITTLECMS support not installed
--------------------------------------------------------------------
Running selftest:
*****************************************************************
Failure in example:
try:
_info(Image.open(os.path.join(ROOT, "Images/lena.jpg")))
except IOError, v:
print v
from line #24 of selftest.testimage
Expected: ('JPEG', 'RGB', (128, 128))
Got: decoder jpeg not available
1 items had failures:
1 of 57 in selftest.testimage
***Test Failed*** 1 failures.
*** 1 tests of 57 failed.
Apres coup j'ai lu. sur
http://fedoraproject.org/wiki/Features/Pillow, cela:
Pillow : Replace PIL (python-imaging) with Pillow, an actively maintained fork which is also heading for python3 compatibility
Je me demande si j'ai pas fait une betise ???
Si oui, comment en sortir 🙂
Comme toujours, merci d'avance pour toute idee !
Bonne journee