Roy*_*cow 1 python pyinstaller
我正在使用 python2 并且在安装 pyinstaller 时遇到问题。这是我尝试过的:
root@host:~/setup# pip install pyinstaller
Collecting pyinstaller
Using cached https://files.pythonhosted.org/packages/82/96/21ba3619647bac2b34b4996b2dbbea8e74a703767ce24192899d9153c058/pyinstaller-4.0.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-build-6zdWWq/pyinstaller/setup.py", line 63
file=sys.stderr)
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-6zdWWq/pyinstaller/
Run Code Online (Sandbox Code Playgroud)
根据我的理解,Pyinstaller v4.0 不支持 Python 2,这是我假设在您使用pip install pyinstaller.
解决方案:
访问Pyinstaller Release History查看你想要安装的版本(从 Python v3.6 到 v3.0 的所有版本都支持 Python 2)
使用以下命令安装您选择的 Pyinstaller 版本:pip install pyinstaller==3.5这应该适合您!
下面的图片:
| 归档时间: |
|
| 查看次数: |
2851 次 |
| 最近记录: |