Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Find a way to make Python apps portable #131

Closed
RazZziel opened this issue Apr 3, 2016 · 8 comments
Closed

Find a way to make Python apps portable #131

RazZziel opened this issue Apr 3, 2016 · 8 comments

Comments

@RazZziel
Copy link

RazZziel commented Apr 3, 2016

Python apps are not really portable: the python interpreter is needed in the host system, along with pygtk2, and weird stuff happens on many distros like Archlinux or OpenSUSE (see #6)

Possibilities:

@probonopd
Copy link
Member

Just putting python and its required modules and libs inside the AppImage should do the trick; as long as python is coming from an "old enough" host like CentOS 6.

@RazZziel
Copy link
Author

RazZziel commented Apr 5, 2016

Is there any example somewhere of a working AppImage that does it?

I tried to do it a while ago and failed (worked with perl and java, but not with python)

@mykolav
Copy link

mykolav commented Jun 3, 2016

Hi guys,

Admittedly, I haven't really had a chance to try it out.
But http://www.pyinstaller.org/ might be worth looking at.

The web page states that

Flexible packaging mode:
Single directory: build a directory containing an executable plus all the external binary modules (.dll, .pyd, .so) used by the program.
Single file: build a single executable file, totally self-contained, which runs without any external dependency.
Custom: you can automate PyInstaller to do whatever packaging mode you want through a simple script file in Python.

So, maybe, a python app can be first processed by PyInstaller in the single directory packaging mode. And then the generated directory can be packed as an AppImage.

@probonopd
Copy link
Member

This has been solved a long time ago, see https://github.com/probonopd/AppImages/blob/master/recipes/pythongtk3hello/Recipe for an example.

@probonopd
Copy link
Member

The currently recommended cause of action is to also bundle python itself, and either set binpatch: true or union: true in the .ymlfile.

@aarmea-butterfly
Copy link

Is there an up-to-date example of this? The link no longer exists.

@TheAssassin
Copy link
Member

@aarmea-butterfly you can try https://github.com/TheAssassin/linuxdeploy-plugin-conda, the latest and greatest way to make AppImages with Python. Not very well documented yet, so please visit us on IRC to allow us to guide you (#appimage on Freenode).

@deekb
Copy link

deekb commented Sep 28, 2022

Mu Editor looks like its a\Appimage functions this way: https://github.com/mu-editor/mu/releases/download/v1.1.1/Mu_Editor-1.1.1-x86_64.AppImage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants