diff --git a/sys/build.rs b/sys/build.rs index 43b0d23..9a97c3e 100644 --- a/sys/build.rs +++ b/sys/build.rs @@ -130,6 +130,13 @@ fn main() { if cfg!(feature = "opencl") { config.define("WHISPER_CLBLAST", "ON"); } + + if cfg!(feature = "metal") { + config.define("WHISPER_METAL", "ON"); + } else { + // Metal is enabled by default, so we need to explicitly disable it + config.define("WHISPER_METAL", "OFF"); + } let destination = config.build();