From f17d5a8e36f117cd7b8cb0d066a1a45cb44ea3c7 Mon Sep 17 00:00:00 2001 From: Nivaldo Date: Wed, 25 Nov 2026 15:23:49 -0300 Subject: [PATCH] build.rs: link MetalKit for tvOS targets The MetalKit link was gated on the target name containing "darwin" or "ios", so tvOS targets never linked it, and the iOS backend's class!(MTKView) panicked at launch. Co-Authored-By: Claude Opus 5.5 --- build.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.rs b/build.rs index 50ba1b615..9eddd9d49 100644 --- a/build.rs +++ b/build.rs @@ -3,7 +3,7 @@ use std::env; fn main() { let target = env::var("TARGET").unwrap_or_else(|e| panic!("{}", e)); - if target.contains("darwin") || target.contains("ios") { + if target.contains("darwin") || target.contains("ios") || target.contains("tvos") { println!("cargo:rustc-link-lib=framework=MetalKit"); } }