|
| 1 | +--- |
| 2 | +title: Meta |
| 3 | +lastUpdated: 2026-04-22T00:00:00Z |
| 4 | +description: The format of the Meta record |
| 5 | +--- |
| 6 | + |
| 7 | +The Meta record carries information about the *stone* |
| 8 | +itself or other <a href="/developers/stone/v1/header/#type">binary packages</a>, hence the name "meta". |
| 9 | +It is composed of a 8 bytes long header-like section, plus a value of variable length. |
| 10 | +The information it carries is strongly typed. |
| 11 | + |
| 12 | +Some of its fields can only be found in Repository *stones*, since they are information about packages to download. |
| 13 | + |
| 14 | +| Field | Type | Size (bytes) | Description | |
| 15 | +|---|---|---|---| |
| 16 | +| length | uint | 4 | Length, in bytes, of the value that follows the header-like section. | |
| 17 | +| tag | uint | 2 | What information this record carries about the *stone*. | |
| 18 | +| kind | uint | 1 | The base type of the information, for proper encoding and decoding. | |
| 19 | +| padding | blob | 1 | Unused. | |
| 20 | +| value | blob | `length` | Value of the information. The encoding depends on the value of `kind`. | |
| 21 | + |
| 22 | +### tag |
| 23 | + |
| 24 | +`tag` is an enum. |
| 25 | + |
| 26 | +|Value|Name|Description| |
| 27 | +|---|---|---| |
| 28 | +| 1 | Name | Name of the *stone*, which is typically the name of a package to install or remove. | |
| 29 | +| 2 | Architecture | Target hardware architecture of the package. | |
| 30 | +| 3 | Version | Version of the package. | |
| 31 | +| 4 | Summary | Succinct description of a package. | |
| 32 | +| 5 | Description | Full length description of the package. | |
| 33 | +| 6 | Homepage | Web homepage of the project being packaged. | |
| 34 | +| 7 | SourceID | ID of the source package, used for grouping. | |
| 35 | +| 8 | Depends | One dependency of the package. | |
| 36 | +| 9 | Provides | One capability, or the name, of the package. See further paragraphs for details. | |
| 37 | +| 10 | Conflicts | One capability, or name of another package, that conflicts with this package. | |
| 38 | +| 11 | Release | Release number of the package. It differs from Version in that Version identifies a state of the upstream project. Release is an increasing number that relates to the package. | |
| 39 | +| 12 | License | One license under which the upstream project is released, in [SPDX format](https://spdx.org/licenses). | |
| 40 | +| 13 | BuildRelease | Uniquely identifies a rebuild of a *stone*. It is an increasing number. | |
| 41 | +| 14 | PackageURI | URL relative to the base repository URL, where to download a package from. It is specific to a Repository *stone*. | |
| 42 | +| 15 | PackageHash | SHA-256 hash of a whole package *stone*. It is specific to a Repository *stone*. | |
| 43 | +| 16 | PackageSize | Size, in bytes, of a package when installed on disk (assumed when the CAS is empty, thus without de-duplication). It is specific to a Repository *stone*. | |
| 44 | +| 17 | BuildDepends | Build-time dependency of a package. | |
| 45 | +| 18 | SourceURI | Upstream URL for the source archive of a package. | |
| 46 | +| 19 | SourcePath | Relative path for the source within the upstream URL. | |
| 47 | +| 20 | SourceRef | Git commit or ref of the upstream source. | |
| 48 | + |
| 49 | +### kind |
| 50 | + |
| 51 | +`kind` is an enum. |
| 52 | + |
| 53 | +|Value|Name|Description| |
| 54 | +|---|---|---| |
| 55 | +| 1 | Int8 | int, 1 byte long. | |
| 56 | +| 2 | Uint8 | uint, 1 byte long. | |
| 57 | +| 3 | Int16 | int, 2 bytes long. | |
| 58 | +| 4 | Uint16 | uint, 2 bytes long. | |
| 59 | +| 5 | Int32 | int, 4 bytes long. | |
| 60 | +| 6 | Uint32 | uint, 4 bytes long. | |
| 61 | +| 7 | Int64 | int, 8 bytes long. | |
| 62 | +| 8 | Uint64 | uint, 8 bytes long. | |
| 63 | +| 9 | String | String. | |
| 64 | +| 10 | Dependency | <a href="#packagereference">PackageReference</a> structure. | |
| 65 | +| 11 | Provider | <a href="#packagereference">PackageReference</a> structure. | |
| 66 | + |
| 67 | +### PackageReference |
| 68 | + |
| 69 | +As explained before, the encoding format of `value` is explicated by the `kind` enum. |
| 70 | +Most of the kinds are a characterization of a <a href="/developers/stone">base format</a>, |
| 71 | +but there is one outstanding kind: PackageReference. Below is the format of PackageReference. |
| 72 | + |
| 73 | +| Field | Type | Size (bytes) | Description | |
| 74 | +|---|---|---|---| |
| 75 | +| kind | uint | 1 | Kind of package one depends on, or provides. | |
| 76 | +| name | str | `length` - 1 | Value of the reference. | |
| 77 | + |
| 78 | +#### kind |
| 79 | + |
| 80 | +`PackageReference`'s `kind` field is an enum. |
| 81 | + |
| 82 | +|Value|Name|Description| |
| 83 | +|---|---|---| |
| 84 | +| 0 | PackageName | A package depends on, or provides, a package name. | |
| 85 | +| 1 | SharedLibrary | A package depends on, or provides, a shared library (`*.so` file). | |
| 86 | +| 2 | PkgConfig | A package depends on, or provides, a [pkg-config](https://www.freedesktop.org/wiki/Software/pkg-config) target. | |
| 87 | +| 3 | Interpreter | A package depends on, or provides, a program interpreter (i.e. an ELF binary with `PT_INTERP` set). | |
| 88 | +| 4 | CMake | A package depends on, or provides, a [CMake](https://cmake.org) target. | |
| 89 | +| 5 | Python | A package depends on, or provides, a Python module. | |
| 90 | +| 6 | BinaryDep | A package depends on, or provides, a binary file in `/usr/bin`. | |
| 91 | +| 7 | SystemBinary | A package depends on, or provides, a binary file in `/usr/sbin`. | |
| 92 | +| 8 | PkgConfig32 | Like `PkgConfig`, but emul32-compatible. | |
0 commit comments