Flatpak provides features for application sandboxing and distribution.
Applications for the phone will be distributed as flatpaks – packages that can
be distributed via repositories. Documentation for the
flatpak tool and
flatpak-builder wrapper can be found in the Flatpak documentation.
Versions of these tools provided with modern GNU/Linux distributions should be
sufficient. Debian-based distributions provide packages called
flatpak-builder that can be installed with the following command:
sudo apt -y install flatpak flatpak-builder
flatpak-builder tool is used to build flatpaks; the
flatpak tool is
used to install and uninstall flatpaks, manage repositories and keep track of
the applications that are available to run.
Building and testing applications locally is straightforward. Cross-compiling applications with Flatpak requires the use of the qemu user mode emulation binaries. On Debian-based platforms these can be installed with the following command:
sudo apt -y install qemu-user-static
This package, or the equivalent on other platforms, is necessary if you want to build applications for the Librem 5 on systems with a processor architecture different to that used by the phone (aarch64).