MegaGlest Forum

MegaGlest => MegaGlest => Topic started by: andy_5995 on 5 February 2019, 20:54:36

Title: Installing MegaGlest using the Flatpak
Post by: andy_5995 on 5 February 2019, 20:54:36
I tried out the MegaGlest Flatpak (https://flathub.org/apps/details/org.megaglest.MegaGlest) last night.

Worked well, but a couple things worth noting:

1. It doesn't use an existing $HOME/.megaglest folder for user data. The path is $HOME/.var/app/org.megaglest.MegaGlest/.megaglest
2. It doesn't come with 7z and there's a warning when I enter the mod center that files can't be downloaded or installed.
3. MG doesn't see a mod if it's being pointed to with a symlink (only tried with .megaglest/techs
Title: Re: Installing MegaGlest using the Flatpak
Post by: jammyjamjamman on 27 March 2019, 01:35:38
I tried out the MegaGlest Flatpak (https://flathub.org/apps/details/org.megaglest.MegaGlest) last night.

Worked well, but a couple things worth noting:

1. It doesn't use an existing $HOME/.megaglest folder for user data. The path is $HOME/.var/app/org.megaglest.MegaGlest/.megaglest
2. It doesn't come with 7z and there's a warning when I enter the mod center that files can't be downloaded or installed.
3. MG doesn't see a mod if it's being pointed to with a symlink (only tried with .megaglest/techs

I think points 1 and 3 are related to this: http://docs.flatpak.org/en/latest/conventions.html#xdg-base-directories (http://docs.flatpak.org/en/latest/conventions.html#xdg-base-directories)
Basically, flatpak is sandboxing applications (or trying to*), and this means giving applications their own directory to write to and not giving them access to any other folders. This means megaglest user files are being stored in a special xdg-spec directory. This is to avoid nasty situations such as... https://www.reddit.com/r/linux/comments/2sjjr3/warning_to_steam_users_dont_try_to_move_your/ (https://www.reddit.com/r/linux/comments/2sjjr3/warning_to_steam_users_dont_try_to_move_your/).

Flatpak is probably also blocking symlinks in these directories, because otherwise applications can just jump out of the sandbox (e.g. by writing their own symlinks). The only solution to this is to give flatpak-megaglest-build home directory privileges (http://docs.flatpak.org/en/latest/sandbox-permissions.html) (which standard megaglest has anyway).

*Here's someone else's opinions on flatpak's attempts to sandbox: https://flatkill.org/ (https://flatkill.org/)