• <bdo id='GGOOL'></bdo><ul id='GGOOL'></ul>

    1. <i id='GGOOL'><tr id='GGOOL'><dt id='GGOOL'><q id='GGOOL'><span id='GGOOL'><b id='GGOOL'><form id='GGOOL'><ins id='GGOOL'></ins><ul id='GGOOL'></ul><sub id='GGOOL'></sub></form><legend id='GGOOL'></legend><bdo id='GGOOL'><pre id='GGOOL'><center id='GGOOL'></center></pre></bdo></b><th id='GGOOL'></th></span></q></dt></tr></i><div id='GGOOL'><tfoot id='GGOOL'></tfoot><dl id='GGOOL'><fieldset id='GGOOL'></fieldset></dl></div>
      1. <legend id='GGOOL'><style id='GGOOL'><dir id='GGOOL'><q id='GGOOL'></q></dir></style></legend>
        <tfoot id='GGOOL'></tfoot>

        <small id='GGOOL'></small><noframes id='GGOOL'>

        在 Centos 7 上安装 lxml - 错误:命令“gcc"失败,

        时间:2023-09-14
          • <tfoot id='2cSok'></tfoot>

            <small id='2cSok'></small><noframes id='2cSok'>

          • <legend id='2cSok'><style id='2cSok'><dir id='2cSok'><q id='2cSok'></q></dir></style></legend>

                <tbody id='2cSok'></tbody>

            1. <i id='2cSok'><tr id='2cSok'><dt id='2cSok'><q id='2cSok'><span id='2cSok'><b id='2cSok'><form id='2cSok'><ins id='2cSok'></ins><ul id='2cSok'></ul><sub id='2cSok'></sub></form><legend id='2cSok'></legend><bdo id='2cSok'><pre id='2cSok'><center id='2cSok'></center></pre></bdo></b><th id='2cSok'></th></span></q></dt></tr></i><div id='2cSok'><tfoot id='2cSok'></tfoot><dl id='2cSok'><fieldset id='2cSok'></fieldset></dl></div>

                <bdo id='2cSok'></bdo><ul id='2cSok'></ul>

                  本文介绍了在 Centos 7 上安装 lxml - 错误:命令“gcc"失败,退出状态为 4的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我在虚拟环境中使用 python 3.4:

                  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/site-packages (python 3.4)
                  

                  lxml 安装失败错误:命令 'gcc' 失败,退出状态为 4":

                  Installation of lxml failed "error: command 'gcc' failed with exit status 4":

                  (af)[root@domain backend]# pip install lxml
                  You are using pip version 7.1.0, however version 7.1.2 is available.
                  You should consider upgrading via the 'pip install --upgrade pip' command.
                  Collecting lxml
                    Using cached lxml-3.5.0.tar.gz
                  Building wheels for collected packages: lxml
                    Running setup.py bdist_wheel for lxml
                    Complete output from command /home/af/af-stage/backend/.ves/af/bin/python3.4 -c "import setuptools;__file__='/tmp/pip-build-tlogtyk2/lxml/setup.py';exec(compile(open(__file__).read().replace('
                  ', '
                  '), __file__, 'exec'))" bdist_wheel -d /tmp/tmpod9hcw0ypip-wheel-:
                    Building lxml version 3.5.0.
                    Building without Cython.
                    Using build configuration of libxslt 1.1.28
                    Building against libxml2/libxslt in the following directory: /usr/lib64
                    running bdist_wheel
                    running build
                    running build_py
                    creating build
                    creating build/lib.linux-x86_64-3.4
                    creating build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/usedoctest.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/__init__.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/builder.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/sax.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/doctestcompare.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/_elementpath.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/cssselect.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/ElementInclude.py -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/pyclasslookup.py -> build/lib.linux-x86_64-3.4/lxml
                    creating build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/__init__.py -> build/lib.linux-x86_64-3.4/lxml/includes
                    creating build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/usedoctest.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/html5parser.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/__init__.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/_html5builder.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/builder.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/_setmixin.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/_diffcommand.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/ElementSoup.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/formfill.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/soupparser.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/diff.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/defs.py -> build/lib.linux-x86_64-3.4/lxml/html
                    copying src/lxml/html/clean.py -> build/lib.linux-x86_64-3.4/lxml/html
                    creating build/lib.linux-x86_64-3.4/lxml/isoschematron
                    copying src/lxml/isoschematron/__init__.py -> build/lib.linux-x86_64-3.4/lxml/isoschematron
                    copying src/lxml/lxml.etree.h -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/lxml.etree_api.h -> build/lib.linux-x86_64-3.4/lxml
                    copying src/lxml/includes/etreepublic.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/uri.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xmlschema.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/config.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xmlerror.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xslt.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/tree.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xpath.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/relaxng.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/htmlparser.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xinclude.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/xmlparser.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/schematron.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/dtdvalid.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/c14n.pxd -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/lxml-version.h -> build/lib.linux-x86_64-3.4/lxml/includes
                    copying src/lxml/includes/etree_defs.h -> build/lib.linux-x86_64-3.4/lxml/includes
                    creating build/lib.linux-x86_64-3.4/lxml/isoschematron/resources
                    creating build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/rng
                    copying src/lxml/isoschematron/resources/rng/iso-schematron.rng -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/rng
                    creating build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl
                    copying src/lxml/isoschematron/resources/xsl/RNG2Schtrn.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl
                    copying src/lxml/isoschematron/resources/xsl/XSD2Schtrn.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl
                    creating build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_svrl_for_xslt1.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_dsdl_include.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_abstract_expand.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_schematron_message.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_schematron_skeleton_for_xslt1.xsl -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    copying src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/readme.txt -> build/lib.linux-x86_64-3.4/lxml/isoschematron/resources/xsl/iso-schematron-xslt1
                    running build_ext
                    building 'lxml.etree' extension
                    creating build/temp.linux-x86_64-3.4
                    creating build/temp.linux-x86_64-3.4/src
                    creating build/temp.linux-x86_64-3.4/src/lxml
                    gcc -pthread -Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/libxml2 -Isrc/lxml/includes -I/usr/include/python3.4m -c src/lxml/lxml.etree.c -o build/temp.linux-x86_64-3.4/src/lxml/lxml.etree.o -w
                    {standard input}: Assembler messages:
                    {standard input}:1531298: Error: unknown pseudo-op: `.uleb'
                    gcc: internal compiler error: Killed (program cc1)
                    Please submit a full bug report,
                    with preprocessed source if appropriate.
                    See <http://bugzilla.redhat.com/bugzilla> for instructions.
                    Compile failed: command 'gcc' failed with exit status 4
                    creating tmp
                    cc -I/usr/include/libxml2 -I/usr/include/libxml2 -c /tmp/xmlXPathInitpm92p5c8.c -o tmp/xmlXPathInitpm92p5c8.o
                    cc tmp/xmlXPathInitpm92p5c8.o -L/usr/lib64 -lxml2 -o a.out
                    error: command 'gcc' failed with exit status 4
                  
                    ----------------------------------------
                    Failed building wheel for lxml
                  Failed to build lxml
                  Installing collected packages: lxml
                    Running setup.py install for lxml
                      Complete output from command /home/af/af-stage/backend/.ves/af/bin/python3.4 -c "import setuptools, tokenize;__file__='/tmp/pip-build-tlogtyk2/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('
                  ', '
                  '), __file__, 'exec'))" install --record /tmp/pip-99hwjy1o-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/af/af-stage/backend/.ves/af/include/site/python3.4/lxml:
                      Building lxml version 3.5.0.
                      Building without Cython.
                      Using build configuration of libxslt 1.1.28
                      Building against libxml2/libxslt in the following directory: /usr/lib64
                      running install
                      running build
                      running build_py
                      copying src/lxml/includes/lxml-version.h -> build/lib.linux-x86_64-3.4/lxml/includes
                      running build_ext
                      building 'lxml.etree' extension
                      gcc -pthread -Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/libxml2 -Isrc/lxml/includes -I/usr/include/python3.4m -c src/lxml/lxml.etree.c -o build/temp.linux-x86_64-3.4/src/lxml/lxml.etree.o -w
                      {standard input}: Assembler messages:
                      {standard input}:1320351: Error: unknown pseudo-op: `.uleb1'
                      gcc: internal compiler error: Killed (program cc1)
                      Please submit a full bug report,
                      with preprocessed source if appropriate.
                      See <http://bugzilla.redhat.com/bugzilla> for instructions.
                      Compile failed: command 'gcc' failed with exit status 4
                      cc -I/usr/include/libxml2 -I/usr/include/libxml2 -c /tmp/xmlXPathInit3tj66iu0.c -o tmp/xmlXPathInit3tj66iu0.o
                      cc tmp/xmlXPathInit3tj66iu0.o -L/usr/lib64 -lxml2 -o a.out
                      error: command 'gcc' failed with exit status 4
                  
                      ----------------------------------------
                  Command "/home/af/af-stage/backend/.ves/af/bin/python3.4 -c "import setuptools, tokenize;__file__='/tmp/pip-build-tlogtyk2/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('
                  ', '
                  '), __file__, 'exec'))" install --record /tmp/pip-99hwjy1o-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/af/af-stage/backend/.ves/af/include/site/python3.4/lxml" failed with error code 1 in /tmp/pip-build-tlogtyk2/lxml
                  

                  注意事项:
                  我已经完成了 yum install libxslt-devel libxml2-devel

                  推荐答案

                  这对我有用:yum install -y libxml2 libxml2-devel libxslt libxslt-devel

                  这篇关于在 Centos 7 上安装 lxml - 错误:命令“gcc"失败,退出状态为 4的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:修复“警告:未找到 GMP 或 MPIR 库;不构建 Crypto 下一篇:sudo python 运行旧的python版本

                  相关文章

                  最新文章

                1. <small id='kGVDM'></small><noframes id='kGVDM'>

                    <bdo id='kGVDM'></bdo><ul id='kGVDM'></ul>

                    <i id='kGVDM'><tr id='kGVDM'><dt id='kGVDM'><q id='kGVDM'><span id='kGVDM'><b id='kGVDM'><form id='kGVDM'><ins id='kGVDM'></ins><ul id='kGVDM'></ul><sub id='kGVDM'></sub></form><legend id='kGVDM'></legend><bdo id='kGVDM'><pre id='kGVDM'><center id='kGVDM'></center></pre></bdo></b><th id='kGVDM'></th></span></q></dt></tr></i><div id='kGVDM'><tfoot id='kGVDM'></tfoot><dl id='kGVDM'><fieldset id='kGVDM'></fieldset></dl></div>
                    <legend id='kGVDM'><style id='kGVDM'><dir id='kGVDM'><q id='kGVDM'></q></dir></style></legend>
                      <tfoot id='kGVDM'></tfoot>