安裝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/
