synthesizer-io
synthesizer-io copied to clipboard
Can't build on macOS Monterey
I wasn't able to just cargo build the project in macOS Monterey.
The error:
Compiling coreaudio-sys v0.2.2
error: failed to run custom build command for `coreaudio-sys v0.2.2`
Caused by:
process didn't exit successfully: `/Users/fredguth/Code/pianocast/experiments/synthesizer-io/target/debug/build/coreaudio-sys-a05d30c9e3820cb9/build-script-build` (exit status: 101)
--- stdout
cargo:rustc-link-lib=framework=AudioToolbox
cargo:rustc-link-lib=framework=AudioUnit
cargo:rustc-link-lib=framework=CoreAudio
cargo:rustc-link-lib=framework=OpenAL
cargo:rustc-link-lib=framework=CoreMIDI
--- stderr
error: header '/System/Library/Frameworks/CoreMIDI.framework/Headers/CoreMIDI.h' does not exist.
thread 'main' panicked at 'unable to generate bindings: ()', /Users/fredguth/.cargo/registry/src/github.com-1ecc6299db9ec823/coreaudio-sys-0.2.2/build.rs:144:10
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
I guess the problem is that CoreMIDI.framework path is hard coded. Because in my machine it is intalled inside Xcode.app contents:
xcrun --sdk macosx --show-sdk-path
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk