错误提示Command "/Library/Frameworks/Python.framework/Versions/3.5/bin/python3 -u -c "import setuptools, tokenize;__file__='/private/var/folders/66/bxp594wj6_z32vq7lmjmsl0w0000gn/T/pip-build-pgy_8noy/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/66/bxp594wj6_z32vq7lmjmsl0w0000gn/T/pip-3b058xt2-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/66/bxp594wj6_z32vq7lmjmsl0w0000gn/T/pip-build-pgy_8noy/lxml/
解决方案
windows下:1. 安装wheel,命令行运行:
pip install wheel
3. 进入.whl所在的文件夹,执行命令即可完成安装
pip install 带后缀的完整文件名
mac下:
首先确认安装了xcode commond line tool 也就是xcode的命令行工具,因为编译lxml需要用到cc 等命令
所以先在命令行输入xcode-select --install
安装