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

Install Lutris as a Flatpak #329

Closed
LukeShortCloud opened this issue Apr 20, 2022 · 15 comments
Closed

Install Lutris as a Flatpak #329

LukeShortCloud opened this issue Apr 20, 2022 · 15 comments
Assignees
Labels
enhancement New feature or request upstream Waiting on an upstream code merge.

Comments

@LukeShortCloud
Copy link
Owner

Lutris developers are now priorotizing Flatpak support now that they got a Steam Deck about a month ago. It is still in-development. Once it reaches the stable Flathub repository, we should consider switching over to that.

https://www.gamingonlinux.com/2022/04/game-manager-lutris-continues-flatpak-improvements/

I also want to wait until Steam is Flatpak ready as those improvements may be related: #328

Related issue (winesapOS switching to using Flatpaks): #300

@LukeShortCloud LukeShortCloud added the enhancement New feature or request label Apr 20, 2022
@LukeShortCloud LukeShortCloud added the upstream Waiting on an upstream code merge. label Apr 29, 2022
@LukeShortCloud
Copy link
Owner Author

Reports from users suggest that Wine works and most of the lingering issues with the Flatpak are regarding game console emulators which is not a focus for us currently.

@LukeShortCloud LukeShortCloud modified the milestones: 3.3.0 - The Major Upgrade Update, The Steam Flatpak Update Jun 25, 2022
@soredake
Copy link
Contributor

soredake commented Jul 2, 2022

@soredake
Copy link
Contributor

flathub/net.lutris.Lutris#53 are solved now

@LukeShortCloud
Copy link
Owner Author

@soredake That's great news! Having all of the required dependencies (i.e., both the 64-bit and now also the 32-bit libraries) of Lutris is a huge step in the right direction.

All that's left now is (1) performance issues due to seccomp and (2) AppImage/FUSE compatibility issues. Regarding # 1, we can make a desktop shortcut for Steam that runs it without seccomp. Regarding # 2, there's no workaround and I'm not sure if that will ever be fixed. That sounds like a bigger engineering effort from the Flatpak developers.

@soredake
Copy link
Contributor

soredake commented Sep 1, 2022

About seccomp, flathub/com.valvesoftware.Steam#810 (comment), let's think performance issues are from mesa, not seccomp. Regarding fuse, appimage games can run in flatpak without fuse using --appimage-extract-and-run, dunno if they will be unpacked every time when running appimage with this option though, another option is to unpack appimage in lutris installer with --appimage-extract, the last option is to wait ~5 years for flatpak to implement this flatpak/xdg-desktop-portal#695

@LukeShortCloud
Copy link
Owner Author

That's great that seccomp was not the issue! The reporter mentioned that it was because they were on an old version of Mesa (and presumably were able to update to a newer version that's faster?). One less thing for us to worry about.

You're absolutely right, it sounds like we would have to wait a long time for Flatpak to have proper FUSE support. I doubt many users will even be installing AppImage games. Either way, we can at least document the --appimage-extract-and-run workaround.

It sounds like everything upstream is in a good state for us to seriously consider switching to Flatpak versions of these applications. I've been using Lutris as a Flatpak on my Steam Deck for months now and it's been great. Controller support and all.

@soredake
Copy link
Contributor

@LukeShortCloud when you are going to document this parameter, also mention that it's better to set NO_CLEANUP=1 to prevent cleaning up extracted appimage contents after exit.

@LukeShortCloud
Copy link
Owner Author

Acknowledged. For Lutris, I'll document that Flatpaks need to (1) be passed the --appimage-extract-and-run parameter and (2) should run with the NO_CLEANUP=1 environment variable for the best results.

@soredake
Copy link
Contributor

soredake commented Sep 27, 2022

Actually, there is no need to document this, you can just add flatpak --user override --env=APPIMAGE_EXTRACT_AND_RUN=1 net.lutris.Lutris to post-install script and that's all, some appimages will work inside lutris (i decided not to use NO_CLEANUP as i realized it will leave extracted contents forever clogging /tmp).

I've tested minetest appimage, and it works, osu!lazer appimage is not (missing xdg-icon-resource command), i will report this to lutris flatpak bugtracker later, another one tested is openra appimage, it crashes in
x11.txt but works in wayland.

@soredake
Copy link
Contributor

There are many appimage based installers on lutris https://lutris.net/games?page=1&paginate_by=25&ordering=name&q=appimage&search-installers=on, some of them will need adjustments (example), some deps may need to be added to lutris flatpak to satisfy needs of appimages. Another problem that there can be big appimages (>1gb), as they will be unpacked to /tmp by default, those who have 8gb or less will lose usable considerable amount of usable ram, this can be workarounded by setting TMPDIR=~/<non tmpfs directory> NO_CLEANUP=1.

@LukeShortCloud
Copy link
Owner Author

Even better! I didn't know it was possible to permanently set environment variables in a Flatpak with overrides.

Our /tmp directory was recently switched from ramfs to tmpfs. That was actually to support AppImages. Now that storage will use RAM + swap (instead of RAM only), it slightly helps in terms of storage needs. The swap size is configured by end-users during our first-time setup with a suggested size of 8 GB. It won't hurt for me to add some documentation about the temporary files either way.

Thanks for helping test these things and getting upstream reports open to further improve the wider Linux community!

@soredake
Copy link
Contributor

soredake commented Oct 6, 2022

I decided to submit pr with this env to lutris flatpak directly: flathub/net.lutris.Lutris#300

@soredake
Copy link
Contributor

Pr merged to lutris flatpak.

@LukeShortCloud
Copy link
Owner Author

@soredake Thanks for all of your hard working helping out with the winesapOS project and, even more importantly, the wider upstream Flatpak community!

I wanted to extend an invite and see if you'd be interested in doing some freelance or even full-time work regarding making a Linux gaming OS. If you're interested, e-mail me at ekultails a.t. gmail.com (it's the same e-mail I use here on GitHub) and I can fill you in with more details.

Either way, hoping you are well and still having fun in the Linux gaming community! :-)

@LukeShortCloud LukeShortCloud modified the milestones: 4.3.0 - The Gaming Flatpaks Update, 4.1.0 - The KDE Plasma 6 Update Apr 29, 2024
@LukeShortCloud LukeShortCloud self-assigned this Apr 29, 2024
LukeShortCloud added a commit that referenced this issue Apr 29, 2024
Use the Flatpak instead of the native application.

Resolves #329
@LukeShortCloud
Copy link
Owner Author

A lot of the original concerns with the Lutris Flatpak have been addressed. I will go ahead and switch winesapOS over to it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request upstream Waiting on an upstream code merge.
Projects
None yet
Development

No branches or pull requests

2 participants