我是python中的新手,我尝试使用openpyxl来处理excel。当我使用sudo pip install lxml
时,我遇到了这种错误的信息:
In file included from src/lxml/lxml.etree.c:239:0:
/tmp/pip_build_root/lxml/src/lxml/includes/etree_defs.h:14:31: fatal error: libxml/xmlversion.h: No such file or directory
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
Rolling back uninstall of lxml
感谢您的帮助
答案 0 :(得分:3)
您需要安装其他软件包,有关详细信息,请参阅here。
sudo apt-get install libxml2-dev libxslt-dev python-dev