How to compile the Python code to executable binary file like Linux C and Golang

Hi, how can I compile the python files to an executable binary file like Linux C and Golang in different platforms such as Linux, Mac and Windows?

1 Like

You’ll find plenty of details if you Google this yourself or even if you use the search on the forum here, but the more popular ways to do this which I’m aware of are with one of these tools:

I believe for PyInstaller you need to be working on the target platform (ie to produce a Windows .exe you need to do this on a Windows computer). Not sure if this is a requirement for the others but I suspect it may be too.

1 Like