我们在公司中托管了一个简单的 pypi 服务器。
此命令适用于大多数 pip 包,但它失败argon2-cffi
:
pypi@pypihost:~> pip install -d packages argon2-cffi
Collecting argon2-cffi
File was already downloaded packages/argon2_cffi-16.2.0.tar.gz
Complete output from command python setup.py egg_info:
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libffi' found
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libffi' found
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libffi' found
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libffi' found
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libffi' found
c/_cffi_backend.c:15:17: fatal error: ffi.h: Datei oder Verzeichnis nicht gefunden
compilation terminated.
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/home/pypi/tmp/pip-build-LJ1EjJ/argon2-cffi/setup.py", line 206, in <module>
extras_require=EXTRAS_REQUIRE,
File "/usr/lib/python2.7/distutils/core.py", line 112, in setup
_setup_distribution = dist = klass(attrs)
File "/home/pypi/lib/python2.7/site-packages/setuptools/dist.py", line 265, in __init__
self.fetch_build_eggs(attrs['setup_requires'])
File "/home/pypi/lib/python2.7/site-packages/setuptools/dist.py", line 310, in fetch_build_eggs
replace_conflicting=True,
File "/home/pypi/lib/python2.7/site-packages/pkg_resources/__init__.py", line 824, in resolve
dist = best[req.key] = env.best_match(req, ws, installer)
File "/home/pypi/lib/python2.7/site-packages/pkg_resources/__init__.py", line 1069, in best_match
return self.obtain(req, installer)
File "/home/pypi/lib/python2.7/site-packages/pkg_resources/__init__.py", line 1081, in obtain
return installer(requirement)
File "/home/pypi/lib/python2.7/site-packages/setuptools/dist.py", line 377, in fetch_build_egg
return cmd.easy_install(req)
File "/home/pypi/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 629, in easy_install
return self.install_item(spec, dist.location, tmpdir, deps)
File "/home/pypi/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 659, in install_item
dists = self.install_eggs(spec, download, tmpdir)
File "/home/pypi/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 842, in install_eggs
return self.build_and_install(setup_script, setup_base)
File "/home/pypi/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1070, in build_and_install
self.run_setup(setup_script, setup_base, args)
File "/home/pypi/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 1058, in run_setup
raise DistutilsError("Setup script exited with %s" % (v.args[0],))
distutils.errors.DistutilsError: Setup script exited with error: command 'gcc' failed with exit status 1
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /home/pypi/tmp/pip-build-LJ1EjJ/argon2-cffi/
我不希望 gcc 在这种情况下运行,因为我只想下载它。
我做错了什么?
我正在运行 SuSE Linux 12.3