libbrillo: Add MountNamespaceInterface and UnownedMountNamespace

Add the interface class MountNamespaceInterface and the
UnownedMountNamespace class which only has one method to return the
namespace path.

Only one process should have the ability to create MountNamespace at a
given path. However more than one processes need to enter this namespace.
Thus the path of the namespace is needed by multiple independent
packages. The interface class is created for this need.

BUG=chromium:1052197
TEST=FEATURES=test emerge-betty libbrillo

Change-Id: I9892da25c5ff9614bc3574e9f7e589fa059f81c6
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/2160141
Tested-by: Betul Soysal <betuls@google.com>
Commit-Queue: Betul Soysal <betuls@google.com>
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Cr-Mirrored-From: https://chromium.googlesource.com/chromiumos/platform2
Cr-Mirrored-Commit: f8c0d1f43c844ac26f655d3724780c1022fbb4be
1 file changed
tree: 1c075f705b8e156e070ce519ff55a9dab70aef20
  1. brillo/
  2. install_attributes/
  3. policy/
  4. BUILD.gn
  5. libpolicy.ver
  6. OWNERS
  7. PRESUBMIT.cfg
  8. README.md
  9. testrunner.cc
README.md

libbrillo: platform utility library

libbrillo is a shared library meant to hold common utility code that we deem useful for platform projects. It supplements the functionality provided by libbase/libchrome since that project, by design, only holds functionality that Chromium (the browser) needs. As a result, this tends to be more OS-centric code.

AOSP Usage

This project is also used by Update Engine which is maintained in AOSP. However, AOSP doesn't use this codebase directly, it maintains its own libbrillo fork.

To help keep the projects in sync, we have a gsubtree set up on our GoB: https://chromium.googlesource.com/chromiumos/platform2/libbrillo/

This allows AOSP to cherry pick or merge changes directly back into their fork.