我正在尝试使用以下setup.py代码用Py2exe库转换我的Python程序:
from distutils.core import setup
import py2exe
file = raw_input("Python file to convert:")
setup(console=[file])
然后,当我输入要转换的程序时,它会显示:
。
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
然后它停止了。你们中有谁知道是什么原因引起的吗?
python setup.py py2exe
- derricw