python3.6.3 Conversion to win Method of publishing exe files

  • 2021-01-22 05:12:14
  • OfStack

All kinds of pit

py2exe (2.x only

cx_frezee, various questions

methods

Use pyinstaller.

Be sure to use pip3 install pyinstaller when installing.

pip3.6 install pyinstaller does not pass, this is another big hole.

Today is November 18, 2017, and it's clear

pyonstaller is compatible with python3.6!

The installation

pip3, install, pyinstaller pass perfectly.

Packaging releases

Go to your programming directory.

Open the cmd.

pyinstaller-w-i c://logo.ico yourfilename.py"

Three new directories appear under the directory: dist, build, -- pycache --

Go to dist, find the exe file, and click Open.

And you're done!

Parameters that

-F means to generate a single executable

-w means to remove the console window, which is useful in the GUI interface. But if it's a command line program then remove this option!

-p means that you can customize the classpath you need to load, but it is not usually used

-i represents the icon of the executable file


Related articles: