The garnet, peridot, and topaz layers share some structure. This section documents these common aspects.
The public/
directory defines the public interface to this repository. Code
outside this repository should not depend on files outside of this directory.
This directory should not depend on any files in this repository outside of this
directory. This property ensures that code outside this repository does not
transitively depend on any of the private files in this repository.
The public/build/
directory contains files that support the build systems of
clients of the public/
directory.
The public/fidl
directory contains the FIDL definitions for this layer,
which are language-agnostic definitions of interprocess communication
protocols. Each subdirectory corresponds to a FIDL library and has a name that
matches the name of the FIDL library.
The public/lib/
directory contains libraries (both static and dynamic) in
various languages that clients can link into their processes. Both the headers
and source files for these libraries are included in this directory.
Libraries that are private implementation details of this repository (i.e., not
part of this repository's public interface) should be in lib/
instead.
The bin/
directory contains executable binaries. Typically, these binaries
implement one or more of the interfaces defined in public/
, but the binaries
themselves are not part of the public interface of this repository.
The docs/
directory contains documentation about this repository.
The examples/
directory contains code that demonstrates how to use the public
interfaces exposed by this repository. This code should not be required for the
system to execute correctly and should not depend on the private code in this
repository.
If the repository needs infrastructure related files, e.g., CQ configs, then these files go here.
The lib/
directory contains libraries (both static and dynamic) that are used
internally by this repository. These libraries are internal implementation
details of this repository and should not be used by code outside this
repository.
Libraries that are part of the public interface of this repository (i.e., not
private implementation details) should be in public/lib/
instead.
The manifest/
directory contains jiri manifests for repo.
The packages/
directory contains package definitions for each
package in the repo.