1.使用pip安装pyinstaller,(一次安装)
pip install pyinstaller
2.打包
pyinstaller -F myfile.py
我的测试:
我的程序目录
pythons\
code1\
myfile.py
pythonbin\
scripts\
pip.exe
pyinstaller.exe
python.exe
在cmd,下,
命令 pythons\code1>..\pythonbin\scripts\pyinstaller -F myfile.py
生成:4个,
__pycache__/*
dist/myfile.exe //这个是可执行的,
build/*
myfile.spec
。。
转载于:https://www.cnblogs.com/ijunxiong/articles/10381837.html
相关资源:如何使用pyinstaller打包32位的exe程序