使用zc.buildout,如何从网站安装tarball?

时间:2010-04-03 18:04:17

标签: python buildout recipe

我正在尝试让zc.buildout从源代码安装Gunicorn。使用以下配置:

[gunicorn]
recipe = collective.recipe.distutils
url = http://github.com/benoitc/gunicorn/tarball/master

导致以下错误:

SystemError: ('Failed', '"/usr/bin/python" setup.py -q install --install-  purelib="/mnt/hgfs/Projects/intranation/parts/site-packages" --install-platlib="/mnt/hgfs/Projects/intranation/parts/site-packages"')

提供--install-dir--prefix无济于事。

zc.buildout是否有下载tarball并通过easy_install或类似方法安装的配方?

1 个答案:

答案 0 :(得分:3)

你可以“只”安装它。在命令行中,“easy_install http://github.com/benoitc/gunicorn/tarball/master”工作正常。

buildout等价物将依赖于“gunicorn”(以便buildout尝试安装它)并告诉buildout你的github链接实际上是gunicorn。你可以用find-links做到这一点:

[buildout]
  find-links =
      http://github.com/benoitc/gunicorn/tarball/master#egg=gunicorn
  parts = console_scripts


  [console_scripts]
  recipe = zc.recipe.egg
  eggs = gunicorn