HiveBrain v1.2.0
Get Started
← Back to all entries
snippetpythonCritical

How can I make a Python script standalone executable to run without any dependency?

Submitted by: @import:stackoverflow-api··
0
Viewed 0 times
howpythonmakescriptruncananywithoutstandalonedependency

Problem

I'm building a Python application and don't want to force my clients to install Python and modules.

So, is there a way to compile a Python script to be a standalone executable?

Solution

You can use py2exe as already answered and use Cython to convert your key .py files in .pyc, C compiled files, like .dll in Windows and .so on Linux.

It is much harder to revert than common .pyo and .pyc files (and also gain in performance!).

Context

Stack Overflow Q#5458048, score: 309

Revisions (0)

No revisions yet.