JACK: bump to 0.13.0 and fix compliation (#915)

This commit is contained in:
Alexandre Bique 2024-09-25 21:13:56 +02:00 • committed by GitHub
parent 6ecfec4ed0
commit eb3d44542c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 4 deletions

View file

@ -45,7 +45,7 @@ num-traits = { version = "0.2.6", optional = true }
[target.'cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd", target_os = "netbsd"))'.dependencies] [target.'cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd", target_os = "netbsd"))'.dependencies]
alsa = "0.9" alsa = "0.9"
libc = "0.2" libc = "0.2"
jack = { version = "0.12", optional = true } jack = { version = "0.13.0", optional = true }
[target.'cfg(any(target_os = "macos", target_os = "ios"))'.dependencies] [target.'cfg(any(target_os = "macos", target_os = "ios"))'.dependencies]
core-foundation-sys = "0.8.2" # For linking to CoreFoundation.framework and handling device name `CFString`s. core-foundation-sys = "0.8.2" # For linking to CoreFoundation.framework and handling device name `CFString`s.

View file

@ -37,7 +37,7 @@ impl Stream {
let mut port_names: Vec<String> = vec![]; let mut port_names: Vec<String> = vec![];
// Create ports // Create ports
for i in 0..channels { for i in 0..channels {
let port_try = client.register_port(&format!("in_{}", i), jack::AudioIn); let port_try = client.register_port(&format!("in_{}", i), jack::AudioIn::default());
match port_try { match port_try {
Ok(port) => { Ok(port) => {
// Get the port name in order to later connect it automatically // Get the port name in order to later connect it automatically
@ -102,7 +102,7 @@ impl Stream {
let mut port_names: Vec<String> = vec![]; let mut port_names: Vec<String> = vec![];
// Create ports // Create ports
for i in 0..channels { for i in 0..channels {
let port_try = client.register_port(&format!("out_{}", i), jack::AudioOut); let port_try = client.register_port(&format!("out_{}", i), jack::AudioOut::default());
match port_try { match port_try {
Ok(port) => { Ok(port) => {
// Get the port name in order to later connect it automatically // Get the port name in order to later connect it automatically
@ -437,7 +437,7 @@ impl JackNotificationHandler {
} }
impl jack::NotificationHandler for JackNotificationHandler { impl jack::NotificationHandler for JackNotificationHandler {
fn shutdown(&mut self, _status: jack::ClientStatus, reason: &str) { unsafe fn shutdown(&mut self, _status: jack::ClientStatus, reason: &str) {
self.send_error(format!("JACK was shut down for reason: {}", reason)); self.send_error(format!("JACK was shut down for reason: {}", reason));
} }