1.安装setuptools
将ez_setup.py 放到python目录下,然后在命令行执行:python ez_setup.py
2.安装xlrd
命令行进入xlrd目录,python setup.py install
3.安装xlwt,同上;
4.pyinstaller
进入PyInstaller-3.2目录,然后命令行:python setup.py install
然后使用:python pyinstaller.py测试一下
则表示可以使用pyinstaller了。
把要打包的文件拷贝到PyInstaller-3.2目录下,在命令行执行:
python pyinstaller.py --console --onefile D:\PyInstaller-3.2\getFileVersion2.py