Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Distributing python on Mac, Linux, and Windows using cx_freeze: can I generate all apps from one platform?

I'm setting up a scripted build of a cross-platform python app (Python 3) and I'd like to create all the distributables from linux. Is that possible?

like image 864
Drew Avatar asked Sep 19 '11 04:09

Drew


People also ask

What version of Python does cx_Freeze run on?

I use python3 (3.x). cx_Freeze works on Windows, Mac and Linux, but on each platform it only makes an executable that runs on that platform. So if you want to freeze your program for Windows, freeze it on Windows; if you want to run it on Macs, freeze it on a Mac.

What is the best way to freeze a Python program?

With Python 2.7, Py2exe is a great choice & for Python 3, cx_freeze works quite nicely. CX_Freeze | .py to .exe cx_Freeze is a set of scripts and modules for freezing Python scripts into executables, in much the same way that py2exe and py2app do.

How to pack and distribute Python apps for Windows desktop?

Create a simple project called boneca Build an MSI installer using Cx_freeze Add an Auto-update feature to the project, using Esky Show how to use Inno Setup to build a more powerful and custom installer In the end will be able to pack and distribute Python apps for windows desktop in an easy way.

How to install and use cx_Freeze?

cx_Freeze is very easy to install and use. The best way to install it inside a virtualenvironment use the command To install it without the virtualenvironment How to create an executable? There are 3 ways but 2 are mostly used methods. The first method is to use the command line cx_script command to generate an executable.


1 Answers

Short answer: no

I've been doing something similiar recently (using cx_Freeze with Python 3). If you set up Python inside Wine, you can generate a Windows build, but I had to copy some DLLs in before it worked properly (cx_Freeze calls a Windows API function that's not implemented in Wine). I've not run into any way of packaging applications for Macs without actually having a Mac.

Perhaps someone should set up a community build service so people could build distributables for different platforms for each other. That doesn't get round the problem of testing, though.

like image 129
Thomas K Avatar answered Sep 28 '22 16:09

Thomas K