mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-18 08:52:45 +00:00
modify hosted mode specifier to clarify build intentions
This commit is contained in:
parent
49f14d32c9
commit
e9dcdb015b
2 changed files with 16 additions and 3 deletions
|
|
@ -262,6 +262,17 @@ impl Builder {
|
||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Configure for hosted mode
|
||||||
|
pub fn target_hosted_baosec(&mut self) -> &mut Builder {
|
||||||
|
self.loader = CrateSpec::None;
|
||||||
|
self.target = None;
|
||||||
|
self.target_kernel = None;
|
||||||
|
self.stream = BuildStream::Release;
|
||||||
|
self.utra_target = "hosted-baosec".to_string();
|
||||||
|
self.run_svd2repl = false;
|
||||||
|
self
|
||||||
|
}
|
||||||
|
|
||||||
/// Configure for renode targets
|
/// Configure for renode targets
|
||||||
pub fn target_renode(&mut self) -> &mut Builder {
|
pub fn target_renode(&mut self) -> &mut Builder {
|
||||||
self.target = Some(crate::TARGET_TRIPLE_RISCV32.to_string());
|
self.target = Some(crate::TARGET_TRIPLE_RISCV32.to_string());
|
||||||
|
|
@ -668,7 +679,7 @@ impl Builder {
|
||||||
self.features.push("renode".into());
|
self.features.push("renode".into());
|
||||||
self.loader_features.push("renode".into());
|
self.loader_features.push("renode".into());
|
||||||
self.kernel_features.push("renode".into());
|
self.kernel_features.push("renode".into());
|
||||||
} else if self.utra_target.contains("hosted") {
|
} else if self.utra_target == "hosted" {
|
||||||
self.features.push("hosted".into());
|
self.features.push("hosted".into());
|
||||||
// there is no loader in hosed mode
|
// there is no loader in hosed mode
|
||||||
self.kernel_features.push("hosted".into());
|
self.kernel_features.push("hosted".into());
|
||||||
|
|
@ -696,6 +707,8 @@ impl Builder {
|
||||||
self.kernel_features.push(format!("utralib/{}", &self.utra_target));
|
self.kernel_features.push(format!("utralib/{}", &self.utra_target));
|
||||||
self.loader_features.push("cramium-soc".into());
|
self.loader_features.push("cramium-soc".into());
|
||||||
self.loader_features.push(format!("utralib/{}", &self.utra_target));
|
self.loader_features.push(format!("utralib/{}", &self.utra_target));
|
||||||
|
} else if self.utra_target.contains("hosted-baosec") {
|
||||||
|
self.features.push("hosted-baosec".into());
|
||||||
} else {
|
} else {
|
||||||
return Err("Target unknown: please check your UTRA target".into());
|
return Err("Target unknown: please check your UTRA target".into());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -367,8 +367,8 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||||
Some("baosec-emu") => {
|
Some("baosec-emu") => {
|
||||||
let bao_pkgs = ["xous-ticktimer", "xous-log", "xous-names", "modals", "bao-video"];
|
let bao_pkgs = ["xous-ticktimer", "xous-log", "xous-names", "modals", "bao-video"];
|
||||||
builder
|
builder
|
||||||
.target_hosted()
|
// hosted-baosec feature added below
|
||||||
.add_feature("hosted-baosec")
|
.target_hosted_baosec()
|
||||||
.add_services(&bao_pkgs)
|
.add_services(&bao_pkgs)
|
||||||
.add_apps(&get_cratespecs());
|
.add_apps(&get_cratespecs());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue