2

I have a Python application built with PyQt5. My current OS is Windows 11 and I'm able to distribute my software to Windows users using PyInstaller and Inno Setup (to create the installer). However, I would like to distribute it to MacOS and Linux users too.

From PyInstaller's documentation:

PyInstaller is tested against Windows, Mac OS X, and GNU/Linux. However, it is not a cross-compiler: to make a Windows app you run PyInstaller in Windows; to make a GNU/Linux app you run it in GNU/Linux, etc. PyInstaller has been used successfully with AIX, Solaris, FreeBSD and OpenBSD but testing against them is not part of our continuous integration tests.

As you can see, PyInstaller is not cross-compiler. So, I'm wondering the best way to distribute my software to all OS using PyInstaller. Actually, I'm able to create .deb using WSL2, but no clues for .dmg for MacOS.

I've already read that I can use virtual machines to achieve this, but I would like some alternatives (maybe Docker?)

Thanks!

Leo Eiji
  • 54
  • 6
  • Docker is a bad choice for distributing graphical applications: the setup to run it is very complex and platform-specific, you generally need administrator-equivalent permissions to run a container, and the container won't have access to the user's files and preferences. I'd prefer the native Python packaging system over anything you suggest here. – David Maze Mar 23 '22 at 15:31
  • 1
    I must have expressed myself badly. The idea was using Docker to run PyInstaller over my application in different OS. For example, run a MacOS in a Docker, install PyInstaller, get the application files, bundle them and export the `.dmg` (same for linux). – Leo Eiji Mar 23 '22 at 15:39

0 Answers0