Subject: [PATCH 43/81] gnu: Add rust-asn1-rs-0.6.

From: Herman Rimm <[email-masked]>
Date: Mon, 20 May 2024 10:58:48 +0200

* gnu/packages/crates-tls.scm (rust-asn1-rs-0.6): Add variable.
(rust-asn1-rs-0.5): Inherit from rust-asn1-rs-0.6.

Change-Id: Ie0a87f742a7ad8165ba870f950f214209b808c82
---
 gnu/packages/crates-tls.scm | 44 ++++++++++++++++++++++++++++++++-----
 1 file changed, 38 insertions(+), 6 deletions(-)

diff --git a/gnu/packages/crates-tls.scm b/gnu/packages/crates-tls.scm
index 991508a2d0..addba26f3a 100644
--- a/gnu/packages/crates-tls.scm
+++ b/gnu/packages/crates-tls.scm
@@ -129,8 +129,45 @@ (define-public rust-asn1-derive-0.13
         ("rust-quote" ,rust-quote-1)
         ("rust-syn" ,rust-syn-1))))))
 
+(define-public rust-asn1-rs-0.6
+  (package
+    (name "rust-asn1-rs")
+    (version "0.6.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (crate-uri "asn1-rs" version))
+       (file-name (string-append name "-" version ".tar.gz"))
+       (sha256
+        (base32 "17a2sb40l1wk542hhlj8rf8iabhmqymrm4skxiq0zykyfmri7b92"))))
+    (build-system cargo-build-system)
+    (arguments
+     (list
+      #:cargo-inputs (list rust-asn1-rs-derive-0.5
+                           rust-asn1-rs-impl-0.2
+                           rust-bitvec-1
+                           rust-cookie-factory-0.3
+                           rust-displaydoc-0.2
+                           rust-nom-7
+                           rust-num-bigint-0.4
+                           rust-num-traits-0.2
+                           rust-rusticata-macros-4
+                           rust-thiserror-1
+                           rust-time-0.3)
+      #:cargo-development-inputs (list rust-colored-2
+                                       rust-hex-literal-0.4
+                                       rust-pem-3
+                                       rust-trybuild-1)))
+    (home-page "https://github.com/rusticata/asn1-rs")
+    (synopsis "Parser/encoder for ASN.1 BER/DER data")
+    (description
+     "This package provides a parser and encoder for ASN.1 BER and DER
+data.")
+    (license (list license:expat license:asl2.0))))
+
 (define-public rust-asn1-rs-0.5
   (package
+    (inherit rust-asn1-rs-0.6)
     (name "rust-asn1-rs")
     (version "0.5.2")
     (source (origin
@@ -140,7 +177,6 @@ (define-public rust-asn1-rs-0.5
               (sha256
                (base32
                 "1w7zq0392qs7kkv0nzw50bfqvq7q9zxv48fsp3sxyl83mzfxavvz"))))
-    (build-system cargo-build-system)
     (arguments
      `(#:cargo-inputs
        (("rust-asn1-rs-derive" ,rust-asn1-rs-derive-0.4)
@@ -159,11 +195,7 @@ (define-public rust-asn1-rs-0.5
         ("rust-hex-literal" ,rust-hex-literal-0.3)
         ("rust-oid-registry" ,rust-oid-registry-0.6)
         ("rust-pem" ,rust-pem-1)
-        ("rust-trybuild" ,rust-trybuild-1))))
-    (home-page "https://github.com/rusticata/asn1-rs")
-    (synopsis "Parser/encoder for ASN.1 BER/DER data")
-    (description "Parser/encoder for ASN.1 BER/DER data")
-    (license (list license:expat license:asl2.0))))
+        ("rust-trybuild" ,rust-trybuild-1))))))
 
 (define-public rust-asn1-rs-0.3
   (package
-- 
2.41.0