File tree 4 files changed +10
-8
lines changed
webrtc-audio-processing-sys
4 files changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -27,11 +27,11 @@ name = "recording"
27
27
required-features = [" derive_serde" ]
28
28
29
29
[dev-dependencies ]
30
+ anyhow = " 1"
30
31
crossbeam-channel = " 0.5"
31
32
ctrlc = { version = " 3" , features = [" termination" ] }
32
- failure = " 0.1"
33
- hound = " 3.4"
34
- json5 = " 0.3"
33
+ hound = " 3"
34
+ json5 = " 0.4"
35
35
portaudio = " 0.7"
36
36
regex = " 1"
37
37
serde = { version = " 1" , features = [" derive" ]}
Original file line number Diff line number Diff line change 1
1
// This example loops the microphone input back to the speakers, while applying echo cancellation,
2
2
// creating an experience similar to Karaoke microphones. It uses PortAudio as an interface to the
3
3
// underlying audio devices.
4
+ use anyhow:: Error ;
4
5
use ctrlc;
5
- use failure:: Error ;
6
6
use portaudio;
7
7
use std:: {
8
8
sync:: {
Original file line number Diff line number Diff line change 21
21
/// $ cargo run --example recording --features bundled --features derive_serde -- --config-file \
22
22
/// examples/recording-configs/record-pipeline.json5
23
23
/// ```
24
- use failure :: { format_err , Error } ;
24
+ use anyhow :: { anyhow , Error } ;
25
25
use hound:: { WavIntoSamples , WavReader , WavWriter } ;
26
26
use regex:: Regex ;
27
27
use serde:: { Deserialize , Serialize } ;
@@ -96,7 +96,7 @@ fn match_device(
96
96
return Ok ( device. 0 ) ;
97
97
}
98
98
}
99
- Err ( format_err ! ( "Audio device matching \" {}\" not found." , device_name) )
99
+ Err ( anyhow ! ( "Audio device matching \" {}\" not found." , device_name) )
100
100
}
101
101
102
102
fn create_stream_settings (
Original file line number Diff line number Diff line change @@ -111,10 +111,12 @@ fn main() -> Result<(), Error> {
111
111
}
112
112
113
113
if cfg ! ( target_os = "macos" ) {
114
+ // TODO: Remove after confirming this is not necessary.
114
115
//println!("cargo:rustc-link-lib=dylib=c++");
115
- // println!("cargo:rustc-link-lib=framework=CoreFoundation");
116
+ println ! ( "cargo:rustc-link-lib=framework=CoreFoundation" ) ;
116
117
} else {
117
- println ! ( "cargo:rustc-link-lib=dylib=stdc++" ) ;
118
+ // TODO: Remove after confirming this is not necessary.
119
+ //println!("cargo:rustc-link-lib=dylib=stdc++");
118
120
}
119
121
120
122
cc:: Build :: new ( )
You can’t perform that action at this time.
0 commit comments