我想安装Lxml,以便随后可以安装Scrapy。
今天更新Mac时,不允许我重新安装lxml,但出现以下错误:
In file included from src/lxml/lxml.etree.c:314:
/private/tmp/pip_build_root/lxml/src/lxml/includes/etree_defs.h:9:10: fatal error: 'libxml/xmlversion.h' file not found
#include "libxml/xmlversion.h"
^
1 error generated.
error: command 'cc' failed with exit status 1
我尝试使用brew安装libxml2和libxslt,两者都安装良好,但仍然无法安装lxml。
上次安装时,我需要在Xcode上启用开发人员工具,但由于其更新为Xcode 5,因此不再提供该选项。
有人知道我需要做什么吗?
您应该为xcode安装或升级命令行工具。在终端上尝试一下:
xcode-select --install
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句