gnu: rust-permutohedron-0.2: Don't hide package.
[jackhill/guix/guix.git] / gnu / packages / crates-io.scm
index 3bf5d54..57319c7 100644 (file)
   #:use-module (guix build-system cargo)
   #:use-module (guix download)
   #:use-module ((guix licenses) #:prefix license:)
-  #:use-module (guix packages))
+  #:use-module (guix packages)
+  #:use-module (gnu packages compression)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages ssh)
+  #:use-module (gnu packages tls)
+  #:use-module (gnu packages version-control))
 
 ;;;
 ;;; Please: Try to add new module packages in alphabetic order.
@@ -4669,6 +4674,32 @@ heap.")
 total runtime size of an object on the heap")
     (license license:mpl2.0)))
 
+(define-public rust-heck-0.3
+  (package
+    (name "rust-heck")
+    (version "0.3.1")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (crate-uri "heck" version))
+        (file-name (string-append name "-" version ".crate"))
+        (sha256
+         (base32
+          "01a2v7yvkiqxakdqz4hw3w3g4sm52ivz9cs3qcsv2arxsmw4wmi0"))))
+    (build-system cargo-build-system)
+    (arguments
+     `(#:skip-build? #t
+       #:cargo-inputs
+       (("rust-unicode-segmentation" ,rust-unicode-segmentation-1.3))))
+    (home-page "https://github.com/withoutboats/heck")
+    (synopsis "Case conversion library")
+    (description
+     "This library exists to provide case conversion between common cases like
+CamelCase and snake_case.  It is intended to be unicode aware, internally
+consistent, and reasonably well performing.")
+    (license (list license:asl2.0
+                   license:expat))))
+
 (define-public rust-hex-0.4
   (package
     (name "rust-hex")
@@ -5567,28 +5598,46 @@ values of all the exported APIs match the platform that libc is compiled for.")
          (base32
           "0l9fvki7qxsl97vgzqwlv75nl213a5vxw7b1jaik97ala356pv6r"))))
     (build-system cargo-build-system)
-    ;(arguments
-    ; `(#:phases
-    ;  (modify-phases %standard-phases
-    ;    (add-after 'unpack 'find-openssl
-    ;      (lambda* (#:key inputs #:allow-other-keys)
-    ;        (let ((openssl (assoc-ref inputs "openssl")))
-    ;          (setenv "OPENSSL_DIR" openssl))
-    ;        (delete-file-recursively "libgit2")
-    ;        (setenv "LIBGIT2_SYS_USE_PKG_CONFIG" "1")
-    ;        (setenv "LIBSSH2_SYS_USE_PKG_CONFIG" "1")
-    ;        #t)))))
-    ;(native-inputs
-    ; `(("pkg-config" ,pkg-config)))
-    ;(inputs
-    ; `(("libgit2" ,libgit2)
-    ;   ("openssl" ,openssl)
-    ;   ("zlib" ,zlib)))
+    (arguments
+     `(#:cargo-inputs
+       (("rust-libc" ,rust-libc-0.2)
+        ("rust-libz-sys" ,rust-libz-sys-1.0)
+        ("rust-libssh2-sys" ,rust-libssh2-sys-0.2)
+        ("rust-openssl-sys" ,rust-openssl-sys-0.9)
+        ;; Build dependencies:
+        ("rust-cc" ,rust-cc-1.0)
+        ("rust-pkg-config" ,rust-pkg-config-0.3))
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'configure 'dont-vendor-sources
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((openssl (assoc-ref inputs "openssl")))
+               (setenv "OPENSSL_DIR" openssl))
+             (delete-file-recursively "libgit2")
+             (delete-file-recursively
+               (string-append "guix-vendor/rust-libgit2-sys-"
+                              ,(package-version rust-libgit2-sys-0.10)
+                              ".crate/libgit2"))
+             (delete-file-recursively
+               (string-append "guix-vendor/rust-libz-sys-"
+                              ,(package-version rust-libz-sys-1.0)
+                              ".crate/src/zlib"))
+             (delete-file-recursively
+               (string-append "guix-vendor/rust-libssh2-sys-"
+                              ,(package-version rust-libssh2-sys-0.2)
+                              ".crate/libssh2"))
+             (setenv "LIBGIT2_SYS_USE_PKG_CONFIG" "1")
+             (setenv "LIBSSH2_SYS_USE_PKG_CONFIG" "1")
+             #t)))))
+    (native-inputs
+     `(("libgit2" ,libgit2)
+       ("openssl" ,openssl)
+       ("pkg-config" ,pkg-config)
+       ("zlib" ,zlib)))
     (home-page "https://github.com/rust-lang/git2-rs")
     (synopsis "Native bindings to the libgit2 library")
     (description
      "This package provides native rust bindings to the @code{libgit2} library.")
-    (properties '((hidden? . #t)))
     (license (list license:asl2.0
                    license:expat))))
 
@@ -5604,7 +5653,9 @@ values of all the exported APIs match the platform that libc is compiled for.")
         (file-name (string-append name "-" version ".crate"))
         (sha256
          (base32
-          "0y2mibmx7wy91s2kmb2gfb29mrqlqaxpy5wcwr8s1lwws7b9w5sc"))))))
+          "0y2mibmx7wy91s2kmb2gfb29mrqlqaxpy5wcwr8s1lwws7b9w5sc"))))
+    (arguments '())
+    (properties '((hidden? . #t)))))
 
 (define-public rust-libgit2-sys-0.7
   (package
@@ -5618,7 +5669,9 @@ values of all the exported APIs match the platform that libc is compiled for.")
         (file-name (string-append name "-" version ".crate"))
         (sha256
          (base32
-          "1wcvg2qqra2aviasvqcscl8gb2rnjnd6h998wy5dlmf2bnriqi28"))))))
+          "1wcvg2qqra2aviasvqcscl8gb2rnjnd6h998wy5dlmf2bnriqi28"))))
+    (arguments '())
+    (properties '((hidden? . #t)))))
 
 (define-public rust-libloading-0.5
   (package
@@ -5652,7 +5705,7 @@ functions and static variables these libraries contain.")
 (define-public rust-libssh2-sys-0.2
   (package
     (name "rust-libssh2-sys")
-    (version "0.2.12")
+    (version "0.2.14")
     (source
       (origin
         (method url-fetch)
@@ -5660,29 +5713,44 @@ functions and static variables these libraries contain.")
         (file-name (string-append name "-" version ".crate"))
         (sha256
          (base32
-          "1zb6gsw795nq848nk5x2smzpfnn1s15wjlzjnvr8ihlz2l5x2549"))))
+          "042gsgbvxgm5by4mk906j3zm4qdvzcfhjxrb55is1lrr6f0nxain"))))
     (build-system cargo-build-system)
-    ;(arguments
-    ; `(#:phases
-    ;  (modify-phases %standard-phases
-    ;    (add-after 'unpack 'find-openssl
-    ;      (lambda* (#:key inputs #:allow-other-keys)
-    ;        (let ((openssl (assoc-ref inputs "openssl")))
-    ;          (setenv "OPENSSL_DIR" openssl))
-    ;        (delete-file-recursively "libssh2")
-    ;        (setenv "LIBSSH2_SYS_USE_PKG_CONFIG" "1")
-    ;        #t)))))
-    ;(native-inputs
-    ; `(("pkg-config" ,pkg-config)))
-    ;(inputs
-    ; `(("libssh2" ,libssh2)
-    ;   ("openssl" ,openssl)
-    ;   ("zlib" ,zlib)))
+    (arguments
+     `(#:skip-build? #t ; it wants rust-openssl-src
+       #:cargo-inputs
+       (("rust-libc" ,rust-libc-0.2)
+        ("rust-libz-sys" ,rust-libz-sys-1.0)
+        ("rust-openssl-sys" ,rust-openssl-sys-0.9)
+        ;; Build dependencies:
+        ("rust-cc" ,rust-cc-1.0)
+        ("rust-pkg-config" ,rust-pkg-config-0.3)
+        ("rust-vcpkg" ,rust-vcpkg-0.2))
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'configure 'dont-vendor-sources
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((openssl (assoc-ref inputs "openssl")))
+               (setenv "OPENSSL_DIR" openssl))
+             (delete-file-recursively "libssh2")
+             (delete-file-recursively
+               (string-append "guix-vendor/rust-libssh2-sys-"
+                              ,(package-version rust-libssh2-sys-0.2)
+                              ".crate/libssh2"))
+             (delete-file-recursively
+               (string-append "guix-vendor/rust-libz-sys-"
+                              ,(package-version rust-libz-sys-1.0)
+                              ".crate/src/zlib"))
+             (setenv "LIBSSH2_SYS_USE_PKG_CONFIG" "1")
+             #t)))))
+    (native-inputs
+     `(("libssh2" ,libssh2)
+       ("openssl" ,openssl)
+       ("pkg-config" ,pkg-config)
+       ("zlib" ,zlib)))
     (home-page "https://github.com/alexcrichton/ssh2-rs")
     (synopsis "Native bindings to the libssh2 library")
     (description
      "This package provides native rust bindings to the @code{libssh2} library.")
-    (properties '((hidden? . #t)))
     (license (list license:asl2.0
                    license:expat))))
 
@@ -5946,6 +6014,33 @@ whether an expression matches a pattern.")
     (properties '((hidden? . #t)))
     (license license:expat)))
 
+(define-public rust-matrixmultiply-0.1
+  (package
+    (name "rust-matrixmultiply")
+    (version "0.1.15")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (crate-uri "matrixmultiply" version))
+        (file-name (string-append name "-" version ".crate"))
+        (sha256
+         (base32
+          "00p0fpjhm45qdzi37mgv7ggsy8b9gqvq4999yrbgyn1dxkf6gbfw"))))
+    (build-system cargo-build-system)
+    (arguments
+     `(#:skip-build? #t
+       #:cargo-inputs (("rust-rawpointer" ,rust-rawpointer-0.1))
+       #:cargo-development-inputs (("rust-bencher" ,rust-bencher-0.1))))
+    (home-page "https://github.com/bluss/matrixmultiply/")
+    (synopsis "General matrix multiplication for f32 and f64 matrices")
+    (description "General matrix multiplication for f32 and f64 matrices.
+Operates on matrices with general layout (they can use arbitrary row and column
+stride).  Detects and uses AVX or SSE2 on x86 platforms transparently for higher
+performance.  Uses a microkernel strategy, so that the implementation is easy to
+parallelize and optimize.")
+    (license (list license:asl2.0
+                   license:expat))))
+
 (define-public rust-md5-0.6
   (package
     (name "rust-md5")
@@ -6993,22 +7088,30 @@ system for OpenSSL.")
         (sha256
          (base32 "0vvk8vzrc73y8n5rf4yj3x8ygyxjaz7wxrbxiwqi7qy0gyp1cpa6"))))
     (build-system cargo-build-system)
-    ;(arguments
-    ; `(#:phases
-    ;   (modify-phases %standard-phases
-    ;     (add-after 'unpack 'find-openssl
-    ;       (lambda* (#:key inputs #:allow-other-keys)
-    ;         (let ((openssl (assoc-ref inputs "openssl")))
-    ;           (setenv "OPENSSL_DIR" openssl))
-    ;         #t)))))
-    ;(inputs
-    ; `(("openssl" ,openssl)
-    ;   ("pkg-config" ,pkg-config)))
+    (arguments
+     `(#:skip-build? #t ; it wants rust-openssl-src
+       #:cargo-inputs
+       (("rust-libc" ,rust-libc-0.2)
+        ;; Build dependencies:
+        ("rust-autocfg" ,rust-autocfg-0.1)
+        ("rust-cc" ,rust-cc-1.0)
+        ("rust-pkg-config" ,rust-pkg-config-0.3)
+        ;("rust-openssl-src" ,rust-openssl-src-111)
+        ("rust-vcpkg" ,rust-vcpkg-0.2))
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'find-openssl
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((openssl (assoc-ref inputs "openssl")))
+               (setenv "OPENSSL_DIR" openssl))
+             #t)))))
+    (native-inputs
+     `(("openssl" ,openssl)
+       ("pkg-config" ,pkg-config)))
     (home-page "https://github.com/sfackler/rust-openssl")
     (synopsis "FFI bindings to OpenSSL")
     (description
      "This package provides FFI bindings to OpenSSL for use in rust crates.")
-    (properties '((hidden? . #t)))
     (license license:expat)))
 
 (define-public rust-ordermap-0.3
@@ -7468,13 +7571,13 @@ the @code{take_while} predicate returned false after dropping the @code{by_ref}.
          (base32
           "0b1pzh48j86v46wxngch6k1kx9cdw3jr3lwa86gd6jd4bmxzz1xn"))))
     (build-system cargo-build-system)
+    (arguments '(#:skip-build? #t))
     (home-page "https://github.com/bluss/permutohedron")
     (synopsis "Generate permutations of sequences")
     (description
      "Generate permutations of sequences.  Either lexicographical order
 permutations, or a minimal swaps permutation sequence implemented using Heap's
 algorithm.")
-    (properties '((hidden? . #t)))
     (license (list license:asl2.0
                    license:expat))))
 
@@ -8181,6 +8284,26 @@ to write.")
         ("rust-log" ,rust-log-0.4)
         ("rust-rand" ,rust-rand-0.4))))))
 
+(define-public rust-quickcheck-0.5
+  (package
+    (inherit rust-quickcheck-0.8)
+    (name "rust-quickcheck")
+    (version "0.5.0")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (crate-uri "quickcheck" version))
+        (file-name (string-append name "-" version ".tar.gz"))
+        (sha256
+         (base32
+          "1jzm1ygfbn4igaq14b9nipc8yvsn6c8panpgd1qiy5r2insjllyd"))))
+    (arguments
+     `(#:skip-build? #t
+       #:cargo-inputs
+       (("rust-env-logger" ,rust-env-logger-0.4)
+        ("rust-log" ,rust-log-0.3)
+        ("rust-rand" ,rust-rand-0.3))))))
+
 (define-public rust-quote-1.0
   (package
     (name "rust-quote")
@@ -12645,7 +12768,7 @@ described in Unicode Standard Annex #15.")
     (arguments
      `(#:skip-build? #t
        #:cargo-development-inputs
-       (("rust-quickcheck" ,rust-quickcheck-0.8))))
+       (("rust-quickcheck" ,rust-quickcheck-0.7))))
     (home-page "https://github.com/unicode-rs/unicode-segmentation")
     (synopsis "Grapheme Cluster, Word and Sentence boundaries")
     (description