Subject: [bug#74432] [PATCH 07/10] gnu: Add rust-gtk4-0.4.

From: Divya Ranjan <[email-masked]>
Date: Wed, 11 Dec 2024 01:23:03 +0000

* gnu/packages/crates-gtk.scm (rust-gtk4-0.4): New variable.

Change-Id: Ic8d3e431e25da2ae17486b4a13a6c0847f71e3e9
---
 gnu/packages/crates-gtk.scm | 38 +++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/crates-gtk.scm b/gnu/packages/crates-gtk.scm
index 9a778a059a..3646bc9a8c 100644
--- a/gnu/packages/crates-gtk.scm
+++ b/gnu/packages/crates-gtk.scm
@@ -4179,6 +4179,44 @@ (define-public rust-gtk4-0.7
        #:cargo-development-inputs
        (("rust-gir-format-check" ,rust-gir-format-check-0.1))))))
 
+(define-public rust-gtk4-0.4
+  (package
+    (name "rust-gtk4")
+    (version "0.4.9")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (crate-uri "gtk4" version))
+        (file-name
+          (string-append name "-" version ".tar.gz"))
+        (sha256
+          (base32
+            "1g5v9wwf9sgz9vx0vwfc3sxm9pm5cah3ypjy3daw6fvryapfb2jf"))))
+    (build-system cargo-build-system)
+    (arguments
+      `(#:cargo-inputs
+        (("rust-bitflags" ,rust-bitflags-1)
+         ("rust-cairo-rs" ,rust-cairo-rs-0.15)
+         ("rust-field-offset" ,rust-field-offset-0.3)
+         ("rust-futures-channel"
+          ,rust-futures-channel-0.3)
+         ("rust-gdk-pixbuf" ,rust-gdk-pixbuf-0.15)
+         ("rust-gdk4" ,rust-gdk4-0.4)
+         ("rust-gio" ,rust-gio-0.15)
+         ("rust-glib" ,rust-glib-0.15)
+         ("rust-graphene-rs" ,rust-graphene-rs-0.15)
+         ("rust-gsk4" ,rust-gsk4-0.4)
+         ("rust-gtk4-macros" ,rust-gtk4-macros-0.4)
+         ("rust-gtk4-sys" ,rust-gtk4-sys-0.4)
+         ("rust-libc" ,rust-libc-0.2)
+         ("rust-once-cell" ,rust-once-cell-1)
+         ("rust-pango" ,rust-pango-0.15))))
+    (home-page "https://gtk-rs.org/gtk4-rs")
+    (synopsis "Rust bindings of the GTK 4 library")
+    (description
+      "This package provides Rust bindings of the GTK 4 library.")
+    (license license:expat)))
+
 (define-public rust-gtk4-macros-0.8
   (package
     (name "rust-gtk4-macros")
-- 
2.46.0