Skip to repository content29 lines · 771 B · rust
tenant.openagents/omega
No repository description is available.
OpenAgents Git authority 2026-07-28T00:36:06.445Z Public web read
NIP-34 coordinate
30617:7649603503856e5148d571eac2766b288a8ff1e9e35d380337a1d2b0015b4f92:omegaMaintainersHidden in public view
References2 branches · 1 tag
Read-only clone
git clone https://openagents.com/git/tenant.openagents/omega.gitBrowse files
build.rs
1#![allow(clippy::disallowed_methods, reason = "build scripts are exempt")]
2
3fn main() {
4 println!("cargo::rustc-check-cfg=cfg(macos_sdk_26_or_later)");
5
6 #[cfg(target_os = "macos")]
7 {
8 use std::process::Command;
9
10 let output = Command::new("xcrun")
11 .args(["--sdk", "macosx", "--show-sdk-version"])
12 .output()
13 .unwrap();
14
15 let sdk_version = String::from_utf8(output.stdout).unwrap();
16 let major_version: Option<u32> = sdk_version
17 .trim()
18 .split('.')
19 .next()
20 .and_then(|v| v.parse().ok());
21
22 if let Some(major) = major_version
23 && major >= 26
24 {
25 println!("cargo:rustc-cfg=macos_sdk_26_or_later");
26 }
27 }
28}
29