Skip to content

Investigate Freedesktop SDK #992

Open

Description

@probonopd

Investigate Freedesktop SDK to build what goes into an AppImage.

Freedesktop SDK claims to be distribution agnostic, desktop environment agnostic, and package format agnostic:

agnostic

  • So how do we compile something using Freedesktop SDK without Flatpak? Let's start with GNU Hello https://www.gnu.org/software/hello/
  • Which version of Freedesktop SDK do we need to use so that binaries compiled using it will run with the Platform "runtime" that comes by default with all still-supported distributions? (I mean, not a real Freedesktop runtime but the OS itself.)
  • In case we would allow a Freedesktop Platform (runtime) to be required to run an AppImage, how large would the recent Freedesktop Platform (runtime) be (as a squashfs image)? --> mksquashfs /var/lib/flatpak/runtime/org.freedesktop.Platform/x86_64/19.08/active/files/ org.freedesktop.Platform_19.08_x86_64 209 MB, Sdk 520 MB
  • Why is Snappy not using Freedesktop Platforms but their own Base Snaps?
  • What would the advantage be to use Freedesktop Platforms rather than Base Snaps?
  • How often do new versions of the Freedesktop Platform appear? (Hopefully only once after every few years!)
  • Is there a backward binary compatibility guarantee, e.g., saying that binaries compiled with Freedesktop SDK version i will run on Freedesktop Platform i, i+1, ... i+n? What is n?
  • What is org.freedesktop.Platform.Compat? it is undocumented on http://docs.flatpak.org/en/latest/available-runtimes.html

Activity

  1. probonopd commented on Sep 15, 2019

    @probonopd
    MemberAuthor

    Note to self:

    sudo add-apt-repository -y ppa:alexlarsson/flatpak
    sudo apt update
    
    sudo apt-get -y install flatpak
    flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
    flatpak install flathub org.freedesktop.Sdk//19.08
    flatpak install flathub org.freedesktop.Platform//19.08
    mksquashfs /var/lib/flatpak/runtime/org.freedesktop.Platform/x86_64/19.08/active/files/ org.freedesktop.Platform_19.08_x86_64.sqs
    

    Further investigation blocked because I can't get Flatpak to work, as has been my problem since its inception.

  2. probonopd commented on Sep 15, 2019

    @probonopd
    MemberAuthor
  3. adds68 commented on Sep 24, 2019

    @adds68
    • So how do we compile something using Freedesktop SDK without Flatpak? Let's start with GNU Hello https://www.gnu.org/software/hello/
      
    • Which version of Freedesktop SDK do we need to use so that binaries compiled using it will run with the Platform "runtime" that comes by default with all still-supported distributions? (I mean, not a real Freedesktop runtime but the OS itself.)
      
      • I'm not to sure on this requirement, but we maintain backwards/forwards compatibility for 2 years with each release
    • In case we would allow a Freedesktop Platform (runtime) to be required to run an AppImage, how large would the recent Freedesktop Platform (runtime) be (as a squashfs image)? --> mksquashfs /var/lib/flatpak/runtime/org.freedesktop.Platform/x86_64/19.08/active/files/ org.freedesktop.Platform_19.08_x86_64 209 MB, Sdk 520 MB
      
      • seems you have already done the calculations here, but these seems correct?
    • Why is Snappy not using Freedesktop Platforms but their own Base Snaps?
      
    • What would the advantage be to use Freedesktop Platforms rather than Base Snaps?
      
      • We are a distribution agnostic runtime and are built entirely from source, with 19.08 being self bootstrapped.
    • How often do new versions of the Freedesktop Platform appear? (Hopefully only once after every few years!)
      
    • Is there a backward binary compatibility guarantee, e.g., saying that binaries compiled with Freedesktop SDK version i will run on Freedesktop Platform i, i+1, ... i+n? What is n?
      
      • see above ^
    • What is org.freedesktop.Platform.Compat? it is undocumented on http://docs.flatpak.org/en/latest/available-runtimes.html
      
      • It's a 32 bit extension, for example which is used by Steam to support old games

    I hope these answer some of your questions, i would encourage you to ask some questions in the channel on freenode (#freedesktop-sdk) also as some developers are more active there than on Gitlab.

  4. probonopd commented on Sep 25, 2019

    @probonopd
    MemberAuthor

    Thank you very much for your answers @weTrain. Highly appreciated.

    Especially the page you linked to,

    The aim is to continuously update the runtime while keeping the ABI backward and forward compatible for as long as reasonably possible.

    For the base runtime we expect multiple years of ABI stability to be feasible (parallel installation of multiple versions may occasionally be necessary for a few libraries). When an ABI break is required (e.g., C++ ABI break), the plan is to keep the previous branch maintained (at least for security updates) for two years.

    is highly relevant to us. Will have to think about the implications a bit and discuss.

    Would you happen to have a "hello world" example without BuildStream? (Nothing against it, in fact I heard about it today for the first time, but a lot of our users want to build on OBS, Travis CI, GitLab CI, Azure Pipelines, Jenkins, local machines, etc. and are not ready to jump to an entire new build setup)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions