1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
use crate::commands::shared::cargo_rustc_command;
use crate::error::*;
use crate::types::*;
use std::path::Path;

pub fn apple_rust_compile(
    target: Target,
    build_target: AppleTarget,
    project_path: &Path,
    profile: Profile,
    features: Vec<String>,
    all_features: bool,
    no_default_features: bool,
) -> Result<()> {
    let cargo = cargo_rustc_command(
        &target,
        project_path,
        &profile,
        &features,
        all_features,
        no_default_features,
        &build_target.into(),
        &[],
    );
    cargo.output_err(true)?;
    Ok(())
}