Search code examples
pythonexecutablepy2exe

How to convert a .pyc to a .exe file


I want to create the Windows executable file of my project, but I don't want to share the source code.
I use Linux, but py2exe doesn't work on Linux. Is there a py2exe alternative for Linux?


Solution

  • I'd use cx_freeze.

    I've tried py2exe, and it doesn't handle dependencies as well as cx_freeze. Best of all, it's cross-platform! I've made Windows and Linux binaries with it, so I can confirm it works properly.

    Here's a little tutorial to get you started: http://www.blog.pythonlibrary.org/2010/08/12/a-cx_freeze-tutorial-build-a-binary-series/.