Distributing Python Programs

Possible duplicate:
Python distribution

I have some source code for some graphics programs that I created in Python. I would like to distribute them. However, I would like to make it as simple as possible so that the end user can run the program and run it. What is the general way to solve this problem?

This applies to Windows XP and on.

+9
python
Nov 16 '10 at 2:17
source share
2 answers

All noteworthy Linux and Mac OS distributions ship with some version of Python. Windows does not have Python installed by default, so you must install it separately to run the Python module. Of course, the installed version of Python should match your program (version 2 or 3).

The easiest way to distribute your program is to simply distribute the source code (for example, send your module by e-mail or download it somewhere), but in this case, Python must be installed on the target PC and it must correspond to the dependencies. An even better solution (at least for the community) is to download your program as a package in PyPi . More information for this procedure can be found HERE .

In some cases, there are reasons that prevent you from using these options. For example, you cannot install python and / or dependencies (without root / admin account). If so, you can link your modules with everything else that is required to run your program (for example, python * .dll on Windows). As far as I know, the main options for this type of distribution are as follows:

  1. PyInstaller
  2. portfolio
  3. Fbs
  4. Pyoxidizer
  5. nuita --standalone
  6. py2app (Mac OS only)
  7. cx_Freeze
  8. freeze
  9. py2exe

  10. Cython --embed

Another approach is to use Portable Python or in the case of Linux / BSD StaticPython

Note: not all of the above tools work on all platforms and / or support Python3. Check their documentation.

Not supported

  1. bbFreeze
  2. eski (not supported)
  3. Vendorid
  4. gui2exe
+21
Mar 20 2018-11-21T00:
source share
— -

You want py2exe , which is a distutils package extension.

http://www.py2exe.org/

+4
Nov 16 '10 at 2:21
source share



All Articles