pub struct BuildInfoV2 {Show 14 fields
pub pkgname: Name,
pub pkgbase: Name,
pub pkgver: FullVersion,
pub pkgarch: Architecture,
pub pkgbuild_sha256sum: Checksum<Sha256>,
pub packager: Packager,
pub builddate: BuildDate,
pub builddir: BuildDirectory,
pub buildenv: Vec<BuildEnvironmentOption>,
pub options: Vec<PackageOption>,
pub installed: Vec<InstalledPackage>,
pub startdir: StartDirectory,
pub buildtool: BuildTool,
pub buildtoolver: BuildToolVersion,
}Expand description
BUILDINFO version 2
BuildInfoV2 is (exclusively) compatible with data following the v2 specification of the
BUILDINFO file.
§Examples
use std::str::FromStr;
use alpm_buildinfo::BuildInfoV2;
let buildinfo_data = r#"format = 2
pkgname = foo
pkgbase = foo
pkgver = 1:1.0.0-1
pkgarch = any
pkgbuild_sha256sum = b5bb9d8014a0f9b1d61e21e796d78dccdf1352f23cd32812f4850b878ae4944c
packager = Foobar McFooface <foobar@mcfooface.org>
builddate = 1
builddir = /build
startdir = /startdir/
buildtool = devtools
buildtoolver = 1:1.2.1-1-any
buildenv = ccache
buildenv = color
options = lto
options = !strip
installed = bar-1.2.3-1-any
installed = beh-2.2.3-4-any
"#;
let buildinfo = BuildInfoV2::from_str(buildinfo_data)?;
assert_eq!(buildinfo.to_string(), buildinfo_data);Fields§
§pkgname: NameThe package name
pkgbase: NameThe package base name
pkgver: FullVersionThe package version
pkgarch: ArchitectureThe package architecture
pkgbuild_sha256sum: Checksum<Sha256>The package build SHA-256 checksum
packager: PackagerThe packager
builddate: BuildDateThe build date
builddir: BuildDirectoryThe build directory
buildenv: Vec<BuildEnvironmentOption>The build environment
options: Vec<PackageOption>The package options
installed: Vec<InstalledPackage>The installed packages
startdir: StartDirectoryThe start directory of the build process
buildtool: BuildToolThe tool used for building the package
buildtoolver: BuildToolVersionThe version of the build tool
Implementations§
Trait Implementations§
Source§impl Clone for BuildInfoV2
impl Clone for BuildInfoV2
Source§fn clone(&self) -> BuildInfoV2
fn clone(&self) -> BuildInfoV2
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BuildInfoV2
impl Debug for BuildInfoV2
Source§impl<'de> Deserialize<'de> for BuildInfoV2
impl<'de> Deserialize<'de> for BuildInfoV2
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for BuildInfoV2
impl Display for BuildInfoV2
Source§impl FromStr for BuildInfoV2
impl FromStr for BuildInfoV2
Source§impl PartialEq for BuildInfoV2
impl PartialEq for BuildInfoV2
Source§impl Serialize for BuildInfoV2
impl Serialize for BuildInfoV2
impl StructuralPartialEq for BuildInfoV2
Auto Trait Implementations§
impl Freeze for BuildInfoV2
impl RefUnwindSafe for BuildInfoV2
impl Send for BuildInfoV2
impl Sync for BuildInfoV2
impl Unpin for BuildInfoV2
impl UnwindSafe for BuildInfoV2
Blanket Implementations§
§impl<T> AnyEq for T
impl<T> AnyEq for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more