Pip安装错误-命令python setup.py egg_info失败,错误代码为1 [英] Pip Installation Error - Command python setup.py egg_info failed with error code 1

查看:1124
本文介绍了Pip安装错误-命令python setup.py egg_info失败,错误代码为1的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚在 Windows 7(32位)框中安装了 Python 2.7.5 .

当尝试通过Windows控制台安装 Scrapy 模块时,出现以下错误:

When trying to install Scrapy module via the Windows console I get the below error:

Command python setup.py egg_info failed with error code 1 in c:\users\compaq\app
data\local\temp\pip_build_COMPAQ\pyOpenSSL
Storing debug log for failure in C:\Users\COMPAQ\pip\pip.log

我已经阅读了其他主题,建议重新安装或更新安装工具.我已经尝试过此操作(存在最新的设置工具),但仍然存在拼凑的安装错误.

I have read other threads on this, suggesting that setup tools be re-installed or updated. I have already attempted this (the latest setup tools exist) but the scrapy install error remains.

以下是完整的安装脚本和失败信息:

The below is the full install script and failure:

  C:\Windows\system32>pip install scrapy
  Downloading/unpacking scrapy
    Running setup.py (path:c:\users\compaq\appdata\local\temp\pip_build_COMPAQ\scr
  apy\setup.py) egg_info for package scrapy

      no previously-included directories found matching 'docs\build'
  Downloading/unpacking Twisted>=10.0.0 (from scrapy)
  Downloading/unpacking w3lib>=1.2 (from scrapy)
    Downloading w3lib-1.5.tar.gz
    Running setup.py (path:c:\users\compaq\appdata\local\temp\pip_build_COMPAQ\w3l
  ib\setup.py) egg_info for package w3lib

  Downloading/unpacking queuelib (from scrapy)
    Downloading queuelib-1.1.1.tar.gz
    Running setup.py (path:c:\users\compaq\appdata\local\temp\pip_build_COMPAQ\que
  uelib\setup.py) egg_info for package queuelib

  Downloading/unpacking lxml (from scrapy)
    Running setup.py (path:c:\users\compaq\appdata\local\temp\pip_build_COMPAQ\lxm
  l\setup.py) egg_info for package lxml
      Building lxml version 3.3.0.
      Building without Cython.
      ERROR: 'xslt-config' is not recognized as an internal or external command,
      operable program or batch file.

      ** make sure the development packages of libxml2 and libxslt are installed *
  *

      Using build configuration of libxslt
      C:\HACK\Python\lib\distutils\dist.py:267: UserWarning: Unknown distribution
  option: 'bugtrack_url'
        warnings.warn(msg)

      warning: no previously-included files found matching '*.py'
  Downloading/unpacking pyOpenSSL (from scrapy)
    Running setup.py (path:c:\users\compaq\appdata\local\temp\pip_build_COMPAQ\pyO
  penSSL\setup.py) egg_info for package pyOpenSSL

      error: Only found improper OpenSSL directories: ['C:\\RUBY\\RailsInstaller\\
  Git']
      Complete output from command python setup.py egg_info:
      running egg_info

  creating pip-egg-info\pyOpenSSL.egg-info

  writing dependency_links to pip-egg-info\pyOpenSSL.egg-info\dependency_links.txt


  writing pip-egg-info\pyOpenSSL.egg-info\PKG-INFO

  writing top-level names to pip-egg-info\pyOpenSSL.egg-info\top_level.txt

  writing manifest file 'pip-egg-info\pyOpenSSL.egg-info\SOURCES.txt'

  warning: manifest_maker: standard file '-c' not found



  error: Only found improper OpenSSL directories: ['C:\\RUBY\\RailsInstaller\\Git'
  ]

  ----------------------------------------
  Cleaning up...
  Command python setup.py egg_info failed with error code 1 in c:\users\compaq\app
  data\local\temp\pip_build_COMPAQ\pyOpenSSL
  Storing debug log for failure in C:\Users\COMPAQ\pip\pip.log

推荐答案

pip尝试从源代码构建软件包.因此,您将需要库和VS2008编译器的开发标头,而这些标头的设置都非常麻烦.

pip tries to build packages from source. So you'll need development headers for libraries and VS2008 compiler, all of which is rather painful to set up.

从此处下载失败软件包的预编译二进制文件更加容易: http://www.lfd.uci.edu/~gohlke/pythonlibs/

It's easier to download prebuilt binaries for failed packages from here: http://www.lfd.uci.edu/~gohlke/pythonlibs/

然后尝试重新安装scrapy.

这篇关于Pip安装错误-命令python setup.py egg_info失败,错误代码为1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆