servoshell: Switch from winres to winresources (#39344)

`winres` is unmaintained and it seems like `winresoures` is the
successor.

Testing: This should not have any behavior changes and just modifies
a build step, so shouldn't need tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
This commit is contained in:
Martin Robinson 2025-09-17 10:04:45 +02:00 committed by GitHub
parent 5fd01ca25f
commit 6deb42dbd5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 18 additions and 27 deletions

40
Cargo.lock generated
View file

@ -378,7 +378,7 @@ dependencies = [
"objc2-foundation 0.3.1", "objc2-foundation 0.3.1",
"parking_lot", "parking_lot",
"percent-encoding", "percent-encoding",
"windows-sys 0.52.0", "windows-sys 0.60.2",
"x11rb", "x11rb",
] ]
@ -1216,7 +1216,7 @@ dependencies = [
"serde-untagged", "serde-untagged",
"serde-value", "serde-value",
"thiserror 1.0.69", "thiserror 1.0.69",
"toml 0.8.23", "toml",
"unicode-xid", "unicode-xid",
"url", "url",
] ]
@ -2151,7 +2151,7 @@ dependencies = [
"libc", "libc",
"option-ext", "option-ext",
"redox_users", "redox_users",
"windows-sys 0.59.0", "windows-sys 0.61.0",
] ]
[[package]] [[package]]
@ -2556,7 +2556,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"
dependencies = [ dependencies = [
"libc", "libc",
"windows-sys 0.52.0", "windows-sys 0.61.0",
] ]
[[package]] [[package]]
@ -4971,7 +4971,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "07033963ba89ebaf1584d767badaa2e8fcec21aedea6b8c0346d487d49c28667" checksum = "07033963ba89ebaf1584d767badaa2e8fcec21aedea6b8c0346d487d49c28667"
dependencies = [ dependencies = [
"cfg-if", "cfg-if",
"windows-targets 0.52.6", "windows-targets 0.53.3",
] ]
[[package]] [[package]]
@ -7185,7 +7185,7 @@ dependencies = [
"errno", "errno",
"libc", "libc",
"linux-raw-sys 0.9.4", "linux-raw-sys 0.9.4",
"windows-sys 0.52.0", "windows-sys 0.60.2",
] ]
[[package]] [[package]]
@ -8031,7 +8031,7 @@ dependencies = [
"webdriver_server", "webdriver_server",
"windows-sys 0.61.0", "windows-sys 0.61.0",
"winit", "winit",
"winres", "winresource",
"xcomponent-sys", "xcomponent-sys",
] ]
@ -8580,7 +8580,7 @@ dependencies = [
"cfg-expr 0.15.8", "cfg-expr 0.15.8",
"heck 0.5.0", "heck 0.5.0",
"pkg-config", "pkg-config",
"toml 0.8.23", "toml",
"version-compare", "version-compare",
] ]
@ -8593,7 +8593,7 @@ dependencies = [
"cfg-expr 0.20.2", "cfg-expr 0.20.2",
"heck 0.5.0", "heck 0.5.0",
"pkg-config", "pkg-config",
"toml 0.8.23", "toml",
"version-compare", "version-compare",
] ]
@ -8649,7 +8649,7 @@ dependencies = [
"getrandom 0.3.3", "getrandom 0.3.3",
"once_cell", "once_cell",
"rustix 1.0.8", "rustix 1.0.8",
"windows-sys 0.52.0", "windows-sys 0.61.0",
] ]
[[package]] [[package]]
@ -8959,15 +8959,6 @@ dependencies = [
"tokio", "tokio",
] ]
[[package]]
name = "toml"
version = "0.5.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234"
dependencies = [
"serde",
]
[[package]] [[package]]
name = "toml" name = "toml"
version = "0.8.23" version = "0.8.23"
@ -10168,7 +10159,7 @@ version = "0.1.11"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"
dependencies = [ dependencies = [
"windows-sys 0.52.0", "windows-sys 0.61.0",
] ]
[[package]] [[package]]
@ -10651,12 +10642,13 @@ dependencies = [
] ]
[[package]] [[package]]
name = "winres" name = "winresource"
version = "0.1.12" version = "0.1.23"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b68db261ef59e9e52806f688020631e987592bd83619edccda9c47d42cde4f6c" checksum = "edcacf11b6f48dd21b9ba002f991bdd5de29b2da8cc2800412f4b80f677e4957"
dependencies = [ dependencies = [
"toml 0.5.11", "toml",
"version_check",
] ]
[[package]] [[package]]

View file

@ -97,7 +97,6 @@ skip = [
# New versions of these dependencies is pulled in by GStreamer / GLib. # New versions of these dependencies is pulled in by GStreamer / GLib.
"itertools", "itertools",
"toml",
# Duplicated by egui # Duplicated by egui
"nix", "nix",

View file

@ -26,7 +26,7 @@ bench = false
cc = "1.2" cc = "1.2"
[target.'cfg(windows)'.build-dependencies] [target.'cfg(windows)'.build-dependencies]
winres = "0.1" winresource = "0.1"
[package.metadata.winres] [package.metadata.winres]
FileDescription = "Servo" FileDescription = "Servo"

View file

@ -50,7 +50,7 @@ fn main() -> Result<(), Box<dyn Error>> {
if target_os == "windows" { if target_os == "windows" {
#[cfg(windows)] #[cfg(windows)]
{ {
let mut res = winres::WindowsResource::new(); let mut res = winresource::WindowsResource::new();
res.set_icon("../../resources/servo.ico"); res.set_icon("../../resources/servo.ico");
res.set_manifest_file("platform/windows/servo.exe.manifest"); res.set_manifest_file("platform/windows/servo.exe.manifest");
res.compile().unwrap(); res.compile().unwrap();