Add asio cargo feature for optional ASIO support
ASIO introduces quite a few extra crates and requires a fairly complicated setup process (see the readme), so this feature is disabled by default.
This commit is contained in:
parent
76fab4f982
commit
8f95042b8d
4 changed files with 23 additions and 2 deletions
|
|
@ -8,6 +8,9 @@ documentation = "https://docs.rs/cpal"
|
|||
license = "Apache-2.0"
|
||||
keywords = ["audio", "sound"]
|
||||
|
||||
[features]
|
||||
asio = ["asio-sys"] # Only available on Windows. See README for setup instructions.
|
||||
|
||||
[dependencies]
|
||||
failure = "0.1.5"
|
||||
lazy_static = "1.3"
|
||||
|
|
@ -18,7 +21,7 @@ hound = "3.4"
|
|||
|
||||
[target.'cfg(target_os = "windows")'.dependencies]
|
||||
winapi = { version = "0.3", features = ["audiosessiontypes", "audioclient", "coml2api", "combaseapi", "debug", "devpkey", "handleapi", "ksmedia", "mmdeviceapi", "objbase", "std", "synchapi", "winuser"] }
|
||||
asio-sys = { version = "0.1", path = "asio-sys" }
|
||||
asio-sys = { version = "0.1", path = "asio-sys", optional = true }
|
||||
|
||||
[target.'cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd", target_os = "openbsd"))'.dependencies]
|
||||
alsa-sys = { version = "0.1", path = "alsa-sys" }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue