Install lxml on Centos 7 - error: command 'gcc' failed with exit status 4

前端 未结 4 1649
伪装坚强ぢ
伪装坚强ぢ 2020-12-31 14:40

I\'m using python 3.4 in a virtual environment:

(af)[root@domain backend]# pip --version
pip 7.1.0 from /home/af/af-stage/backend/.ves/af/lib/python3.4/sit         


        
相关标签:
4条回答
  • 2020-12-31 15:00

    I updated my lxml version from 3.7.0 to the latest one 4.1.1 and that works for me.

    0 讨论(0)
  • 2020-12-31 15:02

    You just need to use yum install python-lxml. Of course, lxml module depend on libxml2 libxslt libxml2-devel libxslt-devel.

    0 讨论(0)
  • 2020-12-31 15:11

    This worked for me: yum install -y libxml2 libxml2-devel libxslt libxslt-devel

    0 讨论(0)
  • 2020-12-31 15:19

    It works after installing:

    libxml++-2.30.0-1.el6.i686
    libsigc++20-devel-2.2.4.2-1.el6.i686
    libxml2-static-2.7.6-21.el6_8.1.i686
    libxml++-devel-2.30.0-1.el6.i686
    libxslt-python-1.1.26-2.el6_3.1.i686
    gccxml-0.9.0-0.27.20150423.git3afa8ba.el6.i686
    
    0 讨论(0)
提交回复
热议问题