From fc5aec45720a33869a6f035762da5c6faac2402c Mon Sep 17 00:00:00 2001 From: Eugene Hauptmann Date: Thu, 6 Jun 2024 16:02:29 -0400 Subject: [PATCH] and AudioUnit.h again --- build.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build.rs b/build.rs index 9c06139..8d6c376 100644 --- a/build.rs +++ b/build.rs @@ -60,13 +60,13 @@ fn build(sdk_path: Option<&str>, target: &str) { // Since iOS 10.0, macOS 10.12, visionOS 1.0, all the functionality in AudioUnit // moved to AudioToolbox, and the AudioUnit headers have been simple // wrappers ever since. - if target.contains("apple-ios") { + if target.contains("apple-ios") || target.contains("apple-visionos"){ // On iOS, the AudioUnit framework does not have (and never had) an // actual dylib to link to, it is just a few header files. // The AudioToolbox framework contains the symbols instead. println!("cargo:rustc-link-lib=framework=AudioToolbox"); headers.push("AudioToolbox/AudioUnit.h"); - } else if !target.contains("apple-visionos") { + } else { // On macOS, the symbols are present in the AudioToolbox framework, // but only on macOS 10.12 and above. //