zoukankan      html  css  js  c++  java
  • Odoo ParseError:"decoder jpeg not available" while parsing....

    The reason causing this problem is the plugin PIL install error

    to solve this problem,try this:

    1. clear PIL packages

    rm -rf /usr/lib/python2.7/site-packages/PIL
    rm -rf /usr/lib/python2.7/site-packages/PIL.pth
    

    2.install required packages

    ubuntu:
    apt-get install libjpeg-dev
    apt-get install libfreetype6-dev
    apt-get install zlib1g-dev
    apt-get install libpng12-dev
    
    centos:
    yum install zlib zlib-devel
    yum install libjpeg libjpeg-devel
    yum install freetype freetype-devel
    

    3.download Image and install

    wget http://effbot.org/downloads/Imaging-1.1.7.tar.gz
    tar xzvf Imaging-1.1.7.tar.gz
    cd Imaging-1.1.7
    # if the sys is x64, you must also do this: edit the setup.py file and set:
    # centOS:
    TCL_ROOT = '/usr/lib64'
    JPEG_ROOT = '/usr/lib64'
    ZLIB_ROOT = '/usr/lib64'
    TIFF_ROOT = '/usr/lib64'
    FREETYPE_ROOT = '/usr/lib64'
    LCMS_ROOT = '/usr/lib64'
    # Ubuntu:
    TCL_ROOT = '/usr/lib/x86_64-linux-gnu'
    JPEG_ROOT = '/usr/lib/x86_64-linux-gnu'
    ZLIB_ROOT = '/usr/lib/x86_64-linux-gnu'
    TIFF_ROOT = '/usr/lib/x86_64-linux-gnu'
    FREETYPE_ROOT = '/usr/lib/x86_64-linux-gnu'
    LCMS_ROOT = '/usr/lib/x86_64-linux-gnu'
    #then install it use:
    python2.7 setup.py install
    

    4. check if it works

    python2.7 selftest.py
    

    If the result is:

    --- PIL CORE support ok
    --- TKINTER support ok
    --- JPEG support ok
    --- ZLIB (PNG/ZIP) support ok
    --- FREETYPE2 support ok
    *** LITTLECMS support not installed
    --------------------------------------------------------------------
    Running selftest:
    --- 57 tests passed.

     

  • 相关阅读:
    JVM常用参数整理
    mac系统使用Chrome浏览器https不自动保存密码
    JVM和JMM内存模型
    Chrome提示是否保存密码点击了否,导致没有自动保存密码
    解决Mac系统IDEA debug卡顿问题
    DBeaver的时区问题
    IDEA导航光标回退和前进快捷键失效
    Dubbo 2.6.0升级到2.7.3
    chrome浏览器备忘
    电脑导入mobi书籍文件到IPAD的方法
  • 原文地址:https://www.cnblogs.com/kfx2007/p/3858752.html
Copyright © 2011-2022 走看看