eg. change this:

runtime: org.gnome.Platform
runtime-version: "46"

to this:

runtimes:
  - org.gnome.Platform/46
  - org.gnome.Platform/45
  - org.freedesktop.Platform/20.08
  - org.kde.Platform/5.15

Many people complain about flatpaks taking up too much space. Allowing for more runtimes to be shared between apps would take up less space. However, this has been denied.

If I am an app developer and I know my app runs on several different runtimes, why shouldn’t I be able to specify all of those runtimes? Are there technical reasons why this is a bad idea?

EDIT: I mean a list of runtimes of which one must be installed, not a list of runtimes of which all must be installed.

  • LeFantome@programming.dev
    link
    fedilink
    arrow-up
    0
    ·
    edit-2
    5 months ago

    To answer the question of “why not” we only have to ask “what problem are Flatpaks meant to solve”:

    • Flatpaks allow applications to run identically on different distributions
    • Flatpaks reduce the burden for software providers having to support multiple environments

    The way that Flatpaks achieve these goals is precisely by mandating the environment that the application will execute within.

    Allowing the application to run in different environments goes directly against two core value propositions of the project.

    Being resource efficient is not one of the primary goals of Flatpak. Providing a consistent and deterministic execution context is.

    There is your answer.

    I am sympathetic to the question and the desire though. This is one of the reasons I do not like Flatpaks. Dragging in these big environments, and the duplication of resources, feels very wasteful to me. I would like them even less though if they did not even deliver on their core promises.

    Personally, I prefer Distrobox to Flatpak. At least I have more control. Arch / AUR in a distrobox will let you install pretty much any app on any distro. If the app you need only runs in one distro ( like Ubuntu ), you can create a Distrobox of that too.