Python:pip找不到setup.py [英] Python: pip can't find setup.py

查看:444
本文介绍了Python:pip找不到setup.py的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何引导点子找到setup.py?我的setup.py文件位于~/setuptools-3.5.1.

How can I direct pip to find setup.py? My setup.py file is located ~/setuptools-3.5.1.

我跑了

dustin@dustin:~$ python setuptools-3.5.1/setup.py egg_info
running egg_info
writing requirements to setuptools.egg-info/requires.txt
writing setuptools.egg-info/PKG-INFO
writing top-level names to setuptools.egg-info/top_level.txt
writing dependency_links to setuptools.egg-info/dependency_links.txt
writing entry points to setuptools.egg-info/entry_points.txt
reading manifest file 'setuptools.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'setuptools.egg-info/SOURCES.txt'
dustin@dustin:~$ 

看起来一切都很好,但是当我运行pip时,我得到了

so it looks as everything is okay, but when I run pip, I get

Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_root/matplotlib
Storing debug log for failure in /home/dustin/.pip/pip.log

给我的印象是,当我运行pip时没有找到setup.py

I am under the impression that when I run pip it isn't finding setup.py

推荐答案

matplotlib具有许多外部依赖项.其中一些是必需的.您可以在尝试通过pip install生成的日志文件中看到所需的列表.在您的情况下,就是这样:

matplotlib has many external dependencies. Some of these are required. You can see the list of required ones in the log file produced by the attempted pip install. In your case, it is this:

REQUIRED DEPENDENCIES AND EXTENSIONS
                 numpy: yes [version 1.8.1]
              dateutil: yes [dateutil was not found. It is required for date
                        axis support. pip/easy_install may attempt to
                        install it after matplotlib.]
               tornado: yes [using tornado version 3.2.1]
             pyparsing: yes [pyparsing was not found. It is required for
                        mathtext support. pip/easy_install may attempt to
                        install it after matplotlib.]
                 pycxx: yes [Couldn't import.  Using local copy.]
                libagg: yes [pkg-config information for 'libagg' could not
                        be found. Using local copy.]
              freetype: no  [pkg-config information for 'freetype2' could
                        not be found.]
                   png: yes [pkg-config information for 'libpng' could not
                        be found. Using unknown version.]

============================================================================
                        * The following required packages can not be built:
                        * freetype
Complete output from command python setup.py egg_info:
============================================================================

在这里,您会发现找不到freetype.您需要将其安装在系统上.

Here, you can see that freetype couldn't be found. You need to install it on your system.

这篇关于Python:pip找不到setup.py的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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