Giter Site home page Giter Site logo

geometrics / flatpak Goto Github PK

View Code? Open in Web Editor NEW

This project forked from flatpak/flatpak

0.0 2.0 0.0 14.02 MB

Linux application sandboxing and distribution framework (formerly xdg-app)

Home Page: http://flatpak.org

License: GNU Lesser General Public License v2.1

Makefile 0.38% M4 1.43% PHP 0.52% C 90.92% Yacc 1.56% Shell 4.28% C++ 0.12% Python 0.79%

flatpak's Introduction

Flatpak icon

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

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

Community discussion happens in #flatpak on Freenode and on the mailing list.

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

Contributing

Flatpak welcomes contributions from anyone! Here are some ways you can help:

Hacking

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, Debian and Arch (linux kernel v4.14.5 or later), support user namespaces with the kernel.unprivileged_userns_clone sysctl enabled.

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.

flatpak's People

Contributors

alexlarsson avatar mwleeds avatar matthiasclasen avatar pwithnall avatar smcv avatar piotrdrag avatar asciiwolf avatar smspillaz avatar owtaylor avatar cgwalters avatar joaquimrocha avatar jsoref avatar cho2 avatar tingping avatar hughsie avatar ramcq avatar chergert avatar wjt avatar amigadave avatar yurchor avatar cosimoc avatar ebassi avatar gtristan avatar ssssam avatar rffontenelle avatar dbnicholson avatar hadess avatar danvratil avatar georgesstavracas avatar nazgul77 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.