From ce3c90b4ec962ef9bb4f52513067d794ab8153eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C5=91rik=20Levente?= <33373714+Levminer@users.noreply.github.com> Date: Mon, 15 Jul 2024 11:05:27 +0200 Subject: [PATCH] GPU fixes --- Cargo.lock | 48 ++++++++++++++++++- platforms/interface/ui/pages/home.svelte | 2 +- .../web/src/components/appHeader.svelte | 2 +- platforms/unix/hardwareinfo/src/lib.rs | 8 ++-- 4 files changed, 53 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b92cc5f..3a9df6c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1624,6 +1624,7 @@ version = "0.1.0" dependencies = [ "indexmap 2.2.6", "netdev", + "nvml-wrapper", "starship-battery", "sysinfo", ] @@ -2070,7 +2071,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e9ec52138abedcc58dc17a7c6c0c00a2bdb4f3427c7f63fa97fd0d859155caf" dependencies = [ "gtk-sys", - "libloading", + "libloading 0.7.4", "once_cell", ] @@ -2090,6 +2091,16 @@ dependencies = [ "winapi", ] +[[package]] +name = "libloading" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e310b3a6b5907f99202fcdb4960ff45b93735d7c7d96b760fcff8db2dc0e103d" +dependencies = [ + "cfg-if", + "windows-targets 0.52.5", +] + [[package]] name = "libredox" version = "0.1.3" @@ -2481,6 +2492,29 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "nvml-wrapper" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c9bff0aa1d48904a1385ea2a8b97576fbdcbc9a3cfccd0d31fe978e1c4038c5" +dependencies = [ + "bitflags 2.6.0", + "libloading 0.8.4", + "nvml-wrapper-sys", + "static_assertions", + "thiserror", + "wrapcenum-derive", +] + +[[package]] +name = "nvml-wrapper-sys" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "698d45156f28781a4e79652b6ebe2eaa0589057d588d3aec1333f6466f13fcb5" +dependencies = [ + "libloading 0.8.4", +] + [[package]] name = "objc" version = "0.2.7" @@ -5791,6 +5825,18 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "wrapcenum-derive" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a76ff259533532054cfbaefb115c613203c73707017459206380f03b3b3f266e" +dependencies = [ + "darling", + "proc-macro2", + "quote", + "syn 2.0.68", +] + [[package]] name = "wry" version = "0.40.1" diff --git a/platforms/interface/ui/pages/home.svelte b/platforms/interface/ui/pages/home.svelte index b580319..59021d9 100644 --- a/platforms/interface/ui/pages/home.svelte +++ b/platforms/interface/ui/pages/home.svelte @@ -345,7 +345,7 @@