如何正确运行setup.py文件? [英] How do you run a setup.py file properly?
本文介绍了如何正确运行setup.py文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试运行此setup.py文件,该文件位于.tat.gz文件中.我要转到它所在的目录并运行 python setup.py ,但会收到以下错误消息:
I'm trying to run this setup.py file, which was in a .tat.gz file. I'm going to the directory it's in and running python setup.py but get this error message:
brandon@brandon-NV57H:~/Downloads/numpy-1.9.2$ python setup.py
Running from numpy source directory.
/usr/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'test_suite'
warnings.warn(msg)
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: setup.py --help [cmd1 cmd2 ...]
or: setup.py --help-commands
or: setup.py cmd --help
error: no commands supplied
brandon@brandon-NV57H:~/Downloads/numpy-1.9.2$
有人可以帮我吗?我该如何解决?我同时拥有python2.7和python3.4.
Can anyone help me out? How do I fix this? I have both python2.7 and python3.4.
推荐答案
如果要安装它,则命令为install
:
If you want to install it then the command is install
:
python setup.py install
如果需要先构建软件包,请在安装前使用build
命令:
If you need to build the package first, use the build
command before installing:
python setup.py build
希望这会有所帮助!
这篇关于如何正确运行setup.py文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文