Struct cpp_to_rust_common::cpp_build_config::CppBuildConfig
[−]
[src]
pub struct CppBuildConfig { /* fields omitted */ }
Information required to build the C++ wrapper library
on every supported platform. it contains list of linked
libraries, frameworks, compiler types and selected type of
C++ wrapper library (shared or static). Default value of this
object is set before generation of the crate using
cpp_to_rust_generator::config::Config::set_cpp_build_config
or
cpp_build_config_mut
and intended to be cross-platform.
In order to allow target-dependent build configuration,
multiple configurations can be added to one CppBuildConfig
object,
each with a condition.
During evaluation, each configuration item
will only be used if the associated condition is currently true.
All properties from all matching configuration are combined.
If this conditional evaluation is not enough, a custom build script
can modify this config during build script execution using
cpp_to_rust_build_tools::Config::set_cpp_build_config
or
cpp_build_config_mut
.
Methods
impl CppBuildConfig
[src]
fn new() -> CppBuildConfig
[src]
Create an empty configuration
fn add(&mut self, condition: Condition, data: CppBuildConfigData)
[src]
Add data
with condition
.
fn eval(&self, target: &Target) -> Result<CppBuildConfigData>
[src]
Select all conditions that are true on target
, combine all corresponding
configuration items and return the result.
Trait Implementations
impl Default for CppBuildConfig
[src]
fn default() -> CppBuildConfig
[src]
Returns the "default value" for a type. Read more
impl Debug for CppBuildConfig
[src]
impl Clone for CppBuildConfig
[src]
fn clone(&self) -> CppBuildConfig
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more