pub enum BuildEnvironmentOption {
BuildFlags(bool),
Ccache(bool),
Check(bool),
Color(bool),
Distcc(bool),
Sign(bool),
MakeFlags(bool),
}Expand description
An option string used in a build environment
The option string is identified by its name and whether it is on (not prefixed with “!”) or off (prefixed with “!”).
See the makepkg.conf manpage for more information.
§Examples
use alpm_types::BuildEnvironmentOption;
let option = BuildEnvironmentOption::new("distcc")?;
assert_eq!(option.on(), true);
assert_eq!(option.name(), "distcc");
let not_option = BuildEnvironmentOption::new("!ccache")?;
assert_eq!(not_option.on(), false);
assert_eq!(not_option.name(), "ccache");Variants§
BuildFlags(bool)
Use or unset the values of build flags (e.g. CPPFLAGS, CFLAGS, CXXFLAGS, LDFLAGS)
specified in user-specific configs (e.g. makepkg.conf).
Ccache(bool)
Use ccache to cache compilation
Check(bool)
Run the check() function if present in the PKGBUILD
Color(bool)
Colorize output messages
Distcc(bool)
Use the Distributed C/C++/ObjC compiler
Sign(bool)
Generate PGP signature file
MakeFlags(bool)
Use or unset the value of the MAKEFLAGS environment variable specified in
user-specific configs (e.g. makepkg.conf).
Implementations§
Source§impl BuildEnvironmentOption
impl BuildEnvironmentOption
Trait Implementations§
Source§impl AlpmParser for BuildEnvironmentOption
impl AlpmParser for BuildEnvironmentOption
Source§fn parser(input: &mut &str) -> ModalResult<Self>
fn parser(input: &mut &str) -> ModalResult<Self>
Recognizes a BuildEnvironmentOption in a string slice.
§Errors
Returns an error if input does not begin with a valid BuildEnvironmentOption.
Source§impl Clone for BuildEnvironmentOption
impl Clone for BuildEnvironmentOption
Source§fn clone(&self) -> BuildEnvironmentOption
fn clone(&self) -> BuildEnvironmentOption
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BuildEnvironmentOption
impl Debug for BuildEnvironmentOption
Source§impl<'de> Deserialize<'de> for BuildEnvironmentOption
impl<'de> Deserialize<'de> for BuildEnvironmentOption
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>,
Source§impl Display for BuildEnvironmentOption
impl Display for BuildEnvironmentOption
Source§impl FromStr for BuildEnvironmentOption
impl FromStr for BuildEnvironmentOption
Source§fn from_str(s: &str) -> Result<Self, Self::Err>
fn from_str(s: &str) -> Result<Self, Self::Err>
Creates a BuildEnvironmentOption from a string slice.
Delegates to BuildEnvironmentOption::parser.
§Errors
Returns an error if BuildEnvironmentOption::parser fails.
Source§impl PartialEq for BuildEnvironmentOption
impl PartialEq for BuildEnvironmentOption
Source§fn eq(&self, other: &BuildEnvironmentOption) -> bool
fn eq(&self, other: &BuildEnvironmentOption) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for BuildEnvironmentOption
impl Serialize for BuildEnvironmentOption
Source§impl VariantNames for BuildEnvironmentOption
impl VariantNames for BuildEnvironmentOption
impl Eq for BuildEnvironmentOption
impl StructuralPartialEq for BuildEnvironmentOption
Auto Trait Implementations§
impl Freeze for BuildEnvironmentOption
impl RefUnwindSafe for BuildEnvironmentOption
impl Send for BuildEnvironmentOption
impl Sync for BuildEnvironmentOption
impl Unpin for BuildEnvironmentOption
impl UnsafeUnpin for BuildEnvironmentOption
impl UnwindSafe for BuildEnvironmentOption
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<U> ParserUntil for Uwhere
U: AlpmParser,
impl<U> ParserUntil for Uwhere
U: AlpmParser,
Source§fn parser_until<'a, P>(
delimiter: P,
) -> impl Parser<&'a str, U, ErrMode<ContextError>>
fn parser_until<'a, P>( delimiter: P, ) -> impl Parser<&'a str, U, ErrMode<ContextError>>
Returns a [Parser] that parses Self until the given delimiter parser
matches.
§Note
Does not consume the delimiter.
Source§fn parser_until_eof(input: &mut &str) -> Result<Self, ErrMode<ContextError>>
fn parser_until_eof(input: &mut &str) -> Result<Self, ErrMode<ContextError>>
Source§impl<U> ParserUntilInclusive for Uwhere
U: ParserUntil,
impl<U> ParserUntilInclusive for Uwhere
U: ParserUntil,
Source§fn parser_until_inclusive<'a, P>(
delimiter: P,
) -> impl Parser<&'a str, U, ErrMode<ContextError>>
fn parser_until_inclusive<'a, P>( delimiter: P, ) -> impl Parser<&'a str, U, ErrMode<ContextError>>
Returns a [Parser] that parses the whole input and consumes the given delimiter parser.
Delegates to ParserUntil::parser_until and consumes the delimiter.