我必须在我的ubuntu机器上安装pygit2库。当我尝试"pip install pygit2“时,我会得到以下错误。
cffi.ffiplatform.VerificationError: CompileError:命令'x86_64-linux-gnu-gcc‘失败,退出状态1
清理..。命令python setup.py egg_info失败,错误代码1在/tmp/pip_build_root/pygit2 2中存储调试日志,以便在/root/.pip/pip.log中失败
在此之前,我做了以下工作,结果很好(http://www.pygit2.org/install.html#quick-install)。
$ wget https://github.com/libgit2/libgit2/archive/v0.22.0.tar.gz
$ tar xzf v0.22.0.tar.gz
$ cd libgit2-0.22.0/
$ cmake .
$ make
$ sudo make install我的机器上已经有libffi6了。
sudo apt-get install libffi6 libffi-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libffi-dev is already the newest version.
libffi6 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 16 not upgraded.发布于 2015-01-30 01:41:00
看起来您需要安装libffi和它的开发包( pygit2所依赖的)
https://stackoverflow.com/questions/28227764
复制相似问题