jabber-tools / cognitive-services-speech-sdk-rs

Apache License 2.0
24 stars 15 forks source link

Upgrade speech sdk to version 1.36.0 #12

Closed wangfu91 closed 5 months ago

wangfu91 commented 6 months ago

To run the example on macOS:

export DYLD_FALLBACK_FRAMEWORK_PATH=./SpeechSDK/macOS/sdk_output/MicrosoftCognitiveServicesSpeech.xcframework/macos-arm64_x86_64
cargo run --example recognizer

and Linux:

export LD_LIBRARY_PATH=./SpeechSDK/linux/sdk_output/lib/x64
cargo run --example recognizer
adambezecny commented 6 months ago

I like the new build script, especially the fact MACOS_SPEECHSDK_ROOT is not needed any more, this will be real improvement. I was able tom compile on mac but trying to build on linux (my raspberry pi) failed with following error:


  Compiling tokio-macros v1.1.0
   Compiling cognitive-services-speech-sdk-rs v0.2.3 (/home/pi/projects/pr124/cognitive-services-speech-sdk-rs)
error[E0425]: cannot find value `sdk_path` in this scope
  --> build.rs:58:20
   |
58 |     let lib_path = sdk_path.join("lib").join("arm32");
   |                    ^^^^^^^^ not found in this scope

For more information about this error, try `rustc --explain E0425`.
error: could not compile `cognitive-services-speech-sdk-rs` due to previous error
warning: build failed, waiting for other jobs to finish...
pi@raspberrypi:~/projects/pr124/cognitive-services-speech-sdk-rs $

once fixed I will retest and if good I think we can merge this one.

thank you!

regards

Adam

wangfu91 commented 6 months ago
 --> build.rs:58:20
   |
58 |     let lib_path = sdk_path.join("lib").join("arm32");
   |                    ^^^^^^^^ not found in this scope

Ah, my bad, sdk_path should be sdk_output_dir. I was doing some name refactoring and forgot to update the name other than the x86_64 arch. Will fix the code later today.

wangfu91 commented 6 months ago

The build error on linux should be fixed now.