推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
jacklong
V2EX  ›  Python

lxml install on OS X error: "libxml/xmlversion.h"

  •  
  •   jacklong ·
    jack-long · Feb 19, 2015 · 4166 views
    This topic created in 4120 days ago, the information mentioned may be changed or developed.

    error: 'libxml/xmlversion.h' file not found #include "libxml/xmlversion.h"

    brew install libxml2 libxslt

    STATIC_DEPS=true sudo pip install lxml

    http://lxml.de/installation.html#macos-x

    3 replies    2015-10-28 09:52:08 +08:00
    Melodic
        1
    Melodic  
       Feb 19, 2015
    xcode-select --install

    升级一下命令行先?
    chinvo
        2
    chinvo  
       Feb 20, 2015
    $ brew doctor
    autosquid
        3
    autosquid  
       Oct 28, 2015
    lxm 自身安装包的问题。

    workaround 是把 Libxml2 的路径手工指定。

    ```
    CPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/libxml2 CFLAGS=-Qunused-arguments CPPFLAGS=-Qunused-arguments pip install lxml
    ```
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5812 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 40ms · UTC 06:13 · PVG 14:13 · LAX 23:13 · JFK 02:13
    ♥ Do have faith in what you're doing.