Package workstation tools, reuse emulator sessions, and derive build versions

This commit is contained in:
2026-09-23 03:45:48 +08:00
parent 6bfcce8070
commit f5d9f96409
79 changed files with 878 additions and 132 deletions
+20
View File
@@ -0,0 +1,20 @@
// Every workspace crate uses the same resolver, including direct Cargo builds.
use std::{env, path::PathBuf, process::Command};
fn main() {
let manifest = PathBuf::from(env::var_os("CARGO_MANIFEST_DIR").unwrap());
let root = manifest.parent().unwrap().parent().unwrap();
let output = Command::new("python3")
.arg(root.join("tools/version"))
.arg("--cargo")
.output()
.expect("Python 3 is required to resolve the FDS build version");
assert!(
output.status.success(),
"FDS version discovery failed: {}",
String::from_utf8_lossy(&output.stderr)
);
print!(
"{}",
String::from_utf8(output.stdout).expect("Version metadata must be UTF-8")
);
}