Subject: [bug#44492] [PATCH 28/52] gnu: Add rust-pangocairo-0.10.

From: Leo Prikler <[email-masked]>
Date: Wed, 24 Feb 2021 12:11:11 +0100

* gnu/packages/crates-gtk.scm (rust-pangocairo-0.10): New variable.
---
 gnu/packages/crates-gtk.scm | 52 +++++++++++++++++++++++++++++++++++++
 1 file changed, 52 insertions(+)

diff --git a/gnu/packages/crates-gtk.scm b/gnu/packages/crates-gtk.scm
index 8c54e26a46..d562b07480 100644
--- a/gnu/packages/crates-gtk.scm
+++ b/gnu/packages/crates-gtk.scm
@@ -1733,6 +1733,58 @@ converts raw links to http links and strips unwanted tags.")
        (("rust-shell-words" ,rust-shell-words-0.1)
         ("rust-tempfile" ,rust-tempfile-3))))))
 
+(define-public rust-pangocairo-0.10
+  (package
+    (name "rust-pangocairo")
+    (version "0.10.0")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (crate-uri "pangocairo" version))
+        (file-name
+          (string-append name "-" version ".tar.gz"))
+        (sha256
+          (base32
+            "10z8hlc82984nwvy5pnyh95ls9s5r1qrlkpn14zh4pjsl1ksxx80"))))
+    (build-system cargo-build-system)
+    (arguments
+     `(#:cargo-inputs
+       (("rust-bitflags" ,rust-bitflags-1)
+        ("rust-cairo-rs" ,rust-cairo-rs-0.9)
+        ("rust-cairo-sys-rs" ,rust-cairo-sys-rs-0.10)
+        ("rust-glib" ,rust-glib-0.10)
+        ("rust-glib-sys" ,rust-glib-sys-0.10)
+        ("rust-gobject-sys" ,rust-gobject-sys-0.10)
+        ("rust-gtk-rs-lgpl-docs"
+         ,rust-gtk-rs-lgpl-docs-0.1)
+        ("rust-libc" ,rust-libc-0.2)
+        ("rust-pango" ,rust-pango-0.9)
+        ("rust-pango-sys" ,rust-pango-sys-0.10)
+        ("rust-pangocairo-sys" ,rust-pangocairo-sys-0.11))
+       #:cargo-development-inputs
+       (("rust-gir-format-check" ,rust-gir-format-check-0.1))
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'configure 'fix-version-requirements
+           (lambda* (#:key inputs vendor-dir #:allow-other-keys)
+             (substitute*
+                 (map
+                  (lambda (dir) (string-append dir "/Cargo.toml"))
+                  (find-files vendor-dir "system-deps.*" #:directories? #t))
+               (("0.0.10") ,(package-version rust-version-compare-0.0)))
+             #t)))))
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("cairo" ,cairo)
+       ("glib" ,glib)
+       ("pango" ,pango)))
+    (home-page "http://gtk-rs.org/")
+    (synopsis "Rust bindings for the PangoCairo library")
+    (description
+     "Rust bindings for the PangoCairo library.")
+    (license license:expat)))
+
 (define-public rust-pangocairo-0.9
   (package
     (name "rust-pangocairo")
-- 
2.30.1