安装PyInstaller
//地址
https://github.com/pyinstaller/pyinstaller/tree/python3//上面的链接已经失效,新的(20160809更)
https://github.com/pyinstaller/pyinstaller
方法一:直接使用pip,国内网络会无法连接
pip install pyinstaller
方法二:下载源码安装在github中打包下载,解压到电脑中,运行命令行进入此目录。
//进入子目录 bootloader
cd bootloader//build the bootloader 运行
python ./waf configure build install//重新进入根目录
cd ..//安装pyinstaller
python setup.py install//from http://www.cnblogs.com/osfipin/
查看安装结果,运行命令:
pyinstaller --version
说明安装成功。
简单的编译,运行代码:
pyinstaller D:\pyworker\learning\hello.py
目录下会出现编译结果:
结束。来自:http://www.cnblogs.com/osfipin/