Go to file
Alexander Larsson ccdc551b44 Update .gitignore 2017-08-25 09:41:39 +02:00
buildutil spelling: progressive 2016-05-27 06:45:16 +00:00
ci ci/build.sh: also install git 2017-08-14 16:05:59 +02:00
doc Delete non-builder files 2017-08-25 09:27:42 +02:00
libglnx@e226ccf691 Update to latest libglnx (and fix some callers) 2017-08-18 15:34:29 +02:00
m4 Import ostree's compiler warnings, fix up callers 2017-03-27 10:42:36 +02:00
src Move common/flatpak-utils.* to src/builder-flatpak-utils.* 2017-08-25 09:36:49 +02:00
tests Delete non-builder files 2017-08-25 09:27:42 +02:00
.gitignore Update .gitignore 2017-08-25 09:41:39 +02:00
.gitmodules Delete non-builder files 2017-08-25 09:27:42 +02:00
.papr.yml ci: bump tests to use F26 host & container 2017-08-14 16:05:59 +02:00
COPYING Add COPYING to reflect license headers 2015-03-31 15:36:29 +01:00
Makefile.am Move common/flatpak-utils.* to src/builder-flatpak-utils.* 2017-08-25 09:36:49 +02:00
NEWS Update NEWS for release 2017-08-21 18:15:18 +02:00
README.md Fixed README.md 2017-08-22 10:52:33 -05:00
acinclude.m4 Add AX_COMPARE_VERSION to acinclude.m4 2016-09-09 10:03:27 +02:00
autogen.sh Delete non-builder files 2017-08-25 09:27:42 +02:00
configure.ac The module is flatpak-builder, not flatpak 2017-08-25 09:40:42 +02:00
flatpak.png Add the logo to README.md 2016-06-02 18:05:22 -04:00
uncrustify.cfg Add uncrustify config 2016-05-06 15:27:19 +02:00
uncrustify.sh Add uncrustify config 2016-05-06 15:27:19 +02:00

README.md

Flatpak icon

Flatpak is a system for building, distributing and running sandboxed desktop applications on Linux.

See http://flatpak.org/ for more information.

Read documentation for the flatpak commandline tools and for the libflatpak library API.

INSTALLATION

Flatpak uses a traditional autoconf-style build mechanism. To build just do

 ./configure [args]
 make
 make install

Most configure arguments are documented in ./configure --help. However, there are some options that are a bit more complicated.

Flatpak relies on a project called Bubblewrap for the low-level sandboxing. By default, an in-tree copy of this is built (distributed in the tarball or using git submodules in the git tree). This will build a helper called flatpak-bwrap. If your system has a recent enough version of Bubblewrap already, you can use --with-system-bubblewrap to use that instead.

Bubblewrap can run in two modes, either using unprivileged user namespaces or setuid mode. This requires that the kernel supports this, which some distributions disable. For instance, Arch completely disables user namespaces, while Debian supports unprivileged user namespaces, but only if you turn on the kernel.unprivileged_userns_clone sysctl.

If unprivileged user namespaces are not available, then Bubblewrap must be built as setuid root. This is believed to be safe, as it is designed to do this. Any build of Bubblewrap supports both unprivileged and setuid mode, you just need to set the setuid bit for it to change mode.

However, this does complicate the installation a bit. If you pass --with-priv-mode=setuid to configure (of Flatpak or Bubblewrap) then make install will try to set the setuid bit. However that means you have to run make install as root. Alternatively, you can pass --enable-sudo to configure and it will call sudo when setting the setuid bit. Alternatively you can enable setuid completely outside of the installation, which is common for example when packaging Bubblewrap in a .deb or .rpm.

There are some complications when building Flatpak to a different prefix than the system-installed version. First of all, the newly built Flatpak will look for system-installed flatpaks in $PREFIX/var/lib/flatpak, which will not match existing installed flatpaks. You can use --with-system-install-dir=/var/lib/flatpak to make both installations use the same location.

Secondly, Flatpak ships with a root-privileged policykit helper for system-installation, called flatpak-system-helper. This is dbus activated (on the system-bus) and if you install in a non-standard location it is likely that this will not be found by dbus and policykit. However, if the system installation is synchronized, you can often use the system installed helper instead - at least if the two versions are close in versions.