1#![allow(clippy::disallowed_methods, reason = "build scripts are exempt")]
2#![cfg_attr(not(target_os = "macos"), allow(unused))]
3
4fn main() {
5 println!("cargo::rustc-check-cfg=cfg(gles)");
6
7 #[cfg(all(target_os = "windows", feature = "windows-manifest"))]
8 embed_resource();
9}
10
11#[cfg(all(target_os = "windows", feature = "windows-manifest"))]
12fn embed_resource() {
13 let manifest = std::path::Path::new("resources/windows/gpui.manifest.xml");
14 let rc_file = std::path::Path::new("resources/windows/gpui.rc");
15 println!("cargo:rerun-if-changed={}", manifest.display());
16 println!("cargo:rerun-if-changed={}", rc_file.display());
17 embed_resource::compile(rc_file, embed_resource::NONE)
18 .manifest_required()
19 .unwrap();
20}