[Testers wanted] Oolite as a flatpak

For discussion of ports to POSIX based systems, especially using GNUStep.

Moderators: another_commander, winston, Getafix

Post Reply
pritter
Average
Average
Posts: 8
Joined: Fri Jun 15, 2018 7:50 pm

[Testers wanted] Oolite as a flatpak

Post by pritter »

Hi Oolite universe,

I recently started exploring immutable operating systems (like Project Atomic) and flatpak as a distribution method. I thought, it would be nice to also play Oolite on Atomic Workstation, so I started investigation ways to package oolite as a flatpak. Since some people asked for a flatpak'ed version of Oolite on github and in the forum, I am happy to share the results of what I have done lately.

Of course, I am still in the early stages, so nothing is as polished as you would expect it to be, yet. I am going to use this thread to report the state and progress of my efforts. You can help by testing the flatpak'ed version and report issues as answer to this post or using the issue tracker on gitlab. Of course, other contributions are welcome, too.

Current state and roadmap

Packaging and distribution
  • [X] Build a flatpak of Oolite x86_64
  • [X] Automate build of the flatpak'ed version
  • [X] Create a repository for the flatpak
  • [X] Host the repository somwhere, until the long term strategy has been determined
  • [X] GPG-sign the repository
  • [X] Add nightlies to the flatpak repo
  • [ ] Add x86 version to the flatpak repo
Polishing
  • [X] Add appdata
  • [X] Add icon
  • [X] Add desktop file
  • [X] Add screenshots
  • [ ] Determine further requirements of flathub to get oolite in their repo
Tested on
  • [X] Fedora Atomic Workstation
  • [ ] EndlessOS
  • [X] Fedora 27
  • [ ] Fedora 26/28
  • [ ] Ubuntu
  • [ ] Debian

Known issues

Can't find libGLU.so.1
There seems to be an issue with the org.freedesktop.Platform package. It's under investigation.
Update: this issue has been resolved, please use the latest version

How to use / test

Update Jul-09-2018: Using the flatpakref
This is the easiest variant. To install, just use the following command in a terminal:
flatpak install https://pritter.fedorapeople.org/org.oolite.Oolite.flatpakref

Update Jul-23-2018:
The nightly version can be installed via flatpak install https://pritter.fedorapeople.org/org.oolite.OoliteNightly.flatpakref

You can then start the game via the launcher in your application menu. Alternatively, you can use this command: flatpak run org.oolite.Oolite//master or flatpak run org.oolite.Oolite//nightly

Update Jul-09-2018: Using the repo
The Oolite Flatpak is now available in a repo.
You have to add the flathub repo first. Please refer to their docs on how to do that.

You can then add the repo and install oolite with the following commands:
flatpak remote-add --if-not-exists pritter https://pritter.fedorapeople.org/.flatpakrepo
flatpak install pritter org.oolite.Oolite//master or flatpak install pritter org.oolite.Oolite//nightly

To start, use the launcher or the command mentioned in the last paragraph.

Manual Installation
Update Jul-09-2018: If you want to use the latest builds, you have to manually install the releases from gitlab. The flatpak file for the stable version can be found here. The nightly build is here

You have to add the flathub repo first. Please refer to their docs on how to do that. You will also need the org.freedesktop.Platform flatpak from flathub (flatpak install flathub org.freedesktop.Platform).

Note: add --user to flatpak install for a per user installation

To install: flatpak install oolite.flatpak or flatpak install oolite-nightly.flatpak
To run: flatpak run org.oolite.Oolite or flatpak run org.oolite.OoliteNightly
To uninstall: flatpak uninstall org.oolite.Oolite or flatpak uninstall org.oolite.OoliteNightly

If you are adventurous, you can download the repo directory in the linked Results of the automated build process below. The steps to install and run are

flatpak remote-add --no-gpg-verify oolite-repo repo
flatpak install oolite-repo org.oolite.Oolite or flatpak install oolite-repo org.oolite.OoliteNightly
flatpak run org.oolite.Oolite or flatpak run org.oolite.OoliteNightly


Links and references

Blog post explaining motivation and technical details
Gitlab repository (issue tracker, code contributions)
Results of the automated build process (stable)
Results of the automated build process (nightly)
Last edited by pritter on Mon Jul 23, 2018 7:22 pm, edited 4 times in total.
User avatar
Getafix
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 979
Joined: Tue Apr 01, 2008 12:55 pm
Location: A small ice asteroid, orbiting Oresrati in Galaxy 8 (a.k.a. northwest Armorica).
Contact:

Re: [Testers wanted] Oolite as a flatpak

Post by Getafix »

Hi pritter!

Let's make sure that the flatpak release is as polished as possible and thoroughly tested before discussing to go public on flathub.
Furthermore, I would like to consult with the Oolite Elders on probable aspects of this perspective that, perhaps, we miss to consider.

On the "Testing" front, I just got my hands on a misplaced storage having my various Linux distros VM's.
I am about to start testing. I expect to have some feedback in a couple of days.
"Any sufficiently advanced information is indistinguishable from noise." [Newman, Lachmann, Moore]
pritter
Average
Average
Posts: 8
Joined: Fri Jun 15, 2018 7:50 pm

Re: [Testers wanted] Oolite as a flatpak

Post by pritter »

Sorry if I caused some misunderstanding. The requirement to meet flathubs standards is more like a quality assurance goal than an actual plan to submit Oolite to flathub. The major requirement would be to have a clean, self contained build wihout some of the hacks currently needed to make it work. That would clearly be benefitial for any form of distribution, not only for flathub.

That said, I would not submit Oolite for inclusion in the flathub repo without your consent. I regard that as an longterm goal. The next step for me would be to create a repo on a webspace for further testing. Maybe there will be an official repo on oolite.org next, maybe it's going to be flathub. I think, that will be discussed, when everything is working fine.
User avatar
Getafix
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 979
Joined: Tue Apr 01, 2008 12:55 pm
Location: A small ice asteroid, orbiting Oresrati in Galaxy 8 (a.k.a. northwest Armorica).
Contact:

Re: [Testers wanted] Oolite as a flatpak

Post by Getafix »

pritter wrote: Thu Jul 05, 2018 8:07 pm
Sorry if I caused some misunderstanding...
...That said, I would not submit Oolite for inclusion in the flathub repo without your consent....
No misunderstanding at all.
We are cool, bro! 8)
"Any sufficiently advanced information is indistinguishable from noise." [Newman, Lachmann, Moore]
User avatar
Getafix
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 979
Joined: Tue Apr 01, 2008 12:55 pm
Location: A small ice asteroid, orbiting Oresrati in Galaxy 8 (a.k.a. northwest Armorica).
Contact:

Re: [Testers wanted] Oolite as a flatpak

Post by Getafix »

Hi pritter!

I started testing on a lubuntu 18.04 vanilla installation. (more distros will follow)
You have already done a great work with flatpak and I am very optimistic for what is coming next. :D
Here follow some observations to continue.

1. The repo methodology was used for this first test (the rest methodologies will be tested too). (a) Please update the first post to indicate that adding the default repo is mandatory to allow freedesktop runtime (180MB) dependency auto-resolution.

Code: Select all

$ flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
(b) What is the freedesktop runtime used for in Oolite flatpak?


2. The app installation command complained as shown below

Code: Select all

$ flatpak install pritter org.oolite.Oolite/master
error: Error searching remote pritter: Can't find ref org.oolite.Oolite/master
The app installation syntax that actually worked was

Code: Select all

$ flatpak install pritter org.oolite.Oolite/x86_64/master
or

Code: Select all

$ flatpak install pritter org.oolite.Oolite
Update the first post accordingly.


3. The desktop menu launcher did not appear after the app was installed. Installing the oolite.org (own installer) made the desktop menu launcher to appear boasting both versions of Oolite. Rebooting the machine has also forced the desktop meny launcher to appear. Please, note that lubuntu was a vanilla installation with no initial "Games" desktop menu entry and that own packager has no such issue. Is there a known behavior/issue of flatpak on that?

4. Please update the desktop launchers to display "Oolite (flatpak)" and "Oolite-trunk (flatpak)" respectively.

5. It seems that to get flatpak apps, built with OpenGL, to work with proprietary Nvidia graphics drivers, one can only hope that the runtime for the installed version of Nvidia drivers is available on FlatHub. (a) This means that, if the Ooliter installs the latest Nvidia proprietary drivers, playing Oolite will not be possible till the relevant runtime makes it onto FlatHub, right? :!:
(b) Was this the issue you faced with the missing libGLU.so.1?

6. Oolite is using command line options (e.g. --novsync, --nosound, --nosplash, etc.). Would it be possible to add the possibiity to pass command line options at run-time? Browsing the Oolite flatpak installation directory structure I stumbled upon this

Code: Select all

$ cat /var/lib/flatpak/app/org.oolite.Oolite/current/active/export/bin/org.oolite.Oolite 
#!/bin/sh
exec /usr/bin/flatpak run --branch=master --arch=x86_64 org.oolite.Oolite "$@"
$
It seems that it is ready to handle command line options. However, the start.sh script, found in the repo, has stripped the "$@".
"Any sufficiently advanced information is indistinguishable from noise." [Newman, Lachmann, Moore]
pritter
Average
Average
Posts: 8
Joined: Fri Jun 15, 2018 7:50 pm

Re: [Testers wanted] Oolite as a flatpak

Post by pritter »

Getafix wrote: Tue Jul 10, 2018 10:28 pm
Hi pritter!

I started testing on a lubuntu 18.04 vanilla installation. (more distros will follow)
You have already done a great work with flatpak and I am very optimistic for what is coming next. :D
Here follow some observations to continue.

1. The repo methodology was used for this first test (the rest methodologies will be tested too). (a) Please update the first post to indicate that adding the default repo is mandatory to allow freedesktop runtime (180MB) dependency auto-resolution.

Code: Select all

$ flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
(b) What is the freedesktop runtime used for in Oolite flatpak?
As far as I know, the usage of a runtime is mandatory. The freedesktop runtime is the most lightweight runtime of the 3 available. It also provides some extensions (see below).

Getafix wrote: Tue Jul 10, 2018 10:28 pm
2. The app installation command complained as shown below

Code: Select all

$ flatpak install pritter org.oolite.Oolite/master
error: Error searching remote pritter: Can't find ref org.oolite.Oolite/master
The app installation syntax that actually worked was

Code: Select all

$ flatpak install pritter org.oolite.Oolite/x86_64/master
or

Code: Select all

$ flatpak install pritter org.oolite.Oolite
Update the first post accordingly.
Thanks, done
Getafix wrote: Tue Jul 10, 2018 10:28 pm
3. The desktop menu launcher did not appear after the app was installed. Installing the oolite.org (own installer) made the desktop menu launcher to appear boasting both versions of Oolite. Rebooting the machine has also forced the desktop meny launcher to appear. Please, note that lubuntu was a vanilla installation with no initial "Games" desktop menu entry and that own packager has no such issue. Is there a known behavior/issue of flatpak on that?
That confirms my observations. I don't see desktop items appearing until next login. Other flatpaks don't show that behavior, going to investigate.
Getafix wrote: Tue Jul 10, 2018 10:28 pm
4. Please update the desktop launchers to display "Oolite (flatpak)" and "Oolite-trunk (flatpak)" respectively.
Will be done.
Getafix wrote: Tue Jul 10, 2018 10:28 pm
5. It seems that to get flatpak apps, built with OpenGL, to work with proprietary Nvidia graphics drivers, one can only hope that the runtime for the installed version of Nvidia drivers is available on FlatHub. (a) This means that, if the Ooliter installs the latest Nvidia proprietary drivers, playing Oolite will not be possible till the relevant runtime makes it onto FlatHub, right? :!:
The relevant drivers are available as an extension to the freedesktop runtime. You can try flatpak install flathub org.freedesktop.Platform.GL and then use tab completion to show the available extensions.
Getafix wrote: Tue Jul 10, 2018 10:28 pm
(b) Was this the issue you faced with the missing libGLU.so.1?
Maybe, I just compiled ligGLU from source and bundled it with oolite to make it work. Going to investigate, whether using the extensions would be the cleaner approach.
Getafix wrote: Tue Jul 10, 2018 10:28 pm
6. Oolite is using command line options (e.g. --novsync, --nosound, --nosplash, etc.). Would it be possible to add the possibiity to pass command line options at run-time? Browsing the Oolite flatpak installation directory structure I stumbled upon this

Code: Select all

$ cat /var/lib/flatpak/app/org.oolite.Oolite/current/active/export/bin/org.oolite.Oolite 
#!/bin/sh
exec /usr/bin/flatpak run --branch=master --arch=x86_64 org.oolite.Oolite "$@"
$
It seems that it is ready to handle command line options. However, the start.sh script, found in the repo, has stripped the "$@".
Should be an easy fix, going to implement that


Since the build of the repo is not automated yet, it could take some time for the changes to arrive (that is, until I have time to gpg-sign and rsync the repo). If you added the repo, issuing flatpak update should receiver the latest version.
pritter
Average
Average
Posts: 8
Joined: Fri Jun 15, 2018 7:50 pm

Re: [Testers wanted] Oolite as a flatpak

Post by pritter »

I have updated the repo to include both, the main version (master) and the nightly version (nightly). It seems, that you can not have both icons at the same time, although both versions can be installed in parallel. I am going to investigate, whether that's because they are named alike.

When installing oolite using the method descibed in Update Jul-09-2018: Using the repo, the icon appears in the menu instantly. When using the flatpakref, it won't (you have to log off and log in again).

The other issues should have been adressed.

Next steps:
  • investigate icon issue
  • investigate org.freedesktop.Platform.GL and libGLU
Post Reply