diff --git a/Cargo.toml b/Cargo.toml index 896a7a6..419c1d0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "coreaudio-sys" -version = "0.2.13" +version = "0.2.14" authors = ["Mitchell Nordine "] description = "Bindings for Apple's CoreAudio frameworks generated via rust-bindgen" license = "MIT" @@ -20,6 +20,7 @@ default = ["audio_toolbox", "audio_unit", "core_audio", "open_al", "core_midi"] audio_toolbox = [] audio_unit = [] core_audio = [] +io_kit_audio = [] open_al = [] core_midi = [] diff --git a/build.rs b/build.rs index 81cfbcc..7083f9c 100644 --- a/build.rs +++ b/build.rs @@ -86,6 +86,13 @@ fn build(sdk_path: Option<&str>, target: &str) { } } + #[cfg(feature = "io_kit_audio")] + { + assert!(target.contains("apple-darwin")); + println!("cargo:rustc-link-lib=framework=IOKit"); + headers.push("IOKit/audio/IOAudioTypes.h"); + } + #[cfg(feature = "open_al")] { println!("cargo:rustc-link-lib=framework=OpenAL");