From bd15cd595be239671043a21dff5b809f162a5a9d Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 29 Dec 2020 12:51:13 +0100 Subject: gnu: leptonica: Update to 1.80.0. * gnu/packages/image.scm (leptonica): Update to 1.80.0. Signed-off-by: Leo Famulari --- gnu/packages/image.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm index 3d93acc7f9..4c6ab8cda7 100644 --- a/gnu/packages/image.scm +++ b/gnu/packages/image.scm @@ -613,7 +613,7 @@ collection of tools for doing simple manipulations of TIFF images.") (define-public leptonica (package (name "leptonica") - (version "1.74.4") + (version "1.80.0") (source (origin (method git-fetch) @@ -622,7 +622,7 @@ collection of tools for doing simple manipulations of TIFF images.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0sfg1ky0lghlq7xx0qii5167bim0wwfnnr83dl4skbj9awyvjiwi")))) + (base32 "12ddln72z5l3icz0i9rpsfkg5xik8fcwcn8lb0cp3jigjxi8gvkg")))) (build-system gnu-build-system) (native-inputs `(("gnuplot" ,gnuplot) ;needed for test suite -- cgit v1.2.3 From c386de05fbcebf7c178327ca98326be20ba6ccb5 Mon Sep 17 00:00:00 2001 From: Z572 <873216071@qq.com> Date: Fri, 18 Dec 2020 10:25:51 +0800 Subject: gnu: Add ksshaskpass. * gnu/packages/kde-plasma.scm (ksshaskpass): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/kde-plasma.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/kde-plasma.scm b/gnu/packages/kde-plasma.scm index 33b702539b..c64d8ae39f 100644 --- a/gnu/packages/kde-plasma.scm +++ b/gnu/packages/kde-plasma.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2019 Marius Bakke ;;; Copyright © 2017, 2019, 2020 Hartmut Goebel ;;; Copyright © 2019 Tobias Geerinckx-Rice +;;; Copyright © 2020 Zheng Junjie <873216071@qq.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -106,6 +107,35 @@ These window decorations can be used by for example an X11 based window manager which re-parents a Client window to a window decoration frame.") (license license:lgpl3+))) +(define-public ksshaskpass + (package + (name "ksshaskpass") + (version "5.19.5") + (source (origin + (method url-fetch) + (uri (string-append "mirror://kde/stable/plasma/" version + "/ksshaskpass-" version ".tar.xz")) + (sha256 + (base32 + "1k2va2v9051f71w78dn3gihk642iyy5yzrkcfnp97fag8g6dpisi")))) + (build-system qt-build-system) + (native-inputs + `(("extra-cmake-modules" ,extra-cmake-modules) + ("kdoctools" ,kdoctools))) + (inputs + `(("kcoreaddons" ,kcoreaddons) + ("ki18n" ,ki18n) + ("kwallet" ,kwallet) + ("kwidgetsaddons" ,kwidgetsaddons) + ("qtbase" ,qtbase))) + (home-page "https://invent.kde.org/plasma/ksshaskpass") + (synopsis "Front-end for ssh-add using kwallet") + (description "Ksshaskpass is a front-end for @code{ssh-add} which stores the +password of the ssh key in KWallet. Ksshaskpass is not meant to be executed +directly, you need to tell @code{ssh-add} about it. @code{ssh-add} will then +call it if it is not associated to a terminal.") + (license license:gpl2+))) + (define-public kscreenlocker (package (name "kscreenlocker") -- cgit v1.2.3 From 44a4810a752b466a4a94a0e61a58476c50878fbd Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Fri, 18 Dec 2020 06:11:00 -0300 Subject: gnu: Add python-migen. * gnu/packages/fpga.scm (python-migen): New variable. Signed-off-by: Mathieu Othacehe --- gnu/packages/fpga.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 50a19a00d6..96c37791f6 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2016, 2017 Theodoros Foradis ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2019 Amin Bandali +;;; Copyright © 2020 Vinicius Monego ;;; ;;; This file is part of GNU Guix. ;;; @@ -35,6 +36,7 @@ #:use-module (gnu packages tcl) #:use-module (gnu packages readline) #:use-module (gnu packages python) + #:use-module (gnu packages python-xyz) #:use-module (gnu packages bison) #:use-module (gnu packages check) #:use-module (gnu packages flex) @@ -381,6 +383,33 @@ simulator trace files (@dfn{FST}).") ;; Exception against free government use in tcl_np.c and tcl_np.h. (license (list license:gpl2+ license:expat license:tcl/tk)))) +(define-public python-migen + (package + (name "python-migen") + (version "0.9.2") + (source + (origin + ;; Tests fail in the PyPI tarball due to missing files. + (method git-fetch) + (uri (git-reference + (url "https://github.com/m-labs/migen") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1kq11if64zj84gv4w1q7l16fp17xjxl2wv5hc9dibr1z3m1gy67l")))) + (build-system python-build-system) + (propagated-inputs + `(("python-colorama" ,python-colorama))) + (home-page "https://m-labs.hk/gateware/migen/") + (synopsis "Python toolbox for building complex digital hardware") + (description + "Migen FHDL is a Python library that replaces the event-driven +paradigm of Verilog and VHDL with the notions of combinatorial and +synchronous statements, has arithmetic rules that make integers always +behave like mathematical integers, and allows the design's logic to be +constructed by a Python program.") + (license license:bsd-2))) + (define-public python-myhdl (package (name "python-myhdl") -- cgit v1.2.3 From d1d092f198c7a934beab71eaf91a442a8561f767 Mon Sep 17 00:00:00 2001 From: luhux Date: Sun, 15 Nov 2020 20:47:46 +0800 Subject: gnu: Add sdcv. * gnu/packages/dictionaries.scm (sdcv): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/dictionaries.scm | 51 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/dictionaries.scm b/gnu/packages/dictionaries.scm index ffdaf89215..6387132016 100644 --- a/gnu/packages/dictionaries.scm +++ b/gnu/packages/dictionaries.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2018 Pierre-Antoine Rouby ;;; Copyright © 2018 Arun Isaac ;;; Copyright © 2019 Pierre Langlois +;;; Copyright © 2020 Lu hux ;;; ;;; This file is part of GNU Guix. ;;; @@ -32,6 +33,7 @@ #:use-module (guix build-system python) #:use-module (guix build-system trivial) #:use-module (guix build-system copy) + #:use-module (guix build-system cmake) #:use-module (gnu packages) #:use-module (gnu packages autotools) #:use-module (gnu packages base) @@ -39,7 +41,10 @@ #:use-module (gnu packages emacs) #:use-module (gnu packages flex) #:use-module (gnu packages fribidi) + #:use-module (gnu packages gettext) + #:use-module (gnu packages glib) #:use-module (gnu packages linux) + #:use-module (gnu packages ncurses) #:use-module (gnu packages pcre) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -392,3 +397,49 @@ second on ordinary desktop computers) and, in spite of the errors, reasonably intelligible and easily correctable.") (license (list license:gpl2 ; main license license:expat)))) ; utf8/* + +(define-public sdcv + (package + (name "sdcv") + (version "0.5.3") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/Dushistov/sdcv/") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "144qpl9b8r2php0zhi9b7vg6flpvdgjy6yfaipydwwhxi4wy9600")))) + (build-system cmake-build-system) + (arguments + `(#:configure-flags '("-DBUILD_TESTS=YES") + #:phases + (modify-phases %standard-phases + (add-after 'build 'build-lang + (lambda _ + (invoke "make" "lang"))) + (add-before 'check 'pre-check + (lambda _ + (setenv "HOME" (getcwd)) + #t)) + (add-after 'unpack 'remove-jq-requirement + (lambda _ + ;; We don't want to bring in jq for one test. + (substitute* "tests/t_json" + (("jq") "echo")) + #t))))) + (native-inputs + `(("gettext" ,gettext-minimal) + ("pkg-config" ,pkg-config))) + (inputs + `(("glib" ,glib) + ("ncurses" ,ncurses) + ("readline" ,readline) + ("zlib" ,zlib))) + (home-page "https://dushistov.github.io/sdcv/") + (synopsis "Console version of StarDict") + (description "sdcv is simple text-based utility for work with dictionaries +in StarDict's format.") + (license license:gpl2+))) -- cgit v1.2.3 From 77ca156ab2b3a89b2e15d9de4912ad8e022c2c78 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:03 +0100 Subject: gnu: Remove ocaml-js-build-tools. The package is deprecated and no longer maintained. It is recommended to use dune instead. * gnu/packages/ocaml.xyz (ocaml-js-build-tools, janestreet-origin) (janestreet-arguments): Remove variables. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 65 +------------------------------------------------- 1 file changed, 1 insertion(+), 64 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index c4900b6214..64c8633af3 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -17,6 +17,7 @@ ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2020 Simon Tournier ;;; Copyright © 2020 divoplade +;;; Copyright © 2020 pukkamustard ;;; ;;; This file is part of GNU Guix. ;;; @@ -93,47 +94,6 @@ (number->string file-number) "/" name "-" version ".tar.gz")) -;; Janestreet packages are found in a similar way and all need the same patch. -(define (janestreet-origin name version hash) - (origin (method url-fetch) - (uri (string-append "https://ocaml.janestreet.com/ocaml-core/" - (version-major+minor version) "/files/" - name "-" version ".tar.gz")) - (sha256 (base32 hash)) - (modules '((guix build utils))) - (snippet - (let ((pattern (string-append "lib/" name))) - `(begin - ;; install.ml contains an invalid reference to the ppx file and - ;; propagates this error to the generated META file. It - ;; looks for it in the "lib" directory, but it is installed in - ;; "lib/ocaml/site-lib/package". This substitute does not change - ;; this file for non ppx packages. - (substitute* "install.ml" - ((,pattern) (string-append "lib/ocaml/site-lib/" ,name))) - ;; The standard Makefile would try to install janestreet modules - ;; in OCaml's directory in the store, which is read-only. - (substitute* "Makefile" - (("--prefix") - "--libdir $(LIBDIR) --prefix")) - #t))))) - -;; They also require almost the same set of arguments -(define janestreet-arguments - `(#:use-make? #t - #:make-flags - (list (string-append "CONFIGUREFLAGS=--prefix " - (assoc-ref %outputs "out") - " --enable-tests") - (string-append "LIBDIR=" - (assoc-ref %outputs "out") - "/lib/ocaml/site-lib") - ;; for ocaml-bin-prot, otherwise ignored - (string-append "OCAML_TOPLEVEL_PATH=" - (assoc-ref %build-inputs "findlib") - "/lib/ocaml/site-lib")) - #:phases (modify-phases %standard-phases (delete 'configure)))) - (define-public ocaml-4.11 (package (name "ocaml") @@ -2716,29 +2676,6 @@ system in your OCaml projects. It helps to create standard entry points in your build system and allows external tools to analyse your project easily.") (license license:lgpl2.1+))) ; with ocaml static compilation exception -(define-public ocaml-js-build-tools - (package - (name "ocaml-js-build-tools") - (version "113.33.06") - (source (janestreet-origin "js-build-tools" version - "0r8z4fz8iy5y6hkdlkpwf6rk4qigcr3dzyv35585xgg2ahf12zy6")) - (native-inputs - `(("oasis" ,ocaml-oasis) - ("ocamlbuild" ,ocamlbuild) - ("opam" ,opam))) - (build-system ocaml-build-system) - (arguments janestreet-arguments) - (home-page "https://github.com/janestreet/js-build-tools") - (synopsis "Collection of tools to help building Jane Street Packages") - (description "This package contains tools to help building Jane Street -packages, but can be used for other purposes. It contains: -@enumerate -@item an @command{oasis2opam-install} tool to produce a @file{.install} file -from the oasis build log -@item a @code{js_build_tools} ocamlbuild plugin with various goodies. -@end enumerate") - (license license:asl2.0))) - (define-public ocaml-cppo (package (name "ocaml-cppo") -- cgit v1.2.3 From adb30e517bb908eb395825bec9113881997d5060 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:04 +0100 Subject: gnu: Add ocaml-sexplib0. * gnu/packages/ocaml.scm (ocaml-sexplib0): New variable. (ocaml4.07-sexplib0): Inherit from ocaml-sexplib0. (janestreet-origin): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 60 +++++++++++++++++++++++++++++--------------------- 1 file changed, 35 insertions(+), 25 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 64c8633af3..acbdb33f2e 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -94,6 +94,14 @@ (number->string file-number) "/" name "-" version ".tar.gz")) +(define (janestreet-origin name version hash) + (origin (method url-fetch) + (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v" + (version-major+minor version) "/files/" + name "-v" (version-major+minor+point version) + ".tar.gz")) + (sha256 (base32 hash)))) + (define-public ocaml-4.11 (package (name "ocaml") @@ -2918,7 +2926,7 @@ JSON.") ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv))) (propagated-inputs `(("ocaml-re" ,(package-with-ocaml4.07 ocaml-re)) - ("ocaml-sexplib0" ,ocaml4.07-sexplib0) + ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)) ("ocaml-stringext" ,(package-with-ocaml4.07 ocaml-stringext)))) (home-page "https://github.com/mirage/ocaml-uri") (synopsis "RFC3986 URI/URL parsing library") @@ -3649,7 +3657,7 @@ syntax checking on dedukti files.") ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-compiler-libs" ,ocaml4.07-compiler-libs) - ("ocaml-sexplib0" ,ocaml4.07-sexplib0) + ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)) ("ocaml-stdio" ,ocaml4.07-stdio) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) (properties `((upstream-name . "ppx_inline_test"))) @@ -4028,33 +4036,35 @@ an arbitrary number of processes. Cache coherence protocols and mutual exclusion algorithms are typical examples of such systems.") (license license:asl2.0))) -(define-public ocaml4.07-sexplib0 +(define-public ocaml-sexplib0 (package - (name "ocaml4.07-sexplib0") - (version "0.11.0") + (name "ocaml-sexplib0") + (version "0.14.0") (home-page "https://github.com/janestreet/sexplib0") (source - (origin - (method git-fetch) - (uri (git-reference - (url (string-append home-page ".git")) - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "07v3ggyss7xhfv14bjk1n87sr42iqwj4cgjiv2lcdfkqk49i2bmi")))) + (janestreet-origin "sexplib0" version + "0adrc0r1vvvr41dcpj8jwkzh1dfgqf0mks9xlnnskqfm3a51iavg")) (build-system dune-build-system) - (arguments - `(#:tests? #f ;no tests - #:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) + (arguments `(#:tests? #f)) ;no tests + (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sexplib0)))) (synopsis "Library containing the definition of S-expressions and some base converters") (description "Part of Jane Street's Core library The Core suite of libraries is an industrial strength alternative to OCaml's standard library that was developed by Jane Street, the largest industrial user of OCaml.") -(license license:expat))) + (license license:expat))) + +(define-public ocaml4.07-sexplib0 + (package-with-ocaml4.07 + (package + (inherit ocaml-sexplib0) + (name "ocaml-sexplib0") + (version "0.11.0") + (source + (janestreet-origin "sexplib0" version + "1p06p2s7p9xsjn0z9qicniv1ai54d8sj11k8j633di2mm7jzxpin")) + (arguments `(#:tests? #f)) ; no tests + (properties '())))) (define-public ocaml4.07-parsexp (package @@ -4077,7 +4087,7 @@ that was developed by Jane Street, the largest industrial user of OCaml.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (inputs - `(("ocaml-sexplib0" ,ocaml4.07-sexplib0))) + `(("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (synopsis "S-expression parsing library") (description "This library provides generic parsers for parsing S-expressions from @@ -4129,7 +4139,7 @@ parsexp_io.") (propagated-inputs `(("ocaml-num" ,(package-with-ocaml4.07 ocaml-num)) ("ocaml-parsexp" ,ocaml4.07-parsexp) - ("ocaml-sexplib0" ,ocaml4.07-sexplib0))) + ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (synopsis "Library for serializing OCaml values to and from S-expressions") (description @@ -4154,7 +4164,7 @@ functionality for parsing and pretty-printing s-expressions.") "0j6xb4265jr41vw4fjzak6yr8s30qrnzapnc6rl1dxy8bjai0nir")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-sexplib0" ,ocaml4.07-sexplib0))) + `(("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (arguments `(#:phases (modify-phases %standard-phases @@ -4225,7 +4235,7 @@ is now @code{Ocaml_common.Ast_helper}.") (build-system dune-build-system) (propagated-inputs `(("ocaml-base" ,ocaml4.07-base) - ("ocaml-sexplib0" ,ocaml4.07-sexplib0))) + ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (arguments `(#:tests? #f ;no tests #:ocaml ,ocaml-4.07 @@ -4289,7 +4299,7 @@ as part of the same ocaml-migrate-parsetree driver.") ("ocaml-ppx-derivers" ,(package-with-ocaml4.07 ocaml-ppx-derivers)) ("ocaml-stdio" ,ocaml4.07-stdio) ("ocaml-result" ,(package-with-ocaml4.07 ocaml-result)) - ("ocaml-sexplib0" ,ocaml4.07-sexplib0))) + ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (arguments `(#:phases (modify-phases %standard-phases -- cgit v1.2.3 From 55c2851a19af470a19bdaf1539c161bf63a8465a Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:05 +0100 Subject: gnu: Add ocaml-base. * gnu/packages/ocaml.scm (ocaml-base): New variable. (ocaml4.07-base): Inherit from ocaml-base. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 137 +++++++++++++++++++++++++++---------------------- 1 file changed, 75 insertions(+), 62 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index acbdb33f2e..762784a0dd 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -1608,7 +1608,7 @@ library.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (native-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-stdio" ,ocaml4.07-stdio) ("pkg-config" ,pkg-config))) (inputs @@ -2561,7 +2561,7 @@ hierarchy of modules.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (native-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("pcre:bin" ,pcre "bin"))) (propagated-inputs `(("pcre" ,pcre))) (home-page "https://mmottl.github.io/pcre-ocaml") @@ -3653,7 +3653,7 @@ syntax checking on dedukti files.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-compiler-libs" ,ocaml4.07-compiler-libs) @@ -3947,7 +3947,7 @@ Atom.") (inputs `(("gsl" ,gsl))) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-stdio" ,ocaml4.07-stdio))) (home-page "https://mmottl.github.io/gsl-ocaml") (synopsis "Bindings to the GNU Scientific Library") @@ -4147,38 +4147,22 @@ parsexp_io.") functionality for parsing and pretty-printing s-expressions.") (license license:expat))) -(define-public ocaml4.07-base +(define-public ocaml-base (package - (name "ocaml4.07-base") - (version "0.11.1") + (name "ocaml-base") + (version "0.14.0") (home-page "https://github.com/janestreet/base") (source - (origin - (method git-fetch) - (uri (git-reference - (url (string-append home-page ".git")) - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0j6xb4265jr41vw4fjzak6yr8s30qrnzapnc6rl1dxy8bjai0nir")))) + (janestreet-origin "base" version + "1rkdhsgbcv0a8p29mwvpd2ldz8cjk97pixl43izm54wyin4lp778")) (build-system dune-build-system) (propagated-inputs - `(("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) - (arguments - `(#:phases - (modify-phases %standard-phases - (replace 'build - ;; make warnings non fatal (jbuilder behaviour) - (lambda _ - (invoke "dune" "build" "@install" "--profile=release")))) - #:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) - (synopsis - "Full standard library replacement for OCaml") - (description - "Base is a complete and portable alternative to the OCaml standard + `(("ocaml-sexplib0" ,ocaml-sexplib0))) + (properties `((ocaml4.07-variant . ,(delay ocaml4.07-base)))) + (synopsis + "Full standard library replacement for OCaml") + (description + "Base is a complete and portable alternative to the OCaml standard library. It provides all standard functionalities one would expect from a language standard library. It uses consistent conventions across all of its module. @@ -4187,7 +4171,36 @@ Base aims to be usable in any context. As a result system dependent features such as I/O are not offered by Base. They are instead provided by companion libraries such as @url{https://github.com/janestreet/stdio, ocaml-stdio}.") - (license license:expat))) + (license license:expat))) + +(define-public ocaml4.07-base + (package-with-ocaml4.07 + (package + (inherit ocaml-base) + (name "ocaml-base") + (version "0.11.1") + (source + (origin + ;; version 0.11.1 is not released on ocaml.janestreet.org. + (method git-fetch) + (uri (git-reference + (url "https://github.com/janestreet/base.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0j6xb4265jr41vw4fjzak6yr8s30qrnzapnc6rl1dxy8bjai0nir")))) + (arguments + `(#:phases + (modify-phases %standard-phases + (replace 'build + ;; make warnings non fatal (jbuilder behaviour) + (lambda _ + (invoke "dune" "build" "@install" "--profile=release")))) + #:ocaml ,ocaml-4.07 + #:findlib ,ocaml4.07-findlib + #:dune ,ocaml4.07-dune)) + (properties '())))) (define-public ocaml4.07-compiler-libs (package @@ -4234,7 +4247,7 @@ is now @code{Ocaml_common.Ast_helper}.") "1facajqhvq34g2wrg368y0ajxd6lrj5b3lyzyj0jhdmraxajjcwn")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (arguments `(#:tests? #f ;no tests @@ -4292,7 +4305,7 @@ as part of the same ocaml-migrate-parsetree driver.") "0my9x7sxb329h0lzshppdaawiyfbaw6g5f41yiy7bhl071rnlvbv")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-compiler-libs" ,ocaml4.07-compiler-libs) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -4355,7 +4368,7 @@ OCaml AST in the OCaml syntax; "06bq4m1bsm4jlx4g7wh5m99qky7xm4c2g52kaz6pv25hdn5agi2m")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4394,7 +4407,7 @@ by making sure that you only compare comparable values.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4426,7 +4439,7 @@ of a record and create new record values.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4451,7 +4464,7 @@ standard library.") "07zrd3qky2ppbfl55gpm90rvqa5860xgwcsvihrjmkrw6d0jirkc")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-fieldslib" ,ocaml4.07-fieldslib) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -4484,7 +4497,7 @@ new record values.") "0pqwnqy1xp309wvdcaax4lg02yk64lq2w03mbgfvf6ps5ry4gis9")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4514,7 +4527,7 @@ definitions.") "1yc0gsds5m2nv39zga8nnrca2n75rkqy5dz4xj1635ybz20hhbjd")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-variantslib" ,ocaml4.07-variantslib) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -4547,7 +4560,7 @@ variant types.") "11b73smf3g3bpd9lg014pr4rx285nk9mnk6g6464ph51jv0sqzhj")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -4577,7 +4590,7 @@ string conversion.") "1rsd91gx36prj4whi76nsiz1bzpgal9nzyw3pxdz1alv4ilk2il6")))) (build-system dune-build-system) (inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare) ("ocaml-ppx-custom-printf" ,ocaml4.07-ppx-custom-printf) ("ocaml-ppx-fields-conv" ,ocaml4.07-ppx-fields-conv) @@ -4646,7 +4659,7 @@ storage of large amounts of data.") "1p0ic6aijxlrdggpmycj12q3cy9xksbq2vq727215maz4snvlf5p")))) (build-system dune-build-system) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) ("ocaml-migrate-parsetree" @@ -4683,7 +4696,7 @@ hash functions from type exrpessions and definitions.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4745,7 +4758,7 @@ many values).") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4774,7 +4787,7 @@ many values).") #:ocaml ,ocaml-4.07 #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) - (propagated-inputs `(("ocaml-base" ,ocaml4.07-base))) + (propagated-inputs `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)))) (home-page "https://github.com/janestreet/typerep") (synopsis "Typerep is a library for runtime types") (description "Typerep is a library for runtime types.") @@ -4798,7 +4811,7 @@ many values).") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-here" ,ocaml4.07-ppx-here) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) ("ocaml-migrate-parsetree" @@ -4829,7 +4842,7 @@ ocaml values.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-here" ,ocaml4.07-ppx-here) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) ("ocaml-migrate-parsetree" @@ -4894,7 +4907,7 @@ context such as function arguments.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4924,7 +4937,7 @@ else expression.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-stdio" ,ocaml4.07-stdio) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) (properties `((upstream-name . "ppx_optcomp"))) @@ -4953,7 +4966,7 @@ size, the version of the compiler, ...") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-ppxlib" ,ocaml4.07-ppxlib))) @@ -4982,7 +4995,7 @@ match expressions, and if expressions.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-here" ,ocaml4.07-ppx-here) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -5012,7 +5025,7 @@ position.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare) ("ocaml-ppx-here" ,ocaml4.07-ppx-here) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) @@ -5045,7 +5058,7 @@ useful errors on failure.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert) ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare) ("ocaml-ppx-custom-printf" ,ocaml4.07-ppx-custom-printf) @@ -5089,7 +5102,7 @@ to denote the expected output.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) ("ocaml-octavius" ,(package-with-ocaml4.07 ocaml-octavius)) @@ -5122,7 +5135,7 @@ packages.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-typerep" ,ocaml4.07-typerep) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)) @@ -5191,7 +5204,7 @@ verification tool.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-bin-prot" ,ocaml4.07-bin-prot) ("ocaml-ppx-here" ,ocaml4.07-ppx-here) ("ocaml-migrate-parsetree" @@ -5269,7 +5282,7 @@ driver including all standard Jane Street ppx rewriters.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane) ("ocaml-migrate-parsetree" ,(package-with-ocaml4.07 ocaml-migrate-parsetree)))) @@ -5329,7 +5342,7 @@ various Jane Street packages.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-stdio" ,ocaml4.07-stdio))) (home-page "https://github.com/janestreet/configurator") (synopsis "Helper library for gathering system configuration") @@ -5416,7 +5429,7 @@ thousands of times faster than fork. #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-configurator" ,ocaml4.07-configurator) ("ocaml-core-kernel" ,ocaml4.07-core-kernel) ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert) @@ -5456,7 +5469,7 @@ standard library that was developed by Jane Street.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-base" ,ocaml4.07-base) + `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-bin-prot" ,ocaml4.07-bin-prot) ("ocaml-configurator" ,ocaml4.07-configurator) ("ocaml-fieldslib" ,ocaml4.07-fieldslib) @@ -5716,7 +5729,7 @@ library FFTW.") (native-inputs `(("openblas" ,openblas) ("lapack" ,lapack) - ("ocaml-base" ,ocaml4.07-base) + ("ocaml-base" ,(package-with-ocaml4.07 ocaml-base)) ("ocaml-stdio" ,ocaml4.07-stdio))) (home-page "https://mmottl.github.io/lacaml/") (synopsis -- cgit v1.2.3 From 662307c30a462d98cb1b16a6c5de208d18adce71 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:06 +0100 Subject: gnu: Add ocaml-parsexp. * gnu/packages/ocaml.scm (ocaml-parsexp): New variable. (ocaml4.07-parsexp): Inherit from ocaml-parsexp. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 762784a0dd..2ba1dd90e5 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -4066,28 +4066,19 @@ that was developed by Jane Street, the largest industrial user of OCaml.") (arguments `(#:tests? #f)) ; no tests (properties '())))) -(define-public ocaml4.07-parsexp +(define-public ocaml-parsexp (package - (name "ocaml4.07-parsexp") - (version "0.11.0") + (name "ocaml-parsexp") + (version "0.14.0") (home-page "https://github.com/janestreet/parsexp") (source - (origin - (method git-fetch) - (uri (git-reference - (url (string-append home-page ".git")) - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1nyq23s5igd8cf3n4qxprjvhbmb6ighb3fy5mw7hxl0mdgsw5fvz")))) + (janestreet-origin "parsexp" version + "158znj19dvfdcwsgzs3rdhxpj1g4aw0d4nkfr8c05bahf0lnshlb")) (build-system dune-build-system) - (arguments - `(#:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) (inputs - `(("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) + `(("ocaml-sexplib0" ,ocaml-sexplib0) + ("ocaml-base" ,ocaml-base))) + (properties `((ocaml4.07-variant . ,(delay ocaml4.07-parsexp)))) (synopsis "S-expression parsing library") (description "This library provides generic parsers for parsing S-expressions from @@ -4116,6 +4107,17 @@ s-expressions from files or other external sources, you should use parsexp_io.") (license license:expat))) +(define-public ocaml4.07-parsexp + (package-with-ocaml4.07 + (package + (inherit ocaml-parsexp) + (name "ocaml-parsexp") + (version "0.11.0") + (source + (janestreet-origin "parsexp" version + "11a30zkfgbi6pb4whq22k1zc8ghdp9bwxl5s5cdlmx1z8s4yxsf0")) + (properties '())))) + (define-public ocaml4.07-sexplib (package (name "ocaml4.07-sexplib") @@ -4138,7 +4140,7 @@ parsexp_io.") #:dune ,ocaml4.07-dune)) (propagated-inputs `(("ocaml-num" ,(package-with-ocaml4.07 ocaml-num)) - ("ocaml-parsexp" ,ocaml4.07-parsexp) + ("ocaml-parsexp" ,(package-with-ocaml4.07 ocaml-parsexp)) ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) (synopsis "Library for serializing OCaml values to and from S-expressions") -- cgit v1.2.3 From 5de771a49a52ff56ddaec4a911cb44b9d41d31fa Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:07 +0100 Subject: gnu: Add ocaml-sexplib. * gnu/packages/ocaml.scm (ocaml-sexplib): New variable. (ocaml4.07-sexplib): Inherit from ocaml-sexplib. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 49 +++++++++++++++++++++++++------------------------ 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 2ba1dd90e5..b12a795e47 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -2887,7 +2887,7 @@ writing to these structures, and they are accessed via the Bigarray module.") (propagated-inputs `(("ocaml-hex" ,(package-with-ocaml4.07 ocaml-hex)) ("ocaml-jsonm" ,(package-with-ocaml4.07 ocaml-jsonm)) - ("ocaml-sexplib" ,ocaml4.07-sexplib))) + ("ocaml-sexplib" ,(package-with-ocaml4.07 ocaml-sexplib)))) (home-page "https://github.com/mirage/ezjsonm/") (synopsis "Read and write JSON data") (description "Ezjsonm provides more convenient (but far less flexible) input @@ -4118,37 +4118,38 @@ parsexp_io.") "11a30zkfgbi6pb4whq22k1zc8ghdp9bwxl5s5cdlmx1z8s4yxsf0")) (properties '())))) -(define-public ocaml4.07-sexplib +(define-public ocaml-sexplib (package - (name "ocaml4.07-sexplib") - (version "0.11.0") + (name "ocaml-sexplib") + (version "0.14.0") (home-page "https://github.com/janestreet/sexplib") (source - (origin - (method git-fetch) - (uri (git-reference - (url (string-append home-page ".git")) - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1qfl0m04rpcjvc4yw1hzh6r16jpwmap0sa9ax6zjji67dz4szpyb")))) + (janestreet-origin "sexplib" version + "12rlnc6fcrjfdn3gs2agi418sj54ighhs6dfll37zcv7mgywblm2")) (build-system dune-build-system) - (arguments - `(#:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-num" ,(package-with-ocaml4.07 ocaml-num)) - ("ocaml-parsexp" ,(package-with-ocaml4.07 ocaml-parsexp)) - ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0)))) + `(("ocaml-base" ,ocaml-base) + ("ocaml-num" ,ocaml-num) + ("ocaml-parsexp" ,ocaml-parsexp) + ("ocaml-sexplib0" ,ocaml-sexplib0))) + (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sexplib)))) (synopsis "Library for serializing OCaml values to and from S-expressions") (description - "This package is part of Jane Street's Core library. Sexplib contains + "This package is part of Jane Street's Core library. Sexplib contains functionality for parsing and pretty-printing s-expressions.") (license license:expat))) +(define-public ocaml4.07-sexplib + (package-with-ocaml4.07 + (package + (inherit ocaml-sexplib) + (version "0.11.0") + (source + (janestreet-origin "sexplib" version + "0ksx62zsxhz8xmdrsn41n2hbc2qbyh3bxxc6946xisvgwh42h3q3")) + (properties '())))) + (define-public ocaml-base (package (name "ocaml-base") @@ -5436,7 +5437,7 @@ thousands of times faster than fork. ("ocaml-core-kernel" ,ocaml4.07-core-kernel) ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert) ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane) - ("ocaml-sexplib" ,ocaml4.07-sexplib) + ("ocaml-sexplib" ,(package-with-ocaml4.07 ocaml-sexplib)) ("ocaml-spawn" ,ocaml4.07-spawn) ("ocaml-stdio" ,ocaml4.07-stdio) ("ocaml-migrate-parsetree" @@ -5483,7 +5484,7 @@ standard library that was developed by Jane Street.") ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane) ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv) ("ocaml-ppx-sexp-message" ,ocaml4.07-ppx-sexp-message) - ("ocaml-sexplib" ,ocaml4.07-sexplib) + ("ocaml-sexplib" ,(package-with-ocaml4.07 ocaml-sexplib)) ("ocaml-splittable-random" ,ocaml4.07-splittable-random) ("ocaml-stdio" ,ocaml4.07-stdio) ("ocaml-typerep" ,ocaml4.07-typerep) @@ -5650,7 +5651,7 @@ then run the Bisect_ppx report tool on the generated visitation files.") (inputs `(("ocaml-alcotest" ,(package-with-ocaml4.07 ocaml-alcotest)) ("ocaml-markup" ,(package-with-ocaml4.07 ocaml-markup)) - ("ocaml-sexplib" ,ocaml4.07-sexplib) + ("ocaml-sexplib" ,(package-with-ocaml4.07 ocaml-sexplib)) ("ocaml-re" ,(package-with-ocaml4.07 ocaml-re)) ("ocaml-uutf" ,(package-with-ocaml4.07 ocaml-uutf)))) (native-inputs -- cgit v1.2.3 From 349699bbc21c9946486b0b41d8b2e24192bc9b7a Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:08 +0100 Subject: gnu: Add ocaml-ounit2. * gnu/packages/ocaml.xyz (ocaml-ounit2): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index b12a795e47..d10b14bf37 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -982,6 +982,32 @@ compilers that can directly deal with packages.") `(("m4" ,m4) ("ocaml" ,ocaml-4.09))))) +(define-public ocaml-ounit2 + (package + (name "ocaml-ounit2") + (version "2.2.4") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/gildor478/ounit.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0gxjw1bhmjcjzri6x6psqrkbbyq678b69bqfl9i1zswp7cj2lryg")))) + (build-system dune-build-system) + (inputs + ;; XXX Should libev be a propagated-input of ocaml-lwt? + `(("libev" ,libev))) + (propagated-inputs + `(("lwt" ,ocaml-lwt) + ("ocaml-stdlib-shims" ,ocaml-stdlib-shims))) + (home-page "https://github.com/gildor478/ounit") + (synopsis "Unit testing framework for OCaml") + (description "OUnit2 is a unit testing framework for OCaml. It is similar +to JUnit and other XUnit testing frameworks.") + (license license:expat))) + ;; note that some tests may hang for no obvious reason. (define-public ocaml-ounit (package -- cgit v1.2.3 From 1a5bca9b3b143b3d9f234c95d8d2c43ca637de17 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:09 +0100 Subject: gnu: ocaml-tyxml: Update to 4.4.0. * gnu/packages/ocaml.scm (ocaml-tyxml): Update to 4.4.0. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index d10b14bf37..273dc2572c 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -5582,7 +5582,7 @@ stream, and convert everything to UTF-8.") (define-public ocaml-tyxml (package (name "ocaml-tyxml") - (version "4.3.0") + (version "4.4.0") (source (origin (method git-fetch) @@ -5592,7 +5592,7 @@ stream, and convert everything to UTF-8.") (file-name (git-file-name name version)) (sha256 (base32 - "0wv19xipkj8l2sks1h53105ywbjwk7q93fb7b8al4a2g9wr109c0")))) + "1hw4phyadcfgywgh5sj87i76gp56qwxzwlcpfdwjbf6ggag9clmd")))) (build-system dune-build-system) (inputs `(("ocaml-re" ,ocaml-re) -- cgit v1.2.3 From ad6a057724b1f376fdd747de953561cee72720a0 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:10 +0100 Subject: gnu: ocaml-markup: Update to 1.0.0. * gnu/packages/ocaml.scm (ocaml-markup): Update to 1.0.0. (ocaml-markup0.8.0): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 273dc2572c..e3dca82e47 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -5533,7 +5533,7 @@ the full Core is not available, such as in Javascript.") (define-public ocaml-markup (package (name "ocaml-markup") - (version "0.8.2") + (version "1.0.0") (home-page "https://github.com/aantron/markup.ml") (source (origin @@ -5544,7 +5544,7 @@ the full Core is not available, such as in Javascript.") (file-name (git-file-name name version)) (sha256 (base32 - "13zcrwzjmifniv3bvjbkd2ah8wwa3ld75bxh1d8hrzdvfxzh9szn")))) + "09hkrf9pw6hpb9j06p5bddklpnjwdjpqza3bx2179l970yl67an9")))) (build-system dune-build-system) (arguments `(#:package "markup")) @@ -5556,8 +5556,10 @@ the full Core is not available, such as in Javascript.") ("ocaml-uutf" ,ocaml-uutf) ("ocaml-lwt" ,ocaml-lwt))) (native-inputs - `(("ocaml-ounit" ,ocaml-ounit) + `(("ocaml-ounit2" ,ocaml-ounit2) ("pkg-config" ,pkg-config))) + (properties + `((ocaml4.07-variant . ,(delay (package-with-ocaml4.07 ocaml-markup0.8.0))))) (synopsis "Error-recovering functional HTML5 and XML parsers and writers") (description "Markup.ml provides an HTML parser and an XML parser. The parsers are wrapped in a simple interface: they are functions that transform @@ -5579,6 +5581,26 @@ a single pass. They automatically detect the character encoding of the input stream, and convert everything to UTF-8.") (license license:bsd-3))) +;; ocaml-markup 1.0.0 can not be built with old version of dune used in +;; package-with-ocaml4.07 +(define-public ocaml-markup0.8.0 + (package + (inherit ocaml-markup) + (name "ocaml-markup") + (version "0.8.0") + (home-page "https://github.com/aantron/markup.ml") + (source + (origin + (method git-fetch) + (uri (git-reference + (url (string-append home-page ".git")) + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0aif4abvfmi9xc1pvw5n5rbm6rzkkpsxyvdn0lanr33rjpvkwdlm")))) + (properties '()))) + (define-public ocaml-tyxml (package (name "ocaml-tyxml") -- cgit v1.2.3 From 9e02c4acb3e73e9d426d9ec09ffbcb7f047b46db Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:11 +0100 Subject: gnu: Add ocaml-odoc. * gnu/packages/ocaml.scm (ocaml-odoc): New variable. (ocaml4.07-odoc): Inherit from ocaml-odoc and update to 1.5.1. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 60 ++++++++++++++++++++++++++++++++------------------ 1 file changed, 39 insertions(+), 21 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index e3dca82e47..19f91e5091 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -72,6 +72,7 @@ #:use-module (gnu packages time) #:use-module (gnu packages tls) #:use-module (gnu packages virtualization) + #:use-module (gnu packages web) #:use-module (gnu packages web-browsers) #:use-module (gnu packages xml) #:use-module (gnu packages xorg) @@ -2186,7 +2187,7 @@ representation of the data.") #:findlib ,ocaml4.07-findlib #:dune ,ocaml4.07-dune)) (propagated-inputs - `(("ocaml-odoc" ,ocaml4.07-odoc))) + `(("ocaml-odoc" ,(package-with-ocaml4.07 ocaml4.07-odoc)))) (native-inputs `(("ocaml-qtest" ,(package-with-ocaml4.07 ocaml-qtest)) ("ocaml-qcheck" ,(package-with-ocaml4.07 ocaml-qcheck)))) @@ -5678,10 +5679,10 @@ Usage is simple - add package bisect_ppx when building tests, run your tests, then run the Bisect_ppx report tool on the generated visitation files.") (license license:mpl2.0))) -(define-public ocaml4.07-odoc +(define-public ocaml-odoc (package - (name "ocaml4.07-odoc") - (version "1.4.2") + (name "ocaml-odoc") + (version "1.5.2") (source (origin (method git-fetch) @@ -5690,26 +5691,24 @@ then run the Bisect_ppx report tool on the generated visitation files.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0rvhx139jx6wmlfz355mja6mk03x4swq1xxvk5ky6jzhalq3cf5i")))) + (base32 "0fqfyz48q7ss5bc4c5phmp4s3ka3vc08b8gfk8fvyryvb4bq27jm")))) (build-system dune-build-system) - (arguments - `(#:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) (inputs - `(("ocaml-alcotest" ,(package-with-ocaml4.07 ocaml-alcotest)) - ("ocaml-markup" ,(package-with-ocaml4.07 ocaml-markup)) - ("ocaml-sexplib" ,(package-with-ocaml4.07 ocaml-sexplib)) - ("ocaml-re" ,(package-with-ocaml4.07 ocaml-re)) - ("ocaml-uutf" ,(package-with-ocaml4.07 ocaml-uutf)))) + `(("ocaml-alcotest" ,ocaml-alcotest) + ("ocaml-markup" ,ocaml-markup) + ("ocaml-sexplib" ,ocaml-sexplib) + ("ocaml-re" ,ocaml-re) + ("ocaml-uutf" ,ocaml-uutf))) (native-inputs - `(("ocaml-astring" ,(package-with-ocaml4.07 ocaml-astring)) - ("ocaml-cmdliner" ,(package-with-ocaml4.07 ocaml-cmdliner)) - ("ocaml-cppo" ,(package-with-ocaml4.07 ocaml-cppo)) - ("ocaml-fpath" ,(package-with-ocaml4.07 ocaml-fpath)) - ("ocaml-result" ,(package-with-ocaml4.07 ocaml-result)) - ("ocaml-tyxml" ,(package-with-ocaml4.07 ocaml-tyxml)) - ("ocaml-bisect-ppx" ,(package-with-ocaml4.07 ocaml-bisect-ppx)))) + `(("ocaml-astring" ,ocaml-astring) + ("ocaml-cmdliner" ,ocaml-cmdliner) + ("ocaml-cppo" ,ocaml-cppo) + ("ocaml-fpath" ,ocaml-fpath) + ("ocaml-result" ,ocaml-result) + ("ocaml-tyxml" ,ocaml-tyxml) + ("ocaml-bisect-ppx" ,ocaml-bisect-ppx) + ("tidy-html" ,tidy-html))) + (properties `((ocaml4.07-variant . ,(delay ocaml4.07-odoc)))) (home-page "https://github.com/ocaml/odoc") (synopsis "OCaml documentation generator") (description "Odoc is a documentation generator for OCaml. It reads @@ -5721,6 +5720,25 @@ advantage over ocamldoc is an accurate cross-referencer, which handles the complexity of the OCaml module system.") (license license:isc))) +;; version 1.5.2 requires ocaml-markdown 1.0.0 which does not compile +;; with old version of dune used in package-with-ocaml4.07 +(define-public ocaml4.07-odoc + (package-with-ocaml4.07 + (package + (inherit ocaml-odoc) + (name "ocaml-odoc") + (version "1.5.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ocaml/odoc") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0z2nisg1vb5xlk41hqw8drvj90v52wli7zvnih6a844cg6xsvvj2")))) + (properties '())))) + (define-public ocaml4.07-fftw3 (package (name "ocaml4.07-fftw3") -- cgit v1.2.3 From c0bfff6acac651a47c04cda3206b8eb345ee5b3c Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:12 +0100 Subject: gnu: Add ocaml-version. * gnu/packages/ocaml.scm (ocaml-version): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 19f91e5091..2021447a66 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -5845,6 +5845,32 @@ include the X Window System, Quartz, Win32, image buffers, PostScript, PDF, and SVG file output.") (license license:lgpl3+))) +(define-public ocaml-version + (package + (name "ocaml-version") + (version "3.0.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ocurrent/ocaml-version") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "13770mp6adjjbx63zsbh6506dqxz241chw8c3y403sxpw45hnaw6")))) + (build-system dune-build-system) + (arguments `(#:tests? #f)) ; no tests + (home-page + "https://github.com/ocurrent/ocaml-version") + (synopsis + "Manipulate, parse and generate OCaml compiler version strings") + (description + "This library provides facilities to parse version numbers of the OCaml +compiler, and enumerates the various official OCaml releases and configuration +variants.") + (license license:isc))) + (define-public lablgtk3 (package (name "lablgtk") -- cgit v1.2.3 From b13544751f5d93b8d11c9be671131dada531afd2 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:13 +0100 Subject: gnu: Add ocaml-mdx. * gnu/packages/ocaml.scm (ocaml-mdx): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 2021447a66..df07aff29f 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -5871,6 +5871,55 @@ compiler, and enumerates the various official OCaml releases and configuration variants.") (license license:isc))) +(define-public ocaml-mdx + (package + (name "ocaml-mdx") + (version "1.7.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/realworldocaml/mdx") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10avyv99xkfqdq3gmq8gps770jpibbfslg97sbhgmp0dpwikz49d")))) + (build-system dune-build-system) + (inputs + `(("ocaml-fmt" ,ocaml-fmt) + ("ocaml-astring" ,ocaml-astring) + ("ocaml-logs" ,ocaml-logs) + ("ocaml-cmdliner" ,ocaml-cmdliner) + ("ocaml-re" ,ocaml-re) + ("ocaml-result" ,ocaml-result) + ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree) + ("ocaml-odoc" ,ocaml-odoc) + ("ocaml-version" ,ocaml-version))) + (native-inputs + `(("ocaml-cppo" ,ocaml-cppo) + ("ocaml-lwt" ,ocaml-lwt) + ("ocaml-alcotest" ,ocaml-alcotest))) + (home-page + "https://github.com/realworldocaml/mdx") + (synopsis + "Executable code blocks inside markdown files") + (description + "@code{ocaml-mdx} allows to execute code blocks inside markdown files. +There are (currently) two sub-commands, corresponding +to two modes of operations: pre-processing (@code{ocaml-mdx pp}) +and tests (@code{ocaml-mdx test}]). + +The pre-processor mode allows to mix documentation and code, +and to practice @dfn{literate programming} using markdown and OCaml. + +The test mode allows to ensure that shell scripts and OCaml fragments +in the documentation always stays up-to-date. + +@code{ocaml-mdx} is released as two binaries called @code{ocaml-mdx} and +@code{mdx} which are the same, mdx being the deprecated name, kept for now for +compatibility.") + (license license:isc))) + (define-public lablgtk3 (package (name "lablgtk") -- cgit v1.2.3 From f6979a7d9f0cf903113e3beaa606c003084e85c7 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:14 +0100 Subject: gnu: ocaml-yojson: Make dependencies propagated-inputs. * gnu/packages/ocaml.scm (ocaml-yojson): Make dependencies propagated-inputs. (ocaml4.07-merlin)[inputs]: Remove ocaml-biniou and ocaml-easy-format. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index df07aff29f..c5b845c049 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -3858,7 +3858,7 @@ than yojson), with 25-35% space savings.") (build-system dune-build-system) (arguments `(#:test-target ".")) - (inputs + (propagated-inputs `(("ocaml-biniou" ,ocaml-biniou) ("ocaml-easy-format" ,ocaml-easy-format))) (native-inputs @@ -3926,9 +3926,7 @@ format}. @code{craml} is released as a single binary (called @code{craml}).") "15ssgmwdxylbwhld9p1cq8x6kadxyhll5bfyf11dddj6cldna3hb")))) (build-system dune-build-system) (inputs - `(("ocaml-biniou" ,(package-with-ocaml4.07 ocaml-biniou)) - ("ocaml-yojson" ,(package-with-ocaml4.07 ocaml-yojson)) - ("ocaml-easy-format" ,(package-with-ocaml4.07 ocaml-easy-format)))) + `(("ocaml-yojson" ,(package-with-ocaml4.07 ocaml-yojson)))) (native-inputs `(("ocaml-findlib" ,ocaml-findlib))) (arguments -- cgit v1.2.3 From 995685738e0aecfcf6d645334a3d64ac427854af Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:15 +0100 Subject: gnu: Add ocaml-dot-merlin-reader. * gnu/packages/ocaml.scm (ocaml-dot-merlin-reader): New variable. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index c5b845c049..758caa5bc4 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -3909,6 +3909,33 @@ Mercurial's @code{https://www.selenic.com/blog/?p=663, unified test format}. @code{craml} is released as a single binary (called @code{craml}).") (license license:isc))) +(define-public ocaml-dot-merlin-reader + (package + (name "ocaml-dot-merlin-reader") + (version "3.4.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ocaml/merlin") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0i2nwkdh6cfzmnsdsr8aw86vs8j1k5jkjzrs61b9384wnffdbbmj")))) + (build-system dune-build-system) + (arguments '(#:package "dot-merlin-reader" + #:tests? #f)) ; no tests + (inputs + `(("ocaml-yojson" ,ocaml-yojson) + ("ocaml-csexp" ,ocaml-csexp) + ("ocaml-result" ,ocaml-result))) + (home-page "https://ocaml.github.io/merlin/") + (synopsis "Reads config files for @code{ocaml-merlin}") + (description "@code{ocaml-dot-merlin-reader} is an external reader for +@code{ocaml-merlin} configurations.") + (license license:expat))) + (define-public ocaml4.07-merlin (package (name "ocaml4.07-merlin") -- cgit v1.2.3 From 8b036927a45fb2c1428badabdc3dc0d9d51f7f25 Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Mon, 28 Dec 2020 22:10:16 +0100 Subject: gnu: Add ocaml-merlin. * gnu/packages/ocaml.scm (ocaml-merlin): New variable. (ocaml4.07-merlin): Inherit from ocaml-merlin. Signed-off-by: Julien Lepiller --- gnu/packages/ocaml.scm | 54 ++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 41 insertions(+), 13 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 758caa5bc4..2df16e7cd2 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -3936,11 +3936,10 @@ format}. @code{craml} is released as a single binary (called @code{craml}).") @code{ocaml-merlin} configurations.") (license license:expat))) -(define-public ocaml4.07-merlin +(define-public ocaml-merlin (package - (name "ocaml4.07-merlin") - (version "3.2.2") - (home-page "https://ocaml.github.io/merlin/") + (name "ocaml-merlin") + (version "3.4.2") (source (origin (method git-fetch) @@ -3950,18 +3949,19 @@ format}. @code{craml} is released as a single binary (called @code{craml}).") (file-name (git-file-name name version)) (sha256 (base32 - "15ssgmwdxylbwhld9p1cq8x6kadxyhll5bfyf11dddj6cldna3hb")))) + "0i2nwkdh6cfzmnsdsr8aw86vs8j1k5jkjzrs61b9384wnffdbbmj")))) (build-system dune-build-system) + (arguments '(#:package "merlin" + #:test-target "tests")) (inputs - `(("ocaml-yojson" ,(package-with-ocaml4.07 ocaml-yojson)))) + `(("ocaml-yojson" ,ocaml-yojson) + ("ocaml-csexp" ,ocaml-csexp) + ("ocaml-result" ,ocaml-result))) (native-inputs - `(("ocaml-findlib" ,ocaml-findlib))) - (arguments - `(#:package "merlin" - #:tests? #f ;; Errors in tests in version 3.2.2 - #:ocaml ,ocaml-4.07 - #:findlib ,ocaml4.07-findlib - #:dune ,ocaml4.07-dune)) + `(("ocaml-dot-merlin-reader" ,ocaml-dot-merlin-reader) ; required for tests + ("ocaml-mdx" ,ocaml-mdx) + ("jq" ,jq))) + (home-page "https://ocaml.github.io/merlin/") (synopsis "Context sensitive completion for OCaml in Vim and Emacs") (description "Merlin is an editor service that provides modern IDE features for OCaml. Emacs and Vim support is provided out-of-the-box. @@ -3969,6 +3969,34 @@ External contributors added support for Visual Studio Code, Sublime Text and Atom.") (license license:expat))) +;; ocaml-merlin 3.4.2 can not be built with old version of dune used in +;; package-with-ocaml4.07 +(define-public ocaml4.07-merlin + (package-with-ocaml4.07 + (package + (inherit ocaml-merlin) + (name "ocaml-merlin") + (version "3.2.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ocaml/merlin") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "15ssgmwdxylbwhld9p1cq8x6kadxyhll5bfyf11dddj6cldna3hb")))) + (build-system dune-build-system) + (inputs + `(("ocaml-yojson" ,ocaml-yojson))) + (native-inputs + `(("ocaml-findlib" ,ocaml-findlib))) + (arguments + `(#:package "merlin" + ;; Errors in tests in version 3.2.2 + #:tests? #f))))) + (define-public ocaml4.07-gsl (package (name "ocaml4.07-gsl") -- cgit v1.2.3 From 4408c4d046965fe4a99a72043ec42c730f94fb5e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 30 Dec 2020 14:53:03 +0100 Subject: gnu: Add js-commander. * gnu/packages/javascript.scm (js-commander): New variable. --- gnu/packages/javascript.scm | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index c4bce1c42e..aed2ead719 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -187,6 +187,45 @@ plugins or software to be installed on the browser. So the page author can write web documents that include mathematics and be confident that readers will be able to view it naturally and easily."))) +(define-public js-commander + (package + (name "js-commander") + (version "6.2.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/tj/commander.js") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "126m25s6mxpxmdj4aw5awz06b47r8r798lcf1c5bnmmh39cik5i1")))) + (build-system trivial-build-system) + (arguments + `(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (chdir (assoc-ref %build-inputs "source")) + (let ((esbuild (string-append (assoc-ref %build-inputs "esbuild") + "/bin/esbuild")) + (target (string-append %output "/share/javascript/commander"))) + (invoke esbuild + "--bundle" + "--minify" + "--tsconfig=tsconfig.json" + "--platform=node" + (string-append "--outfile=" target "/index.min.js") + "index.js"))))) + (native-inputs + `(("esbuild" ,esbuild))) + (home-page "https://github.com/tj/commander.js") + (synopsis "Library for node.js command-line interfaces") + (description "Commander.js aims to be the complete solution for node.js +command-line interfaces. ") + (license license:expat))) + (define-public js-respond (package (name "js-respond") -- cgit v1.2.3 From 2005aa4b1bb88e6aadf305fb029d736050fc8507 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 30 Dec 2020 15:05:29 +0100 Subject: gnu: Add js-xmldom-sre. * gnu/packages/javascript.scm (js-xmldom-sre): New variable. --- gnu/packages/javascript.scm | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index aed2ead719..7bb2629a1e 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -226,6 +226,49 @@ be able to view it naturally and easily."))) command-line interfaces. ") (license license:expat))) +(define-public js-xmldom-sre + ;; This commit corresponds to the untagged release 0.1.32 + (let ((commit "3c79325bc2c9e5d27e3ba44b680fa8c5dd6a381d") + (revision "1")) + (package + (name "js-xmldom-sre") + (version "0.1.32") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/zorkow/xmldom/") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0a88v0id3mjflpvjqhv8a28br0xvaaszxbf7alg6pxfbnkb69yyq")))) + (build-system trivial-build-system) + (arguments + `(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (chdir (assoc-ref %build-inputs "source")) + (let ((esbuild (string-append (assoc-ref %build-inputs "esbuild") + "/bin/esbuild")) + (target (string-append %output "/share/javascript/xmldom-sre"))) + (invoke esbuild + "--bundle" + "--minify" + "--platform=node" + (string-append "--outfile=" target "/dom-parser.min.js") + "dom-parser.js"))))) + (native-inputs + `(("esbuild" ,esbuild))) + (home-page "https://github.com/zorkow/xmldom/") + (synopsis "DOM parser and XML serializer") + (description "This is a fork of the xmldom library. It allows the use +of wicked-good-xpath together with xmldom.") + ;; One of these licenses may be selected. + (license (list license:expat + license:lgpl2.0))))) + (define-public js-respond (package (name "js-respond") -- cgit v1.2.3 From db785e35485420cb1b9afb35778c33cf98bc3057 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wiktor=20=C5=BBelazny?= Date: Wed, 30 Dec 2020 14:38:39 +0100 Subject: gnu: Add r-mlr3learners. * gnu/packages/cran.scm (r-mlr3learners): New variable. --- gnu/packages/cran.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 0483af3d6b..362978c2a3 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -25493,3 +25493,29 @@ scalability and larger datasets by supporting parallelization and out-of-memory data-backends like databases. While @code{mlr3} focuses on the core computational operations, add-on packages provide additional functionality.") (license license:lgpl3))) + +(define-public r-mlr3learners + (package + (name "r-mlr3learners") + (version "0.4.3") + (source (origin + (method url-fetch) + (uri (cran-uri "mlr3learners" version)) + (sha256 + (base32 + "1wxlpzz3hpkn77n4ag1v868dmp140j1pmrhynsv5xfgk9fg0w7ri")))) + (build-system r-build-system) + (propagated-inputs + `(("r-data-table" ,r-data-table) + ("r-mlr3" ,r-mlr3) + ("r-mlr3misc" ,r-mlr3misc) + ("r-paradox" ,r-paradox) + ("r-r6" ,r-r6))) + (home-page "https://mlr3learners.mlr-org.com/") + (synopsis "Recommended Learners for @code{mlr3}") + (description "@code{mlr3learners} extends @code{mlr3} and @code{mlr3proba} +with interfaces to essential machine learning packages on CRAN. This includes, +but is not limited to: (penalized) linear and logistic regression, linear and +quadratic discriminant analysis, k-nearest neighbors, naive Bayes, support +vector machines, and gradient boosting.") + (license license:lgpl3))) -- cgit v1.2.3 From debb5ad5e0a0785d8ffb6f5ab326685520223760 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wiktor=20=C5=BBelazny?= Date: Wed, 30 Dec 2020 14:38:40 +0100 Subject: gnu: Add r-bbotk. * gnu/packages/cran.scm (r-bbotk): New variable. --- gnu/packages/cran.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 362978c2a3..a31e08fce5 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -25519,3 +25519,31 @@ but is not limited to: (penalized) linear and logistic regression, linear and quadratic discriminant analysis, k-nearest neighbors, naive Bayes, support vector machines, and gradient boosting.") (license license:lgpl3))) + +(define-public r-bbotk + (package + (name "r-bbotk") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (cran-uri "bbotk" version)) + (sha256 + (base32 + "06iz6gyymcxkbjiw049v1dk3vjfni646z247q08i2s0x59sqfqxv")))) + (properties `((upstream-name . "bbotk"))) + (build-system r-build-system) + (propagated-inputs + `(("r-checkmate" ,r-checkmate) + ("r-data-table" ,r-data-table) + ("r-lgr" ,r-lgr) + ("r-mlr3misc" ,r-mlr3misc) + ("r-paradox" ,r-paradox) + ("r-r6" ,r-r6))) + (home-page "https://bbotk.mlr-org.com") + (synopsis "Black-Box Optimization Toolkit") + (description "This package provides a common framework for optimization of +black-box functions for other packages, e.g. @code{mlr3}. It offers various +optimization methods e.g. grid search, random search and generalized simulated +annealing.") + (license license:lgpl3))) -- cgit v1.2.3 From 05c8c4f61fe3d5f70f705729e48e91a5c5927090 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wiktor=20=C5=BBelazny?= Date: Wed, 30 Dec 2020 14:38:41 +0100 Subject: gnu: Add r-mlr3tuning. * gnu/packages/cran.scm (r-mlr3tuning): New variable. --- gnu/packages/cran.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index a31e08fce5..40f8e82c34 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -25547,3 +25547,31 @@ black-box functions for other packages, e.g. @code{mlr3}. It offers various optimization methods e.g. grid search, random search and generalized simulated annealing.") (license license:lgpl3))) + +(define-public r-mlr3tuning + (package + (name "r-mlr3tuning") + (version "0.5.0") + (source (origin + (method url-fetch) + (uri (cran-uri "mlr3tuning" version)) + (sha256 + (base32 + "1pn80qjxzj2pivgs6qgairci6yh1bdnl2zbgl9ykdip2rqzv6r6m")))) + (build-system r-build-system) + (propagated-inputs + `(("r-bbotk" ,r-bbotk) + ("r-checkmate" ,r-checkmate) + ("r-data-table" ,r-data-table) + ("r-lgr" ,r-lgr) + ("r-mlr3" ,r-mlr3) + ("r-mlr3misc" ,r-mlr3misc) + ("r-paradox" ,r-paradox) + ("r-r6" ,r-r6))) + (home-page "https://mlr3tuning.mlr-org.com/") + (synopsis "Tuning for @code{mlr3}") + (description "@code{mlr3tuning} implements methods for hyperparameter +tuning, e.g. Grid Search, Random Search, or Simulated Annealing. Various +termination criteria can be set and combined. The class @code{AutoTuner} provides a +convenient way to perform nested resampling in combination with @code{mlr3}.") + (license license:lgpl3))) -- cgit v1.2.3 From 452cd4094e79655339087d16831b71277f017a57 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 30 Dec 2020 10:18:54 -0500 Subject: gnu: Add python-caniusepython3. * gnu/packages/python-xyz.scm (python-caniusepython3): New variable. --- gnu/packages/python-xyz.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 43d767b1f0..818a244378 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -1354,6 +1354,46 @@ abstractions to different hardware devices, and a suite of utilities for sending and receiving messages on a CAN bus.") (license license:lgpl3+))) +(define-public python-caniusepython3 + (package + (name "python-caniusepython3") + (version "7.2.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "caniusepython3" version)) + (sha256 + (base32 + "0a755444ln38j8d7xb3yw0wzpd0mjrzfn6zqvsh06nw1vdaq4l28")))) + (build-system python-build-system) + (arguments + `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'relax-requirements + (lambda _ + (substitute* "setup.py" + ;; These are for compatibility with Python 2. + ((".*'argparse', 'backports.functools_lru_cache',.*") + "")) + (substitute* "dev_requirements.txt" + ((".*pylint.*") "")) ;not actually required + #t)) + (replace 'check + (lambda _ + (invoke "py.test" "-k" "not NetworkTests")))))) + (propagated-inputs + `(("python-distlib" ,python-distlib) + ("python-packaging" ,python-packaging) + ("python-requests" ,python-requests))) + (native-inputs + `(("python-mock" ,python-mock) + ("python-pytest" ,python-pytest))) + (home-page "https://github.com/brettcannon/caniusepython3") + (synopsis "Check for Python 3-incompatible Python libraries") + (description "The @command{caniusepython3} command scans your project and +reports the Python 3-incompatible libraries it found. It can also be used as +a library.") + (license license:asl2.0))) + (define-public python-diskcache (package (name "python-diskcache") -- cgit v1.2.3 From 7e5d56ee816a5c295824dc9947ec700ea1adbef5 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 30 Dec 2020 13:09:33 -0500 Subject: gnu: onionshare: Replace pycrypto by pycryptodome. The later is maintained, unlike the former (unchanged since 2013). * gnu/packages/tor.scm (onionshare)[inputs]: Replace python-pycrypto by python-pycryptodome. --- gnu/packages/tor.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/tor.scm b/gnu/packages/tor.scm index 5e8bc45d52..e2ce7afe9d 100644 --- a/gnu/packages/tor.scm +++ b/gnu/packages/tor.scm @@ -253,7 +253,7 @@ networks.") (native-inputs `(("python-pytest" ,python-pytest))) (inputs - `(("python-pycrypto" ,python-pycrypto) + `(("python-pycryptodome" ,python-pycryptodome) ("python-flask" ,python-flask) ("python-flask-httpauth" ,python-flask-httpauth) ("python-nautilus" ,python-nautilus) -- cgit v1.2.3 From 958789035fa8b6b1c0ebdb3918a9c45c69bbbc43 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 30 Dec 2020 19:44:18 +0100 Subject: gnu: gzochi: Update to 0.13. * gnu/packages/game-development.scm (gzochi): Update to 0.13. [inputs]: Replace guile-2.2 with guile-3.0. --- gnu/packages/game-development.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 21f7f7e880..79bb6ec7e3 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -277,14 +277,14 @@ PCM data.") (define-public gzochi (package (name "gzochi") - (version "0.12") + (version "0.13") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/gzochi/gzochi-" version ".tar.gz")) (sha256 (base32 - "0h8yvk7154kd8zdfa9nqy73blrjq2x19kv305jcnwlmm09vvss59")))) + "1vcvf04qqzs3q8kaild2x7qvkwc6bwzfsisb78147b8z747j7hj0")))) (build-system gnu-build-system) (arguments '(#:phases (modify-phases %standard-phases @@ -298,7 +298,7 @@ PCM data.") (native-inputs `(("pkgconfig" ,pkg-config))) (inputs `(("bdb" ,bdb) ("glib" ,glib) - ("guile" ,guile-2.2) + ("guile" ,guile-3.0) ("libmicrohttpd" ,libmicrohttpd) ("ncurses" ,ncurses) ("sdl" ,sdl) -- cgit v1.2.3 From 775991f049318f6f4c51438bc582ca3482f122d8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:17:32 +0100 Subject: gnu: Add rust-headers-core-0.1. * gnu/packages/crates-io.scm (rust-headers-core-0.1): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index fc39bacc3c..3caa175a9d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11802,6 +11802,27 @@ hash map.") their key-value pairs in a user controllable order.") (license (list license:expat license:asl2.0)))) +(define-public rust-headers-core-0.1 + (package + (name "rust-headers-core") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "headers-core" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0ds20kg0igncs2r0jrcf26mq72k3j6ilanr0qwh7r7xak8kk2wcn")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-http" ,rust-http-0.1)))) + (home-page "https://hyper.rs") + (synopsis "Typed HTTP headers core trait") + (description "This package provides typed HTTP headers core trait.") + (license license:expat))) + (define-public rust-heapless-0.5 (package (name "rust-heapless") -- cgit v1.2.3 From 6cac86c98530b35cebd098bf432840e5650fe940 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:20:09 +0100 Subject: gnu: Add rust-headers-0.2. * gnu/packages/crates-io.scm (rust-headers-0.2): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3caa175a9d..ef911cd99b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11802,6 +11802,33 @@ hash map.") their key-value pairs in a user controllable order.") (license (list license:expat license:asl2.0)))) +(define-public rust-headers-0.2 + (package + (name "rust-headers") + (version "0.2.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "headers" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0hmnrra00cjqpsn05klnr9cysrv2bm19akxl5lncwcrgfbcafb48")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-base64" ,rust-base64-0.10) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.4) + ("rust-headers-core" ,rust-headers-core-0.1) + ("rust-http" ,rust-http-0.1) + ("rust-mime" ,rust-mime-0.3) + ("rust-sha-1" ,rust-sha-1-0.8) + ("rust-time" ,rust-time-0.1)))) + (home-page "https://hyper.rs") + (synopsis "typed HTTP headers") + (description "This package provides typed HTTP headers.") + (license license:expat))) + (define-public rust-headers-core-0.1 (package (name "rust-headers-core") -- cgit v1.2.3 From 92d03ec8638a2831cf3447b6b587435fdcb7bb83 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:26:33 +0100 Subject: gnu: Add rust-utf8-width-0.1. * gnu/packages/crates-io.scm (rust-utf8-width-0.1): New variable. --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ef911cd99b..aa48315b5e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33940,6 +33940,25 @@ Unix users and groups.") `(#:cargo-development-inputs (("rust-quickcheck" ,rust-quickcheck-0.2)))))) +(define-public rust-utf8-width-0.1 + (package + (name "rust-utf8-width") + (version "0.1.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "utf8-width" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1ylf5mvzck81iszchxyqmhwimkcdqv7jhazvd454g911cchsqwch")))) + (build-system cargo-build-system) + (home-page "https://magiclen.org/utf8-width") + (synopsis "Determine the width of a UTF-8 character") + (description + "This package determines the width of a UTF-8 character by providing its +first byte.") + (license license:expat))) + (define-public rust-utf8parse-0.1 (package (name "rust-utf8parse") -- cgit v1.2.3 From b129046d428515f009a337257e5244876b27f70b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:26:39 +0100 Subject: gnu: Add rust-byte-unit-4. * gnu/packages/crates-io.scm (rust-byte-unit-4): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index aa48315b5e..b96baaca43 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2961,6 +2961,28 @@ constants from build.rs or a script.") (description "Bytes related utility functions.") (license (list license:asl2.0 license:expat)))) +(define-public rust-byte-unit-4 + (package + (name "rust-byte-unit") + (version "4.0.9") + (source + (origin + (method url-fetch) + (uri (crate-uri "byte-unit" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0lxi11qf6h1rqr0yhsh7i6755l325qrkv9r4bgismyik531mi1qw")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-serde" ,rust-serde-1) + ("rust-utf8-width" ,rust-utf8-width-0.1)))) + (home-page "https://magiclen.org/byte-unit") + (synopsis "Library for interaction with units of bytes.") + (description + "This package provides a library for interaction with units of bytes.") + (license license:expat))) + (define-public rust-bytecount-0.6 (package (name "rust-bytecount") -- cgit v1.2.3 From 114a77fad72d26532df3a3132790499433509c09 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:36:34 +0100 Subject: gnu: Add rust-ndk-macro-0.2. * gnu/packages/crates-io.scm (rust-ndk-macro-0.2): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b96baaca43..6f5c4e1022 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17120,6 +17120,30 @@ general elements and for numerics.") (license (list license:asl2.0 license:expat)))) +(define-public rust-ndk-macro-0.2 + (package + (name "rust-ndk-macro") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "ndk-macro" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "07a8vjr4fpksssgp453bf82n73i4i17yj1lvbgvd0964glqcdl85")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-darling" ,rust-darling-0.10) + ("rust-proc-macro-crate" ,rust-proc-macro-crate-0.1) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)))) + (home-page "https://github.com/rust-windowing/android-ndk-rs") + (synopsis "Helper macros for android ndk") + (description "This package provides helper macros for android ndk.") + (license (list license:expat license:asl2.0)))) + (define-public rust-net2-0.2 (package (name "rust-net2") -- cgit v1.2.3 From d8b23fa061acf4619ca67082a665b7781cd66fd1 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 15:55:10 +0100 Subject: gnu: Add rust-num-enum-derive-0.4. * gnu/packages/crates-io.scm (rust-num-enum-derive-0.4): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 6f5c4e1022..72a7e09777 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18054,6 +18054,32 @@ for Rust") (description "Numeric syntax extensions in Rust.") (license (list license:expat license:asl2.0)))) +(define-public rust-num-enum-derive-0.4 + (package + (name "rust-num-enum-derive") + (version "0.4.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "num_enum_derive" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "17fvb7xpxq2dsqp5nsz98w1qhkk3gnc56xis53009vnzvlys79gz")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #f ;FIXME: some doc tests fail + #:cargo-inputs + (("rust-proc-macro-crate" ,rust-proc-macro-crate-0.1) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)))) + (home-page "https://github.com/illicitonion/num_enum") + (synopsis "Procedural macros to ease operation between primitives and enums") + (description + "This package provides procedural macros to make inter-operation between +primitives and enums easier.") + (license license:bsd-3))) + (define-public rust-num-integer-0.1 (package (name "rust-num-integer") -- cgit v1.2.3 From 72c17e1ae563e4ebaab63965859e75ec0c72dae1 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:00:28 +0100 Subject: gnu: Add rust-derivative-2. * gnu/packages/crates-io.scm (rust-derivative-2): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 72a7e09777..59382fab50 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6584,6 +6584,32 @@ algorithm which serves to quantify the difference between two colors.") (description "Demo of proc-macro-hack.") (license (list license:expat license:asl2.0)))) +(define-public rust-derivative-2 + (package + (name "rust-derivative") + (version "2.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "derivative" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "03rqx8j9q5nlrpr7w8cwwrvw916pr0ahzs3y8yln18cx6mh2nn6b")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-trybuild" ,rust-trybuild-1)))) + (home-page "https://github.com/mcarton/rust-derivative") + (synopsis "Set of alternative @code{derive} attributes for Rust") + (description + "This package provides a set of alternative @code{derive} attributes for +Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-derive-builder-0.9 (package (name "rust-derive-builder") -- cgit v1.2.3 From a1fae22af2fcac608a8f11757b009a6dec6da3ce Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:02:47 +0100 Subject: gnu: Add rust-ndk-sys-0.2. * gnu/packages/crates-io.scm (rust-ndk-sys-0.2): New variable. --- gnu/packages/crates-io.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 59382fab50..cbb0c47a40 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17170,6 +17170,24 @@ general elements and for numerics.") (description "This package provides helper macros for android ndk.") (license (list license:expat license:asl2.0)))) +(define-public rust-ndk-sys-0.2 + (package + (name "rust-ndk-sys") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "ndk-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13c68a217ag3k18vlffpcj2qjfinchxxchzlwnsp075v7p5j4jf4")))) + (build-system cargo-build-system) + (arguments `(#:skip-build? #t)) + (home-page "https://github.com/rust-windowing/android-ndk-rs") + (synopsis "FFI bindings for the Android NDK") + (description "This package provides FFI bindings for the Android NDK.") + (license (list license:expat license:asl2.0)))) + (define-public rust-net2-0.2 (package (name "rust-net2") -- cgit v1.2.3 From 72cb721463034ebc6d099fc587124d1e1945b0d2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:12:37 +0100 Subject: gnu: Add rust-combine-regex-1-1. * gnu/packages/crates-io.scm (rust-combine-regex-1-1): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index cbb0c47a40..8dce021b79 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4316,6 +4316,28 @@ CMAKE environmental variable is set.") (sha256 (base32 "0fildacm47g86acmx44yvxx6cka8fdym5qkgfm8x8gh2hsrghc7r")))))) +(define-public rust-combine-regex-1-1 + (package + (name "rust-combine-regex-1") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "combine-regex-1" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1bzir63nvrg98i8g6b7crhgq5qbj4vq9f4y6d279af537djvh5ns")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-regex" ,rust-regex-1)))) + (home-page "https://github.com/Marwes/combine") + (synopsis "Re-export of regex 1.0 letting combine use both 0.2 and 1.0") + (description + "This package is a re-export of regex 1.0 letting combine use both 0.2 +and 1.0.") + (license (list license:expat license:asl2.0)))) + ;; This package requires features which are unavailable ;; on the stable releases of Rust. (define-public rust-compiler-builtins-0.1 -- cgit v1.2.3 From e49cd072c27a56f5ecb28cebd48d7d7c63392cbe Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:24:30 +0100 Subject: gnu: Add rust-combine-3. * gnu/packages/crates-io.scm (rust-combine-3): New variable. --- gnu/packages/crates-io.scm | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 8dce021b79..86e009a5f7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4316,6 +4316,42 @@ CMAKE environmental variable is set.") (sha256 (base32 "0fildacm47g86acmx44yvxx6cka8fdym5qkgfm8x8gh2hsrghc7r")))))) +(define-public rust-combine-3 + (package + (name "rust-combine") + (version "3.8.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "combine" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1006sbl3ybiky3d5q28p0lyph37hk7sipls1rkhikv11lfxacgfs")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-ascii" ,rust-ascii-0.9) + ("rust-byteorder" ,rust-byteorder-1) + ("rust-combine-regex-1" ,rust-combine-regex-1-1) + ("rust-either" ,rust-either-1) + ("rust-memchr" ,rust-memchr-2) + ("rust-regex" ,rust-regex-0.2) + ("rust-unreachable" ,rust-unreachable-1.0)) + #:cargo-development-inputs + (("rust-bencher" ,rust-bencher-0.1) + ("rust-bytes" ,rust-bytes-0.4) + ("rust-futures" ,rust-futures-0.1) + ("rust-partial-io" ,rust-partial-io-0.3) + ("rust-tokio-codec" ,rust-tokio-codec-0.1)))) + (home-page "https://github.com/Marwes/combine") + (synopsis "Parser combinators on arbitrary streams with zero-copy support") + (description + "This package is an implementation of parser combinators for Rust, +inspired by the Haskell library Parsec. As in Parsec the parsers are LL(1) by +default but they can opt-in to arbitrary lookahead using the attempt +combinator.") + (license license:expat))) + (define-public rust-combine-regex-1-1 (package (name "rust-combine-regex-1") -- cgit v1.2.3 From 46f5b2285c325fd7ea1588bd10a77502d345d766 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:28:38 +0100 Subject: gnu: Add rust-bytes-0.6. * gnu/packages/crates-io.scm (rust-bytes-0.6): New variable. (rust-bytes-0.5): Inherit from above. --- gnu/packages/crates-io.scm | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 86e009a5f7..8b293b54b8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3154,29 +3154,48 @@ little-endian.") (("rust-quickcheck" ,rust-quickcheck-0.2) ("rust-rand" ,rust-rand-0.3)))))) -(define-public rust-bytes-0.5 +(define-public rust-bytes-0.6 (package (name "rust-bytes") - (version "0.5.4") + (version "0.6.0") (source (origin (method url-fetch) (uri (crate-uri "bytes" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1q9r7si1l8vndg4n2ny2nv833ghp5vyqzk5indb9rmhd5ibaq2hk")))) + (base32 "05ivrcbgl4f7z2zzm9hbsi8cy66spi70xlm6fp16zsq4ylsvrp70")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-serde" ,rust-serde-1)) #:cargo-development-inputs - (("rust-loom" ,rust-loom-0.2) + (("rust-loom" ,rust-loom-0.3) ("rust-serde-test" ,rust-serde-test-1)))) (home-page "https://github.com/tokio-rs/bytes") (synopsis "Types and traits for working with bytes") - (description "Types and traits for working with bytes.") + (description "This package is a utility library for working with bytes.") (license license:expat))) +(define-public rust-bytes-0.5 + (package + (inherit rust-bytes-0.6) + (name "rust-bytes") + (version "0.5.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "bytes" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1q9r7si1l8vndg4n2ny2nv833ghp5vyqzk5indb9rmhd5ibaq2hk")))) + (arguments + `(#:cargo-inputs + (("rust-serde" ,rust-serde-1)) + #:cargo-development-inputs + (("rust-loom" ,rust-loom-0.2) + ("rust-serde-test" ,rust-serde-test-1)))))) + (define-public rust-bytes-0.4 (package/inherit rust-bytes-0.5 (name "rust-bytes") -- cgit v1.2.3 From b239e496c59e589a6e21935a071c7f75836731ad Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:32:01 +0100 Subject: gnu: rust-tracing-core-0.1: Update to 0.1.17. * gnu/packages/crates-io.scm (rust-tracing-core-0.1): Update to 0.1.17. [description]: Comply to package definition rules. --- gnu/packages/crates-io.scm | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 8b293b54b8..0bed12f0c1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32698,15 +32698,14 @@ automatically instrumenting functions.") (define-public rust-tracing-core-0.1 (package (name "rust-tracing-core") - (version "0.1.16") + (version "0.1.17") (source - (origin - (method url-fetch) - (uri (crate-uri "tracing-core" version)) - (file-name (string-append name "-" version ".crate")) - (sha256 - (base32 - "16hisz8nvbav9q6r5lbar2baac097n33q7xqssifwsphy70ldksv")))) + (origin + (method url-fetch) + (uri (crate-uri "tracing-core" version)) + (file-name (string-append name "-" version ".crate")) + (sha256 + (base32 "0pvbgv301vw6dq4krc14yqbyyixb42lcs4s57xw05llkgy9f63gm")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs @@ -32714,7 +32713,7 @@ automatically instrumenting functions.") (home-page "https://tokio.rs") (synopsis "Core primitives for application-level tracing") (description - "Core primitives for application-level tracing.") + "This package provides core primitives for application-level tracing.") (license (list license:asl2.0 license:expat)))) -- cgit v1.2.3 From c1ed49d22e2e641510fd043b860de250b93cb99f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 16:48:34 +0100 Subject: gnu: rust-tracing-0.1: Update to 0.1.22. * gnu/packages/crates-io.scm (rust-tracing-0.1): Update to 0.1.22. [arguments]: Update rust-cfg-if and rust-pin-project-lite Cargo inputs. Add rust-log, rust-tokio and rust-wasm-bindgen-test to Cargo development inputs. --- gnu/packages/crates-io.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0bed12f0c1..38aad32f91 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32635,30 +32635,31 @@ server @code{Service} tests.") (description "This package provides utilities for working with @code{Service}.") (license license:expat))) - (define-public rust-tracing-0.1 (package (name "rust-tracing") - (version "0.1.20") + (version "0.1.22") (source (origin (method url-fetch) (uri (crate-uri "tracing" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "0hwgbyflibmsz7x6v7ndchnx1qvv43pg18419ji2y7pflzkmngbi")))) + (base32 "1qzg7rcfby8f2nn1ln3gk6fjc80q0bg8fw5k95zc1020vin04iwz")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-cfg-if" ,rust-cfg-if-0.1) + (("rust-cfg-if" ,rust-cfg-if-1) ("rust-log" ,rust-log-0.4) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) ("rust-tracing-attributes" ,rust-tracing-attributes-0.1) ("rust-tracing-core" ,rust-tracing-core-0.1)) #:cargo-development-inputs (("rust-criterion" ,rust-criterion-0.3) ("rust-futures" ,rust-futures-0.1) - ("rust-log" ,rust-log-0.4)))) + ("rust-log" ,rust-log-0.4) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)))) (home-page "https://tokio.rs") (synopsis "Application-level tracing for Rust") (description "@code{rust-tracing} is a framework for instrumenting Rust -- cgit v1.2.3 From 8cd60167f0ad0fd5f21ac7f8f52c8f4494759c00 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:10:01 +0100 Subject: gnu: rust-socket2-0.3: Update to 0.3.18. * gnu/packages/crates-io.scm (rust-socket2-0.3): Update to 0.3.18. --- gnu/packages/crates-io.scm | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 38aad32f91..f161e8ce3a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -28367,20 +28367,19 @@ stack.") (define-public rust-socket2-0.3 (package (name "rust-socket2") - (version "0.3.11") + (version "0.3.18") (source - (origin - (method url-fetch) - (uri (crate-uri "socket2" version)) - (file-name (string-append name "-" version ".crate")) - (sha256 - (base32 - "11bdcz04i106g4q7swkll0qxrb4287srqd2k3aq2q6i22zjlvdz8")))) + (origin + (method url-fetch) + (uri (crate-uri "socket2" version)) + (file-name (string-append name "-" version ".crate")) + (sha256 + (base32 "0mqh39dkspcz3x11jhck9k2yrbx2krawn7xr3zva8n3lazyykq4p")))) (build-system cargo-build-system) (arguments - `(#:tests? #f ; tests require network access + `(#:tests? #f ; tests require network access #:cargo-inputs - (("rust-cfg-if" ,rust-cfg-if-0.1) + (("rust-cfg-if" ,rust-cfg-if-1) ("rust-libc" ,rust-libc-0.2) ("rust-redox-syscall" ,rust-redox-syscall-0.1) ("rust-winapi" ,rust-winapi-0.3)) -- cgit v1.2.3 From 5dbaee9ad71cd83180104520d87166cc36f08f91 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:13:17 +0100 Subject: gnu: rust-miow-0.3: Update to 0.3.6. * gnu/packages/crates-io.scm (rust-miow-0.3): Update to 0.3.6. [arguments]: Remove #:skip-build?. --- gnu/packages/crates-io.scm | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f161e8ce3a..548dbe9c09 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -16695,19 +16695,17 @@ drop-in replacement for miniz.") (define-public rust-miow-0.3 (package (name "rust-miow") - (version "0.3.3") + (version "0.3.6") (source - (origin - (method url-fetch) - (uri (crate-uri "miow" version)) - (file-name (string-append name "-" version ".crate")) - (sha256 - (base32 - "09ljvx6wg30f2xlv7b7hhpkw7k312n3hjgmrbhwzhz9x03ra0sir")))) + (origin + (method url-fetch) + (uri (crate-uri "miow" version)) + (file-name (string-append name "-" version ".crate")) + (sha256 + (base32 "15sqdhh29dqgw5xh59clwv6scbsbvdkbmdc16hbfvyq7b2sw2css")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t - #:cargo-inputs + `(#:cargo-inputs (("rust-socket2" ,rust-socket2-0.3) ("rust-winapi" ,rust-winapi-0.3)) #:cargo-development-inputs -- cgit v1.2.3 From 61830c534f2a355e74dd354f7b2ae9977f1de096 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:17:08 +0100 Subject: gnu: Add rust-ntapi-0.3. * gnu/packages/crates-io.scm (rust-ntapi-0.3): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 548dbe9c09..d7e51d9a21 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17763,6 +17763,26 @@ with all line endings.") "Cross-platform file system notification library.") (license license:cc0))) +(define-public rust-ntapi-0.3 + (package + (name "rust-ntapi") + (version "0.3.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "ntapi" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0i5daj9sr8wyi5jkpwpybln2jqpn59z0mqfc0dpdidipwh1bjsrz")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-winapi" ,rust-winapi-0.3)))) + (home-page "") + (synopsis "FFI bindings for Native API") + (description "FFI bindings for Native API") + (license (list license:asl2.0 license:expat)))) + (define-public rust-ntest-0.3 (package (name "rust-ntest") -- cgit v1.2.3 From 211da9ff5ff2038144a95b38766e551fe38b04ff Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:24:26 +0100 Subject: gnu: Add rust-mio-0.7. * gnu/packages/crates-io.scm (rust-mio-0.7): New variable. (rust-mio-0.6): Inherit from above. --- gnu/packages/crates-io.scm | 44 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 34 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d7e51d9a21..1e458a4f98 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -16545,20 +16545,48 @@ drop-in replacement for miniz.") "This package provides math interoperability standard types.") (license license:expat))) +(define-public rust-mio-0.7 + (package + (name "rust-mio") + (version "0.7.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "mio" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "12qsvmsmpijnghgci5i0liskvwxrbg2dz6hc09kgvwaf0s3whfzk")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-libc" ,rust-libc-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-miow" ,rust-miow-0.3) + ("rust-ntapi" ,rust-ntapi-0.3) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.6) + ("rust-rand" ,rust-rand-0.4)))) + (home-page "https://github.com/tokio-rs/mio") + (synopsis "Lightweight non-blocking IO") + (description + "Mio is a fast, low-level I/O library for Rust focusing on non-blocking +APIs and event notification for building I/O apps with as little overhead as +possible over the OS abstractions.") + (license license:expat))) + (define-public rust-mio-0.6 (package + (inherit rust-mio-0.7) (name "rust-mio") (version "0.6.21") (source (origin (method url-fetch) (uri (crate-uri "mio" version)) - (file-name - (string-append name "-" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "13q02a7cwc140aygf8amadpzpl5lyj3p2r4wnvgydfpnphifqb9h")))) - (build-system cargo-build-system) + (base32 "13q02a7cwc140aygf8amadpzpl5lyj3p2r4wnvgydfpnphifqb9h")))) (arguments `(#:tests? #f #:cargo-inputs @@ -16576,11 +16604,7 @@ drop-in replacement for miniz.") #:cargo-development-inputs (("rust-bytes" ,rust-bytes-0.3) ("rust-env-logger" ,rust-env-logger-0.4) - ("rust-tempdir" ,rust-tempdir-0.3)))) - (home-page "https://github.com/tokio-rs/mio") - (synopsis "Lightweight non-blocking IO") - (description "Lightweight non-blocking IO.") - (license license:expat))) + ("rust-tempdir" ,rust-tempdir-0.3)))))) (define-public rust-mio-anonymous-pipes-0.1 (package -- cgit v1.2.3 From 98e2a06f5674a1e6f33ce97c6c01c5cd7d29a7a8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:28:32 +0100 Subject: gnu: Add rust-cesu8-1. * gnu/packages/crates-io.scm (rust-cesu8-1): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1e458a4f98..4fb950f07a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3704,6 +3704,26 @@ archive to be linked into Rustcode.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cesu8-1 + (package + (name "rust-cesu8") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "cesu8" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0g6q58wa7khxrxcxgnqyi9s1z2cjywwwd3hzr5c55wskhx6s0hvd")))) + (build-system cargo-build-system) + (home-page "https://github.com/emk/cesu8-rs") + (synopsis "Convert to and from CESU-8 encoding") + (description + "This library implements the CESU-8 compatibility encoding scheme. This +is a non-standard variant of UTF-8 that is used internally by some systems +that need to represent UTF-16 data as 8-bit characters.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-cexpr-0.4 (package (name "rust-cexpr") -- cgit v1.2.3 From a4efec5f032d8dede717386452902c3f24b344ad Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 17:53:17 +0100 Subject: gnu: rust-tokio-0.1: Update to 0.1.22. * gnu/packages/crates-io.scm (rust-tokio-0.1): Update to 0.1.22. [arguments]: Add rust-tracing-core-0.1 to Cargo development inputs. --- gnu/packages/crates-io.scm | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 4fb950f07a..f5235771eb 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31409,18 +31409,16 @@ backed applications.") (define-public rust-tokio-0.1 (package + (inherit rust-tokio-0.2) (name "rust-tokio") - (version "0.1.21") + (version "0.1.22") (source (origin (method url-fetch) (uri (crate-uri "tokio" version)) - (file-name - (string-append name "-" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "11ra8jp3fj70a2zrqmd6as7wgpwiiyzjf50gz89i8r7wpksgqbzc")))) - (build-system cargo-build-system) + (base32 "1xhaadfmm6m37f79xv5020gc3np9wqza3bq95ymp522qpfsw02as")))) (arguments `(#:cargo-inputs (("rust-bytes" ,rust-bytes-0.4) @@ -31452,13 +31450,8 @@ backed applications.") ("rust-serde" ,rust-serde-1) ("rust-serde-derive" ,rust-serde-derive-1) ("rust-serde-json" ,rust-serde-json-1) - ("rust-time" ,rust-time-0.1)))) - (home-page "https://tokio.rs") - (synopsis "Event-driven, non-blocking I/O platform") - (description - "An event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.") - (license license:expat))) + ("rust-time" ,rust-time-0.1) + ("rust-tracing-core" ,rust-tracing-core-0.1)))))) (define-public rust-tokio-buf-0.1 (package -- cgit v1.2.3 From 6575e5dd657dca03bf3f26f31222c38e9dc3197e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 18:02:08 +0100 Subject: gnu: Add rust-tokio-openssl-0.3. * gnu/packages/crates-io.scm (rust-tokio-openssl-0.3): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f5235771eb..582521654d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31893,6 +31893,31 @@ Tokio.") backed by OpenSSL.") (license (list license:expat license:asl2.0)))) +(define-public rust-tokio-openssl-0.3 + (package + (inherit rust-tokio-openssl-0.4) + (name "rust-tokio-openssl") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-openssl" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "19zx58jz0vkxppa3pmqnq0b90mqsycikr5nrcy6i1bkhn53647bp")))) + (arguments + `(#:tests? #f ;require internet access + #:cargo-inputs + (("rust-futures" ,rust-futures-0.1) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-tokio-io" ,rust-tokio-io-0.1)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.1)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))))) + (define-public rust-tokio-process-0.2 (package (name "rust-tokio-process") -- cgit v1.2.3 From 80a353437f4d403a4ce873d2a342670ef7306787 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 18:07:43 +0100 Subject: gnu: rust-tokio-openssl-0.4: Fix build. * gnu/packages/crates-io.scm (rust-tokio-openssl-0.4)[arguments]: Disable tests. [native-inputs]: Add pkg-config. [inputs]: Add openssl. * gnu/packages/crates-io.scm (rust-tokio-openssl-0.3): Remove native-inputs, and inputs since they are inherited. --- gnu/packages/crates-io.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 582521654d..a2f8a3bea4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31881,12 +31881,17 @@ Tokio.") "15751d47984ncvllagz35ldl10ifr8555wixvsg6k3i0yk2hhjrw")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #f ;require internet access + #:cargo-inputs (("rust-openssl" ,rust-openssl-0.10) ("rust-tokio" ,rust-tokio-0.2)) #:cargo-development-inputs (("rust-futures" ,rust-futures-0.3) ("rust-tokio" ,rust-tokio-0.2)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))) (home-page "https://github.com/alexcrichton/tokio-openssl") (synopsis "SSL streams for Tokio backed by OpenSSL") (description "This package is an implementation of SSL streams for Tokio @@ -31912,11 +31917,7 @@ backed by OpenSSL.") ("rust-openssl" ,rust-openssl-0.10) ("rust-tokio-io" ,rust-tokio-io-0.1)) #:cargo-development-inputs - (("rust-tokio" ,rust-tokio-0.1)))) - (native-inputs - `(("pkg-config" ,pkg-config))) - (inputs - `(("openssl" ,openssl))))) + (("rust-tokio" ,rust-tokio-0.1)))))) (define-public rust-tokio-process-0.2 (package -- cgit v1.2.3 From 445caffa0ad060bfbb36c0507aaeeef40140965f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 18:49:43 +0100 Subject: gnu: Add rust-tokio-tls-0.2. * gnu/packages/crates-io.scm (rust-tokio-tls-0.2): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a2f8a3bea4..e06dbd702c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32412,6 +32412,33 @@ pool.") implementation of TLS for nonblocking I/O streams.") (license license:expat))) +(define-public rust-tokio-tls-0.2 + (package + (inherit rust-tokio-tls-0.3) + (name "rust-tokio-tls") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-tls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0z0gmvv7jrpan6y42p5f5wd48rqcd96igp592w1c5cr573c8qjrm")))) + (arguments + `(#:tests? #f ;require internet access + #:cargo-inputs + (("rust-futures" ,rust-futures-0.1) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-tokio-io" ,rust-tokio-io-0.1)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.5) + ("rust-security-framework" ,rust-security-framework-0.2) + ("rust-tokio" ,rust-tokio-0.1)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))))) + (define-public rust-tokio-trace-core-0.2 (package (name "rust-tokio-trace-core") -- cgit v1.2.3 From e82c07fd2d57b8ddd14fcfe4a0b60b1c7d71b5e2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 18:53:55 +0100 Subject: gnu: rust-tokio-tls-0.3: Fix build. * gnu/packages/crates-io.scm (rust-tokio-tls-0.3)[arguments]: Skip tests. [native-inputs]: Add pkg-config. [inputs]: Add openssl. * gnu/packages/crates-io.scm (rust-tokio-tls-0.3)[native-inputs, inputs]: Remove since they are inherited. --- gnu/packages/crates-io.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e06dbd702c..f6432c629f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32393,7 +32393,8 @@ pool.") "0hv375949532p32d0w6bm2f6d3r0d00mcdzqjjqlzcmkszyg8w4s")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #f ;require internet access + #:cargo-inputs (("rust-native-tls" ,rust-native-tls-0.2) ("rust-tokio" ,rust-tokio-0.2)) #:cargo-development-inputs @@ -32406,6 +32407,10 @@ pool.") ("rust-tokio" ,rust-tokio-0.2) ("rust-tokio-util" ,rust-tokio-util-0.3) ("rust-winapi" ,rust-winapi-0.3)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))) (home-page "https://tokio.rs") (synopsis "TLS/SSL streams for Tokio") (description "An implementation of TLS/SSL streams for Tokio giving an @@ -32433,11 +32438,7 @@ implementation of TLS for nonblocking I/O streams.") #:cargo-development-inputs (("rust-env-logger" ,rust-env-logger-0.5) ("rust-security-framework" ,rust-security-framework-0.2) - ("rust-tokio" ,rust-tokio-0.1)))) - (native-inputs - `(("pkg-config" ,pkg-config))) - (inputs - `(("openssl" ,openssl))))) + ("rust-tokio" ,rust-tokio-0.1)))))) (define-public rust-tokio-trace-core-0.2 (package -- cgit v1.2.3 From e47a5711f0734d96238fb873288d4158b9030f00 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 30 Dec 2020 21:20:41 +0100 Subject: gnu: Add guile-shapefile. * gnu/packages/guile-xyz.scm (guile-shapefile): New variable. --- gnu/packages/guile-xyz.scm | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 6420600d6a..437d5b77bb 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -4266,3 +4266,44 @@ read-capability.") "This project provides a pure Scheme implementation of Protocol Buffers, including parsing and code generation.") (license license:gpl3+))) + +(define-public guile-shapefile + (package + (name "guile-shapefile") + (version "0.1.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/HugoNikanor/guile-shapefile") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1zvrpc8bshw9w0vhdpmhv00j07mzsdyg2f9hfabr83v08zhfi8ml")))) + (build-system guile-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'delete-pre-generated-docs + (lambda _ + (delete-file-recursively "docs") + #t)) + (add-after 'install 'install-info-documentation + (lambda* (#:key outputs #:allow-other-keys) + (let* ((share (string-append (assoc-ref outputs "out") "/share")) + (doc (string-append share "/doc/" ,name "-" ,version)) + (info (string-append share "/info/")) + (makeinfo (string-append (assoc-ref %build-inputs "texinfo") + "/bin/makeinfo"))) + (invoke makeinfo "guile-shapefile.texi" "-o" info) + #t)))))) + (inputs + `(("guile" ,guile-3.0))) + (native-inputs + `(("texinfo" ,texinfo))) + (home-page "https://github.com/HugoNikanor/guile-shapefile") + (synopsis "Parse shapefiles in Guile") + (description + "Guile Shapefile is a Guile library for reading shapefiles.") + (license license:expat))) -- cgit v1.2.3 From 15122d3cc921bfb423aa8027639d2ca9c42940fd Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 30 Dec 2020 23:24:44 +0200 Subject: gnu: kdav: Update to 20.04.3. * gnu/packages/kde-pim.scm (kdav): Update to 20.04.3. --- gnu/packages/kde-pim.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/kde-pim.scm b/gnu/packages/kde-pim.scm index b0a2e565ed..e055f9a9fd 100644 --- a/gnu/packages/kde-pim.scm +++ b/gnu/packages/kde-pim.scm @@ -617,14 +617,14 @@ functions for accessing calendar data using the kcalcore API.") (define-public kdav (package (name "kdav") - (version "20.04.1") + (version "20.04.3") (source (origin (method url-fetch) (uri (string-append "mirror://kde/stable/release-service/" version "/src/kdav-" version ".tar.xz")) (sha256 - (base32 "10syhwdlx36yip07yylzir8ig8arm1i868f2j6xpkwhxblrprlxk")))) + (base32 "0445gl4xm0h39igkxgb6vmq5iaa04wkgrgbs7nfd0zwngk8xaidn")))) (build-system qt-build-system) (native-inputs `(("extra-cmake-modules" ,extra-cmake-modules))) -- cgit v1.2.3 From b4b1c64040c0f478f71fac6a01694ec78a5f11b5 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 30 Dec 2020 23:25:26 +0200 Subject: gnu: qca: Update to 2.3.1. * gnu/packages/kde.scm (qca): Update to 2.3.1. --- gnu/packages/kde.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm index b1b8b6a484..999633d78c 100644 --- a/gnu/packages/kde.scm +++ b/gnu/packages/kde.scm @@ -505,7 +505,7 @@ used in KDE development tools Kompare and KDevelop.") (define-public qca (package (name "qca") - (version "2.3.0") + (version "2.3.1") (source (origin (method url-fetch) @@ -513,7 +513,7 @@ used in KDE development tools Kompare and KDevelop.") "/qca-" version ".tar.xz")) (sha256 (base32 - "1mrj748yz1grgzmfbmffgjkpcqiaj1l3m4pbddwcj7dnl50yys0x")))) + "0jsfjwz84fc5jnl16aiwrcd6pgs5lzizm2896wildz5yk8852f61")))) (build-system cmake-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From 22233339433df5dc1251ddfa615fd3fdd63d0fcc Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 30 Dec 2020 21:04:06 +0100 Subject: gnu: emacs-sly: Update to 1.0.42. * gnu/packages/emacs-xyz.scm (emacs-sly): Update to 1.0.42. --- gnu/packages/emacs-xyz.scm | 138 ++++++++++++++++++++++----------------------- 1 file changed, 68 insertions(+), 70 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 99df0a72e0..02a487c9aa 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9482,84 +9482,82 @@ are pretty much the same (and SLIME served as the principle inspiration for CIDER).") (license license:gpl3+))) -;; There hasn't been a tag or release since 2016, so we take the latest -;; commit. (define-public emacs-sly - (let ((commit "68561f1b7b66fa0240766ece836bb04da31ea17d") - ;; Update together with sbcl-slynk. - (revision "7")) - (package - (name "emacs-sly") - (version (git-version "1.0.0" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/joaotavora/sly") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1xwx537dhgclngi6b0faf320i8pnac9309wvmk6z2g6dm3v652ds")))) - (build-system emacs-build-system) - (native-inputs - `(("texinfo" ,texinfo))) - (arguments - `(#:include (cons* "^contrib\\/" "^lib\\/" "^slynk\\/" %default-include) - #:phases - ;; The package provides autoloads. - (modify-phases %standard-phases - (delete 'make-autoloads) - (add-before 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (info-dir (string-append out "/share/info")) - (doc-dir (string-append out "/share/doc/" - ,name "-" ,version)) - (doc-files '(;; "doc/sly-refcard.pdf" ; See sly-refcard.pdf below. - "README.md" "NEWS.md" "PROBLEMS.md" - "CONTRIBUTING.md"))) - (with-directory-excursion "doc" - (substitute* "Makefile" - (("infodir=/usr/local/info") - (string-append "infodir=" info-dir)) - ;; Don't rebuild contributors.texi since we are not in - ;; the git repo. - (("contributors.texi: Makefile texinfo-tabulate.awk") - "contributors.texi:")) - (invoke "make" "html/index.html") - (invoke "make" "sly.info") - ;; TODO: We need minimal texlive with "preprint" package - ;; (for fullpage.sty). (invoke "make" "sly-refcard.pdf") - (install-file "sly.info" info-dir) - (copy-recursively "html" (string-append doc-dir "/html"))) - (for-each (lambda (f) - (install-file f doc-dir) - (delete-file f)) - doc-files) - (delete-file-recursively "doc") - #t)))))) - (home-page "https://github.com/joaotavora/sly") - (synopsis "Sylvester the Cat's Common Lisp IDE") - (description - "SLY is Sylvester the Cat's Common Lisp IDE. SLY is a fork of SLIME, and + ;; Update together with sbcl-slynk. + (package + (name "emacs-sly") + (version "1.0.42") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/joaotavora/sly") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "10l867c4hgcpiajcfkz9g9vabp7y4bcgy51la6n9pqxrlg1fs455")))) + (build-system emacs-build-system) + (native-inputs + `(("texinfo" ,texinfo))) + (arguments + `(#:include (cons* "^contrib\\/" "^lib\\/" "^slynk\\/" %default-include) + #:phases + ;; The package provides autoloads. + (modify-phases %standard-phases + (delete 'make-autoloads) + (add-before 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (info-dir (string-append out "/share/info")) + (doc-dir (string-append out "/share/doc/" + ,name "-" ,version)) + (doc-files '( ;; "doc/sly-refcard.pdf" ; See sly-refcard.pdf below. + "README.md" "NEWS.md" "PROBLEMS.md" + "CONTRIBUTING.md"))) + (with-directory-excursion "doc" + (substitute* "Makefile" + (("infodir=/usr/local/info") + (string-append "infodir=" info-dir)) + ;; Don't rebuild contributors.texi since we are not in + ;; the git repo. + (("contributors.texi: Makefile texinfo-tabulate.awk") + "contributors.texi:")) + (invoke "make" "html/index.html") + (invoke "make" "sly.info") + ;; TODO: We need minimal texlive with "preprint" package + ;; (for fullpage.sty). (invoke "make" "sly-refcard.pdf") + (install-file "sly.info" info-dir) + (copy-recursively "html" (string-append doc-dir "/html"))) + (for-each (lambda (f) + (install-file f doc-dir) + (delete-file f)) + doc-files) + (delete-file-recursively "doc") + #t)))))) + (home-page "https://github.com/joaotavora/sly") + (synopsis "Sylvester the Cat's Common Lisp IDE") + (description + "SLY is Sylvester the Cat's Common Lisp IDE. SLY is a fork of SLIME, and contains the following improvements over it: @enumerate -@item Completely redesigned REPL based on Emacs's own full-featured - @code{comint.el}. -@item Live code annotations via a new @code{sly-stickers} contrib. -@item Consistent interactive button interface. Everything can be copied to - the REPL. -@item Multiple inspectors with independent history. +@item A full-featured REPL based on Emacs's @code{comint.el}. Everything +can be copied to the REPL; +@item Stickers, or live code annotations that record values as code traverses them. +@item Flex-style completion out-of-the-box, using Emacs's completion API. +Company, Helm, and other supported natively, no plugin required; +@item An interactive Trace Dialog; +@item Multiple inspectors and multiple REPLs, with independent history. @item Regexp-capable @code{M-x sly-apropos}. -@item Contribs are first class SLY citizens and enabled by default. -@item Use ASDF to loads contribs on demand. +@item Cleanly ASDF-loaded by default, including contribs, enabled out-of-the-box; +@item \"Presentations\" replaced by interactive backreferences, which +highlight the object and remain stable throughout the REPL session; @end enumerate SLY tracks SLIME's bugfixes and all its familiar features (debugger, inspector, -xref, etc...) are still available, but with better integration.") - (license license:gpl3+)))) +xref, etc.) are still available, but with better integration.") + (license license:gpl3+))) (define-public emacs-sly-quicklisp (let ((commit "01ebe3976a244309f2e277c09206831135a0b66c") -- cgit v1.2.3 From 253cd0500508d859584f2fd724b69f48ebc8049f Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 30 Dec 2020 21:04:13 +0100 Subject: gnu: sbcl-slynk: Update to 1.0.42. * gnu/packages/lisp-xyz.scm (sbcl-slynk): Update to 1.0.42. --- gnu/packages/lisp-xyz.scm | 141 +++++++++++++++++++++++----------------------- 1 file changed, 69 insertions(+), 72 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index c9f3794c19..a0426e534f 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -782,82 +782,79 @@ antialiased TrueType font rendering using CLX and XRender extension.") (sbcl-package->ecl-package sbcl-clx-truetype)) (define-public sbcl-slynk - (let ((revision "4") - ;; Update together with emacs-sly. - (commit "68561f1b7b66fa0240766ece836bb04da31ea17d")) - (package - (name "sbcl-slynk") - (version (git-version "1.0.0-beta" revision commit)) - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/joaotavora/sly") - (commit commit))) - (sha256 - (base32 "1xwx537dhgclngi6b0faf320i8pnac9309wvmk6z2g6dm3v652ds")) - (file-name (git-file-name "slynk" version)) - (modules '((guix build utils) - (ice-9 ftw))) - (snippet - '(begin - ;; Move the contribs into the main source directory for easier - ;; access - (substitute* "slynk/slynk.asd" - (("\\.\\./contrib") - "contrib")) - (rename-file "contrib" "slynk/contrib") - ;; Move slynk's contents into the base directory for easier - ;; access - (for-each (lambda (file) - (unless (string-prefix? "." file) - (rename-file (string-append "slynk/" file) - (string-append "./" (basename file))))) - (scandir "slynk")) - #t)))) - (build-system asdf-build-system/sbcl) - (outputs '("out" "image")) - (arguments - `(#:tests? #f ; No test suite - #:asd-systems '("slynk" - "slynk/arglists" - "slynk/fancy-inspector" - "slynk/package-fu" - "slynk/mrepl" - "slynk/trace-dialog" - "slynk/profiler" - "slynk/stickers" - "slynk/indentation" - "slynk/retro") - #:phases - (modify-phases %standard-phases - (add-after 'create-asdf-configuration 'build-image - (lambda* (#:key outputs #:allow-other-keys) - (build-image (string-append - (assoc-ref %outputs "image") - "/bin/slynk") - %outputs - #:dependencies '("slynk" - "slynk/arglists" - "slynk/fancy-inspector" - "slynk/package-fu" - "slynk/mrepl" - "slynk/trace-dialog" - "slynk/profiler" - "slynk/stickers" - "slynk/indentation" - "slynk/retro")) - #t))))) - (synopsis "Common Lisp IDE for Emacs") - (description "SLY is a fork of SLIME, an IDE backend for Common Lisp. + (package + (name "sbcl-slynk") + (version "1.0.42") + (source + (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/joaotavora/sly") + (commit version))) + (sha256 + (base32 "10l867c4hgcpiajcfkz9g9vabp7y4bcgy51la6n9pqxrlg1fs455")) + (file-name (git-file-name "slynk" version)) + (modules '((guix build utils) + (ice-9 ftw))) + (snippet + '(begin + ;; Move the contribs into the main source directory for easier + ;; access + (substitute* "slynk/slynk.asd" + (("\\.\\./contrib") + "contrib")) + (rename-file "contrib" "slynk/contrib") + ;; Move slynk's contents into the base directory for easier + ;; access + (for-each (lambda (file) + (unless (string-prefix? "." file) + (rename-file (string-append "slynk/" file) + (string-append "./" (basename file))))) + (scandir "slynk")) + #t)))) + (build-system asdf-build-system/sbcl) + (outputs '("out" "image")) + (arguments + `(#:tests? #f ; No test suite + #:asd-systems '("slynk" + "slynk/arglists" + "slynk/fancy-inspector" + "slynk/package-fu" + "slynk/mrepl" + "slynk/trace-dialog" + "slynk/profiler" + "slynk/stickers" + "slynk/indentation" + "slynk/retro") + #:phases + (modify-phases %standard-phases + (add-after 'create-asdf-configuration 'build-image + (lambda* (#:key outputs #:allow-other-keys) + (build-image (string-append + (assoc-ref %outputs "image") + "/bin/slynk") + %outputs + #:dependencies '("slynk" + "slynk/arglists" + "slynk/fancy-inspector" + "slynk/package-fu" + "slynk/mrepl" + "slynk/trace-dialog" + "slynk/profiler" + "slynk/stickers" + "slynk/indentation" + "slynk/retro")) + #t))))) + (synopsis "Common Lisp IDE for Emacs") + (description "SLY is a fork of SLIME, an IDE backend for Common Lisp. It also features a completely redesigned REPL based on Emacs's own full-featured @code{comint-mode}, live code annotations, and a consistent interactive button interface. Everything can be copied to the REPL. One can create multiple inspectors with independent history.") - (home-page "https://github.com/joaotavora/sly") - (license license:public-domain) - (properties `((cl-source-variant . ,(delay cl-slynk))))))) + (home-page "https://github.com/joaotavora/sly") + (license license:public-domain) + (properties `((cl-source-variant . ,(delay cl-slynk)))))) (define-public cl-slynk (sbcl-package->cl-source-package sbcl-slynk)) -- cgit v1.2.3 From 32feb2c5f6c33421836cc525aed730be83799939 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 30 Dec 2020 22:35:20 +0100 Subject: gnu: sbcl: Update to 2.1.0. * gnu/packages/lisp.scm (sbcl): Update to 2.1.0. --- gnu/packages/lisp.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm index 9753926d13..603bbab736 100644 --- a/gnu/packages/lisp.scm +++ b/gnu/packages/lisp.scm @@ -393,14 +393,14 @@ an interpreter, a compiler, a debugger, and much more.") (define-public sbcl (package (name "sbcl") - (version "2.0.11") + (version "2.1.0") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/sbcl/sbcl/" version "/sbcl-" version "-source.tar.bz2")) (sha256 - (base32 "07cpswxh2f38b440xdn3fjk7b4r0ipj3sbwb3jd134phrr9smll7")))) + (base32 "0k12m2z60fnq64m8dgivprs2mvrsnmp7c5ipzx7jzkprcsymdvh5")))) (build-system gnu-build-system) (outputs '("out" "doc")) (native-inputs -- cgit v1.2.3 From 846e2e6188218646200ab08101b7d7e28fa89f84 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 30 Dec 2020 22:43:09 +0100 Subject: gnu: Add emacs-sly-stepper. * gnu/packages/emacs-xyz.scm (emacs-sly-stepper): New variable. --- gnu/packages/emacs-xyz.scm | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 02a487c9aa..0fb174f001 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9687,6 +9687,45 @@ file.") inside the source file.") (license license:gpl3+)))) +(define-public emacs-sly-stepper + (let ((commit "cd7fd00f9a701246e2a9ba8c37166dcae2fde04e")) + (package + (name "emacs-sly-stepper") + (version (git-version "0.0.0" "1" commit)) + (home-page "https://github.com/joaotavora/sly-stepper") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "09ll9dv8fd5dgnki82hcd48nm4qdzzn8wpva0zzr69zkjwzf9v25")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-sly" ,emacs-sly))) + (arguments + '(#:include (cons* "\\.lisp$" "\\.asd$" %default-include) + #:phases + (modify-phases %standard-phases + ;; The package provides autoloads. + (delete 'make-autoloads) + (delete 'enable-autoloads-compilation) + (add-after 'add-source-to-load-path 'add-contrib-to-emacs-load-path + (lambda* (#:key inputs #:allow-other-keys) + (let ((sly (assoc-ref inputs "emacs-sly"))) + (setenv "EMACSLOADPATH" + (string-append sly "/share/emacs/site-lisp/contrib:" + (getenv "EMACSLOADPATH")))) + #t))))) + (synopsis "Portable Common Lisp stepper interface for Emacs") + (description + "This package features a new, portable, visual stepping facility for +Common Lisp, realized as an extension to SLY.") + (license license:gpl3+)))) + (define-public emacs-sly-package-inferred (let ((commit "800e71e2be631422277e2ec77e6d6f6ea20e95ef") (revision "1")) -- cgit v1.2.3 From 2919de7e8038fef084c5fc90ff472a7dec94b59e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 19:55:16 +0100 Subject: gnu: Add rust-rusty-fork-0.3. * gnu/packages/crates-io.scm (rust-rusty-fork-0.3): New variable. (rust-rusty-fork-0.2): Inherit from above. --- gnu/packages/crates-io.scm | 39 ++++++++++++++++++++++++++++----------- 1 file changed, 28 insertions(+), 11 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f6432c629f..f7e6d2731a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -25685,23 +25685,20 @@ font rendering.") rustc compiler version.") (license (list license:expat license:asl2.0)))) -(define-public rust-rusty-fork-0.2 +(define-public rust-rusty-fork-0.3 (package (name "rust-rusty-fork") - (version "0.2.2") + (version "0.3.0") (source (origin (method url-fetch) (uri (crate-uri "rusty-fork" version)) - (file-name - (string-append name "-" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "1bjg8adk0i921088j52rn0hmvsry34q19g96x41pamqcw5j35n9x")))) + (base32 "0kxwq5c480gg6q0j3bg4zzyfh2kwmc3v2ba94jw8ncjc8mpcqgfb")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t - #:cargo-inputs + `(#:cargo-inputs (("rust-fnv" ,rust-fnv-1) ("rust-quick-error" ,rust-quick-error-1.2) ("rust-tempfile" ,rust-tempfile-3) @@ -25709,9 +25706,29 @@ rustc compiler version.") (home-page "https://github.com/altsysrq/rusty-fork") (synopsis "Library for running Rust tests in sub-processes") (description - "Cross-platform library for running Rust tests in sub-processes -using a fork-like interface.") - (license (list license:asl2.0 license:expat)))) + "This package is a cross-platform library for running Rust tests in +sub-processes using a fork-like interface.") + (license (list license:expat license:asl2.0)))) + +(define-public rust-rusty-fork-0.2 + (package + (inherit rust-rusty-fork-0.3) + (name "rust-rusty-fork") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "rusty-fork" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1bjg8adk0i921088j52rn0hmvsry34q19g96x41pamqcw5j35n9x")))) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-fnv" ,rust-fnv-1) + ("rust-quick-error" ,rust-quick-error-1.2) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-wait-timeout" ,rust-wait-timeout-0.2)))))) (define-public rust-ryu-1 (package -- cgit v1.2.3 From 1efcfa0f239eedd09892365c95d91538ee813acd Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 20:00:23 +0100 Subject: gnu: Add rust-bit-field-0.10. * gnu/packages/crates-io.scm (rust-bit-field-0.10): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f7e6d2731a..3be01bd81e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2176,6 +2176,26 @@ bindings to C and C++ libraries.") ("rust-diff" ,rust-diff-0.1) ("rust-shlex" ,rust-shlex-0.1)))))) +(define-public rust-bit-field-0.10 + (package + (name "rust-bit-field") + (version "0.10.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "bit-field" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "192rsg8g3ki85gj8rzslblnwr53yw5q4l8vfg6bf1lkn4cfdvdnw")))) + (build-system cargo-build-system) + (home-page "https://github.com/phil-opp/rust-bit-field") + (synopsis "Methods for operating on individual bits and ranges of bits") + (description + "This is a simple crate which provides the BitField trait, which provides +methods for operating on individual bits and ranges of bits on Rust's integral +types.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-bit-set-0.5 (package (name "rust-bit-set") -- cgit v1.2.3 From f35dae5bec2ee6e38d6542e06f1d8f45c7ab1c61 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 20:04:28 +0100 Subject: gnu: Add rust-core-affinity-0.5. * gnu/packages/crates-io.scm (rust-core-affinity-0.5): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3be01bd81e..1a50f5c95c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4993,6 +4993,29 @@ management. It supports signed and private (encrypted, authenticated) jars.") (description "This package implements cookie storage and retrieval.") (license (list license:expat license:asl2.0)))) +(define-public rust-core-affinity-0.5 + (package + (name "rust-core-affinity") + (version "0.5.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "core-affinity" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "07qpwyxps4gp3gci2p6c5h4cmcql7551bp91qgbv0ky3bh8h72kz")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-kernel32-sys" ,rust-kernel32-sys-0.2) + ("rust-libc" ,rust-libc-0.2) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-winapi" ,rust-winapi-0.2)))) + (home-page "https://github.com/Elzair/core_affinity_rs") + (synopsis "Manage CPU affinities") + (description "This package manages CPU affinities.") + (license (list license:expat license:asl2.0)))) + (define-public rust-core-arch-0.1 (package (name "rust-core-arch") -- cgit v1.2.3 From 2df2bf81bd9d9a2dd007589f3950111675b94cff Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 20:06:04 +0100 Subject: gnu: Add rust-raw-cpuid-8. * gnu/packages/crates-io.scm (rust-raw-cpuid-8): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1a50f5c95c..813ed8df94 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -23345,6 +23345,39 @@ random number generators.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.6)))))) +(define-public rust-raw-cpuid-8 + (package + (name "rust-raw-cpuid") + (version "8.1.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "raw-cpuid" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0wry932lx7gqyxn7w54mg61b7hiwywyir754jhfxiws3pnfpvpqz")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-cc" ,rust-cc-1) + ("rust-rustc-version" ,rust-rustc-version-0.2) + ("rust-serde" ,rust-serde-1) + ("rust-serde-derive" ,rust-serde-derive-1)) + #:cargo-development-inputs + (("rust-core-affinity" ,rust-core-affinity-0.5) + ("rust-libc" ,rust-libc-0.2) + ("rust-rustversion" ,rust-rustversion-0.1)))) + (home-page "https://github.com/gz/rust-cpuid") + (synopsis + "A library to parse the x86 CPUID instruction, written in rust with no external dependencies. The implementation closely resembles the Intel CPUID manual description. The library does only depend on libcore.") + (description + "This package provides a library to parse the x86 CPUID instruction, +written in rust with no external dependencies. The implementation closely +resembles the Intel CPUID manual description. The library does only depend on +libcore.") + (license license:expat))) + (define-public rust-rawpointer-0.2 (package (name "rust-rawpointer") -- cgit v1.2.3 From f3091f7d37012df1f3d050af48c309e24782398b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 21:51:17 +0100 Subject: gnu: Add rust-x86-0.33. * gnu/packages/crates-io.scm (rust-x86-0.33): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 813ed8df94..1e5b28d05b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36009,6 +36009,37 @@ API.") "Contains function definitions for the Windows API library ws2_32.") (license license:expat))) +(define-public rust-x86-0.33 + (package + (name "rust-x86") + (version "0.33.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "x86" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0sas98yzn549f5lxswqra2rjdfjxh24f3ndw5dfsnwnm9rlsr1i7")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-bit-field" ,rust-bit-field-0.10) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-csv" ,rust-csv-1.1) + ("rust-phf" ,rust-phf-0.7) + ("rust-phf-codegen" ,rust-phf-codegen-0.7) + ("rust-raw-cpuid" ,rust-raw-cpuid-8) + ("rust-serde-json" ,rust-serde-json-1)))) + (home-page "https://github.com/gz/rust-x86") + (synopsis "Library to program x86 (amd64) hardware") + (description + "This is a Library to program x86 (amd64) hardware. It contains x86 +specific data structure descriptions, data-tables, as well as convenience +function to call assembly instructions typically not exposed in higher level +languages.") + (license license:expat))) + (define-public rust-xattr-0.2 (package (name "rust-xattr") -- cgit v1.2.3 From d37f865d222465a3ba7cfe9a275e1eb92e314e0e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 22:34:20 +0100 Subject: gnu: rust-loom-0.3: Update to 0.3.6. * gnu/packages/crates-io.scm (rust-loom-0.3): Update to 0.3.6. [arguments]: Do not skip build. Update rust-scoped-tls Cargo input. Improve description. --- gnu/packages/crates-io.scm | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1e5b28d05b..ebd688a9d2 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15468,27 +15468,30 @@ by inspecting the system for user preference.") (define-public rust-loom-0.3 (package (name "rust-loom") - (version "0.3.2") + (version "0.3.6") (source (origin (method url-fetch) (uri (crate-uri "loom" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "10z738ig6vgvwc2kxjhjdr5b29p3ribk5f6gg6ak0xjxhjb4cnkc")))) + (base32 "1vabpqzdhcqy1d64kcyzgfwigiak0dr18whq0lkic8915w7lds50")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t ;; TODO fails due to unresolved import - #:cargo-inputs + `(#:cargo-inputs (("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-futures-util" ,rust-futures-util-0.3) ("rust-generator" ,rust-generator-0.6) - ("rust-scoped-tls" ,rust-scoped-tls-0.1) + ("rust-scoped-tls" ,rust-scoped-tls-1.0) ("rust-serde" ,rust-serde-1) ("rust-serde-json" ,rust-serde-json-1)))) (home-page "https://github.com/tokio-rs/loom") (synopsis "Permutation testing for concurrent code") - (description "Permutation testing for concurrent code") + (description + "Loom is a testing tool for concurrent Rust code. It runs a test many +times, permuting the possible concurrent executions of that test under the C11 +memory model. It uses state reduction techniques to avoid combinatorial +explosion.") (license license:expat))) (define-public rust-loom-0.2 -- cgit v1.2.3 From 5c06c4f0f75b4773932631374cef41fd614992c8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 22:45:06 +0100 Subject: gnu: Add rust-nix-0.19. * gnu/packages/crates-io.scm (rust-nix-0.19): New variable. (rust-nix-0.17): Inherit from above. --- gnu/packages/crates-io.scm | 51 ++++++++++++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 11 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ebd688a9d2..1c0087dca9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17482,40 +17482,69 @@ cryptographic library.") release (fork of debug_unreachable)") (license license:expat))) -(define-public rust-nix-0.17 +(define-public rust-nix-0.19 (package (name "rust-nix") - (version "0.17.0") + (version "0.19.1") (source (origin (method url-fetch) (uri (crate-uri "nix" version)) - (file-name - (string-append name "-" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "0qvk09kib3jpvpbaps0682nav20ibql61pf1s2h8jx9v5igpir2h")))) + (base32 "1wk1pmaf9pv84sc4jf19gm1as2yq3ydwcx0n5nc1bpsgzq6bmk5j")))) (build-system cargo-build-system) (arguments - `(#:tests? #f ; test suite hangs + `(#:tests? #f ; test suite hangs #:cargo-inputs (("rust-bitflags" ,rust-bitflags-1) ("rust-cc" ,rust-cc-1) - ("rust-cfg-if" ,rust-cfg-if-0.1) - ("rust-libc" ,rust-libc-0.2) - ("rust-void" ,rust-void-1)) + ("rust-cfg-if" ,rust-cfg-if-1) + ("rust-libc" ,rust-libc-0.2)) #:cargo-development-inputs (("rust-bytes" ,rust-bytes-0.4) ("rust-caps" ,rust-caps-0.3) ("rust-lazy-static" ,rust-lazy-static-1) ("rust-rand" ,rust-rand-0.6) + ("rust-semver" ,rust-semver-0.9) ("rust-sysctl" ,rust-sysctl-0.1) ("rust-tempfile" ,rust-tempfile-3)))) (home-page "https://github.com/nix-rust/nix") (synopsis "Rust friendly bindings to *nix APIs") - (description "Rust friendly bindings to *nix APIs.") + (description + "Nix seeks to provide friendly bindings to various *nix platform APIs. +The goal is to not provide a 100% unified interface, but to unify what can be +while still providing platform specific APIs.") (license license:expat))) +(define-public rust-nix-0.17 + (package + (inherit rust-nix-0.19) + (name "rust-nix") + (version "0.17.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "nix" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0qvk09kib3jpvpbaps0682nav20ibql61pf1s2h8jx9v5igpir2h")))) + (arguments + `(#:tests? #f ; test suite hangs + #:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-cc" ,rust-cc-1) + ("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-libc" ,rust-libc-0.2) + ("rust-void" ,rust-void-1)) + #:cargo-development-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-caps" ,rust-caps-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-rand" ,rust-rand-0.6) + ("rust-sysctl" ,rust-sysctl-0.1) + ("rust-tempfile" ,rust-tempfile-3)))))) + (define-public rust-nix-0.15 (package (inherit rust-nix-0.17) -- cgit v1.2.3 From 0989959ce40e6b2ac83dfdfa2f0ad5f4849779d2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 23:04:57 +0100 Subject: gnu: Add rust-proptest-0.10. * gnu/packages/crates-io.scm (rust-proptest-0.10): New variable. (rust-proptest-0.9): Inherit from above. --- gnu/packages/crates-io.scm | 54 +++++++++++++++++++++++++++++++++++----------- 1 file changed, 41 insertions(+), 13 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1c0087dca9..d841133f71 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -21931,20 +21931,55 @@ transfer). This library mimics the Git way of showing progress.") (license license:gpl2+))) +(define-public rust-proptest-0.10 + (package + (name "rust-proptest") + (version "0.10.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "proptest" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0vv4cvwn1v7h0zjajmhznll554a2ri8dqw26xql3q49r246cirhj")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-bit-set" ,rust-bit-set-0.5) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-byteorder" ,rust-byteorder-1) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-num-traits" ,rust-num-traits-0.2) + ("rust-quick-error" ,rust-quick-error-1.2) + ("rust-rand" ,rust-rand-0.7) + ("rust-rand-chacha" ,rust-rand-chacha-0.2) + ("rust-rand-xorshift" ,rust-rand-xorshift-0.2) + ("rust-regex-syntax" ,rust-regex-syntax-0.6) + ("rust-rusty-fork" ,rust-rusty-fork-0.3) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-x86" ,rust-x86-0.33)) + #:cargo-development-inputs + (("rust-regex" ,rust-regex-1)))) + (home-page "https://altsysrq.github.io/proptest-book/proptest/index.html") + (synopsis "Hypothesis-like property-based testing and shrinking") + (description + "The @code{proptest} crate provides most of Proptest’s functionality, +including most strategies and the testing framework itself.") + (license (list license:expat license:asl2.0)))) + (define-public rust-proptest-0.9 (package + (inherit rust-proptest-0.10) (name "rust-proptest") (version "0.9.6") (source (origin (method url-fetch) (uri (crate-uri "proptest" version)) - (file-name - (string-append name "-" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "0nsslp46lvf3ll5rd83rin652qlz1kqyp0rmsciy0pw4kf0pgi01")))) - (build-system cargo-build-system) + (base32 "0nsslp46lvf3ll5rd83rin652qlz1kqyp0rmsciy0pw4kf0pgi01")))) (arguments `(#:cargo-inputs (("rust-bit-set" ,rust-bit-set-0.5) @@ -21960,14 +21995,7 @@ This library mimics the Git way of showing progress.") ("rust-rusty-fork" ,rust-rusty-fork-0.2) ("rust-tempfile" ,rust-tempfile-3)) #:cargo-development-inputs - (("rust-regex" ,rust-regex-1)))) - (home-page - "https://altsysrq.github.io/proptest-book/proptest/index.html") - (synopsis - "Hypothesis-like property-based testing and shrinking") - (description - "Hypothesis-like property-based testing and shrinking.") - (license (list license:asl2.0 license:expat)))) + (("rust-regex" ,rust-regex-1)))))) (define-public rust-proptest-0.8 (package -- cgit v1.2.3 From 0f89d63722766dcde70f52c1fd7eba38f978978b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 9 Dec 2020 23:07:26 +0100 Subject: gnu: Add rust-tokio-0.3 and rust-tokio-test-0.3. * gnu/packages/crates-io.scm (rust-tokio-0.3): New variable. (rust-tokio-0.2): Inherit from above. (rust-tokio-test-0.3): New variable. (rust-tokio-test-0.2): Inherit from above. --- gnu/packages/crates-io.scm | 98 +++++++++++++++++++++++++++++++++++++--------- 1 file changed, 79 insertions(+), 19 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d841133f71..126f2f1ce0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31515,8 +31515,52 @@ crate.") "A 100% safe crate of vec-like types.") (license (list license:zlib license:asl2.0 license:expat)))) +(define-public rust-tokio-0.3 + (package + (name "rust-tokio") + (version "0.3.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0lj26zy5k1dbln0599bn918z5j16wz5iyzs8cjz33hp2ksrkwam1")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #f ;FIXME: fail due to unresolved imports + #:cargo-inputs + (("rust-autocfg" ,rust-autocfg-1.0) + ("rust-bytes" ,rust-bytes-0.6) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-memchr" ,rust-memchr-2) + ("rust-mio" ,rust-mio-0.7) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) + ("rust-signal-hook-registry" ,rust-signal-hook-registry-1) + ("rust-slab" ,rust-slab-0.4) + ("rust-tokio-macros" ,rust-tokio-macros-0.3) + ("rust-tracing" ,rust-tracing-0.1) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-loom" ,rust-loom-0.3) + ("rust-nix" ,rust-nix-0.19) + ("rust-proptest" ,rust-proptest-0.10) + ("rust-tokio-test" ,rust-tokio-test-0.3)))) + (home-page "https://tokio.rs") + (synopsis "Event-driven, non-blocking I/O platform") + (description + "This package provides an event-driven, non-blocking I/O platform for +writing asynchronous I/O backed applications.") + (license license:expat))) + (define-public rust-tokio-0.2 (package + (inherit rust-tokio-0.3) (name "rust-tokio") (version "0.2.21") (source @@ -31526,7 +31570,6 @@ crate.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "0n1dxsjv9fxv3kmr3nh4n8v8pqckwgdlls942msysavhp4kzm6fh")))) - (build-system cargo-build-system) (arguments `(#:skip-build? #t #:cargo-inputs @@ -31547,18 +31590,12 @@ crate.") ("rust-slab" ,rust-slab-0.4) ("rust-tokio-macros" ,rust-tokio-macros-0.2) ("rust-winapi" ,rust-winapi-0.3)) - #:cargo-development-inputs - (("rust-futures" ,rust-futures-0.3) - ("rust-loom" ,rust-loom-0.3) - ("rust-proptest" ,rust-proptest-0.9) - ("rust-tempfile" ,rust-tempfile-3) - ("rust-tokio-test" ,rust-tokio-test-0.2)))) - (home-page "https://tokio.rs") - (synopsis "Event-driven, non-blocking I/O platform") - (description - "An event-driven, non-blocking I/O platform for writing asynchronous I/O -backed applications.") - (license license:expat))) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-loom" ,rust-loom-0.3) + ("rust-proptest" ,rust-proptest-0.9) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-tokio-test" ,rust-tokio-test-0.2)))))) (define-public rust-tokio-0.1 (package @@ -32408,31 +32445,54 @@ Rust.") ("rust-tokio" ,rust-tokio-0.1) ("rust-tokio-mock-task" ,rust-tokio-mock-task-0.1)))))) -(define-public rust-tokio-test-0.2 +(define-public rust-tokio-test-0.3 (package (name "rust-tokio-test") - (version "0.2.1") + (version "0.3.0") (source (origin (method url-fetch) (uri (crate-uri "tokio-test" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0v81p2n853b1kzyla3dbfmnazirn6s3n8p3z8k20bmdn370lj07d")))) + (base32 "06nzdkjsxr16pbr5m80zm3vcr8dhcl9amjgb9l9vj4x72cmmmp3y")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-bytes" ,rust-bytes-0.5) ("rust-futures-core" ,rust-futures-core-0.3) - ("rust-tokio" ,rust-tokio-0.2)) + ("rust-tokio" ,rust-tokio-0.3)) #:cargo-development-inputs (("rust-futures-util" ,rust-futures-util-0.3) - ("rust-tokio" ,rust-tokio-0.2)))) + ("rust-tokio" ,rust-tokio-0.3)))) (home-page "https://tokio.rs") (synopsis "Testing utilities for Tokio- and futures-based code") - (description "Testing utilities for Tokio- and futures-based code") + (description + "This package provides testing utilities for Tokio- and futures-based +code.") (license license:expat))) +(define-public rust-tokio-test-0.2 + (package + (inherit rust-tokio-test-0.3) + (name "rust-tokio-test") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-test" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0v81p2n853b1kzyla3dbfmnazirn6s3n8p3z8k20bmdn370lj07d")))) + (arguments + `(#:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-tokio" ,rust-tokio-0.2)) + #:cargo-development-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-tokio" ,rust-tokio-0.2)))))) + (define-public rust-tokio-tcp-0.1 (package (name "rust-tokio-tcp") -- cgit v1.2.3 From 082e8a6fa12973f5110211e625088af2bfd5aa71 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 16:18:35 +0100 Subject: gnu: Add rust-tokio-macros-0.3. * gnu/packages/crates-io.scm (rust-tokio-macros-0.3): New variable. (rust-tokio-macros-0.2): Inherit from above. --- gnu/packages/crates-io.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 126f2f1ce0..69efb59298 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31942,6 +31942,50 @@ futures efficiently") (description "This package provides Tokio's proc macros.") (license license:expat))) +(define-public rust-tokio-macros-0.3 + (package + (name "rust-tokio-macros") + (version "0.3.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-macros" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1dvd3gji7a0i1kgck2lwgbcbklk3qb1bsqgd2v9amj63kyjzzps6")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.3)))) + (home-page "https://tokio.rs") + (synopsis "Tokio's proc macros") + (description "This package provides Tokio's proc macros.") + (license license:expat))) + +(define-public rust-tokio-macros-0.2 + (package + (inherit rust-tokio-macros-0.3) + (name "rust-tokio-macros") + (version "0.2.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-macros" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1283aq0l7rnh79zzqk4r34dgimvwcymrzmg1yah9ai2nmb3arhzh")))) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.2)))))) + (define-public rust-tokio-mock-task-0.1 (package (name "rust-tokio-mock-task") -- cgit v1.2.3 From 67fc7dc591581932b3778b2452901172edc92cbe Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 16:21:01 +0100 Subject: gnu: rust-tokio-macros-0.2: Remove duplicate package. * gnu/packages/crates-io.scm (rust-tokio-macros-0.2): Remove duplicate package. --- gnu/packages/crates-io.scm | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 69efb59298..f5cc4c89b0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31918,30 +31918,6 @@ the current thread.") futures efficiently") (license (list license:asl2.0 license:expat)))) -(define-public rust-tokio-macros-0.2 - (package - (name "rust-tokio-macros") - (version "0.2.5") - (source - (origin - (method url-fetch) - (uri (crate-uri "tokio-macros" version)) - (file-name (string-append name "-" version ".tar.gz")) - (sha256 - (base32 "1283aq0l7rnh79zzqk4r34dgimvwcymrzmg1yah9ai2nmb3arhzh")))) - (build-system cargo-build-system) - (arguments - `(#:cargo-inputs - (("rust-proc-macro2" ,rust-proc-macro2-1) - ("rust-quote" ,rust-quote-1) - ("rust-syn" ,rust-syn-1)) - #:cargo-development-inputs - (("rust-tokio" ,rust-tokio-0.2)))) - (home-page "https://tokio.rs") - (synopsis "Tokio's proc macros") - (description "This package provides Tokio's proc macros.") - (license license:expat))) - (define-public rust-tokio-macros-0.3 (package (name "rust-tokio-macros") -- cgit v1.2.3 From b8017db57870a06e09db3be61559faa162a29c0b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 17:46:57 +0100 Subject: gnu: Add rust-trust-dns-openssl-0.6. * gnu/packages/crates-io.scm (rust-trust-dns-openssl-0.6): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f5cc4c89b0..ad2be02344 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33345,6 +33345,29 @@ extension for the Trust-DNS client to use native-tls for TLS.") extension for the Trust-DNS client to use tokio-openssl for TLS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-openssl-0.6 + (package + (inherit rust-trust-dns-openssl-0.19) + (name "rust-trust-dns-openssl") + (version "0.6.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-openssl" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0zwx2bsf1rbyjr6l2c3vi24z7414n4b5qiymva9dmbvwxnqqyk1j")))) + (arguments + `(#:cargo-inputs + (("rust-futures" ,rust-futures-0.1) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-tokio-openssl" ,rust-tokio-openssl-0.3) + ("rust-tokio-tcp" ,rust-tokio-tcp-0.1) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.7)) + #:cargo-development-inputs + (("rust-openssl" ,rust-openssl-0.10) + ("rust-tokio" ,rust-tokio-0.1)))))) + (define-public rust-trust-dns-proto-0.19 (package (name "rust-trust-dns-proto") -- cgit v1.2.3 From 78791ed160828e48f9016c8610f130d78b210191 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 18:00:45 +0100 Subject: gnu: rust-trust-dns-native-tls-0.19: Fix build. * gnu/packages/crates-io.scm (rust-trust-dns-native-tls-0.19)[arguments]: Disable tests. [navite-inputs]: Add pkg-config. [inputs]: Add openssl. --- gnu/packages/crates-io.scm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ad2be02344..f3f28fbf67 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33300,12 +33300,17 @@ extension for the Trust-DNS client to use DNS over HTTPS.") "173443yivsiyzvnai4h53v71br8jsz4zjwhp83q3x4hnh6306ymv")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #false + #:cargo-inputs (("rust-futures" ,rust-futures-0.3) ("rust-native-tls" ,rust-native-tls-0.2) ("rust-tokio" ,rust-tokio-0.2) ("rust-tokio-tls" ,rust-tokio-tls-0.3) ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.19)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))) (home-page "http://www.trust-dns.org/index.html") (synopsis "native-tls extension for the Trust-DNS client") (description "Trust-DNS is a safe and secure DNS library. This is an -- cgit v1.2.3 From 011ad30064ed81fc2e25ce53cb702433885b3699 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 18:05:44 +0100 Subject: gnu: Add rust-trust-dns-native-tls-0.6. * gnu/packages/crates-io.scm (rust-trust-dns-native-tls-0.6): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f3f28fbf67..7880845760 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33317,6 +33317,29 @@ extension for the Trust-DNS client to use DNS over HTTPS.") extension for the Trust-DNS client to use native-tls for TLS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-native-tls-0.6 + (package + (inherit rust-trust-dns-native-tls-0.19) + (name "rust-trust-dns-native-tls") + (version "0.6.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-native-tls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0v18xwcy2vz57gnp1a6wx52c4zpwlakpr75ydmai8gc0h2kfzd7l")))) + (arguments + `(#:tests? #false + #:cargo-inputs + (("rust-futures" ,rust-futures-0.1) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-tokio-tcp" ,rust-tokio-tcp-0.1) + ("rust-tokio-tls" ,rust-tokio-tls-0.2) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.7)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.1)))))) + (define-public rust-trust-dns-openssl-0.19 (package (name "rust-trust-dns-openssl") -- cgit v1.2.3 From 5791cf7df9c663bb8b6784da63a008dc6de65554 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 18:21:50 +0100 Subject: gnu: rust-data-encoding-2: Update to 2.3.1. * gnu/packages/crates-io.scm (rust-data-encoding-2): Update to 2.3.1. --- gnu/packages/crates-io.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7880845760..46936aff1f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6464,7 +6464,7 @@ for Rust.") (define-public rust-data-encoding-2 (package (name "rust-data-encoding") - (version "2.1.2") + (version "2.3.1") (source (origin (method url-fetch) @@ -6472,9 +6472,8 @@ for Rust.") (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "15xd6afhsjl08285piwczrafmckpp8i29padj8v12xhahshprx7l")))) + "027rcrwdschrkdr2n9d24gnh03vl41qmvhjqn9vn6z1njy2n0flr")))) (build-system cargo-build-system) - (arguments '(#:skip-build? #t)) (home-page "https://github.com/ia0/data-encoding") (synopsis "Efficient and customizable data-encoding functions") (description -- cgit v1.2.3 From 158c1bb06e3a07526a8e4bbe4d51d93bce18b063 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 18:42:49 +0100 Subject: gnu: rust-trust-dns-https-0.19: Disable tests. * gnu/packages/crates-io.scm (rust-trust-dns-https-0.19)[arguments]: Disable tests, which are failing. --- gnu/packages/crates-io.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 46936aff1f..b2546e60ec 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33259,7 +33259,8 @@ application authors using tracing to instrument their applications.") "0s6yiqy98wddc2vid0dypj4cdnvycd4vrrj6l9s7yymq0iqpky5g")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #false + #:cargo-inputs (("rust-backtrace" ,rust-backtrace-0.3) ("rust-bytes" ,rust-bytes-0.5) ("rust-data-encoding" ,rust-data-encoding-2) -- cgit v1.2.3 From 44462b1acf4102d485e8477b214f6ca8cd1a7d83 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 18:51:43 +0100 Subject: gnu: Add rust-trust-dns-https-0.3. * gnu/packages/crates-io.scm (rust-trust-dns-https-0.3): New variable. --- gnu/packages/crates-io.scm | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b2546e60ec..a708383b0b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33286,6 +33286,42 @@ application authors using tracing to instrument their applications.") extension for the Trust-DNS client to use DNS over HTTPS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-https-0.3 + (package + (inherit rust-trust-dns-https-0.19) + (name "rust-trust-dns-https") + (version "0.3.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-https" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "14ps1fxngm8d3ynp9jf86zrqbyzjzh62v5grwrqb1q0xhbz98vv1")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;network unreachable + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-data-encoding" ,rust-data-encoding-2) + ("rust-failure" ,rust-failure-0.1) + ("rust-futures" ,rust-futures-0.1) + ("rust-h2" ,rust-h2-0.1) + ("rust-http" ,rust-http-0.1) + ("rust-log" ,rust-log-0.4) + ("rust-rustls" ,rust-rustls-0.15) + ("rust-tokio-executor" ,rust-tokio-executor-0.1) + ("rust-tokio-reactor" ,rust-tokio-reactor-0.1) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.9) + ("rust-tokio-tcp" ,rust-tokio-tcp-0.1) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.7) + ("rust-trust-dns-rustls" ,rust-trust-dns-rustls-0.6) + ("rust-typed-headers" ,rust-typed-headers-0.1) + ("rust-webpki" ,rust-webpki-0.19) + ("rust-webpki-roots" ,rust-webpki-roots-0.16)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.1)))))) + (define-public rust-trust-dns-native-tls-0.19 (package (name "rust-trust-dns-native-tls") -- cgit v1.2.3 From 6aee4aafaf16385a39c17d9ee040d7624d584b4f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 19:04:56 +0100 Subject: gnu: rust-trust-dns-resolver-0.19: Disable tests. * gnu/packages/crates-io.scm (rust-trust-dns-resolver-0.19): Disable tests. --- gnu/packages/crates-io.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a708383b0b..d9c173b2d7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33532,7 +33532,8 @@ foundational DNS protocol library for all Trust-DNS projects.") "0xqv31gndybcrr5gi6jjp47qcvdxsc147s69a0y0nc6qqgyws8qg")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #false ;network unreachable + #:cargo-inputs (("rust-backtrace" ,rust-backtrace-0.3) ("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-futures" ,rust-futures-0.3) -- cgit v1.2.3 From 33ebe9faca851048f32b20dbd6ec2bad981ff42a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 19:11:09 +0100 Subject: gnu: Add rust-trust-dns-resolver-0.11. * gnu/packages/crates-io.scm (rust-trust-dns-resolver-0.11): New variable. --- gnu/packages/crates-io.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d9c173b2d7..10c4422f88 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33568,6 +33568,41 @@ and AsyncResolver for supported resolution types. The Client can be used for other queries.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-resolver-0.11 + (package + (inherit rust-trust-dns-resolver-0.19) + (name "rust-trust-dns-resolver") + (version "0.11.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-resolver" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0fd0w2zsdwlsag27fsg0fzyd7j7niw0r22rwh2c5fdmsipjr56bc")))) + (arguments + `(#:tests? #false ;networking failures + #:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-failure" ,rust-failure-0.1) + ("rust-futures" ,rust-futures-0.1) + ("rust-ipconfig" ,rust-ipconfig-0.2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-lru-cache" ,rust-lru-cache-0.1) + ("rust-resolv-conf" ,rust-resolv-conf-0.6) + ("rust-rustls" ,rust-rustls-0.15) + ("rust-serde" ,rust-serde-1) + ("rust-smallvec" ,rust-smallvec-0.6) + ("rust-tokio" ,rust-tokio-0.1) + ("rust-tokio-executor" ,rust-tokio-executor-0.1) + ("rust-trust-dns-https" ,rust-trust-dns-https-0.3) + ("rust-trust-dns-native-tls" ,rust-trust-dns-native-tls-0.6) + ("rust-trust-dns-openssl" ,rust-trust-dns-openssl-0.6) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.7) + ("rust-trust-dns-rustls" ,rust-trust-dns-rustls-0.6) + ("rust-webpki-roots" ,rust-webpki-roots-0.16)))))) + (define-public rust-trust-dns-rustls-0.19 (package (name "rust-trust-dns-rustls") -- cgit v1.2.3 From b929af8a207143c81294232ba7efffe9bd515e7c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 20:15:34 +0100 Subject: gnu: Add rust-tokio-rustls-0.10. * gnu/packages/crates-io.scm (rust-tokio-rustls-0.10): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 10c4422f88..a9df95c866 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32296,6 +32296,31 @@ using Rustls.") ("rust-webpki-roots" ,rust-webpki-roots-0.18)))) (license (list license:expat license:asl2.0)))) +(define-public rust-tokio-rustls-0.10 + (package + (inherit rust-tokio-rustls-0.12) + (name "rust-tokio-rustls") + (version "0.10.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-rustls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0xh6gxilm7waj55rxfgqmvl8abynzr3ang57qvbap400k67z0z1d")))) + (arguments + `(#:cargo-test-flags '("--release" "--" "--skip=test_badssl") + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-futures" ,rust-futures-0.1) + ("rust-iovec" ,rust-iovec-0.1) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio-io" ,rust-tokio-io-0.1) + ("rust-webpki" ,rust-webpki-0.21)) + #:cargo-development-inputs + (("rust-tokio" ,rust-tokio-0.1) + ("rust-webpki-roots" ,rust-webpki-roots-0.17)))))) + (define-public rust-tokio-rustls-0.9 (package (inherit rust-tokio-rustls-0.12) -- cgit v1.2.3 From 6b9741d78f32f492616d9548671ed8b2b4b4c045 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 21:04:11 +0100 Subject: gnu: Add rust-hyper-rustls-0.17. * gnu/packages/crates-io.scm (rust-hyper-rustls-0.17): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a9df95c866..718d14d26a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -12888,6 +12888,32 @@ HTTPS.") (license (list license:asl2.0 license:isc license:expat)))) +(define-public rust-hyper-rustls-0.17 + (package + (inherit rust-hyper-rustls-0.21) + (name "rust-hyper-rustls") + (version "0.17.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "hyper-rustls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0li9xkzmqd40dbjbl9g0nbf2ka9y0q538ififyd30zsavz3qb7bi")))) + (arguments + `(#:cargo-test-flags '("--release" "--" "--skip=server" "--skip=client" + "--skip=custom_ca_store") + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-ct-logs" ,rust-ct-logs-0.6) + ("rust-futures" ,rust-futures-0.1) + ("rust-hyper" ,rust-hyper-0.12) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio-io" ,rust-tokio-io-0.1) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.10) + ("rust-webpki" ,rust-webpki-0.21) + ("rust-webpki-roots" ,rust-webpki-roots-0.17)))))) + (define-public rust-hyper-tls-0.4 (package (name "rust-hyper-tls") -- cgit v1.2.3 From ba4627e18fd34448c43153a1e9c151b8d447419f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 22:02:49 +0100 Subject: gnu: Add rust-reqwest-0.9. * gnu/packages/crates-io.scm (rust-reqwest-0.9): New variable. --- gnu/packages/crates-io.scm | 52 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 718d14d26a..1f924d8887 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24221,6 +24221,58 @@ uses finite automata and guarantees linear time matching on all inputs.") (description "This package provides a high level HTTP client library.") (license (list license:expat license:asl2.0)))) +(define-public rust-reqwest-0.9 + (package + (inherit rust-reqwest-0.10) + (name "rust-reqwest") + (version "0.9.24") + (source + (origin + (method url-fetch) + (uri (crate-uri "reqwest" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1aql4wpmf1cfl09xddlxnmd7y1nj7fcbzmsh9603qd61lfp471pq")))) + (arguments + `(#:cargo-test-flags '("--release" "--" "--skip=badssl") + #:cargo-inputs + (("rust-base64" ,rust-base64-0.10) + ("rust-bytes" ,rust-bytes-0.4) + ("rust-cookie" ,rust-cookie-0.12) + ("rust-cookie-store" ,rust-cookie-store-0.7) + ("rust-encoding-rs" ,rust-encoding-rs-0.8) + ("rust-flate2" ,rust-flate2-1) + ("rust-futures" ,rust-futures-0.1) + ("rust-http" ,rust-http-0.1) + ("rust-hyper" ,rust-hyper-0.12) + ("rust-hyper-old-types" ,rust-hyper-old-types-0.11) + ("rust-hyper-rustls" ,rust-hyper-rustls-0.17) + ("rust-hyper-tls" ,rust-hyper-tls-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-mime" ,rust-mime-0.3) + ("rust-mime-guess" ,rust-mime-guess-2) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.5) + ("rust-socks" ,rust-socks-0.3) + ("rust-time" ,rust-time-0.1) + ("rust-tokio" ,rust-tokio-0.1) + ("rust-tokio-executor" ,rust-tokio-executor-0.1) + ("rust-tokio-io" ,rust-tokio-io-0.1) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.10) + ("rust-tokio-threadpool" ,rust-tokio-threadpool-0.1) + ("rust-tokio-timer" ,rust-tokio-timer-0.2) + ("rust-trust-dns-resolver" ,rust-trust-dns-resolver-0.11) + ("rust-url" ,rust-url-1) + ("rust-uuid" ,rust-uuid-0.7) + ("rust-webpki-roots" ,rust-webpki-roots-0.17) + ("rust-winreg" ,rust-winreg-0.6)) + #:cargo-development-inputs + (("rust-doc-comment" ,rust-doc-comment-0.3) + ("rust-libflate" ,rust-libflate-0.1)))))) + (define-public rust-resolv-conf-0.6 (package (name "rust-resolv-conf") -- cgit v1.2.3 From 407298028d70a2596436220ab962ddf6d4837e36 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 22:04:20 +0100 Subject: gnu: rust-cc-1: Update to 1.0.66. * gnu/packages/crates-io.scm (rust-cc-1): Update to 1.0.66. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1f924d8887..c428218ed3 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3699,7 +3699,7 @@ used in argon2rs' bench suite.") (define-public rust-cc-1 (package (name "rust-cc") - (version "1.0.58") + (version "1.0.66") (source (origin (method url-fetch) @@ -3707,7 +3707,7 @@ used in argon2rs' bench suite.") (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "065m2fphrv5csy8hvv37msi3a739mfkgw7pcg71dfw9jwnr6z87r")))) + "0j7d7h4n81z5f22l3v8ggjvvw8m64636nlaqax4x1y44da1rc12c")))) (build-system cargo-build-system) (arguments `(#:tests? #f -- cgit v1.2.3 From dd31176b969d59784c92c94c56a23af1d6278baa Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 29 Dec 2020 13:16:55 +0100 Subject: gnu: grpc: Update to 1.34.0. * gnu/packages/rpc.scm (grpc): Update to 1.34.0. Signed-off-by: Leo Famulari --- gnu/packages/rpc.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/rpc.scm b/gnu/packages/rpc.scm index cffa703fe0..a0d979e3bb 100644 --- a/gnu/packages/rpc.scm +++ b/gnu/packages/rpc.scm @@ -45,7 +45,7 @@ (define-public grpc (package (name "grpc") - (version "1.33.2") + (version "1.34.0") (outputs '("out" "static")) (source (origin (method git-fetch) @@ -55,7 +55,7 @@ (file-name (git-file-name name version)) (sha256 (base32 - "09xd9pkyp10gh051kf8kwxn4myw42zv8kngr9z8wpm6mjy0j4ylw")))) + "1fs407hnlnm0b8sncjwys9rc7ia5nb7wxrpx39nq3pzzfs1lv3vq")))) (build-system cmake-build-system) (arguments `(#:tests? #f ; no test target -- cgit v1.2.3 From ca065e60269571e38aee1b3e9a7e3843991359bd Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 30 Dec 2020 17:10:49 -0500 Subject: gnu: Remove python2-pyarrow. This package was failing to build and had no users in the tree. * gnu/packages/databases.scm (python2-pyarrow): Remove variable. --- gnu/packages/databases.scm | 3 --- 1 file changed, 3 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 6c1bb7b34d..6e03724798 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -3806,9 +3806,6 @@ implementation, along with tools for interoperability with pandas, NumPy, and other traditional Python scientific computing packages.") (license license:asl2.0))) -(define-public python2-pyarrow - (package-with-python2 python-pyarrow)) - (define-public python-crate (package (name "python-crate") -- cgit v1.2.3 From 6a69568b9e1c6d990c58dc40dee0f5fd1348589c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 30 Dec 2020 23:48:54 +0100 Subject: gnu: rust-raw-cpuid-8: Shorten synopsis. * gnu/packages/crates-io.scm (rust-raw-cpuid-8)[synopsis]: Shorten it. [decription]: Tiny capitalization fix. --- gnu/packages/crates-io.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c428218ed3..255ce2a0d5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -23454,11 +23454,10 @@ random number generators.") ("rust-libc" ,rust-libc-0.2) ("rust-rustversion" ,rust-rustversion-0.1)))) (home-page "https://github.com/gz/rust-cpuid") - (synopsis - "A library to parse the x86 CPUID instruction, written in rust with no external dependencies. The implementation closely resembles the Intel CPUID manual description. The library does only depend on libcore.") + (synopsis "Library to parse the x86 CPUID instruction, written in Rust") (description "This package provides a library to parse the x86 CPUID instruction, -written in rust with no external dependencies. The implementation closely +written in Rust with no external dependencies. The implementation closely resembles the Intel CPUID manual description. The library does only depend on libcore.") (license license:expat))) -- cgit v1.2.3 From 50abaf63879c93e0ea0e09883defe639396fb04c Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 29 Dec 2020 12:37:21 +0100 Subject: gnu: slurm: Update to 20.11.2. * gnu/packages/parallel.scm (slurm): Update to 20.11.2. Signed-off-by: Leo Famulari --- gnu/packages/parallel.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/parallel.scm b/gnu/packages/parallel.scm index c346ad22d0..3f03792ffd 100644 --- a/gnu/packages/parallel.scm +++ b/gnu/packages/parallel.scm @@ -108,7 +108,7 @@ and they are executed on lists of files, hosts, users or other items.") (define-public slurm (package (name "slurm") - (version "20.02.5") + (version "20.11.2") (source (origin (method url-fetch) (uri (string-append @@ -116,7 +116,7 @@ and they are executed on lists of files, hosts, users or other items.") version ".tar.bz2")) (sha256 (base32 - "08qp60rxsny6fcx58xim88avx7f7h7q1vpq3lfw6nlha04r7lan3")) + "15h2vs58apgdz02ijgr46090vjyaa81qcm76mm6fxlvkkfd4pyxp")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 9d6863de245fc061f24693b58ce87e73fe299d31 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Mon, 28 Dec 2020 14:36:22 +0100 Subject: gnu: borg: Install shell completions. * gnu/packages/backup.scm (borg)[arguments]: Add new 'install-shell-completions' phase. Signed-off-by: Leo Famulari --- gnu/packages/backup.scm | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm index 64fc23bf4c..ce6ea7fd49 100644 --- a/gnu/packages/backup.scm +++ b/gnu/packages/backup.scm @@ -17,6 +17,7 @@ ;;; Copyright © 2019 Mathieu Othacehe ;;; Copyright © 2020 Nicolas Goaziou ;;; Copyright © 2020 Marcin Karpezo +;;; Copyright © 2020 Michael Rohleder ;;; ;;; This file is part of GNU Guix. ;;; @@ -672,6 +673,19 @@ detection, and lossless compression.") "docs/misc/internals-picture.txt" "docs/misc/prune-example.txt")) (copy-recursively "docs/man" man) + #t))) + (add-after 'install-docs 'install-shell-completions + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (etc (string-append out "/etc")) + (share (string-append out "/share"))) + (with-directory-excursion "scripts/shell_completions" + (install-file "bash/borg" + (string-append etc "/bash_completion.d")) + (install-file "zsh/_borg" + (string-append share "/zsh/site-functions")) + (install-file "fish/borg.fish" + (string-append share "/fish/vendor_completions.d"))) #t)))))) (native-inputs `(("python-cython" ,python-cython) -- cgit v1.2.3 From d598e43f03e288dba420821dcf4397bc37700c6d Mon Sep 17 00:00:00 2001 From: Ryan Prior via Guix-patches via Date: Wed, 30 Dec 2020 04:12:39 +0000 Subject: gnu: esbuild: Update to 0.8.27. * gnu/packages/web.scm (esbuild): Update to 0.8.27. Signed-off-by: Leo Famulari --- gnu/packages/web.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 516cabaa19..cef1028d34 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -1487,7 +1487,7 @@ used to validate and fix HTML data.") (define-public esbuild (package (name "esbuild") - (version "0.8.26") + (version "0.8.27") (source (origin (method git-fetch) @@ -1496,7 +1496,7 @@ used to validate and fix HTML data.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0zw68mgmmicbkvx7s22knvm8nng5qn41b1chn35prhkla3kx1jn1")) + (base32 "1n9h6r3q6mik7p5j0cyybh1sdcllig0awbryrx28r03cxv4ip2ij")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 9517fc906a23d14895870b0ab92ac3c06d08696c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 00:35:20 +0100 Subject: gnu: rust-once-cell-1: Update to 1.5.2. * gnu/packages/crates-io.scm (rust-once-cell-1): Update to 1.5.2. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 255ce2a0d5..c01311f43e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18926,7 +18926,7 @@ other crates to create safe wrappers around Oniguruma.") (define-public rust-once-cell-1 (package (name "rust-once-cell") - (version "1.4.1") + (version "1.5.2") (source (origin (method url-fetch) @@ -18935,7 +18935,7 @@ other crates to create safe wrappers around Oniguruma.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1ba56vr8n85xgajnn78pg6iag4inwil3mqg90wi5jaz6xzkm23i6")))) + "183zs1dbmsv24mkafjypf9qwjrx46an58vb004a162l113sl3g8k")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 9aa1930eb4bb815294478f8deeb1df0bf6916faf Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 00:37:57 +0100 Subject: gnu: rust-vcpkg-0.2: Update to 0.2.11. * gnu/packages/crates-io.scm (rust-vcpkg-0.2): Update to 0.2.11. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c01311f43e..e227d26631 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -34826,7 +34826,7 @@ first byte.") (define-public rust-vcpkg-0.2 (package (name "rust-vcpkg") - (version "0.2.10") + (version "0.2.11") (source (origin (method url-fetch) @@ -34834,7 +34834,7 @@ first byte.") (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "132hlmsc4maava91vl4lh677sl1c7vr8ccl53fnr5w41y6dh4m34")))) + "1yvrd2b97j4hv5bfhcj3al0dpkbzkdsr6dclxqz3zqm50rhwl2xh")))) (build-system cargo-build-system) (arguments `(#:tests? #f ; Tests want mysql, harfbuzz, graphite2. -- cgit v1.2.3 From 0492cc2f5078d78d2adfaa1c2cd38dff964b579d Mon Sep 17 00:00:00 2001 From: Ryan Prior via Guix-patches via Date: Wed, 30 Dec 2020 04:12:52 +0000 Subject: gnu: zrythm: Update to 1.0.0-alpha.6.0.1. * gnu/packages/music.scm (zrythm): Update to 1.0.0-alpha.6.0.1. Signed-off-by: Leo Famulari --- gnu/packages/music.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index ab881845ed..84a55e6305 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -32,6 +32,7 @@ ;;; Copyright © 2020 Tanguy Le Carrour ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2019 Riku Viitanen +;;; Copyright © 2020 Ryan Prior ;;; ;;; This file is part of GNU Guix. ;;; @@ -5782,7 +5783,7 @@ and as an LV2 plugin.") ;; distros to make necessary changes to integrate the software into the ;; distribution. (name "zrythm") - (version "1.0.0-alpha.3.0.1") + (version "1.0.0-alpha.6.0.1") (source (origin (method url-fetch) @@ -5790,7 +5791,7 @@ and as an LV2 plugin.") version ".tar.xz")) (sha256 (base32 - "06025367x08y4g9grhcn35bk1dsrpgm04c8l8j50i3p49dl3s1n0")))) + "1zfky3yj0k0rmbxighlk9sp4fsgw8rj7viv44yv626kldfvc04ab")))) (build-system meson-build-system) (arguments `(#:glib-or-gtk? #t -- cgit v1.2.3 From 13c9a1e77c0da47c42b3b748c25ab87638f6606b Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 30 Dec 2020 15:40:05 -0500 Subject: gnu: linux-libre: Update to 5.10.4. * gnu/packages/linux.scm (linux-libre-5.10-version): Update to 5.10.4. (linux-libre-5.10-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 3f5d1f1502..9ea2bf203a 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -352,7 +352,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.10-version "5.10.3") +(define-public linux-libre-5.10-version "5.10.4") (define deblob-scripts-5.10 (linux-libre-deblob-scripts linux-libre-5.10-version @@ -360,7 +360,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0hh27ccqimagr3aij7ygwikxw66y63sqwd0xlf49bhpjd090r9a7"))) (define-public linux-libre-5.10-pristine-source (let ((version linux-libre-5.10-version) - (hash (base32 "09cml495fnf52lhlkjxjznw34q5s8arvq7shkb6wjq6fwlrk65gr"))) + (hash (base32 "1v2nbpp21c3fkw23dgrrfznnnlvi0538kj8wrlb2m6g94rn3jklh"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.10))) -- cgit v1.2.3 From 19a5ca839d188c6948e30454b22934c48684c03a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 30 Dec 2020 15:40:29 -0500 Subject: gnu: linux-libre 5.4: Update to 5.4.86. * gnu/packages/linux.scm (linux-libre-5.4-version): Update to 5.4.86. (linux-libre-5.4-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 9ea2bf203a..88d397e3a2 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -368,7 +368,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; -(define-public linux-libre-5.4-version "5.4.85") +(define-public linux-libre-5.4-version "5.4.86") (define deblob-scripts-5.4 (linux-libre-deblob-scripts linux-libre-5.4-version @@ -376,7 +376,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1xghbbnaisjd0k1klbyn1p7r6r4x5a1bpmkm56a3gh2zvw4s7mj8"))) (define-public linux-libre-5.4-pristine-source (let ((version linux-libre-5.4-version) - (hash (base32 "0220k327aa7gg48fqw171mcng8h717c4a1v14r3q36ksirnmiqqx"))) + (hash (base32 "12qf7gza94s4f7smi3dk6i6hqcz0fbc64ghapan57fgpdvybadpb"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.4))) -- cgit v1.2.3 From c6a201bef34deb5153bcab90f7ee3bcc67c5f305 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 30 Dec 2020 15:41:05 -0500 Subject: gnu: linux-libre 4.19: Update to 4.19.164. * gnu/packages/linux.scm (linux-libre-4.19-version): Update to 4.19.164. (linux-libre-4.19-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 88d397e3a2..4da730faf9 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -381,7 +381,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.4))) -(define-public linux-libre-4.19-version "4.19.163") +(define-public linux-libre-4.19-version "4.19.164") (define deblob-scripts-4.19 (linux-libre-deblob-scripts linux-libre-4.19-version @@ -389,7 +389,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1jiaw0as1ippkrjdpd52657w5mz9qczg3y2hlra7m9k0xawwiqlf"))) (define-public linux-libre-4.19-pristine-source (let ((version linux-libre-4.19-version) - (hash (base32 "1z65iwwyx2b01fncygckmhpxirzs52qfqmv3agirn4laxgjw9viy"))) + (hash (base32 "1amafhydq934a04pizc5w4h4y4ny982zn33yrz7q0h2d6sskmyp5"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.19))) -- cgit v1.2.3 From dfcd1a876e8c5ded8a5ad67450deaed3a7be7475 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 16:15:26 -0500 Subject: gnu: Revise comment for Linux-Libre-LTS. * gnu/packages/linux.scm (linux-libre-lts): Modify comment. Signed-off-by: Leo Famulari --- gnu/packages/linux.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 4da730faf9..42107d0bc0 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -903,7 +903,8 @@ It has been modified to remove all non-free binary blobs.") ("CONFIG_DEVPTS_MULTIPLE_INSTANCES" . #t)) %default-extra-linux-options))) -;; Linux-Libre-LTS means the *current* long-term support version of Linux-Libre. +;; Linux-Libre-LTS points to the *newest* released long-term support version of +;; Linux-Libre. ;; Reference: https://jxself.org/linux-libre/ (define-public linux-libre-lts-version linux-libre-5.10-version) -- cgit v1.2.3 From 764fbd0abcbfffc9302554f264e14777cb18815e Mon Sep 17 00:00:00 2001 From: pukkamustard Date: Wed, 30 Dec 2020 10:43:35 +0100 Subject: gnu: Add erofs-utils. * gnu/packages/linux.scm (erofs-utils): New variable. Signed-off-by: Leo Famulari --- gnu/packages/linux.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 42107d0bc0..6b0e9f6c8f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -52,6 +52,7 @@ ;;; Copyright © 2020 Greg Hogan ;;; Copyright © 2020 Zhu Zihao ;;; Copyright © 2020 David Dashyan +;;; Copyright © 2020 pukkamustard ;;; ;;; This file is part of GNU Guix. ;;; @@ -7718,3 +7719,32 @@ helpers to setup and teardown io_uring instances, and also a simplified interface for applications that don't need (or want) to deal with the full kernel side implementation.") (license license:expat))) + +(define-public erofs-utils + (package + (name "erofs-utils") + (version "1.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs-utils.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "07hvijq2hsn3gg1kb8abrfk23n83j57yx8kyv4wqgwhhvd30myjc")))) + (build-system gnu-build-system) + (inputs + `(("lz4" ,lz4) + ("libuuid" ,util-linux "lib"))) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake) + ("libtool" ,libtool) + ("pkg-config" ,pkg-config))) + (home-page "https://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs-utils.git/") + (synopsis "User-space tools for EROFS filesystem") + (description "EROFS (Enhanced Read-Only File System) is a compressed, +read-only filesystem optimized for resource-scarce devices. This package +provides user-space tools for creating EROFS filesystems.") + (license license:gpl2+))) -- cgit v1.2.3 From bffc33d2d6c4b198aefab9187b505c2eec242a21 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:37:09 +0100 Subject: gnu: librsync: Update to 2.3.1. * gnu/packages/rsync.scm (librsync): Update to 2.3.1. Signed-off-by: Leo Famulari --- gnu/packages/rsync.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/rsync.scm b/gnu/packages/rsync.scm index 214095aa61..f90feaf57f 100644 --- a/gnu/packages/rsync.scm +++ b/gnu/packages/rsync.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2017, 2019 Efraim Flashner ;;; Copyright © 2018 Tobias Geerinckx-Rice ;;; Copyright © 2019 Leo Famulari +;;; Copyright © 2020 Vincent Legoll ;;; ;;; This file is part of GNU Guix. ;;; @@ -70,7 +71,7 @@ files in the destination.") (define-public librsync (package (name "librsync") - (version "2.2.1") + (version "2.3.1") (source (origin (method git-fetch) (uri (git-reference @@ -79,7 +80,7 @@ files in the destination.") (file-name (git-file-name name version)) (sha256 (base32 - "08wdlxsa9zg2pyasz1lwg70d5psi4amv81v4yxwffx67ndzb9yp5")))) + "131cd4asmpm4nskidzgiy8xibbnpibvvbq857a0pcky77min5g4z")))) (build-system cmake-build-system) (inputs `(("popt" ,popt))) -- cgit v1.2.3 From 9606041dcb8509a1d62c9c80261178330cf60615 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:40:28 +0100 Subject: gnu: libupnp: Update to 1.14.0. * gnu/packages/upnp.scm (libupnp): Update to 1.14.0. Signed-off-by: Leo Famulari --- gnu/packages/upnp.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index f0c03e12b3..aac2ae370f 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -94,7 +94,7 @@ over IRC, instant messaging, network games, and most server software.") (define-public libupnp (package (name "libupnp") - (version "1.12.1") + (version "1.14.0") (source (origin (method url-fetch) @@ -102,7 +102,7 @@ over IRC, instant messaging, network games, and most server software.") "/release-" version "/libupnp-" version".tar.bz2")) (sha256 (base32 - "02a0dnbk1cla8xlb5l2zp09grv2hsf8n4jbd560mmzj830mn8dpw")))) + "1sswsdqzarrd6h9mld2lncbcrfhd4p16zcafvmxqm34nj513vcpc")))) (native-inputs `(("pkg-config" ,pkg-config))) (build-system gnu-build-system) -- cgit v1.2.3 From 093429cc6ae07e9238b12ce729ed078200cbcf46 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Thu, 31 Dec 2020 09:21:37 +0100 Subject: gnu: monero: Update to 0.17.1.8. * gnu/packages/finance.scm (monero): Update to 0.17.1.8. --- gnu/packages/finance.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index b6921d343f..400e84d9f1 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -630,7 +630,7 @@ other machines/servers. Electroncash does not download the Bitcoin Cash blockch ;; the system's dynamically linked library. (package (name "monero") - (version "0.17.1.7") + (version "0.17.1.8") (source (origin (method git-fetch) @@ -650,7 +650,7 @@ other machines/servers. Electroncash does not download the Bitcoin Cash blockch "external/unbound")) #t)) (sha256 - (base32 "1fdw4i4rw87yz3hz4yc1gdw0gr2mmf9038xaw2l4rrk5y50phjp4")))) + (base32 "10blazbk1602slx3wrmw4jfgkdry55iclrhm5drdficc5v3h735g")))) (build-system cmake-build-system) (native-inputs `(("doxygen" ,doxygen) -- cgit v1.2.3 From 67497e20890348ebbd41612e2582b1745a80fec5 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Thu, 31 Dec 2020 10:04:23 +0100 Subject: gnu: monero-gui: Update to 0.17.1.8. * gnu/packages/finance.scm (monero-gui): Update to 0.17.1.8. --- gnu/packages/finance.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index 400e84d9f1..3a239d0d61 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -740,7 +740,7 @@ the Monero command line client and daemon.") (define-public monero-gui (package (name "monero-gui") - (version "0.17.1.7") + (version "0.17.1.8") (source (origin (method git-fetch) @@ -749,7 +749,7 @@ the Monero command line client and daemon.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1dd2ddkxh9ynxnscysl46hj4dm063h1v13fnyah69am26qzzbby4")))) + (base32 "13cjrfdkr7c2ff8j2rg8hvhlc00af38vcs67wlx2109i2baq4pp3")))) (build-system qt-build-system) (native-inputs `(,@(package-native-inputs monero) -- cgit v1.2.3 From 6418033a650c0a85fb116465d921a2235c5c226c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 13:10:14 +0100 Subject: gnu: rust-libgit2-sys-0.12: Update to 0.12.17+1.1.0. * gnu/packages/crates-io.scm (rust-libgit2-sys-0.12): Update to 0.12.17+1.1.0. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e227d26631..06cf744785 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14569,14 +14569,14 @@ algorithm and related formats (ZLIB, GZIP).") (define-public rust-libgit2-sys-0.12 (package (name "rust-libgit2-sys") - (version "0.12.14+1.1.0") + (version "0.12.17+1.1.0") (source (origin (method url-fetch) (uri (crate-uri "libgit2-sys" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0jgmp69a53lki14p8pigxniwyl755lhqzl0r56ppqps9wrcay9cg")) + (base32 "0hc89v7kp2b3rbc64cxq024shd85m8vqcs14i3gjclblr9jxzszl")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "libgit2") #t)))) -- cgit v1.2.3 From 246adeacbce5ab0d81efea0288088bc51d0946a2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 13:14:01 +0100 Subject: gnu: rust-paste-impl-0.1: Update to 0.1.18. * gnu/packages/crates-io.scm (rust-paste-impl-0.1): Update to 0.1.18. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 06cf744785..02c991430d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -19972,7 +19972,7 @@ and would-block I/O operations.") (define-public rust-paste-impl-0.1 (package (name "rust-paste-impl") - (version "0.1.10") + (version "0.1.18") (source (origin (method url-fetch) @@ -19981,7 +19981,7 @@ and would-block I/O operations.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "12jsm83dnsqnrcabfacnwcxh3h4kykl622vi7glv2wg527hqc956")))) + "1dlqzk05cx74522s4iyhyzzhszig4n401pp6r1qg6zmr02r7snnr")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From c5f9fba25a4da2ca345df0634a43983e5f5589c7 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 13:14:15 +0100 Subject: gnu: rust-paste-0.1: Update to 0.1.18. * gnu/packages/crates-io.scm (rust-paste-0.1): Update to 0.1.18. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 02c991430d..f98c65ae8b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -19945,7 +19945,7 @@ and would-block I/O operations.") (define-public rust-paste-0.1 (package (name "rust-paste") - (version "0.1.10") + (version "0.1.18") (source (origin (method url-fetch) @@ -19954,7 +19954,7 @@ and would-block I/O operations.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0yk4zbi7128dcrklsbwfa63d39x0dv8f7pdbrylvdlcj0s9v2kxb")))) + "10587zrlmzhq66yhd0z36fzglf32m1nlhi9bxxm6dgl0gp3j1jj5")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 5556146ffad4d3d840e8664663aa694b5fddfca2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 13:17:03 +0100 Subject: gnu: rust-git2-0.13: Update to 0.13.15. * gnu/packages/crates-io.scm (rust-git2-0.13): Update to 0.13.15. [arguments]: Add rust-paste to Cargo development inputs. --- gnu/packages/crates-io.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f98c65ae8b..6208089c03 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11043,14 +11043,14 @@ DWARF debugging format.") (define-public rust-git2-0.13 (package (name "rust-git2") - (version "0.13.12") + (version "0.13.15") (source (origin (method url-fetch) (uri (crate-uri "git2" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0912gv7mvqzdlgkzny0z7ph07g2dmkmz8hp6bvyziy6p7011lvya")))) + (base32 "0na3vsa44nn1sr6pzscn93w69wbmdih277mm2p3f6kcavb4ngwj4")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs @@ -11062,7 +11062,8 @@ DWARF debugging format.") ("rust-openssl-sys" ,rust-openssl-sys-0.9) ("rust-url" ,rust-url-2)) #:cargo-development-inputs - (("rust-structopt" ,rust-structopt-0.3) + (("rust-paste" ,rust-paste-0.1) + ("rust-structopt" ,rust-structopt-0.3) ("rust-time" ,rust-time-0.1)))) (native-inputs `(("pkg-config" ,pkg-config) -- cgit v1.2.3 From fb533563f08663e8807f039858cdc385094d2fcb Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 31 Dec 2020 13:18:45 +0100 Subject: gnu: rust-toml-0.5: Update to 0.5.8. * gnu/packages/crates-io.scm (rust-toml-0.5): Update to 0.5.8. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 6208089c03..ab90ec141b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32900,7 +32900,7 @@ Tokio.") (define-public rust-toml-0.5 (package (name "rust-toml") - (version "0.5.7") + (version "0.5.8") (source (origin (method url-fetch) @@ -32908,7 +32908,7 @@ Tokio.") (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "0iannv6pb226h0q9vlqg7hdn36fs146yrahw016n107g1fxlbkvm")))) + "1apcmjrrjw429pjw7mqlmdwwd67g8305vwqy4kw3swr612bl44d3")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 5f6216d55153e62d680e42a544bc0a029d7f3500 Mon Sep 17 00:00:00 2001 From: Zhu Zihao Date: Fri, 18 Dec 2020 10:27:39 +0800 Subject: build-system/cargo: Use argument "--no-track" in "cargo install". * guix/build/cargo-build-system(install): Add argument "--no-track" in "cargo install". Remove stale hack. Signed-off-by: Efraim Flashner --- guix/build/cargo-build-system.scm | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/guix/build/cargo-build-system.scm b/guix/build/cargo-build-system.scm index c7beffc6e4..1d21b33895 100644 --- a/guix/build/cargo-build-system.scm +++ b/guix/build/cargo-build-system.scm @@ -183,13 +183,9 @@ directory = '" port) ;; otherwise cargo will raise an error. (or skip-build? (not (has-executable-target?)) - (invoke "cargo" "install" "--path" "." "--root" out + (invoke "cargo" "install" "--no-track" "--path" "." "--root" out "--features" (string-join features))) - ;; This is a file which we definitely don't need installed. - (when (file-exists? (string-append out "/.crates.toml")) - (delete-file (string-append out "/.crates.toml"))) - #t)) (define %standard-phases -- cgit v1.2.3 From c9156e811c8f4ef90d3e45726535d9e9dc81f912 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 31 Dec 2020 14:39:29 +0200 Subject: gnu: gsasl: Fix cross compiling. Fixes . * gnu/packages/gsasl.scm (gsasl)[native-inputs]: Add libgcrypt. --- gnu/packages/gsasl.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gnu/packages/gsasl.scm b/gnu/packages/gsasl.scm index 98acc3c756..32ffbfa174 100644 --- a/gnu/packages/gsasl.scm +++ b/gnu/packages/gsasl.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2017 Ricardo Wurmus ;;; Copyright © 2017 Eric Bavier ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice +;;; Copyright © 2020 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -96,6 +97,9 @@ the underlying security implementation.") ("libntlm" ,libntlm) ("mit-krb5" ,mit-krb5) ("zlib" ,zlib))) + (native-inputs + `(;; Needed for cross compiling. + ("libgcrypt" ,libgcrypt))) (propagated-inputs ;; Propagate GnuTLS because libgnutls.la reads `-lnettle', and Nettle is a ;; propagated input of GnuTLS. -- cgit v1.2.3 From 75166b29f2b7521c99b036bb0a24ac59bd1d16df Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:49:00 +0100 Subject: gnu: matio: Update to 1.5.19. * gnu/packages/maths.scm (matio): Update to 1.5.19. Signed-off-by: Efraim Flashner --- gnu/packages/maths.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index b54cd6dff1..0ba6b3444e 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -4558,7 +4558,7 @@ structured and unstructured grid problems."))) (define-public matio (package (name "matio") - (version "1.5.6") + (version "1.5.19") (source (origin (method url-fetch) @@ -4566,7 +4566,7 @@ structured and unstructured grid problems."))) "matio-" version ".tar.gz")) (sha256 (base32 - "0y2qymgxank8wdiwc68ap8bxdzrhvyw86i29yh3xgn4z1njfd9ir")))) + "0vr8c1mz1k6mz0sgh6n3scl5c3a71iqmy5fnydrgq504icj4vym4")))) (build-system gnu-build-system) (inputs `(("zlib" ,zlib) -- cgit v1.2.3 From 63e6f8a5829937605ac6f92f030a0d2f6f4a1130 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 13:17:49 +0100 Subject: gnu: vips: Update to 8.10.5. * gnu/packages/image-processing.scm (vips): Update to 8.10.5. Signed-off-by: Efraim Flashner --- gnu/packages/image-processing.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index e313b14ebf..3dbe6f34f1 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -520,7 +520,7 @@ vision algorithms. It can be used to do things like: (define-public vips (package (name "vips") - (version "8.7.4") + (version "8.10.5") (source (origin (method url-fetch) @@ -528,7 +528,7 @@ vision algorithms. It can be used to do things like: "https://github.com/libvips/libvips/releases/download/v" version "/vips-" version ".tar.gz")) (sha256 - (base32 "01gjhcrl6zj7mcj1al717v5jsniahplqhz1xkfh2j78vyfl1hxff")))) + (base32 "1n6gw7cw66rfn1wdb92ydpkv7gfmjiinsg6d6gqxpdja6gsz5vm4")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config) -- cgit v1.2.3 From 5d99167a46def3ac290a3005ff515ae4498e0c2f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 31 Dec 2020 14:58:15 +0200 Subject: gnu: vips: Sort inputs alphabetically. * gnu/packages/image-processing.scm (vips)[native-inputs]: Sort inputs alphabetically. [inputs]: Same. --- gnu/packages/image-processing.scm | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index 3dbe6f34f1..8d31029963 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -531,30 +531,30 @@ vision algorithms. It can be used to do things like: (base32 "1n6gw7cw66rfn1wdb92ydpkv7gfmjiinsg6d6gqxpdja6gsz5vm4")))) (build-system gnu-build-system) (native-inputs - `(("pkg-config" ,pkg-config) - ("gobject-introspection" ,gobject-introspection))) + `(("gobject-introspection" ,gobject-introspection) + ("pkg-config" ,pkg-config))) (inputs - `(("glib" ,glib) + `(("expat" ,expat) + ("fftw" ,fftw) + ("giflib" ,giflib) + ("glib" ,glib) + ("hdf5" ,hdf5) + ("imagemagick" ,imagemagick) + ("lcms" ,lcms) + ("libexif" ,libexif) + ("libgsf" ,libgsf) ("libjpeg" ,libjpeg-turbo) ("libpng" ,libpng) ("librsvg" ,librsvg) ("libtiff" ,libtiff) - ("libexif" ,libexif) - ("giflib" ,giflib) - ("libgsf" ,libgsf) - ("fftw" ,fftw) - ("poppler" ,poppler) - ("pango" ,pango) - ("lcms" ,lcms) - ("matio" ,matio) + ("libxml2" ,libxml2) ("libwebp" ,libwebp) + ("matio" ,matio) ("niftilib" ,niftilib) ("openexr" ,openexr) ("orc" ,orc) - ("imagemagick" ,imagemagick) - ("libxml2" ,libxml2) - ("expat" ,expat) - ("hdf5" ,hdf5))) + ("pango" ,pango) + ("poppler" ,poppler))) (home-page "https://libvips.github.io/libvips/") (synopsis "Multithreaded image processing system with low memory needs") (description -- cgit v1.2.3 From e29432ace743e0e7a46713e023869753c2648567 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:59:45 +0100 Subject: gnu: minixml: Update to 3.2. * gnu/packages/xml.scm (minixml): Update to 3.2. [home-page]: Update. Signed-off-by: Efraim Flashner --- gnu/packages/xml.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm index 9dc37addf4..69e86d9177 100644 --- a/gnu/packages/xml.scm +++ b/gnu/packages/xml.scm @@ -1125,7 +1125,7 @@ Libxml2).") (define-public minixml (package (name "minixml") - (version "2.12") + (version "3.2") (source (origin (method url-fetch) (uri (string-append "https://github.com/michaelrsweet/mxml/" @@ -1133,14 +1133,14 @@ Libxml2).") "/mxml-" version ".tar.gz")) (sha256 (base32 - "0kq3wiycb40dcyswvajrqb1n5ffm5xcnsfxxaml92vhpl6x57yvb")))) + "0x698ayv00vrjg0yfm20lakpgl7m02x1fk2n09wygwk4973gd55q")))) (build-system gnu-build-system) (arguments `(#:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath=" (assoc-ref %outputs "out") "/lib")) #:tests? #f)) ; tests are run during build - (home-page "https://michaelrsweet.github.io/mxml") + (home-page "https://www.msweet.org/mxml/") (synopsis "Small XML parsing library") (description "Mini-XML is a small C library to read and write XML files and strings in -- cgit v1.2.3 From 6af3d85a511dea423aed0d0a7fef25b480b9b306 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Thu, 31 Dec 2020 14:01:35 +0100 Subject: gnu: sbcl-mcclim: Update to 0.9.7-1.04cc542. * gnu/packages/lisp-xyz.scm (sbcl-mcclim): Update to 0.9.7-1.04cc542. --- gnu/packages/lisp-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index a0426e534f..87e130a82e 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -10679,8 +10679,8 @@ and saving 2-dimensional pixel-based images.") (sbcl-package->ecl-package sbcl-opticl)) (define-public sbcl-mcclim - (let ((commit "27b4d7a667c9b3faa74cabcb57706b888314fff7") - (revision "0")) + (let ((commit "04cc542dd4b461b9d56406e40681d1a8f080730f") + (revision "1")) (package (name "sbcl-mcclim") (version (git-version "0.9.7" revision commit)) @@ -10692,7 +10692,7 @@ and saving 2-dimensional pixel-based images.") (commit commit))) (file-name (git-file-name name version)) (sha256 - (base32 "0jijfgkwas6xnpp5wiii6slcx9pgsalngacb8zm29x6pamx2193h")))) + (base32 "1xjly8i62z72hfhlnz5kjd9i8xhrwckc7avyizxvhih67pkjmsx0")))) (build-system asdf-build-system/sbcl) (native-inputs `(("fiveam" ,sbcl-fiveam) -- cgit v1.2.3 From 79eee4f1b1bec3989138eda4f078d151d49a0627 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 14:56:56 +0100 Subject: gnu: drumstick: Update to 2.0.0. * gnu/packages/music.scm (drumstick): Update to 2.0.0. [inputs]: Add qttools. [native-inputs]: Add graphviz. --- gnu/packages/music.scm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 84a55e6305..6aa7c200d2 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -2513,14 +2513,14 @@ browser.") (define-public drumstick (package (name "drumstick") - (version "1.1.3") + (version "2.0.0") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/drumstick/" version "/drumstick-" version ".tar.bz2")) (sha256 (base32 - "1n9wvg79yvkygrkc8xd8pgrd3d7hqmr7gh24dccf0px23lla9b3m")))) + "088j0w3kr9i4lh78y0js0q8adlfzkr89xq2dxc8y3bafsgihax1x")))) (build-system cmake-build-system) (arguments `(#:tests? #f ; no test target @@ -2539,12 +2539,14 @@ browser.") (inputs `(("qtbase" ,qtbase) ("qtsvg" ,qtsvg) + ("qttools" ,qttools) ("alsa-lib" ,alsa-lib))) (native-inputs `(("pkg-config" ,pkg-config) ("libxslt" ,libxslt) ; for xsltproc ("docbook-xsl" ,docbook-xsl) - ("doxygen" ,doxygen))) + ("doxygen" ,doxygen) + ("graphviz" ,graphviz))) ; for dot (home-page "http://drumstick.sourceforge.net/") (synopsis "C++ MIDI library") (description -- cgit v1.2.3 From e3eea177c8741559a956d5430b7a9b2db98eb8a2 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 14:57:19 +0100 Subject: gnu: vmpk: Update to 0.8.0. * gnu/packages/music.scm (vmpk): Update to 0.8.0. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 6aa7c200d2..c2a2668810 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -2561,14 +2561,14 @@ backends, including ALSA, OSS, Network and FluidSynth.") (define-public vmpk (package (name "vmpk") - (version "0.7.2") + (version "0.8.0") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/vmpk/vmpk/" version "/vmpk-" version ".tar.bz2")) (sha256 (base32 - "1i3hnvdgz46n4k5v0q4jhgh7nkh0s390ix4nqr69z0q3026yp0p6")))) + "0wn45c4sbvan7schq93zmsgg5fcf144mbbawxn5kq699vrbc3473")))) (build-system cmake-build-system) (arguments `(#:tests? #f ; no test target -- cgit v1.2.3 From f249af3086ce420d73feb385a4120f15210285fd Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 15:50:48 +0100 Subject: import/elpa: Abort early on failure to fetch meta data. * guix/import/elpa.scm (elpa->guix-package): Raise condition instead of returning #FALSE. * guix/scripts/import/elpa.scm (guix-import-elpa): Handle conditions when importing recursively. --- guix/import/elpa.scm | 10 +++++++++- guix/scripts/import/elpa.scm | 15 ++++++++------- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/guix/import/elpa.scm b/guix/import/elpa.scm index 8922e57840..1d586acab6 100644 --- a/guix/import/elpa.scm +++ b/guix/import/elpa.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2015, 2016, 2017, 2018, 2020 Ludovic Courtès ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2020 Martin Becze +;;; Copyright © 2020 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -29,6 +30,8 @@ #:use-module (srfi srfi-9 gnu) #:use-module (srfi srfi-11) #:use-module (srfi srfi-26) + #:use-module (srfi srfi-34) + #:use-module (srfi srfi-35) #:use-module ((guix download) #:select (download-to-store)) #:use-module (guix import utils) #:use-module (guix http-client) @@ -392,7 +395,12 @@ type ''." (define* (elpa->guix-package name #:key (repo 'gnu) version) "Fetch the package NAME from REPO and produce a Guix package S-expression." (match (fetch-elpa-package name repo) - (#f #f) + (#false + (raise (condition + (&message + (message (format #false + "couldn't find meta-data for ELPA package `~a'." + name)))))) (package ;; ELPA is known to contain only GPLv3+ code. Other repos may contain ;; code under other license but there's no license metadata. diff --git a/guix/scripts/import/elpa.scm b/guix/scripts/import/elpa.scm index 07ac07a3d5..d6b38e5c4b 100644 --- a/guix/scripts/import/elpa.scm +++ b/guix/scripts/import/elpa.scm @@ -96,13 +96,14 @@ Import the latest package named PACKAGE-NAME from an ELPA repository.\n")) (match args ((package-name) (if (assoc-ref opts 'recursive) - (map (match-lambda - ((and ('package ('name name) . rest) pkg) - `(define-public ,(string->symbol name) - ,pkg)) - (_ #f)) - (elpa-recursive-import package-name - (or (assoc-ref opts 'repo) 'gnu))) + (with-error-handling + (map (match-lambda + ((and ('package ('name name) . rest) pkg) + `(define-public ,(string->symbol name) + ,pkg)) + (_ #f)) + (elpa-recursive-import package-name + (or (assoc-ref opts 'repo) 'gnu)))) (let ((sexp (elpa->guix-package package-name #:repo (assoc-ref opts 'repo)))) (unless sexp -- cgit v1.2.3 From 51c06d10cfa9559ef647d7542702256e00cea47a Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 15:52:13 +0100 Subject: import/utils: recursive-import: Fix typo. * guix/import/utils.scm (recursive-import): Fix typo. --- guix/import/utils.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guix/import/utils.scm b/guix/import/utils.scm index cdbcf6bfa5..2f5ccf7cea 100644 --- a/guix/import/utils.scm +++ b/guix/import/utils.scm @@ -453,10 +453,10 @@ obtain the Guix package name corresponding to the upstream name." (let* ((package dependencies (repo->guix-package name #:version version #:repo repo)) - (normalizied-deps (map (match-lambda + (normalized-deps (map (match-lambda ((name version) (list name version)) (name (list name #f))) dependencies))) - (make-node name version package normalizied-deps))) + (make-node name version package normalized-deps))) (map node-package (topological-sort (list (lookup-node package-name version)) -- cgit v1.2.3 From 3da8b44bfc2377c81e9da5daca789e1c09b0784f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 15:59:05 +0100 Subject: gnu: Add emacs-window-purpose. * gnu/packages/emacs-xyz.scm (emacs-window-purpose): New variable. --- gnu/packages/emacs-xyz.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 0fb174f001..0a32e2147c 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -7703,6 +7703,52 @@ with the arrow keys. It prefers to move the right or bottom border when possible, and falls back to moving the left or top border otherwise.") (license license:gpl3+)))) +(define-public emacs-window-purpose + (let ((commit "f6421966761ad911fe8861aba2b110c5dd60d1ea") + (revision "1")) + (package + (name "emacs-window-purpose") + (version (git-version "1.7" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/bmag/emacs-purpose.git") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1p0y5gnrw7q65py2wjdf1hrdpiw5c2zbgvfbfmb13257jq5mga38")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-let-alist" ,emacs-let-alist) + ("emacs-imenu-list" ,emacs-imenu-list))) + (arguments + '(#:include + '("^[^/]+.el$" + "^[^/]+.el.in$" + "^dir$" + "^[^/]+.info$" + "^[^/]+.texi$" + "^[^/]+.texinfo$" + "^doc/dir$" + "^doc/[^/]+.info$" + "^doc/[^/]+.texi$" + "^doc/[^/]+.texinfo$" + "^layouts$") + #:exclude + '("^.dir-locals.el$" + "^test.el$" + "^tests.el$" + "^[^/]+-test.el$" + "^[^/]+-tests.el$"))) + (home-page "https://github.com/bmag/emacs-purpose") + (synopsis "Purpose-based window management for Emacs") + (description "Purpose is a package that introduces the concept of a +\"purpose\" for windows and buffers, and then helps you maintain a robust +window layout easily.") + (license license:gpl3+)))) + (define-public emacs-iedit ;; Last release version was in 2016. (let ((commit "e2c100cdd67b7d82835d281ac2cd1bf4f374bc8f") -- cgit v1.2.3 From 0faa58f62c30be3a45d5d809757d29dc6d7bc6c3 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Thu, 31 Dec 2020 13:41:50 +0100 Subject: gnu: emacs-logview: Update to 0.14. * gnu/packages/emacs-xyz.scm (emacs-logview): Update to 0.14. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 0a32e2147c..5b077aa350 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -16953,7 +16953,7 @@ and doesn't require memorisation of commands. (define-public emacs-logview (package (name "emacs-logview") - (version "0.9") + (version "0.14") (source (origin (method git-fetch) @@ -16962,7 +16962,7 @@ and doesn't require memorisation of commands. (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1qhzs75pxnaksbhczmpdcy2zmrqavlzkzss7ik5nv2wf9vs0sn02")))) + (base32 "1cchmr25z5zj7rgb2fyxkaq8kpw7i5yg1pvn42dvm09c2wrfbj46")))) (propagated-inputs `(("emacs-datetime" ,emacs-datetime) ("emacs-extmap" ,emacs-extmap))) -- cgit v1.2.3 From 675322890168c7e9282202d6829d32a10ad7e48d Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Thu, 31 Dec 2020 14:13:53 +0100 Subject: gnu: emacs-vterm: Update to 0-4.a670b78. * gnu/packages/emacs-xyz.scm (emacs-vterm): Update to 0-4.a670b78. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 5b077aa350..2ea7bc5811 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -20755,8 +20755,8 @@ stored playlists.") (define-public emacs-vterm (let ((version "0") - (revision "3") - (commit "14e4afdfc160b2e625c3e483d169786ac00cb4fe")) + (revision "4") + (commit "a670b786539d3c8865d8f68fe0c67a2d4afbf1aa")) (package (name "emacs-vterm") (version (git-version version revision commit)) @@ -20768,7 +20768,7 @@ stored playlists.") (file-name (git-file-name name version)) (sha256 (base32 - "0wl613rxw493i3397n34qwqnd5fkyqrnn1fx3y2040xhvjl9rx70")))) + "0s244crjkbzl2jhp9m4sm1xdhbpxwph0m3jg18livirgajvdz6hn")))) (build-system emacs-build-system) (arguments `(#:modules ((guix build emacs-build-system) -- cgit v1.2.3 From 592d6952f68f0feb45965027e533a7b1a2909004 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Thu, 31 Dec 2020 14:16:31 +0100 Subject: gnu: libproxy: Update to 0.4.17. * gnu/packages/networking.scm (libproxy): Update to 0.4.17. Signed-off-by: Leo Famulari --- gnu/packages/networking.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm index 30b17da069..8c9db0c6b4 100644 --- a/gnu/packages/networking.scm +++ b/gnu/packages/networking.scm @@ -2111,7 +2111,7 @@ sockets in Perl.") (define-public libproxy (package (name "libproxy") - (version "0.4.15") + (version "0.4.17") (source (origin (method url-fetch) (uri (string-append "https://github.com/libproxy/libproxy/" @@ -2119,7 +2119,7 @@ sockets in Perl.") version ".tar.xz")) (sha256 (base32 - "0kvdrazlzwia876w988cmlypp253gwy6idlh8mjk958c29jb8kb5")))) + "01cbgz6lc3v59sldqk96l1281kp2qxnsa2qwlf2ikvjlyr1gi2dw")))) (build-system cmake-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From 94803ec345a1f83ce6fdc446452cb887a7a302a7 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Wed, 23 Dec 2020 10:43:55 +0000 Subject: gnu: bitcoin-unlimited: Fix time specific test failure. * gnu/packages/finance.scm (bitcoin-unlimited)[arguments]: Patch test to fix time specific failure. --- gnu/packages/finance.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index 3a239d0d61..326df299a2 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -1474,6 +1474,11 @@ entity management.") (modify-phases %standard-phases (add-after 'unpack 'fix-tests (lambda _ + ;; Fix data specific test failure + ;; https://reviews.bitcoinabc.org/rABC67bbd3d0aaee2952ff1cb5da51d1fd0b50c2b63a + (substitute* "src/test/rpc_tests.cpp" + (("1607731200") "9907731200")) + ;; Disable utilprocess_tests because it never ends. ;; It looks like it tries to start /bin/sleep and waits until it ;; is in the list of running processes, but /bin/sleep doesn't -- cgit v1.2.3 From 906fb641841fe560abdd23d8b146fc6b6bd569f6 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 22:35:17 +0100 Subject: gnu: guile-picture-language: Update to 0.0.1-2.bf4600b. * gnu/packages/guile-xyz.scm (guile-picture-language): Update to 0.0.1-2.bf4600b. --- gnu/packages/guile-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 437d5b77bb..35be78c488 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2501,8 +2501,8 @@ format is also supported.") (deprecated-package "guile3.0-mcron" mcron)) (define-public guile-picture-language - (let ((commit "91d10c96708d732145006dd2802acc4de08b632e") - (revision "1")) + (let ((commit "bf4600bd68af9ab3163253ccb6429fb681753cbc") + (revision "2")) (package (name "guile-picture-language") (version (git-version "0.0.1" revision commit)) @@ -2514,7 +2514,7 @@ format is also supported.") (file-name (git-file-name name version)) (sha256 (base32 - "1ydvw9dvssdvlvhh1dr8inyzy2x6m41qgp8hsivca1xysr4gc23a")))) + "0q05m3b6krc1fsnnbdhvm11v33qdcc3j16m1cs2j09y42jpql5hv")))) (build-system gnu-build-system) (inputs `(("guile" ,guile-3.0))) -- cgit v1.2.3 From 777ecc1eeb082cf6c8a8e8489279af9d0e2195e2 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 31 Dec 2020 22:35:36 +0100 Subject: gnu: guile-studio: Update to 0.0.4-1.84d4e8d. * gnu/packages/guile-xyz.scm (guile-studio): Update to 0.0.4-1.84d4e8d. [inputs]: Remove emacs-smart-mode-line; add emacs-f, emacs-memoize, emacs-all-the-icons, emacs-doom-modeline, emacs-modus-themes, and emacs-ivy. --- gnu/packages/guile-xyz.scm | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 35be78c488..14a3847602 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2542,11 +2542,11 @@ The picture values can directly be displayed in Geiser.") guile-picture-language)) (define-public guile-studio - (let ((commit "5c05b03e8a5c450f7358ceec7ea602f29c49d54e") + (let ((commit "84d4e8d42593d4a6a04be55d07f0f7efb9d801e7") (revision "1")) (package (name "guile-studio") - (version (git-version "0.0.3" revision commit)) + (version (git-version "0.0.4" revision commit)) (source (origin (method git-fetch) (uri (git-reference @@ -2555,7 +2555,7 @@ The picture values can directly be displayed in Geiser.") (file-name (git-file-name name version)) (sha256 (base32 - "11wyf6x7mhyhimv0cd57pl39zgav9hc9ljqi3g2g35b264hylpnx")))) + "1ws1b9m1n133wx4m9hgmq9kqx1acm1yyq0aniirqphd4l6bzy4qs")))) (build-system gnu-build-system) (arguments `(#:modules @@ -2589,11 +2589,16 @@ The picture values can directly be displayed in Geiser.") `(("guile" ,guile-3.0) ("guile-picture-language" ,guile-picture-language) ("emacs" ,emacs) + ("emacs-f" ,emacs-f) ; needed by doom-modeline + ("emacs-memoize" ,emacs-memoize) ; needed by all-the-icons + ("emacs-all-the-icons" ,emacs-all-the-icons) ; needed by doom-modeline + ("emacs-doom-modeline" ,emacs-doom-modeline) + ("emacs-modus-themes" ,emacs-modus-themes) ("emacs-geiser" ,emacs-geiser) ("emacs-company" ,emacs-company) + ("emacs-ivy" ,emacs-ivy) ("emacs-flycheck" ,emacs-flycheck) ("emacs-flycheck-guile" ,emacs-flycheck-guile) - ("emacs-smart-mode-line" ,emacs-smart-mode-line) ("emacs-paren-face" ,emacs-paren-face) ("adwaita-icon-theme" ,adwaita-icon-theme))) (native-inputs -- cgit v1.2.3 From f59bfc11175c838fe949f1a699d98a1df82dc337 Mon Sep 17 00:00:00 2001 From: Z572 <873216071@qq.com> Date: Fri, 25 Dec 2020 15:23:53 +0800 Subject: gnu: Add yakuake. * gnu/packages/kde-systemtools.scm (yakuake): New variable. Signed-off-by: Christopher Baines --- gnu/packages/kde-systemtools.scm | 49 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/gnu/packages/kde-systemtools.scm b/gnu/packages/kde-systemtools.scm index 0fbf6e3373..f5d97dae27 100644 --- a/gnu/packages/kde-systemtools.scm +++ b/gnu/packages/kde-systemtools.scm @@ -318,3 +318,52 @@ who want to quickly see problems occurring on their server. This package is part of the KDE administration module.") (license license:gpl2+))) + +(define-public yakuake + (package + (name "yakuake") + (version "20.12.0") + (source (origin + (method url-fetch) + (uri (string-append "mirror://kde/stable/release-service/" version + "/src/yakuake-" version ".tar.xz")) + (sha256 + (base32 + "175vvkpkpbd7nm0lqjyiw27xmfdfcs9syvfngnjlndmlzwagk8d1")))) + (build-system qt-build-system) + (native-inputs + `(("extra-cmake-modules" ,extra-cmake-modules))) + (inputs + `(("breeze-icons" ,breeze-icons) + ("karchive" ,karchive) + ("kconfig" ,kconfig) + ("kcoreaddons" ,kcoreaddons) + ("kcrash" ,kcrash) + ("kdbusaddons" ,kdbusaddons) + ("kglobalaccel" ,kglobalaccel) + ("ki18n" ,ki18n) + ("kiconthemes" ,kiconthemes) + ("kio" ,kio) + ("knewstuff" ,knewstuff) + ("knotifications" ,knotifications) + ("knotifyconfig" ,knotifyconfig) + ("konsole" ,konsole) + ("kparts" ,kparts) + ("kwayland" ,kwayland) + ("kwidgetsaddons" ,kwidgetsaddons) + ("kwindowsystem" ,kwindowsystem) + ("qtbase" ,qtbase) + ("qtsvg" ,qtsvg) + ("qtx11extras" ,qtx11extras))) + (home-page "https://www.kde.org/applications/system/yakuake/") + (synopsis "Quad-style terminal emulator for KDE") + (description "Yakuake is a drop-down terminal emulator based on KDE Konsole +technology. Features include: +@itemize +@item Smoothly rolls down from the top of your screen +@item Tabbed interface +@item Configurable dimensions and animation speed +@item Skinnable +@item Sophisticated D-Bus interface +@end itemize") + (license license:gpl2+))) -- cgit v1.2.3 From fbbee36da04fd494a1e0be3966cf9b3c4f749b9a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Thu, 31 Dec 2020 14:13:34 -0500 Subject: gnu: msmtp: Update to 1.8.14. * gnu/packages/mail.scm (msmtp): Update to 1.8.14. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 9bbf567aef..734b2cd707 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1591,14 +1591,14 @@ addons which can add many functionalities to the base client.") (define-public msmtp (package (name "msmtp") - (version "1.8.13") + (version "1.8.14") (source (origin (method url-fetch) (uri (string-append "https://marlam.de/msmtp/releases/" "/msmtp-" version ".tar.xz")) (sha256 - (base32 "1fcv99nis7c6yc63n04cncjysv9jndrp469gcfxh54aiinmlbadd")))) + (base32 "1d3knxpwpglg20z4zcsi82mqv9285ah1b1b16k1fk1hlf5fhcvym")))) (build-system gnu-build-system) (inputs `(("libsecret" ,libsecret) -- cgit v1.2.3 From fdf7095e856c3c13a54baee5d942d14e96f7fb4d Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 29 Dec 2020 13:01:30 +0100 Subject: gnu: java-xstream: Update to 1.4.15. * gnu/packages/xml.scm (java-xstream): Update to 1.4.15. Signed-off-by: Julien Lepiller --- gnu/packages/xml.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm index 69e86d9177..163fff60c0 100644 --- a/gnu/packages/xml.scm +++ b/gnu/packages/xml.scm @@ -2132,7 +2132,7 @@ outputting XML data from Java code.") (define-public java-xstream (package (name "java-xstream") - (version "1.4.10") + (version "1.4.15") (source (origin (method git-fetch) @@ -2144,7 +2144,7 @@ outputting XML data from Java code.") version))))) (file-name (git-file-name name version)) (sha256 - (base32 "12m2bw8bapdc1w0pni9wl5hh2y8jfdgcvxd464jl9917dsp3ai2n")))) + (base32 "1178qryrjwjp44439pi5dxzd32896r5zs429z1qhlc09951r7mi9")))) (build-system ant-build-system) (arguments `(#:jar-name "xstream.jar" -- cgit v1.2.3 From 153151a865cfae5e7f8c8d98be78b238a6cc7a33 Mon Sep 17 00:00:00 2001 From: Oleg Pykhalov Date: Fri, 1 Jan 2021 12:04:24 +0300 Subject: Revert "gnu: tigervnc-client: Update to 1.11.0." This reverts commit 776c700aafb380ffc72f10cc463c6dfeb35dd7c1 with missing /gnu/store/...-tigervnc-server-1.11.0/bin/vncserver binary. --- gnu/packages/vnc.scm | 86 +++++++++++++++++++++++++--------------------------- 1 file changed, 42 insertions(+), 44 deletions(-) diff --git a/gnu/packages/vnc.scm b/gnu/packages/vnc.scm index b8979b2921..ab89bad7aa 100644 --- a/gnu/packages/vnc.scm +++ b/gnu/packages/vnc.scm @@ -1,9 +1,8 @@ -;; GNU Guix --- Functional package management for GNU +;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Todor Kondić ;;; Copyright © 2020 Oleg Pykhalov ;;; Copyright © 2020 Hartmut Goebel ;;; Copyright © 2020 Marius Bakke -;;; Copyright © 2020 Vincent Legoll ;;; ;;; This file is part of GNU Guix. ;;; @@ -42,56 +41,55 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages sdl) #:use-module (gnu packages tls) - #:use-module (gnu packages xdisorg) #:use-module (gnu packages xorg)) (define-public tigervnc-client - (package - (name "tigervnc-client") - (version "1.11.0") - (source (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/TigerVNC/tigervnc") - (commit (string-append "v" version)))) - (sha256 - (base32 - "1bg79ahr4mzy48ak0caxy3ckdsxmhpchypggaz6lxjjk92hgsz91")) - (file-name (git-file-name name version)))) - (build-system cmake-build-system) - (arguments - '(#:tests? #f ; Tests that do exists are not automated. - #:phases (modify-phases %standard-phases - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (with-directory-excursion "vncviewer" - (invoke "make" "install"))))))) - (native-inputs - `(("autoconf" ,autoconf) - ("gettext-minimal" ,gettext-minimal) - ("automake" ,automake))) - (inputs - `(("zlib" ,zlib) - ("gnutls" ,gnutls) - ("libjpeg-turbo" ,libjpeg-turbo) - ("fltk" ,fltk) - ("linux-pam" ,linux-pam) - ("libx11" ,libx11) - ("libxext" ,libxext) - ("libxtst" ,libxtst) - ("libxrandr" ,libxrandr) - ("libxdamage" ,libxdamage) - ("pixman" ,pixman))) - (home-page "https://tigervnc.org/") - (synopsis "High-performance, platform-neutral + (let ((commit "920d9c4d6562ecabf79497bc901d50522d4bc661")) + (package + (name "tigervnc-client") + (version (git-version "1.10.1" "1" commit)) + (source (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/TigerVNC/tigervnc") + (commit commit))) + (sha256 + (base32 + "1lp6mxl5dqlkrzx0q145jzgpbwvhsni3fj6x9ngf8v5s63x82q1p")) + (file-name (git-file-name name version)))) + (build-system cmake-build-system) + (arguments + '(#:tests? #f ; Tests that do exists are not automated. + #:phases (modify-phases %standard-phases + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion "vncviewer" + (invoke "make" "install"))))))) + (native-inputs + `(("autoconf" ,autoconf) + ("gettext-minimal" ,gettext-minimal) + ("automake" ,automake))) + (inputs + `(("zlib" ,zlib) + ("gnutls" ,gnutls) + ("libjpeg-turbo" ,libjpeg-turbo) + ("fltk" ,fltk) + ("linux-pam" ,linux-pam) + ("libx11" ,libx11) + ("libxext" ,libxext) + ("libxtst" ,libxtst) + ("libxrandr" ,libxrandr) + ("libxdamage" ,libxdamage))) + (home-page "https://tigervnc.org/") + (synopsis "High-performance, platform-neutral implementation of VNC (client)") - (description "TigerVNC is a client/server implementation of VNC (Virtual + (description "TigerVNC is a client/server implementation of VNC (Virtual Network Computing). It provides enough performance to run even 3D and video applications. It also provides extensions for advanced authentication methods and TLS encryption. This package installs only the VNC client, the application which is needed to connect to VNC servers.") - (license license:gpl2))) + (license license:gpl2)))) ;; A VNC server is, in fact, an X server so it seems like a good idea ;; to build on the work already done for xorg-server package. This is -- cgit v1.2.3 From 0d85401db5b7132a86a71405fbab8c5cac3bdead Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 29 Dec 2020 11:35:57 +0100 Subject: gnu: tigervnc-client: Update to 1.11.0. This commit follows 153151a865cfae5e7f8c8d98be78b238a6cc7a33, which downgraded tigervnc-client, because vncserver location was changed without notifying users. The new location is /gnu/store/...-tigervnc-server-1.11.0/libexec/vncserver * gnu/packages/vnc.scm (tigervnc-client): Update to 1.11.0. [inputs]: Add pixman. --- gnu/packages/vnc.scm | 86 +++++++++++++++++++++++++++------------------------- 1 file changed, 44 insertions(+), 42 deletions(-) diff --git a/gnu/packages/vnc.scm b/gnu/packages/vnc.scm index ab89bad7aa..b8979b2921 100644 --- a/gnu/packages/vnc.scm +++ b/gnu/packages/vnc.scm @@ -1,8 +1,9 @@ -;;; GNU Guix --- Functional package management for GNU +;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Todor Kondić ;;; Copyright © 2020 Oleg Pykhalov ;;; Copyright © 2020 Hartmut Goebel ;;; Copyright © 2020 Marius Bakke +;;; Copyright © 2020 Vincent Legoll ;;; ;;; This file is part of GNU Guix. ;;; @@ -41,55 +42,56 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages sdl) #:use-module (gnu packages tls) + #:use-module (gnu packages xdisorg) #:use-module (gnu packages xorg)) (define-public tigervnc-client - (let ((commit "920d9c4d6562ecabf79497bc901d50522d4bc661")) - (package - (name "tigervnc-client") - (version (git-version "1.10.1" "1" commit)) - (source (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/TigerVNC/tigervnc") - (commit commit))) - (sha256 - (base32 - "1lp6mxl5dqlkrzx0q145jzgpbwvhsni3fj6x9ngf8v5s63x82q1p")) - (file-name (git-file-name name version)))) - (build-system cmake-build-system) - (arguments - '(#:tests? #f ; Tests that do exists are not automated. - #:phases (modify-phases %standard-phases - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (with-directory-excursion "vncviewer" - (invoke "make" "install"))))))) - (native-inputs - `(("autoconf" ,autoconf) - ("gettext-minimal" ,gettext-minimal) - ("automake" ,automake))) - (inputs - `(("zlib" ,zlib) - ("gnutls" ,gnutls) - ("libjpeg-turbo" ,libjpeg-turbo) - ("fltk" ,fltk) - ("linux-pam" ,linux-pam) - ("libx11" ,libx11) - ("libxext" ,libxext) - ("libxtst" ,libxtst) - ("libxrandr" ,libxrandr) - ("libxdamage" ,libxdamage))) - (home-page "https://tigervnc.org/") - (synopsis "High-performance, platform-neutral + (package + (name "tigervnc-client") + (version "1.11.0") + (source (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/TigerVNC/tigervnc") + (commit (string-append "v" version)))) + (sha256 + (base32 + "1bg79ahr4mzy48ak0caxy3ckdsxmhpchypggaz6lxjjk92hgsz91")) + (file-name (git-file-name name version)))) + (build-system cmake-build-system) + (arguments + '(#:tests? #f ; Tests that do exists are not automated. + #:phases (modify-phases %standard-phases + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion "vncviewer" + (invoke "make" "install"))))))) + (native-inputs + `(("autoconf" ,autoconf) + ("gettext-minimal" ,gettext-minimal) + ("automake" ,automake))) + (inputs + `(("zlib" ,zlib) + ("gnutls" ,gnutls) + ("libjpeg-turbo" ,libjpeg-turbo) + ("fltk" ,fltk) + ("linux-pam" ,linux-pam) + ("libx11" ,libx11) + ("libxext" ,libxext) + ("libxtst" ,libxtst) + ("libxrandr" ,libxrandr) + ("libxdamage" ,libxdamage) + ("pixman" ,pixman))) + (home-page "https://tigervnc.org/") + (synopsis "High-performance, platform-neutral implementation of VNC (client)") - (description "TigerVNC is a client/server implementation of VNC (Virtual + (description "TigerVNC is a client/server implementation of VNC (Virtual Network Computing). It provides enough performance to run even 3D and video applications. It also provides extensions for advanced authentication methods and TLS encryption. This package installs only the VNC client, the application which is needed to connect to VNC servers.") - (license license:gpl2)))) + (license license:gpl2))) ;; A VNC server is, in fact, an X server so it seems like a good idea ;; to build on the work already done for xorg-server package. This is -- cgit v1.2.3 From 947aed127a48ef41bab3bdbb4252eb2a56dafc10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= Date: Fri, 1 Jan 2021 20:51:09 +0800 Subject: gnu: pipewire: Update to 0.3.18. * gnu/packages/linux.scm (pipewire-0.3): Update to 0.3.18. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 6b0e9f6c8f..a8bb9db172 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -7300,7 +7300,7 @@ of Linux application development.") (package (inherit pipewire) (name "pipewire") - (version "0.3.13") + (version "0.3.18") (source (origin (method git-fetch) (uri (git-reference @@ -7309,7 +7309,7 @@ of Linux application development.") (file-name (git-file-name name version)) (sha256 (base32 - "19j5kmb7iaivkq2agfzncfm2qms41ckqi0ddxvhpc91ihwprdc5w")))) + "1yghhgs18yqrnd0b2r75l5n8yng962r1wszbsi01v6i9zib3jc9g")))) (arguments '(#:configure-flags (list (string-append "-Dudevrulesdir=" (assoc-ref %outputs "out") -- cgit v1.2.3 From 50812aaeb6c8c736a73547b781b8e47b8b345ed1 Mon Sep 17 00:00:00 2001 From: Mathieu Othacehe Date: Fri, 1 Jan 2021 17:28:23 +0100 Subject: gnu: guile-squee: Update to 0-2.c1497a2. * gnu/packages/guile-xyz.scm (guile-squee): Update to 0-2.c1497a2. --- gnu/packages/guile-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 14a3847602..fc3ab2ce61 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -744,8 +744,8 @@ It has a nice, simple s-expression based syntax.") (inputs `(("guile" ,guile-2.2))))) (define-public guile-squee - (let ((commit "7dcd22b54fd56c9e629489191bb27ac80ecea9db") - (revision "1")) + (let ((commit "c1497a216e881cfde39d6aa7c73d0bf6b497c89b") + (revision "2")) (package (name "guile-squee") (version (string-append "0-" revision "." (string-take commit 7))) @@ -757,7 +757,7 @@ It has a nice, simple s-expression based syntax.") (file-name (git-file-name name version)) (sha256 (base32 - "1568sk6ada7x9qpfhax0qq1bq93qll1q7nyjrb7h3c1c3lc9sc15")))) + "1alskrplnyl1n5wb39drn72cwplp47a8cpdd1n9cdnw3jhk5p12p")))) (build-system guile-build-system) (arguments '(#:phases -- cgit v1.2.3 From 49ef49a824f590a959036973e4d784c409c383c7 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Fri, 1 Jan 2021 19:39:56 +0100 Subject: gnu: emacs-emms: Update to 6.3. * gnu/packages/emacs-xyz.scm (emacs-emms): (emacs-emms-print-metadata): Update to 6.3. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 2ea7bc5811..52661e3631 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -1631,14 +1631,14 @@ incrementally confined in Isearch manner.") (define emacs-emms-print-metadata (package (name "emacs-emms-print-metadata") - (version "6.2") + (version "6.3") (source (origin (method url-fetch) (uri (string-append "https://elpa.gnu.org/packages/" "emms-" version ".tar")) (sha256 - (base32 "0d95sjrh9vpl41vz26y8clgji987z15lj4ky2kr9yrl0zpa8yv35")))) + (base32 "12cfq503li0gcqmm5bmqz8yjvfdif5xvz0l9vx3g5jl6ljygwgmf")))) (build-system gnu-build-system) (arguments `(#:make-flags '("emms-print-metadata") -- cgit v1.2.3 From 66e6a3dc431950c2d62847afdf1403e6a3f35b95 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 1 Jan 2021 22:01:49 +0100 Subject: gnu: emacs-dired-sidebar: Update to 0.1.0-2.da77919. * gnu/packages/emacs-xyz.scm (emacs-dired-sidebar): Update to 0.1.0-2.da77919. --- gnu/packages/emacs-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 52661e3631..c5430fdc23 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -12902,8 +12902,8 @@ additions: (license license:gpl3+)))) (define-public emacs-dired-sidebar - (let ((commit "21ccb6723bea69f2e2ca25998268d8a039f904cc") - (revision "1")) + (let ((commit "da77919081d9a4e73c2df63542353319381e4f89") + (revision "2")) (package (name "emacs-dired-sidebar") (home-page "https://github.com/jojojames/dired-sidebar") @@ -12914,7 +12914,7 @@ additions: (file-name (git-file-name name version)) (sha256 (base32 - "0mck4qk6srbbf8xnn2sg11j822z4ybxvgavvy402d5sli515i8ca")))) + "05h56wdl2xvc8davnx83ypg20fl7wlks97cafa4r2yf141xjc05h")))) (build-system emacs-build-system) (propagated-inputs `(("emacs-dired-subtree" ,emacs-dired-hacks))) -- cgit v1.2.3 From 6908552b32208907b10947aa30794b859af01a3c Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 1 Jan 2021 22:02:26 +0100 Subject: gnu: guile-studio: Update to 0.0.4-2.e9f2b46. * gnu/packages/guile-xyz.scm (guile-studio): Update to 0.0.4-2.e9f2b46. [inputs]: Add emacs-dired-sidebar. --- gnu/packages/guile-xyz.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index fc3ab2ce61..0ae870aaf5 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2542,8 +2542,8 @@ The picture values can directly be displayed in Geiser.") guile-picture-language)) (define-public guile-studio - (let ((commit "84d4e8d42593d4a6a04be55d07f0f7efb9d801e7") - (revision "1")) + (let ((commit "e9f2b469cc452b384af0243f3eba2f07871090ad") + (revision "2")) (package (name "guile-studio") (version (git-version "0.0.4" revision commit)) @@ -2555,7 +2555,7 @@ The picture values can directly be displayed in Geiser.") (file-name (git-file-name name version)) (sha256 (base32 - "1ws1b9m1n133wx4m9hgmq9kqx1acm1yyq0aniirqphd4l6bzy4qs")))) + "16hwin8zdfyp25iczz3gr5w7hav6av6r8gw64nplgxgxkyaw53a6")))) (build-system gnu-build-system) (arguments `(#:modules @@ -2592,6 +2592,7 @@ The picture values can directly be displayed in Geiser.") ("emacs-f" ,emacs-f) ; needed by doom-modeline ("emacs-memoize" ,emacs-memoize) ; needed by all-the-icons ("emacs-all-the-icons" ,emacs-all-the-icons) ; needed by doom-modeline + ("emacs-dired-sidebar" ,emacs-dired-sidebar) ("emacs-doom-modeline" ,emacs-doom-modeline) ("emacs-modus-themes" ,emacs-modus-themes) ("emacs-geiser" ,emacs-geiser) -- cgit v1.2.3 From 05c37c53c7308732f4f43d894195a0c296db4439 Mon Sep 17 00:00:00 2001 From: Tanguy Le Carrour Date: Fri, 1 Jan 2021 18:28:15 +0100 Subject: gnu: polybar: Update to 3.5.3. * gnu/packages/wm.scm (polybar): Update to 3.5.3. [source]: Update URI. Signed-off-by: Leo Famulari --- gnu/packages/wm.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index cbcebd7129..fbbb975a58 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -1301,14 +1301,14 @@ its size (define-public polybar (package (name "polybar") - (version "3.4.3") + (version "3.5.3") (source (origin (method url-fetch) (uri (string-append "https://github.com/polybar/polybar/releases/" - "download/" version "/polybar-" version ".tar")) + "download/" version "/polybar-" version ".tar.gz")) (sha256 - (base32 "0bw22qvbcdvyd0qv3ax48r34rnclbbb6dyb8h8zljq1r3lf15vfl")))) + (base32 "1016g4b981c4hl2pr0m09b4wy0ln1zf3mfp09wrxs73zgfdbngyj")))) (build-system cmake-build-system) (arguments ;; Test is disabled because it requires downloading googletest from the -- cgit v1.2.3 From ce3b439ae7c6dcc1f0cc334fa1c6a783854ec761 Mon Sep 17 00:00:00 2001 From: Greg Hogan Date: Thu, 31 Dec 2020 18:18:11 +0000 Subject: gnu: git: Update to 2.30.0. * gnu/packages/version-control.scm (git): Update to 2.30.0. (native-inputs)[git-manpages]: Update hash. Signed-off-by: Leo Famulari --- gnu/packages/version-control.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index d20cf7e655..b57b0320b0 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -32,6 +32,7 @@ ;;; Copyright © 2020 Vinicius Monego ;;; Copyright © 2020 Tanguy Le Carrour ;;; Copyright © 2020 Michael Rohleder +;;; Copyright © 2021 Greg Hogan ;;; ;;; This file is part of GNU Guix. ;;; @@ -163,14 +164,14 @@ as well as the classic centralized workflow.") (define-public git (package (name "git") - (version "2.29.2") + (version "2.30.0") (source (origin (method url-fetch) (uri (string-append "mirror://kernel.org/software/scm/git/git-" version ".tar.xz")) (sha256 (base32 - "1h87yv117ypnc0yi86941089c14n91gixk8b6shj2y35prp47z7j")))) + "06ad6dylgla34k9am7d5z8y3rryc8ln3ibq5z0d74rcm20hm0wsm")))) (build-system gnu-build-system) (native-inputs `(("native-perl" ,perl) @@ -187,7 +188,7 @@ as well as the classic centralized workflow.") version ".tar.xz")) (sha256 (base32 - "14npkg9rnp2yclsx5p622qpm6byzfy5k5wb209vkmm5r60m4mm72")))) + "0xngjg60rwzrb9x32d1qbdd8szkzwcyha5qni7ilkldxsl2q8avv")))) ;; For subtree documentation. ("asciidoc" ,asciidoc-py3) ("docbook-xsl" ,docbook-xsl) -- cgit v1.2.3 From a8384752c38acfe8c1e13ea23ca54f95097dfcbc Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 1 Jan 2021 21:08:43 -0500 Subject: gnu: bootterm: Update to 0.2. * gnu/packages/terminals.scm (bootterm): Update to 0.2. --- gnu/packages/terminals.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 881a75d09d..b313c806cb 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -1432,7 +1432,7 @@ terminal. Note that you need support for OpenGL 3.2 or higher.") (define-public bootterm (package (name "bootterm") - (version "0.1") + (version "0.2") (source (origin (method git-fetch) (uri (git-reference @@ -1441,7 +1441,7 @@ terminal. Note that you need support for OpenGL 3.2 or higher.") (file-name (git-file-name name version)) (sha256 (base32 - "1mh2i47ppcrw027nmkpjgbmx55ml21bmqihvwkhlvj1jr0vv8pva")))) + "08yb4kiid3028cqsx7wzyrzk46asphxlxlj1y141hi245wbql55n")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; no test suite -- cgit v1.2.3 From d38e410c6a4b101b544774620ca7158ae5c57f7c Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Fri, 1 Jan 2021 23:37:20 -0500 Subject: gnu: Add perl-eval-withlexicals. * gnu/packages/perl.scm (perl-eval-withlexicals): New variable. --- gnu/packages/perl.scm | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm index 040206504d..896a474bba 100644 --- a/gnu/packages/perl.scm +++ b/gnu/packages/perl.scm @@ -28,6 +28,7 @@ ;;; Copyright © 2020 Paul Garlick ;;; Copyright © 2020 Nicolas Goaziou ;;; Copyright © 2020 Malte Frank Gerdes +;;; Copyright © 2021 Maxim Cournoyer ;;; ;;; This file is part of GNU Guix. ;;; @@ -4056,6 +4057,41 @@ environment, other than a fixed list of specified variables. Compilation errors are rethrown automatically.") (license (package-license perl)))) +(define-public perl-eval-withlexicals + (package + (name "perl-eval-withlexicals") + (version "1.003006") + (source + (origin + (method url-fetch) + (uri (string-append + "mirror://cpan/authors/id/H/HA/HAARG/Eval-WithLexicals-" + version + ".tar.gz")) + (sha256 + (base32 + "0x09mq0q745cxkw3xgr0h7dil7p1pdq3l5299kj3mk2ijkk2gwb6")))) + (build-system perl-build-system) + (arguments + `(#:phases (modify-phases %standard-phases + (add-after 'install 'wrap-tinyrepl + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out"))) + (wrap-program (string-append out "/bin/tinyrepl") + `("PERL5LIB" ":" prefix + (,(getenv "PERL5LIB") + ,(string-append out "/lib/perl5/site_perl")))) + #t)))))) + (propagated-inputs + `(("perl-moo" ,perl-moo) + ("perl-strictures" ,perl-strictures))) + (home-page "https://metacpan.org/release/Eval-WithLexicals") + (synopsis "Lexical scope evaluation library for Perl") + (description "The Eval::WithLexicals Perl library provides support for +lexical scope evaluation. This package also includes the @command{tinyrepl} +command, which can be used as a minimal Perl read-eval-print loop (REPL).") + (license (package-license perl)))) + (define-public perl-exception-class (package (name "perl-exception-class") -- cgit v1.2.3 From 88a4e5f19b7288d73a70115e3c80a8dbcb2c04d7 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Sat, 2 Jan 2021 10:48:08 +0100 Subject: gnu: txr: Update to 246. * gnu/packages/lisp.scm (txr): Update to 246. --- gnu/packages/lisp.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm index 603bbab736..9ef37d706b 100644 --- a/gnu/packages/lisp.scm +++ b/gnu/packages/lisp.scm @@ -840,7 +840,7 @@ enough to play the original mainframe Zork all the way through.") (define-public txr (package (name "txr") - (version "245") + (version "246") (source (origin (method git-fetch) @@ -849,7 +849,7 @@ enough to play the original mainframe Zork all the way through.") (commit (string-append "txr-" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1pnajvqhzjlw0rwwhhk4hyps5pbg9njh10iqhnmvl1xnah6ff94z")))) + (base32 "1ynkz0ss7nn1ssiaxagpq80iabknf085nk0pra9hn8y9hx7av0db")))) (build-system gnu-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 1fc9baeebb24a36431736f1a187e501943918444 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Fri, 1 Jan 2021 23:27:43 +0000 Subject: gnu: Add cl-ixf. * gnu/packages/lisp-xyz.scm (cl-ixf, ecl-ixf, sbcl-ixf): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 87e130a82e..d61b4b7b0d 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -10803,6 +10803,43 @@ Inflector module.") (define-public ecl-cl-inflector (sbcl-package->ecl-package sbcl-cl-inflector)) +(define-public sbcl-ixf + (let ((commit "ed26f87e4127e4a9e3aac4ff1e60d1f39cca5183") + (revision "1")) + (package + (name "sbcl-ixf") + (version (git-version "0.1.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/dimitri/cl-ixf") + (commit commit))) + (file-name (git-file-name "cl-ixf" version)) + (sha256 + (base32 "1wjdnf4vr9z7lcfc49kl43g6l2i23q9n81siy494k17d766cdvqa")))) + (build-system asdf-build-system/sbcl) + (inputs + `(("alexandria" ,sbcl-alexandria) + ("babel" ,sbcl-babel) + ("cl-ppcre" ,sbcl-cl-ppcre) + ("ieee-floats" ,sbcl-ieee-floats) + ("local-time" ,sbcl-local-time) + ("md5" ,sbcl-md5) + ("split-sequence" ,sbcl-split-sequence))) + (home-page "https://github.com/dimitri/cl-ixf") + (synopsis "Parse IBM IXF file format") + (description + "This is a Common Lisp library to handle the IBM PC version of the IXF +(Integration Exchange Format) file format.") + (license license:public-domain)))) + +(define-public ecl-ixf + (sbcl-package->ecl-package sbcl-ixf)) + +(define-public cl-ixf + (sbcl-package->cl-source-package sbcl-ixf)) + (define-public sbcl-qbase64 (package (name "sbcl-qbase64") -- cgit v1.2.3 From d9010a35bfb1479b59d88c17612a4dc5f23ae977 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Sat, 2 Jan 2021 15:07:43 +0100 Subject: gnu: sbcl-cl-fastcgi: Update to 20210121. * gnu/packages/lisp-xyz.scm (sbcl-cl-fastcgi): Update to 20210121. --- gnu/packages/lisp-xyz.scm | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index d61b4b7b0d..2d9ad8c7eb 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -4409,8 +4409,8 @@ mime-type of a file.") (sbcl-package->ecl-package sbcl-ningle)) (define-public sbcl-cl-fastcgi - (let ((commit "d576d20eeb12f225201074b28934ba395b15781a") - (revision "1")) + (let ((commit "de8b49b26de9863996ec18db28af8ab7e8ac4e20") + (revision "2")) (package (name "sbcl-cl-fastcgi") (version (git-version "0.2" revision commit)) @@ -4422,7 +4422,7 @@ mime-type of a file.") (commit commit))) (file-name (git-file-name name version)) (sha256 - (base32 "02mvzzyn0k960s38rbxaqqmdkwcfmyhf8dx6ynz8xyxflmp0s5zv")))) + (base32 "0xgmhx766q4nmrvn5z7ag3ikpr9phlh8ypi8b14azshq9lqbq0m7")))) (build-system asdf-build-system/sbcl) (inputs `(("usocket" ,sbcl-usocket) @@ -4443,8 +4443,6 @@ mime-type of a file.") (description "CL-FastCGI is a generic version of SB-FastCGI, targeting to run on mostly Common Lisp implementation.") - ;; TODO: Upstream on specifies "BSD license": - ;; https://github.com/KDr2/cl-fastcgi/issues/4 (license license:bsd-2)))) (define-public cl-fastcgi -- cgit v1.2.3 From 7d05575ef5b9841c171d6069ff82c471317d6c30 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 2 Jan 2021 15:30:19 +0100 Subject: gnu: brlaser: Update to 6-1.9d7ddda. * gnu/packages/printers.scm (brlaser): Update to 6-1.9d7ddda. --- gnu/packages/printers.scm | 62 ++++++++++++++++++++++++----------------------- 1 file changed, 32 insertions(+), 30 deletions(-) diff --git a/gnu/packages/printers.scm b/gnu/packages/printers.scm index bbf98ee653..e03582c47b 100644 --- a/gnu/packages/printers.scm +++ b/gnu/packages/printers.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2018 Ludovic Courtès ;;; Copyright © 2018 Tobias Geerinckx-Rice -;;; Copyright © 2019 Ricardo Wurmus +;;; Copyright © 2019, 2021 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -75,34 +75,36 @@ with Graphtec and Sihouette plotting cutters using an SVG file as its input.") (license license:gpl3+))) (define-public brlaser - (package - (name "brlaser") - (version "6") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/pdewacht/brlaser") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1995s69ksq1fz0vb34v0ndiqncrinbrlpmp70rkl6az7kag99s80")))) - (build-system cmake-build-system) - (arguments - `(#:configure-flags - (list (string-append "-DCUPS_DATA_DIR=" - (assoc-ref %outputs "out") - "/share/cups") - (string-append "-DCUPS_SERVER_BIN=" - (assoc-ref %outputs "out") - "/lib/cups")))) - (inputs - `(("ghostscript" ,ghostscript) - ("cups" ,cups) - ("zlib" ,zlib))) - (home-page "https://github.com/pdewacht/brlaser") - (synopsis "Brother laser printer driver") - (description "Brlaser is a CUPS driver for Brother laser printers. This + (let ((commit "9d7ddda8383bfc4d205b5e1b49de2b8bcd9137f1") + (revision "1")) + (package + (name "brlaser") + (version (git-version "6" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/pdewacht/brlaser") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1drh0nk7amn9a8wykki4l9maqa4vy7vwminypfy1712alwj31nd4")))) + (build-system cmake-build-system) + (arguments + `(#:configure-flags + (list (string-append "-DCUPS_DATA_DIR=" + (assoc-ref %outputs "out") + "/share/cups") + (string-append "-DCUPS_SERVER_BIN=" + (assoc-ref %outputs "out") + "/lib/cups")))) + (inputs + `(("ghostscript" ,ghostscript) + ("cups" ,cups) + ("zlib" ,zlib))) + (home-page "https://github.com/pdewacht/brlaser") + (synopsis "Brother laser printer driver") + (description "Brlaser is a CUPS driver for Brother laser printers. This driver is known to work with these printers: @enumerate @@ -137,4 +139,4 @@ driver is known to work with these printers: @item Brother MFC-L2710DW series @item Lenovo M7605D @end enumerate") - (license license:gpl2+))) + (license license:gpl2+)))) -- cgit v1.2.3 From ef126b97553c8119d9478d368c3fd51fa3471b72 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 19:22:15 +0200 Subject: gnu: alive: Update to 2.0.3. * gnu/packages/admin.scm (alive): Update to 2.0.3. --- gnu/packages/admin.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index e45e228624..ed6d2768d3 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2016, 2017, 2020 Leo Famulari ;;; Copyright © 2016 Pjotr Prins ;;; Copyright © 2016, 2017 Ricardo Wurmus -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2016 Peter Feigl ;;; Copyright © 2016 John J. Foerch ;;; Copyright © 2016, 2017 Nikita @@ -929,14 +929,14 @@ recursive runs on the generated subnets. (also IPv6) (define-public alive (package (name "alive") - (version "2.0.2") + (version "2.0.3") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/alive/alive-" version ".tar.xz")) (sha256 (base32 - "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j")))) + "053hfp7s66lnilm1ii4jrjmy44wpa2cwwh6f0sl8cyz0mm813x4b")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("alive_cv_nice_ping=yes"))) (inputs `(("guile" ,guile-2.0) -- cgit v1.2.3 From 072abfe4141833af71adb3266c46419fe5192a4b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 19:32:26 +0200 Subject: gnu: evisum: Update to 0.5.8. * gnu/packages/enlightenment.scm (evisum): Update to 0.5.8. --- gnu/packages/enlightenment.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/enlightenment.scm b/gnu/packages/enlightenment.scm index 5ce2229a75..99309dd4a0 100644 --- a/gnu/packages/enlightenment.scm +++ b/gnu/packages/enlightenment.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 Tomáš Čech ;;; Copyright © 2015 Daniel Pimentel -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2017 Nikita ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2018 Timo Eisenmann @@ -566,14 +566,14 @@ directories. (define-public evisum (package (name "evisum") - (version "0.5.7") + (version "0.5.8") (source (origin (method url-fetch) (uri (string-append "https://download.enlightenment.org/rel/apps/" "evisum/evisum-" version ".tar.xz")) (sha256 - (base32 "0pm63n3rls8vkjv3awq0f3zlqk33ddql3g0rl2bc46n48g2mcmbd")))) + (base32 "0cg4vqd069h89k3wrvl550p29y3yzbdnvii58gwc8rghwym621jx")))) (build-system meson-build-system) (arguments '(#:tests? #f)) ; no tests -- cgit v1.2.3 From 98535733e2921685100e48337f5751910ace27bd Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 19 Nov 2020 19:01:25 +0100 Subject: gnu: Add bcache-tools. * gnu/packages/disk.scm (bcache-tools): New public variable. --- gnu/packages/disk.scm | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm index c4f128d14a..4070804fcb 100644 --- a/gnu/packages/disk.scm +++ b/gnu/packages/disk.scm @@ -89,6 +89,73 @@ #:use-module (guix packages) #:use-module (guix utils)) +(define-public bcache-tools + ;; The 1.1 release is a year old and missing new features & documentation. + (let ((commit "096d205a9f1be8540cbc5a468c0da8203023de70") + (revision "0")) + (package + (name "bcache-tools") + (version (git-version "1.1" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url (string-append "https://git.kernel.org/pub/scm/" + "linux/kernel/git/colyli/bcache-tools.git")) + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0r0vwg4vacz5zgsafk360xn7gi2scy01c79mkmjrdyxjfij5z3iy")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no test suite + #:make-flags + (list (string-append "PREFIX=" (assoc-ref %outputs "out")) + (string-append "UDEVLIBDIR=" (assoc-ref %outputs "out") + "/lib/udev") + (string-append "DRACUTLIBDIR=" (assoc-ref %outputs "out") + "/lib/dracut") + (string-append "CC=" ,(cc-for-target))) + #:phases + (modify-phases %standard-phases + (delete 'configure) ; no configure script + (add-before 'install 'fix-hard-coded-file-names + (lambda _ + ;; Some rules still hard-code /usr. + (substitute* "Makefile" + (("/usr") "${PREFIX}")) + #t)) + (add-before 'install 'create-target-directories + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out"))) + (for-each (lambda (dir) + (mkdir-p (string-append out dir))) + (list "/lib/udev/rules.d" + "/sbin" + "/share/man/man8")) + #t)))))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("util-linux:lib" ,util-linux "lib"))) ; libblkid + (home-page "https://bcache.evilpiepirate.org") + (synopsis "Tools for the Linux kernel block layer cache") + (description + "This package contains user-space utilities to create and inspect bcache +partitions. It's rather minimal as bcache is designed to work well without +configuration on any system. + +Linux's @acronym{bcache, block layer cache} lets one or more fast block devices, +such as flash-based @acronym{SSDs, solid state drives}, to act as a cache for +one or more slower (and inexpensive) devices, such as hard disk drives or +redundant storage arrays. In fact, bcache intends to be a superior alternative +to battery-backed RAID controllers. + +Bcache is designed around the performance characteristics of SSDs and tries to +minimize write inflation. It's file-system agnostic and does both write-through +and write-back caching.") + (license license:gpl2)))) + (define-public udevil (package (name "udevil") -- cgit v1.2.3 From 2d4c1c0bc01b7d2eca800d36a0852d3b3ac645f4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:01:02 +0100 Subject: gnu: ndctl: Update to 71.1. * gnu/packages/disk.scm (ndctl): Update to 71.1. --- gnu/packages/disk.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm index 4070804fcb..3cc9601d21 100644 --- a/gnu/packages/disk.scm +++ b/gnu/packages/disk.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2012, 2013 Nikita Karetnikov ;;; Copyright © 2015 Mathieu Lirzin ;;; Copyright © 2015 Mark H Weaver -;;; Copyright © 2016, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016, 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016, 2019, 2020 Efraim Flashner ;;; Copyright © 2016 Jan Nieuwenhuizen ;;; Copyright © 2016 Roel Janssen @@ -759,7 +759,7 @@ passphrases.") (define-public ndctl (package (name "ndctl") - (version "71") + (version "71.1") (source (origin (method git-fetch) (uri (git-reference @@ -768,7 +768,7 @@ passphrases.") (file-name (git-file-name name version)) (sha256 (base32 - "14vhldncflxgsam49ssn1x3h4m9xxw9dwyl748xajf1js33ph5av")))) + "1vi61bm9wyawklswh9mj9zdp28ar7r97qckwnhgiyila73fb3jx2")))) (build-system gnu-build-system) (native-inputs `(("asciidoc" ,asciidoc) -- cgit v1.2.3 From da7fde00b507359570cc846fa30d57bfebf1752c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:01:20 +0100 Subject: gnu: smartmontools: Update to 7.2. * gnu/packages/admin.scm (smartmontools): Update to 7.2. --- gnu/packages/admin.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm index ed6d2768d3..375073363f 100644 --- a/gnu/packages/admin.scm +++ b/gnu/packages/admin.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2016 Peter Feigl ;;; Copyright © 2016 John J. Foerch ;;; Copyright © 2016, 2017 Nikita -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 John Darrington ;;; Copyright © 2017 Ben Sturmfels ;;; Copyright © 2017 Ethan R. Jones @@ -2110,7 +2110,7 @@ various ways that may be running with too much privilege.") (define-public smartmontools (package (name "smartmontools") - (version "7.1") + (version "7.2") (source (origin (method url-fetch) (uri (string-append @@ -2118,7 +2118,7 @@ various ways that may be running with too much privilege.") version "/smartmontools-" version ".tar.gz")) (sha256 (base32 - "0imqb7ka4ia5573w8rnpck571pjjc9698pdjcapy9cfyk4n4swrz")))) + "1mlc25sd5rgj5xmzcllci47inmfdw7cp185fday6hc9rwqkqmnaw")))) (build-system gnu-build-system) (inputs `(("libcap-ng" ,libcap-ng))) (home-page "https://www.smartmontools.org/") -- cgit v1.2.3 From ab3fbb27121e4a7d80aedfe2061f3b4e3418bd11 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:02:11 +0100 Subject: gnu: oath-toolkit: Update to 2.6.5. * gnu/packages/authentication.scm (oath-toolkit): Update to 2.6.5. --- gnu/packages/authentication.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/authentication.scm b/gnu/packages/authentication.scm index e45bbb6b26..bd40a6eb5c 100644 --- a/gnu/packages/authentication.scm +++ b/gnu/packages/authentication.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2020, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2019, 2020 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. @@ -33,14 +33,14 @@ (define-public oath-toolkit (package (name "oath-toolkit") - (version "2.6.4") + (version "2.6.5") (source (origin (method url-fetch) (uri (string-append "https://download.savannah.nongnu.org/releases/" name "/" name "-" version ".tar.gz")) (sha256 - (base32 "116na9nncpwshl3ww8w3llzwk49igilplxcjy1k6jzl3mmg2bimz")))) + (base32 "06f21smb412xads4lygvyb47fcpvhdns0k6h880m9pbzgq6141yj")))) (build-system gnu-build-system) (arguments ;; TODO ‘--enable-pskc’ causes xmlsec-related test suite failures. -- cgit v1.2.3 From 74d811297dccb23f585084b40724643d262101d6 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:03:16 +0100 Subject: gnu: font-gnu-unifont: Update to 13.0.05. * gnu/packages/fonts.scm (font-gnu-unifont): Update to 13.0.05. --- gnu/packages/fonts.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index d5806cda36..92b55f57f8 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2016, 2020 Marius Bakke ;;; Copyright © 2016 Toni Reina -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 José Miguel Sánchez García ;;; Copyright © 2017 Alex Griffin ;;; Copyright © 2017 Clément Lassieur @@ -711,7 +711,7 @@ for use at smaller text sizes"))) (define-public font-gnu-unifont (package (name "font-gnu-unifont") - (version "13.0.04") + (version "13.0.05") (source (origin (method url-fetch) @@ -721,7 +721,7 @@ for use at smaller text sizes"))) (string-append "mirror://gnu/unifont/unifont-" version "/unifont-" version ".tar.gz"))) (sha256 - (base32 "064ilpbnz62cwmpajszs2b08x2zg7yh9whlaiqhjzi7bir3im94j")))) + (base32 "0kkgagnyhl92pwgnvf1vjrc1ql8lk5khb125sz18ck8vnxk4i3pr")))) (build-system gnu-build-system) (outputs '("out" ; TrueType version "pcf" ; PCF (bitmap) version -- cgit v1.2.3 From d6660ef6ee014d5e3a2e8d0dad0a4a4b800cebc7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:08:37 +0100 Subject: gnu: deutex: Update to 5.2.2. * gnu/packages/game-development.scm (deutex): Update to 5.2.2. [source]: Change tarball extension. [native-inputs]: Add zstd. --- gnu/packages/game-development.scm | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 79bb6ec7e3..fa7875d077 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2016, 2017, 2020 Kei Kebreau ;;; Copyright © 2016, 2018, 2019 Ricardo Wurmus ;;; Copyright © 2016, 2017, 2018 Julian Graham -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Manolis Fragkiskos Ragkousis ;;; Copyright © 2017 Peter Mikkelsen ;;; Copyright © 2017 Arun Isaac @@ -163,21 +163,22 @@ is used in some video games and movies.") (define-public deutex (package (name "deutex") - (version "5.2.1") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/Doom-Utils/deutex" - "/releases/download/v" version "/" - "deutex-" version ".tar.xz")) - (sha256 - (base32 - "07w3asqxx89wl2wfv1z3cak8v83h3ys3b39mq9qq4gyf3xdhs76n")))) + (version "5.2.2") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/Doom-Utils/deutex" + "/releases/download/v" version "/" + "deutex-" version ".tar.zst")) + (sha256 + (base32 "0psb2za6ldrlak7s8pjvli98ij5yiwjx8j1ms2v7rj9yadx0xv8h")))) (build-system gnu-build-system) (inputs `(("libpng" ,libpng))) (native-inputs `(("asciidoc" ,asciidoc) - ("pkg-config" ,pkg-config))) + ("pkg-config" ,pkg-config) + ("zstd" ,zstd))) (home-page "https://github.com/Doom-Utils/deutex") (synopsis "WAD file composer for Doom and related games") (description -- cgit v1.2.3 From e2492f5814ea6c20486b053d8dae3d37b54a6635 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:15:20 +0100 Subject: gnu: routino: Update to 3.3.3. * gnu/packages/geo.scm (routino): Update to 3.3.3. --- gnu/packages/geo.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm index c0c1ef96c6..c682613ff1 100644 --- a/gnu/packages/geo.scm +++ b/gnu/packages/geo.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2016 Leo Famulari ;;; Copyright © 2016 Alex Griffin ;;; Copyright © 2017, 2018 Björn Höfling -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Ricardo Wurmus ;;; Copyright © 2018, 2019 Arun Isaac ;;; Copyright © 2018 Joshua Sierles, Nextjournal @@ -1559,15 +1559,14 @@ The API also works with MaxMind’s free GeoLite2 databases.") (define-public routino (package (name "routino") - (version "3.3.2") + (version "3.3.3") (source (origin (method url-fetch) (uri (string-append "http://www.routino.org/download/routino-" version ".tgz")) (sha256 - (base32 - "1ccx3s99j8syxc1gqkzsaqkmyf44l7h3adildnc5iq2md7bp8wab")))) + (base32 "1xa7l2bjn832nk6bc7b481nv8hd2gj41jwhg0d2qy10lqdvjpn5b")))) (build-system gnu-build-system) (native-inputs `(("perl" ,perl))) -- cgit v1.2.3 From f50adf0b7917231cad59dd2ddfda7fe0872be79a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:16:26 +0100 Subject: gnu: lsp-dsp-lib: Update to 0.5.11. * gnu/packages/audio.scm (lsp-dsp-lib): Update to 0.5.11. --- gnu/packages/audio.scm | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 87c7e6f4de..5d607e37dc 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2016, 2017 Alex Griffin ;;; Copyright © 2016 Nikita ;;; Copyright © 2016 Lukas Gradl -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018, 2020 Oleg Pykhalov ;;; Copyright © 2018 okapi ;;; Copyright © 2018, 2020 Maxim Cournoyer @@ -4832,16 +4832,15 @@ edited, converted, compressed and saved.") (define-public lsp-dsp-lib (package (name "lsp-dsp-lib") - (version "0.5.8") + (version "0.5.11") (source (origin (method url-fetch) (uri (string-append "https://github.com/sadko4u/lsp-dsp-lib/" - "releases/download/lsp-dsp-lib-" version + "releases/download/" version "/lsp-dsp-lib-" version "-src.tar.gz")) (sha256 - (base32 - "07w3d2i0z0xmvi1ngcgs7lc5a0da8jvf7rv4dnjk01md43b7fkh1")))) + (base32 "0lkar6r9jfrrqswi8nnndlm5a9kfwqjn92d81gp2yhc3p46xsswz")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; no tests -- cgit v1.2.3 From 673c58cdeead11be86688096ff77ca62bdd17ef3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:17:05 +0100 Subject: gnu: lsp-dsp-lib: Omit static library. * gnu/packages/audio.scm (lsp-dsp-lib)[arguments]: Add an 'omit-static-library phase. --- gnu/packages/audio.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 5d607e37dc..cf68ddf0d8 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -4848,6 +4848,11 @@ edited, converted, compressed and saved.") (list (string-append "CC=" ,(cc-for-target))) #:phases (modify-phases %standard-phases + (add-after 'unpack 'omit-static-library + (lambda _ + (substitute* "src/Makefile" + ((".*@.*ARTIFACT_SLIB.*") "") ; don't install it + ((" \\$\\(ARTIFACT_SLIB\\)") "")))) ; don't build it (replace 'configure (lambda* (#:key outputs #:allow-other-keys) (invoke "make" "config" -- cgit v1.2.3 From 81c7a751403d193d66db0f19b2a6d30cefebbc81 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:39:24 +0100 Subject: gnu: gnome-tweaks: Update to 3.34.1. * gnu/packages/gnome.scm (gnome-tweaks): Update to 3.34.1. --- gnu/packages/gnome.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 55189d096f..6f9fc92246 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -21,7 +21,7 @@ ;;; Copyright © 2016 Alex Griffin ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016 David Craven -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017 Hartmut Goebel ;;; Copyright © 2017, 2018 nee @@ -9485,7 +9485,7 @@ existing databases over the internet.") (define-public gnome-tweaks (package (name "gnome-tweaks") - (version "3.34.0") + (version "3.34.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/gnome-tweaks/" @@ -9495,7 +9495,7 @@ existing databases over the internet.") (list (search-patch "gnome-tweaks-search-paths.patch"))) (sha256 (base32 - "0l2j42ba7v866iknygamnkiq7igh0fjvq92r93cslvvfnkx2ccq0")))) + "19y62dj4n5i6v4zpjllxl51dch6ndy8xs45v5aqmmq9xyfrqk5yq")))) (build-system meson-build-system) (arguments `(#:glib-or-gtk? #t -- cgit v1.2.3 From 961fdd3a2af40ec212fdc928754eb49ee27f984f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 17:54:04 +0100 Subject: gnu: wavemon: Update to 0.9.3. * gnu/packages/hardware.scm (wavemon): Update to 0.9.3. [source]: Remove applied patches. --- gnu/packages/hardware.scm | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm index a3418878e7..d130ebd48b 100644 --- a/gnu/packages/hardware.scm +++ b/gnu/packages/hardware.scm @@ -289,7 +289,7 @@ be dangerous and may void your CPU or system board's warranty.") (define-public wavemon (package (name "wavemon") - (version "0.9.2") + (version "0.9.3") (source (origin (method git-fetch) @@ -298,24 +298,7 @@ be dangerous and may void your CPU or system board's warranty.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0y984wm03lzqf7bk06a07mw7d1fzjsp9x7zxcvlx4xqmv7wlgb29")) - (patches - (list - ;; Two upstream commits required to find the correct . - (origin - (method url-fetch) - (uri (string-append - "https://github.com/uoaerg/wavemon/commit/" - "ce7f9c4da90767bb50e4b80cdb3cee61264d8d12.patch")) - (sha256 - (base32 "04b4qbsa5l0jr41dkj0c8yw74lm8z8b50nw1iwas6hnzq41dwdm3"))) - (origin - (method url-fetch) - (uri (string-append - "https://github.com/uoaerg/wavemon/commit/" - "31e3def1c7332ad830bd966e7d21b343b4f2da54.patch")) - (sha256 - (base32 "0kyv3sbkv9hl8b88xnk6bq550axh9wzfjlhp3jbvqd4fqf7663br"))))))) + (base32 "0m9n5asjxs1ir5rqprigqcrm976mgjvh4yql1jhfnbszwbf95193")))) (build-system gnu-build-system) (arguments `(#:make-flags -- cgit v1.2.3 From 8933abafe04fadc6e180a6abbb0714b51e19e37f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 18:18:55 +0100 Subject: gnu: gpick: Update to 0.2.6. * gnu/packages/image.scm (gpick): Update to 0.2.6. [native-inputs]: Add ragel. --- gnu/packages/image.scm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm index 4c6ab8cda7..8cba9c298b 100644 --- a/gnu/packages/image.scm +++ b/gnu/packages/image.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2014, 2017 John Darrington ;;; Copyright © 2016, 2017, 2018, 2020 Leo Famulari ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 Eric Bavier ;;; Copyright © 2016, 2017, 2020 Arun Isaac ;;; Copyright © 2016, 2017 Kei Kebreau @@ -78,6 +78,7 @@ #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) + #:use-module (gnu packages ragel) #:use-module (gnu packages sphinx) #:use-module (gnu packages swig) #:use-module (gnu packages textutils) @@ -1734,7 +1735,7 @@ medical image data, e.g. magnetic resonance image (MRI) and functional MRI (define-public gpick (package (name "gpick") - (version "0.2.5") + (version "0.2.6") (source (origin (method git-fetch) (uri (git-reference @@ -1743,12 +1744,13 @@ medical image data, e.g. magnetic resonance image (MRI) and functional MRI (file-name (git-file-name name version)) (sha256 (base32 - "0mcj806zagh122qgrdkrg0macpzby97y89xi2sjyn3bh8vmmyxjy")))) + "0nl89gca5nmbyycv5rl5bm6k7facapdk4pab9pl949aa3cjw9bk7")))) (build-system scons-build-system) (native-inputs `(("boost" ,boost) ("gettext" ,gettext-minimal) - ("pkg-config" ,pkg-config))) + ("pkg-config" ,pkg-config) + ("ragel" ,ragel))) (inputs `(("expat" ,expat) ("gtk2" ,gtk+-2) -- cgit v1.2.3 From 48dafe7da67315328022ac8513b087f4acc71146 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 18:25:52 +0100 Subject: gnu: udunits: Update to 2.2.28. * gnu/packages/c.scm (udunits): Update to 2.2.28. --- gnu/packages/c.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm index 2ea9c2ac51..c5d425fb13 100644 --- a/gnu/packages/c.scm +++ b/gnu/packages/c.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016, 2018 Ludovic Courtès ;;; Copyright © 2016, 2017, 2018, 2019 Ricardo Wurmus -;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2020, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2018, 2019 Pierre Neidhardt ;;; Copyright © 2019, 2020 Efraim Flashner ;;; Copyright © 2019 Guillaume Le Vaillant @@ -189,14 +189,14 @@ language with thin bindings for other languages.") (name "udunits") ;; Four-part version numbers are development snapshots, not releases. See ;; . - (version "2.2.26") + (version "2.2.28") (source (origin (method url-fetch) (uri (string-append "ftp://ftp.unidata.ucar.edu/pub/udunits/" "udunits-" version ".tar.gz")) (sha256 (base32 - "0v9mqw4drnkzkm57331ail6yvs9485jmi37s40lhvmf7r5lli3rn")))) + "17jpbp6f0rr132jn2gqy8ry8mv1w27v6dyhfq1igv8v1674aw2sr")))) (build-system gnu-build-system) (inputs `(("expat" ,expat))) -- cgit v1.2.3 From 2a7dce4f8cf99c2d2785a35102be096ed5df752b Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 18:26:40 +0100 Subject: gnu: udunits: Omit static library. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/c.scm (udunits)[arguments]: Add ‘--disable-static’ to #:configure-flags. --- gnu/packages/c.scm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm index c5d425fb13..d9e5e4d7de 100644 --- a/gnu/packages/c.scm +++ b/gnu/packages/c.scm @@ -198,6 +198,9 @@ language with thin bindings for other languages.") (base32 "17jpbp6f0rr132jn2gqy8ry8mv1w27v6dyhfq1igv8v1674aw2sr")))) (build-system gnu-build-system) + (arguments + `(#:configure-flags + (list "--disable-static"))) (inputs `(("expat" ,expat))) (home-page "https://www.unidata.ucar.edu/software/udunits/") -- cgit v1.2.3 From 7431bdb5d5683af19c43058145605682394beb2b Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 20:19:25 +0100 Subject: gnu: brltty: Update to 6.2. * gnu/packages/accessibility.scm (brltty): Update to 6.2. [arguments]: Set INSTALL_WRITABLE_DIRECTORY to something harmless. --- gnu/packages/accessibility.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gnu/packages/accessibility.scm b/gnu/packages/accessibility.scm index 5180f88bae..f3bd094c92 100644 --- a/gnu/packages/accessibility.scm +++ b/gnu/packages/accessibility.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017 Nikita ;;; Copyright © 2017 Stefan Reichör -;;; Copyright © 2018 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2019 Andrew Miloradovsky ;;; Copyright © 2020 Efraim Flashner ;;; @@ -95,15 +95,14 @@ terminals.") (define-public brltty (package (name "brltty") - (version "6.1") + (version "6.2") (source (origin (method url-fetch) (uri - (string-append "https://brltty.app/archive/" - name "-" version ".tar.gz")) + (string-append "https://brltty.app/archive/brltty-" version ".tar.gz")) (sha256 - (base32 "0nk54chr7z2w579vyiak9xk2avhnvrx7x2l5sk8nyw2zplchkx9q")))) + (base32 "0m0cq3p1cwp52n81si621gij82w3mdqwgr39m6bs652pmk5na72l")))) (build-system glib-or-gtk-build-system) (arguments `(#:tests? #f ; No target @@ -138,7 +137,8 @@ terminals.") "PYTHON_ROOT=/" (string-append "TCL_DIR=" (assoc-ref %outputs "out") - "/lib")) + "/lib") + "INSTALL_WRITABLE_DIRECTORY=no-thanks") #:phases (modify-phases %standard-phases (add-after 'unpack 'fix-errors -- cgit v1.2.3 From 2836936b9174e2ba575cc02b2ae52cc9ed2078df Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 20:38:25 +0100 Subject: gnu: mutt: Update to 2.0.4. * gnu/packages/mail.scm (mutt): Update to 2.0.4. --- gnu/packages/mail.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 734b2cd707..ed0a677cf7 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -22,7 +22,7 @@ ;;; Copyright © 2016, 2018 Marius Bakke ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017 Kyle Meyer -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018, 2020 Rene Saavedra ;;; Copyright © 2018, 2019, 2020 Pierre Langlois ;;; Copyright © 2018 Alex Vong @@ -445,7 +445,7 @@ aliasing facilities to work just as they would on normal mail.") (define-public mutt (package (name "mutt") - (version "2.0.3") + (version "2.0.4") (source (origin (method url-fetch) (uri (list @@ -455,7 +455,7 @@ aliasing facilities to work just as they would on normal mail.") version ".tar.gz"))) (sha256 (base32 - "1vf1ab3mnx7p4s4n4pssajj211s3zr4730bwgsjx9gxcnyppqclw")) + "1m4ig69qw4g3lhm4351snmy5i0ch65fqc9vqqdybr6jy21w7w225")) (patches (search-patches "mutt-store-references.patch")))) (build-system gnu-build-system) (inputs -- cgit v1.2.3 From b7e8863d0da25ddcca2786d04d1e471f151b2458 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 20:38:33 +0100 Subject: gnu: mpop: Update to 1.4.12. * gnu/packages/mail.scm (mpop): Update to 1.4.12. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index ed0a677cf7..977222a70e 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -2682,14 +2682,14 @@ easily (one at a time).") (define-public mpop (package (name "mpop") - (version "1.4.11") + (version "1.4.12") (source (origin (method url-fetch) (uri (string-append "https://marlam.de/mpop/releases/" "mpop-" version ".tar.xz")) (sha256 - (base32 "1gcxvhin5y0q47svqbf90r5aip0cgywm8sq6m84ygda7km8xylwv")))) + (base32 "02j8qfd44dfyq1sq7r9znj9y6wam39ncch1sc8chcdlw5nsmaqsz")))) (build-system gnu-build-system) (inputs `(("gnutls" ,gnutls))) -- cgit v1.2.3 From fe84facca04f3b05e8acda2d19085330f0946d59 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:52:44 +0100 Subject: gnu: synthv1: Update to 0.9.19. * gnu/packages/music.scm (synthv1): Update to 0.9.19. --- gnu/packages/music.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index c2a2668810..ea2397830c 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2017, 2018, 2019, 2020 Nicolas Goaziou ;;; Copyright © 2017, 2018, 2019 Pierre Langlois ;;; Copyright © 2017 Arun Isaac -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 nee ;;; Copyright © 2018 Stefan Reichör ;;; Copyright © 2018 Pierre Neidhardt @@ -1839,7 +1839,7 @@ users to select LV2 plugins and run them with jalv.") (define-public synthv1 (package (name "synthv1") - (version "0.9.18") + (version "0.9.19") (source (origin (method url-fetch) (uri @@ -1847,7 +1847,7 @@ users to select LV2 plugins and run them with jalv.") "/synthv1-" version ".tar.gz")) (sha256 (base32 - "1sggiaswcdpyxnnbg583ldg0m92fiys6nc5qdiqli7450w416a6c")))) + "17sizhav01mn07gi812n8wqdcr85290zqg609s18cww2b95dy6mn")))) (build-system gnu-build-system) (arguments `(#:tests? #f)) ; there are no tests -- cgit v1.2.3 From 433344c5f87fcc163de46aa87fed74f11567e2c0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:52:56 +0100 Subject: gnu: drumkv1: Update to 0.9.19. * gnu/packages/music.scm (drumkv1): Update to 0.9.19. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index ea2397830c..eb23a0607d 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -1871,7 +1871,7 @@ oscillators and stereo effects.") (define-public drumkv1 (package (name "drumkv1") - (version "0.9.18") + (version "0.9.19") (source (origin (method url-fetch) (uri @@ -1879,7 +1879,7 @@ oscillators and stereo effects.") "/drumkv1-" version ".tar.gz")) (sha256 (base32 - "1bzkaz7sqx1pvirja8zm7i2ckzl5ad6xspr4840389ik3l8qpnr5")))) + "0w9frc634yg2m0yc84szdf6x7l4f19pcviqpg065a1kdixf98qrf")))) (build-system gnu-build-system) (arguments `(#:tests? #f)) ; there are no tests -- cgit v1.2.3 From c5cba7d38318f807b737a043ec24d81b2a1e0a67 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:53:09 +0100 Subject: gnu: samplv1: Update to 0.9.19. * gnu/packages/music.scm (samplv1): Update to 0.9.19. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index eb23a0607d..3c9c36029b 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -1904,7 +1904,7 @@ effects.") (define-public samplv1 (package (name "samplv1") - (version "0.9.18") + (version "0.9.19") (source (origin (method url-fetch) (uri @@ -1912,7 +1912,7 @@ effects.") "/samplv1-" version ".tar.gz")) (sha256 (base32 - "13p5aj1513fwhzi9s4i1a5dbvzmbx9867zb0ddb9s9nbwks4ry3q")))) + "1fwvk83sfvp1k6qyqv1a7a1l8sbm6azcldaiiqa3ls1vhl4m5wv4")))) (build-system gnu-build-system) (arguments `(#:tests? #f)) ; there are no tests -- cgit v1.2.3 From 29889682b0efb86c1a8c6e937b05776952c4941e Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:53:20 +0100 Subject: gnu: padthv1: Update to 0.9.19. * gnu/packages/music.scm (padthv1): Update to 0.9.19. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 3c9c36029b..61a3bf2f79 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -1937,7 +1937,7 @@ effects.") (define-public padthv1 (package (name "padthv1") - (version "0.9.18") + (version "0.9.19") (source (origin (method url-fetch) (uri @@ -1945,7 +1945,7 @@ effects.") "/padthv1-" version ".tar.gz")) (sha256 (base32 - "1karrprb3ijrbiwpr43rl3nxnzc33lnmwrd1832psgr3flnr9fp5")))) + "06fkrc4xxzr3sa3c76lnkcm4q9k0xl5993bn60la0ja4sz2kp6r7")))) (build-system gnu-build-system) (arguments `(#:tests? #f)) ; there are no tests -- cgit v1.2.3 From a4ca7912d3b636d5c6dff48a639e28de1cb1cd7c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:53:33 +0100 Subject: gnu: qtractor: Update to 0.9.19. * gnu/packages/music.scm (qtractor): Update to 0.9.19. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 61a3bf2f79..aba87ab6f2 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -2913,14 +2913,14 @@ from the command line.") (define-public qtractor (package (name "qtractor") - (version "0.9.18") + (version "0.9.19") (source (origin (method url-fetch) (uri (string-append "https://downloads.sourceforge.net/qtractor/" "qtractor-" version ".tar.gz")) (sha256 (base32 - "121vmygdzp37p6f93f8dbbg2m2r55j7amyiapzkqgypgn4vfdbwr")))) + "0gdr1hvda56vmv4998z9xcqsp7da6lplj00f217x9g2i2snyvkzp")))) (build-system gnu-build-system) (arguments `(#:tests? #f)) ; no "check" target -- cgit v1.2.3 From 35d6d33a6cae99c6b4b689760e70fa0dcd163bc1 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 21:54:52 +0100 Subject: gnu: highlight: Update to 3.60. * gnu/packages/pretty-print.scm (highlight): Update to 3.60. --- gnu/packages/pretty-print.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm index a3f9bef63c..4ab1da5ca9 100644 --- a/gnu/packages/pretty-print.scm +++ b/gnu/packages/pretty-print.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2016 Ricardo Wurmus ;;; Copyright © 2017 Marius Bakke ;;; Copyright © 2017, 2020 Ludovic Courtès -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2019 Meiyo Peng ;;; Copyright © 2020 Paul Garlick ;;; Copyright © 2020 Vincent Legoll @@ -270,14 +270,14 @@ seen in a terminal.") (define-public highlight (package (name "highlight") - (version "3.59") + (version "3.60") (source (origin (method url-fetch) (uri (string-append "http://www.andre-simon.de/zip/highlight-" version ".tar.bz2")) (sha256 - (base32 "18j9q9w9l71zxaaf8klcl4f5rqcmqnz9632azabv8scfw2l6r4l5")))) + (base32 "098xwzj70f2kp9zbfknlqca41lgdjv71clfx1m84151xdszv8p56")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; no tests -- cgit v1.2.3 From 320340ecc087eab1361ae8e0a949dbb9d2fde7f9 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 22:08:31 +0100 Subject: gnu: b4: Update to 0.6.2. * gnu/packages/version-control.scm (b4): Update to 0.6.2. --- gnu/packages/version-control.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index b57b0320b0..cc0d8e3148 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -2319,13 +2319,13 @@ based on a manifest file published by servers.") (define-public b4 (package (name "b4") - (version "0.6.1") + (version "0.6.2") (source (origin (method url-fetch) (uri (pypi-uri "b4" version)) (sha256 - (base32 "01qid6mvddikcdpf2ihsyn8x3z5j2n64g0ip9pqbx42hrc50pmcz")))) + (base32 "1j904dy9cwxl85k2ngc498q5cdnqwsmw3jibjr1m55w8aqdck68z")))) (build-system python-build-system) (arguments '(#:tests? #f)) ; No tests. (inputs -- cgit v1.2.3 From a0ad182f4ca3c1ae9adfa7f6f1a82379724268b3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 22:16:02 +0100 Subject: gnu: youtube-dl: Update to 2020.12.31. * gnu/packages/video.scm (youtube-dl): Update to 2020.12.31. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index b99846a3ff..d171c4a185 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -2197,14 +2197,14 @@ To load this plugin, specify the following option when starting mpv: (define-public youtube-dl (package (name "youtube-dl") - (version "2020.12.14") + (version "2020.12.31") (source (origin (method url-fetch) (uri (string-append "https://youtube-dl.org/downloads/latest/" "youtube-dl-" version ".tar.gz")) (sha256 (base32 - "0ws2nsvn0qlnnyxz9g95ffygscfmg5npzmwbq8iyyi6b2njsb0cn")) + "0ncqkzzaasda2hd89psgc0j34r2jinn1dcsfcapzrsd902qghkh9")) (snippet '(begin ;; Delete the pre-generated files, except for the man page -- cgit v1.2.3 From 43cb64d09bb5a92dc8e473c4b4243d0cc98f6883 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 22:22:08 +0100 Subject: gnu: cifs-utils: Update to 6.12. * gnu/packages/samba.scm (cifs-utils): Update to 6.12. [arguments]: Remove obsolete 'bootstrap phase replacement. --- gnu/packages/samba.scm | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/gnu/packages/samba.scm b/gnu/packages/samba.scm index f869831dec..679e2ab869 100644 --- a/gnu/packages/samba.scm +++ b/gnu/packages/samba.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2016 Adonay "adfeno" Felipe Nogueira ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017, 2018, 2020 Marius Bakke -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Ricardo Wurmus ;;; Copyright © 2019 Rutger Helling ;;; Copyright © 2020 Pierre Langlois @@ -64,14 +64,14 @@ (define-public cifs-utils (package (name "cifs-utils") - (version "6.11") + (version "6.12") (source (origin (method url-fetch) (uri (string-append "https://download.samba.org/pub/linux-cifs/" "cifs-utils/cifs-utils-" version ".tar.bz2")) (sha256 (base32 - "1n98hy3zi4klm1xxhb840br1x7hhz0xx8kp5sch84kr07yd26ndq")))) + "1vw570pvir73kl4y6fhd6ns936ankimkhb1ii43yh8lr0p1xqbcj")))) (build-system gnu-build-system) (native-inputs `(("autoconf" ,autoconf) @@ -87,12 +87,6 @@ (arguments `(#:phases (modify-phases %standard-phases - (replace 'bootstrap - ;; Force a bootstrap to fix a ‘cannot find install-sh, install.sh, - ;; or shtool’ error since version 6.10. - (lambda _ - (invoke "autoreconf" "-vfi") - #t)) (add-before 'configure 'set-root-sbin (lambda* (#:key outputs #:allow-other-keys) ;; Don't try to install into "/sbin". -- cgit v1.2.3 From 3b4bfe8dca503c30cbd4386feb0c034469da1c25 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 22:34:09 +0100 Subject: gnu: lighttpd: Update to 1.4.58. * gnu/packages/web.scm (lighttpd): Update to 1.4.58. --- gnu/packages/web.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index cef1028d34..d972e21425 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -16,7 +16,7 @@ ;;; Copyright © 2016 Clément Lassieur ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016, 2017, 2018, 2019 Arun Isaac -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 Bake Timmons ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017, 2018, 2020 Marius Bakke @@ -684,7 +684,7 @@ programming language."))) (define-public lighttpd (package (name "lighttpd") - (version "1.4.57") + (version "1.4.58") (source (origin (method url-fetch) (uri (string-append "https://download.lighttpd.net/lighttpd/" @@ -692,7 +692,7 @@ programming language."))) "lighttpd-" version ".tar.xz")) (sha256 (base32 - "0zr1ssagirv5l4r2ii1k9v366a4vwylwbq74nb5pwby1i4drdjjj")))) + "03kd28nq6wndvvyk0zs5120ajvg1icnif5bvrsyhw69sl7yyyzr6")))) (build-system gnu-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 810c1853998d13e34caa16e049c5ffd5f73b4366 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 00:06:25 +0100 Subject: gnu: egl-wayland: Update to 1.1.6. * gnu/packages/graphics.scm (egl-wayland): Update to 1.1.6. --- gnu/packages/graphics.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index def3dc6913..5672339496 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2016 Andreas Enge ;;; Copyright © 2017 Manolis Fragkiskos Ragkousis ;;; Copyright © 2017, 2018 Ben Woodcroft -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Mathieu Othacehe ;;; Copyright © 2018 Alex Kost ;;; Copyright © 2018 Kei Kebreau @@ -166,7 +166,7 @@ application-facing EGL functions.") (define-public egl-wayland (package (name "egl-wayland") - (version "1.1.5") + (version "1.1.6") (source (origin (method git-fetch) @@ -177,7 +177,7 @@ application-facing EGL functions.") (file-name (git-file-name name version)) (sha256 - (base32 "09r6a69z75j3hb9751g3ap4gm1xn71aw3j7z0c7jns292cnaa76n")))) + (base32 "1n9lg8hpjgxlf7dpddkjhbslsfd0symla2wk6jjmnl9n9jv2gmzk")))) (build-system meson-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From e14d29f93288e5a20162d09866adee1f59bb1ec3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 00:07:08 +0100 Subject: gnu: httpstat: Update to 1.3.1. * gnu/packages/networking.scm (httpstat): Update to 1.3.1. --- gnu/packages/networking.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm index 8c9db0c6b4..fad917a7c0 100644 --- a/gnu/packages/networking.scm +++ b/gnu/packages/networking.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2015 Mark H Weaver ;;; Copyright © 2015, 2016, 2017 Stefan Reichör ;;; Copyright © 2016 Raimon Grau -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 John Darrington ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Nicolas Goaziou ;;; Copyright © 2016 Eric Bavier @@ -1581,7 +1581,7 @@ application stack itself.") (define-public httpstat (package (name "httpstat") - (version "1.3.0") + (version "1.3.1") (source (origin (method git-fetch) @@ -1590,8 +1590,7 @@ application stack itself.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 - "18k2glnyzxlmry19ijmndim2vqqn3c86smd7xc3haw6k7qafifx1")))) + (base32 "0cw8299a080m42slsimz31xs0gjnh833gpbj2dsr4hkcinrn4iyd")))) (build-system python-build-system) (inputs `(("curl" ,curl))) (arguments -- cgit v1.2.3 From 1da9de511bbd2dc335ec619dfae4e189c44d80d5 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 00:07:26 +0100 Subject: gnu: notmuch: Update to 0.31.3. * gnu/packages/mail.scm (notmuch): Update to 0.31.3. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 977222a70e..7a634403d4 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1249,14 +1249,14 @@ invoking @command{notifymuch} from the post-new hook.") (define-public notmuch (package (name "notmuch") - (version "0.31.2") + (version "0.31.3") (source (origin (method url-fetch) (uri (string-append "https://notmuchmail.org/releases/notmuch-" version ".tar.xz")) (sha256 (base32 - "1vzv9imd0ba51y5zw8h358wikm1fh52rlvvyzvp98w330hzbcmhl")))) + "1jisflxdly1nlyy17212ch3hk96dns4j9f5552jz724gs2p42h28")))) (build-system gnu-build-system) (arguments `(#:modules ((guix build gnu-build-system) -- cgit v1.2.3 From eba2c6a5ed9753b67425a3174544b4e784f0054d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 00:08:02 +0100 Subject: gnu: font-liberation: Update to 2.1.2. * gnu/packages/fonts.scm (font-liberation): Update to 2.1.2. --- gnu/packages/fonts.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 92b55f57f8..35646a7728 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -314,14 +314,14 @@ The Lato 2.010 family supports more than 100 Latin-based languages, over (define-public font-liberation (package (name "font-liberation") - (version "2.1.1") + (version "2.1.2") (source (origin (method url-fetch) (uri (string-append "https://github.com/liberationfonts/liberation-fonts/" - "files/4743886/liberation-fonts-ttf-" version ".tar.gz")) + "files/5722233/liberation-fonts-ttf-" version ".tar.gz")) (sha256 - (base32 "1jkg8j8jx7ffj13z5ilw7dids99dyypljm1pv06ycmghw1pw3qlf")))) + (base32 "1q7qx9bpn1gqjh1zbb8n9fkzwz8skn41hyy61186g4c3y8q4js8l")))) (build-system font-build-system) (home-page "https://github.com/liberationfonts") (synopsis "Fonts compatible with Arial, Times New Roman, and Courier New") -- cgit v1.2.3 From 64fc78c8884f1d8ea3650809deddf4346e86be59 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 00:47:50 +0100 Subject: gnu: dash: Update to 0.5.11.3. * gnu/packages/shells.scm (dash): Update to 0.5.11.3. --- gnu/packages/shells.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm index 5b3ae21e0d..0b4edbe452 100644 --- a/gnu/packages/shells.scm +++ b/gnu/packages/shells.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2014, 2015 David Thompson ;;; Copyright © 2014 Kevin Lemonnier ;;; Copyright © 2015 Jeff Mickey -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 Stefan Reichör ;;; Copyright © 2017, 2018 Ricardo Wurmus ;;; Copyright © 2017, 2018 Nikita @@ -65,14 +65,14 @@ (define-public dash (package (name "dash") - (version "0.5.11.2") + (version "0.5.11.3") (source (origin (method url-fetch) (uri (string-append "http://gondor.apana.org.au/~herbert/dash/files/" "dash-" version ".tar.gz")) (sha256 - (base32 "0pvdpm1cgfbc25ramn4305a0158yq031q1ain4dc972rnxl7vyq0")) + (base32 "0amwphfal2rnfa63f7qd4i9m4ckv0gm3j6jlxkmfi9x6ddkz3fb2")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 434f378dff3ac0d51f3f81d93d7157ffbfecbdb2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 01:08:08 +0100 Subject: gnu: you-get: Update to 0.4.1500. * gnu/packages/video.scm (you-get): Update to 0.4.1500. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index d171c4a185..28cde06f04 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -2379,7 +2379,7 @@ other site that youtube-dl supports.") (define-public you-get (package (name "you-get") - (version "0.4.1488") + (version "0.4.1500") (source (origin (method git-fetch) (uri (git-reference @@ -2388,7 +2388,7 @@ other site that youtube-dl supports.") (file-name (git-file-name name version)) (sha256 (base32 - "10dx1gka92m42f8ah1mzylbd71apzrphfa48r5ci7g1j8ysdcs7q")))) + "02wkmq6bjg9iz0kccsgs192aiky99l2jnw1xs6zjhvjvq7jyvf7s")))) (build-system python-build-system) (inputs `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos -- cgit v1.2.3 From 405220916ae8ab4ec8f34adee9b9e09407071fe6 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 03:07:05 +0100 Subject: gnu: font-jetbrains-mono: Update to 2.221. * gnu/packages/fonts.scm (font-jetbrains-mono): Update to 2.221. --- gnu/packages/fonts.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 35646a7728..11a8e6261b 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -1787,7 +1787,7 @@ This package provides the TrueType fonts.") (define-public font-jetbrains-mono (package (name "font-jetbrains-mono") - (version "2.210") + (version "2.221") (source (origin (method url-fetch) @@ -1795,7 +1795,7 @@ This package provides the TrueType fonts.") (string-append "https://github.com/JetBrains/JetBrainsMono/releases/" "download/v" version "/JetBrainsMono-" version ".zip")) (sha256 - (base32 "19wbggnmqs3k1wdqy7l7imnx23g7hh159pl32nz3mzz8s8sqfdix")))) + (base32 "1acrgv2q9vxviirpi01xy67pkkswyssw4dn5pgyvrnjxr85cgjrg")))) (build-system font-build-system) (arguments `(#:phases -- cgit v1.2.3 From e9aaa2fbe08c20f1bc18f5b982fad32c17c488c5 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 03:42:05 +0100 Subject: gnu: freeciv: Update to 2.6.3. * gnu/packages/games.scm (freeciv): Update to 2.6.3. --- gnu/packages/games.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index d1a076e091..a0390c6937 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -5571,7 +5571,7 @@ for Un*x systems with X11.") (define-public freeciv (package (name "freeciv") - (version "2.6.2.1") + (version "2.6.3") (source (origin (method url-fetch) @@ -5583,7 +5583,7 @@ for Un*x systems with X11.") (version-major+minor version) "/" version "/freeciv-" version ".tar.bz2"))) (sha256 - (base32 "0pjqnwpxsirhyf5c4f1b9gxkqah0213wqaynklq84mahq41sq15x")))) + (base32 "1lgq7wcbhwpy2yqdw4biwfmp5q8fh7lhlwxcgm0fpaapfl12whvp")))) (build-system gnu-build-system) (inputs `(("curl" ,curl) -- cgit v1.2.3 From 0ad41c3246a478aa69f7f3439e8685caecc9ed26 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 03:42:28 +0100 Subject: gnu: stellarium: Update to 0.20.4. * gnu/packages/astronomy.scm (stellarium): Update to 0.20.4. --- gnu/packages/astronomy.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 18ed96f7fd..9485fe600f 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016 John Darrington -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2019 by Amar Singh ;;; Copyright © 2020 R Veera Kumar @@ -159,7 +159,7 @@ programs for the manipulation and analysis of astronomical data.") (define-public stellarium (package (name "stellarium") - (version "0.20.3") + (version "0.20.4") (source (origin (method url-fetch) @@ -167,7 +167,7 @@ programs for the manipulation and analysis of astronomical data.") "/releases/download/v" version "/stellarium-" version ".tar.gz")) (sha256 - (base32 "0z5r7b1ac43l330xphxnw54xg7jm87ajix8yl4hkq82cs5ja7097")))) + (base32 "1253zlr0mi4kdbj119spxk7spg4rkahb4rlpd0hz1d81mnv3n0v3")))) (build-system cmake-build-system) (inputs `(("qtbase" ,qtbase) -- cgit v1.2.3 From 7d0e111e272dc9f337f8907310f561e22a3ef329 Mon Sep 17 00:00:00 2001 From: Matthew Kraai Date: Sun, 6 Dec 2020 16:03:09 -0800 Subject: gnu: Add Rust 1.47. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/rust.scm (rust-1.47): New variable. Signed-off-by: Jakub Kądziołka --- gnu/packages/rust.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 91b5d6b6ec..3c09f09edd 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -10,6 +10,7 @@ ;;; Copyright © 2019 Ivan Petkov ;;; Copyright © 2020 Jakub Kądziołka ;;; Copyright © 2020 Pierre Langlois +;;; Copyright © 2020 Matthew Kraai ;;; ;;; This file is part of GNU Guix. ;;; @@ -1319,5 +1320,42 @@ move around." (rust-bootstrapped-package rust-1.45 "1.46.0" "0a17jby2pd050s24cy4dfc0gzvgcl585v3vvyfilniyvjrqknsid")) +(define-public rust-1.47 + (let ((base-rust + (rust-bootstrapped-package rust-1.46 "1.47.0" + "07fqd2vp7cf1ka3hr207dnnz93ymxml4935vp74g4is79h3dz19i"))) + (package + (inherit base-rust) + (inputs + (alist-replace "llvm" (list llvm-11) + (package-inputs base-rust))) + (arguments + (substitute-keyword-arguments (package-arguments base-rust) + ((#:phases phases) + `(modify-phases ,phases + ;; The source code got rearranged: libstd is now in the newly created library folder. + (replace 'patch-tests + (lambda* (#:key inputs #:allow-other-keys) + (let ((bash (assoc-ref inputs "bash"))) + (substitute* "library/std/src/process.rs" + (("\"/bin/sh\"") (string-append "\"" bash "/bin/sh\""))) + ;; + (substitute* "library/std/src/sys/unix/process/process_common.rs" + (("fn test_process_mask") "#[allow(unused_attributes)] + #[ignore] + fn test_process_mask")) + #t))) + (delete 'patch-cargo-checksums) + (add-after 'patch-generated-file-shebangs 'patch-cargo-checksums + ;; Generate checksums after patching generated files (in + ;; particular, vendor/jemalloc/rep/Makefile). + (lambda* _ + (use-modules (guix build cargo-utils)) + (substitute* "Cargo.lock" + (("(checksum = )\".*\"" all name) + (string-append name "\"" ,%cargo-reference-hash "\""))) + (generate-all-checksums "vendor") + #t))))))))) + ;; TODO(staging): Bump this variable to the latest packaged rust. (define-public rust rust-1.45) -- cgit v1.2.3 From 402e697a1144788102b16ca8c9ea74607d2c2c3c Mon Sep 17 00:00:00 2001 From: Matthew Kraai Date: Mon, 7 Dec 2020 14:47:39 -0800 Subject: gnu: Add Rust 1.48. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/rust.scm (rust-1.48): New variable. Signed-off-by: Jakub Kądziołka --- gnu/packages/patches/rust-1.48-linker-locale.patch | 14 +++++++++++ gnu/packages/rust.scm | 28 ++++++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 gnu/packages/patches/rust-1.48-linker-locale.patch diff --git a/gnu/packages/patches/rust-1.48-linker-locale.patch b/gnu/packages/patches/rust-1.48-linker-locale.patch new file mode 100644 index 0000000000..d06dcbe682 --- /dev/null +++ b/gnu/packages/patches/rust-1.48-linker-locale.patch @@ -0,0 +1,14 @@ +https://github.com/rust-lang/rust/pull/74416 +diff --git a/compiler/rustc_codegen_ssa/src/back/linker.rs b/compiler/rustc_codegen_ssa/src/back/linker.rs +index 3df956c465e..f45fee45be4 100644 +--- a/compiler/rustc_codegen_ssa/src/back/linker.rs ++++ b/compiler/rustc_codegen_ssa/src/back/linker.rs +@@ -28,7 +28,7 @@ + pub fn disable_localization(linker: &mut Command) { + // No harm in setting both env vars simultaneously. + // Unix-style linkers. +- linker.env("LC_ALL", "C"); ++ linker.env("LC_ALL", "en_US.UTF-8"); + // MSVC's `link.exe`. + linker.env("VSLANG", "1033"); + } diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 3c09f09edd..334c2621dc 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -1357,5 +1357,33 @@ move around." (generate-all-checksums "vendor") #t))))))))) +(define-public rust-1.48 + (let ((base-rust + (rust-bootstrapped-package rust-1.47 "1.48.0" + "0fz4gbb5hp5qalrl9lcl8yw4kk7ai7wx511jb28nypbxninkwxhf"))) + (package + (inherit base-rust) + (source + (origin + (inherit (package-source base-rust)) + ;; New patch required due to the second part of the source code rearrangement: + ;; the relevant source code is now in the compiler directory. + (patches (search-patches "rust-1.48-linker-locale.patch")))) + (arguments + (substitute-keyword-arguments (package-arguments base-rust) + ((#:phases phases) + `(modify-phases ,phases + ;; Some tests got split out into separate files. + (replace 'patch-tests + (lambda* (#:key inputs #:allow-other-keys) + (let ((bash (assoc-ref inputs "bash"))) + (substitute* "library/std/src/process/tests.rs" + (("\"/bin/sh\"") (string-append "\"" bash "/bin/sh\""))) + (substitute* "library/std/src/sys/unix/process/process_common/tests.rs" + (("fn test_process_mask") "#[allow(unused_attributes)] + #[ignore] + fn test_process_mask")) + #t)))))))))) + ;; TODO(staging): Bump this variable to the latest packaged rust. (define-public rust rust-1.45) -- cgit v1.2.3 From 062854de7fb6c0cc60fe84b91fbdd6b8795923d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20K=C4=85dzio=C5=82ka?= Date: Sat, 2 Jan 2021 19:11:27 +0100 Subject: gnu: Add Rust 1.49. * gnu/packages/rust.scm (rust-1.49): New variable. --- gnu/packages/rust.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 334c2621dc..58a9092ac4 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2018 Danny Milosavljevic ;;; Copyright © 2019 Ivan Petkov -;;; Copyright © 2020 Jakub Kądziołka +;;; Copyright © 2020, 2021 Jakub Kądziołka ;;; Copyright © 2020 Pierre Langlois ;;; Copyright © 2020 Matthew Kraai ;;; @@ -1385,5 +1385,9 @@ move around." fn test_process_mask")) #t)))))))))) +(define-public rust-1.49 + (rust-bootstrapped-package rust-1.48 "1.49.0" + "0yf7kll517398dgqsr7m3gldzj0iwsp3ggzxrayckpqzvylfy2mm")) + ;; TODO(staging): Bump this variable to the latest packaged rust. (define-public rust rust-1.45) -- cgit v1.2.3 From b252db39ef982d763738f692dccb806b1673b99a Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 20:33:19 +0200 Subject: gnu: gsasl: Update to 1.10.0. * gnu/packages/gsasl.scm (gsasl): Update to 1.10.0. --- gnu/packages/gsasl.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/gsasl.scm b/gnu/packages/gsasl.scm index 32ffbfa174..d2aba5450d 100644 --- a/gnu/packages/gsasl.scm +++ b/gnu/packages/gsasl.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2017 Ricardo Wurmus ;;; Copyright © 2017 Eric Bavier ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice -;;; Copyright © 2020 Efraim Flashner +;;; Copyright © 2020, 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -79,14 +79,14 @@ the underlying security implementation.") (define-public gsasl (package (name "gsasl") - (version "1.8.1") + (version "1.10.0") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/gsasl/gsasl-" version ".tar.gz")) (sha256 (base32 - "1lnqfbaajkj1r2fx1db1qgcxy69pfgbyq7xd2kpvyxhra4m1dnjd")))) + "1lv8fp01aq4jjia9g4vkx90zacl8rgmjhfi6f1wdwnh9ws7bvg45")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--with-gssapi-impl=mit" -- cgit v1.2.3 From 143a4f03db70e24de2559020441e72e74815d0f1 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 20:40:16 +0200 Subject: gnu: libinfinity: Update to 0.7.2. * gnu/packages/gobby.scm (libinfinity): Update to 0.7.2. --- gnu/packages/gobby.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gobby.scm b/gnu/packages/gobby.scm index 91484c7576..91cf7a2a29 100644 --- a/gnu/packages/gobby.scm +++ b/gnu/packages/gobby.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016, 2017 Andy Wingo ;;; Copyright © 2017, 2019 Arun Isaac +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -177,7 +178,7 @@ together over the internet in real-time.") (define-public libinfinity (package (name "libinfinity") - (version "0.7.1") + (version "0.7.2") (source (origin (method url-fetch) @@ -185,7 +186,7 @@ together over the internet in real-time.") version ".tar.gz")) (sha256 (base32 - "1jw2fhrcbpyz99bij07iyhy9ffyqdn87vl8cb1qz897y3f2f0vk2")))) + "17i3g61hxz9pzl3ryd1yr15142r25m06jfzjrpdy7ic1b8vjjw3f")))) (build-system gnu-build-system) (inputs `(("glib" ,glib) -- cgit v1.2.3 From f39ee7334a727dc3deff236699e30f9ee12ed913 Mon Sep 17 00:00:00 2001 From: Zheng Junjie <873216071@qq.com> Date: Fri, 25 Dec 2020 13:56:16 +0800 Subject: gnu: Add python-pdftotext. * gnu/packages/python-xyz.scm (python-pdftotext): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 818a244378..5e138fc832 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -93,6 +93,7 @@ ;;; Copyright © 2020 Diego N. Barbato ;;; Copyright © 2020 Leo Prikler ;;; Copyright © 2019 Kristian Trandem +;;; Copyright © 2020 Zheng Junjie <873216071@qq.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -158,6 +159,7 @@ #:use-module (gnu packages ncurses) #:use-module (gnu packages openstack) #:use-module (gnu packages pcre) + #:use-module (gnu packages pdf) #:use-module (gnu packages perl) #:use-module (gnu packages photo) #:use-module (gnu packages pkg-config) @@ -4901,6 +4903,25 @@ algorithm. Patiencediff provides a good balance of performance, nice output for humans, and implementation simplicity.") (license license:gpl2))) +(define-public python-pdftotext + (package + (name "python-pdftotext") + (version "2.1.5") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pdftotext" version)) + (sha256 + (base32 + "19la1cw1hmkcr8big04gm2dd5fw0y0z97g930aiy29s1gaqbiblq")))) + (build-system python-build-system) + (inputs + `(("poppler" ,poppler))) + (home-page "https://github.com/jalan/pdftotext") + (synopsis "Simple PDF text extraction") + (description "Pdftotext is a Python library of PDF text extraction.") + (license license:expat))) + (define-public python-pyparsing (package (name "python-pyparsing") -- cgit v1.2.3 From c389899d83ee8e43c66e6e468483389a865a716b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 20:48:50 +0200 Subject: gnu: Register missing patch. This is a follow-up to 402e697a1144788102b16ca8c9ea74607d2c2c3c. * gnu/local.mk (dist_patch_DATA): Register rust-1.48 patch. --- gnu/local.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/gnu/local.mk b/gnu/local.mk index 2402b1e349..c03a8b9f51 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1595,6 +1595,7 @@ dist_patch_DATA = \ %D%/packages/patches/rust-1.19-mrustc.patch \ %D%/packages/patches/rust-1.25-accept-more-detailed-gdb-lines.patch \ %D%/packages/patches/rust-1.45-linker-locale.patch \ + %D%/packages/patches/rust-1.48-linker-locale.patch \ %D%/packages/patches/rust-bootstrap-stage0-test.patch \ %D%/packages/patches/rust-coresimd-doctest.patch \ %D%/packages/patches/rust-ndarray-remove-blas-src-dep.patch \ -- cgit v1.2.3 From 28f15b985fde85b06858157ccacd04abfc8c9e96 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 2 Jan 2021 21:12:18 +0100 Subject: gnu: giac: Update to 1.6.0-41. * gnu/packages/algebra.scm (giac): Update to 1.6.0-41. --- gnu/packages/algebra.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/algebra.scm b/gnu/packages/algebra.scm index a5eef508cd..214878949e 100644 --- a/gnu/packages/algebra.scm +++ b/gnu/packages/algebra.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Andreas Enge ;;; Copyright © 2013, 2015, 2017, 2018 Ludovic Courtès -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Nicolas Goaziou +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Nicolas Goaziou ;;; Copyright © 2014, 2018 Mark H Weaver ;;; Copyright © 2016, 2018, 2019 Ricardo Wurmus ;;; Copyright © 2017, 2020 Efraim Flashner @@ -355,7 +355,7 @@ precision.") (define-public giac (package (name "giac") - (version "1.6.0-31") + (version "1.6.0-41") (source (origin (method url-fetch) @@ -367,7 +367,7 @@ precision.") "~parisse/debian/dists/stable/main/source/" "giac_" version ".tar.gz")) (sha256 - (base32 "1dr1y88sx2gzldn0zl6p8b1ngjjcmh89iv4kzyhi2cf74j3yw85m")))) + (base32 "1z5b3jm6ffxk3yvdqzwn9icbna68brkrz5kspgacq823d03jfklc")))) (build-system gnu-build-system) (arguments `(#:modules ((ice-9 ftw) -- cgit v1.2.3 From 2bb3cedac746c344f5089ba69d8766431a381e83 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 2 Jan 2021 21:26:38 +0100 Subject: gnu: python-libnacl: Update to 1.7.2. * gnu/packages/python-crypto.scm (python-libnacl): Update to 1.7.2. [arguments]: Fix phase locating libsodium.so. --- gnu/packages/python-crypto.scm | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index 6f3dbbf9f2..bfc6614c6b 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -1212,14 +1212,14 @@ none of them have everything that I'd like, so here's one more. It uses (define-public python-libnacl (package (name "python-libnacl") - (version "1.6.1") + (version "1.7.2") (source (origin (method url-fetch) (uri (pypi-uri "libnacl" version)) (sha256 (base32 - "0nv7n8nfswkhl614x5mllrkvaslraa0053q11iylb337cy43vb4v")))) + "0srx7i264v4dq9and8y6gpzzhrg8jpxs5iy9ggw4plimfj0rjfdm")))) (build-system python-build-system) (arguments `(#:phases @@ -1227,11 +1227,10 @@ none of them have everything that I'd like, so here's one more. It uses (add-after 'unpack 'locate-libsodium (lambda* (#:key inputs #:allow-other-keys) (substitute* "libnacl/__init__.py" - (("(return ctypes.cdll.LoadLibrary\\(')libsodium.so('\\))" - _ pre post) - (let ((libsodium (string-append (assoc-ref inputs "libsodium") - "/lib/libsodium.so"))) - (string-append pre libsodium post))))))))) + (("/usr/local/lib/libsodium.so") + (string-append (assoc-ref inputs "libsodium") + "/lib/libsodium.so"))) + #t))))) (native-inputs `(("python-pyhamcrest" ,python-pyhamcrest))) (inputs -- cgit v1.2.3 From ee375d1cf2960a48b7e71b5cc6ff5a7b6d7c9ef0 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 2 Jan 2021 21:28:19 +0100 Subject: gnu: Update a copyright line. * gnu/packages/python-crypto.scm: Update copyright line. --- gnu/packages/python-crypto.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/python-crypto.scm b/gnu/packages/python-crypto.scm index bfc6614c6b..486cc48457 100644 --- a/gnu/packages/python-crypto.scm +++ b/gnu/packages/python-crypto.scm @@ -16,7 +16,7 @@ ;;; Copyright © 2016, 2017, 2020 Arun Isaac ;;; Copyright © 2017 Carlo Zancanaro ;;; Copyright © 2018 Tomáš Čech -;;; Copyright © 2018 Nicolas Goaziou +;;; Copyright © 2018, 2021 Nicolas Goaziou ;;; Copyright © 2018 Vagrant Cascadian ;;; Copyright © 2018 Nam Nguyen ;;; Copyright © 2019 Guillaume Le Vaillant -- cgit v1.2.3 From 8f93628100fe5e31d4beed049df8e960b11637ed Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 2 Jan 2021 21:31:21 +0100 Subject: gnu: python-graphql-core: Update to 3.1.2. * gnu/packages/python-xyz.scm (python-graphql-core): Update to 3.1.2. --- gnu/packages/python-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 5e138fc832..0ac95deb1d 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -50,7 +50,7 @@ ;;; Copyright © 2018 Mathieu Lirzin ;;; Copyright © 2018 Adam Massmann ;;; Copyright © 2016, 2018 Tomáš Čech -;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou +;;; Copyright © 2018, 2019, 2020, 2021 Nicolas Goaziou ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2018, 2019 Clément Lassieur ;;; Copyright © 2018, 2019, 2020 Maxim Cournoyer @@ -14165,14 +14165,14 @@ monitors CPU, load, memory, network bandwidth, disk I/O, disk use, and more.") (define-public python-graphql-core (package (name "python-graphql-core") - (version "0.5.3") + (version "3.1.2") (source (origin (method url-fetch) (uri (pypi-uri "graphql-core" version)) (sha256 (base32 - "0rsaarx2sj4xnw9966rhh4haiqaapm4lm2mfqm48ywd51j5vh1a0")))) + "0fjv5w2wvgdr8gb27v241bavliipyir9fdz48rsgc3xapm644mn0")))) (build-system python-build-system) (arguments `(#:tests? #f ; Tests require the unpackaged pytest-benchmark. -- cgit v1.2.3 From 461d81727a554be16a86fe436fca0aab802cedb5 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 2 Jan 2021 21:55:51 +0100 Subject: gnu: python-attrs: Update to 20.3.0. * gnu/packages/python-xyz.scm (python-attrs): Update to 20.3.0. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0ac95deb1d..0288feb343 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15224,13 +15224,13 @@ and bit flag values.") (define-public python-attrs (package (name "python-attrs") - (version "19.3.0") + (version "20.3.0") (source (origin (method url-fetch) (uri (pypi-uri "attrs" version)) (sha256 (base32 - "0wky4h28n7xnr6xv69p9z6kv8bzn50d10c3drmd9ds8gawbcxdzp")))) + "007pchhxk2nh6m2rgflkkij9xjwysq3fl7xr72cy8i4pw76s6al3")))) (build-system python-build-system) (arguments `(#:modules ((guix build utils) -- cgit v1.2.3 From 1f7af04e3de747c256591b4938df251f76e8a670 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sat, 2 Jan 2021 20:52:52 +0000 Subject: gnu: guix-build-coordinator: Update to 0-13.3a921d4. * gnu/packages/package-management.scm (guix-build-coordinator): Update to 0-13.3a921d4. (arguments): Remove nproc directory from the $PATH. --- gnu/packages/package-management.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 20a331f391..898f0a1db7 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -1028,8 +1028,8 @@ environments.") (license (list license:gpl3+ license:agpl3+ license:silofl1.1)))) (define-public guix-build-coordinator - (let ((commit "c33d3f570bd32afc2def410067db6b92ad6aff0a") - (revision "12")) + (let ((commit "3a921d472ebad0600e58abdc8808125771dfc309") + (revision "13")) (package (name "guix-build-coordinator") (version (git-version "0" revision commit)) @@ -1040,7 +1040,7 @@ environments.") (commit commit))) (sha256 (base32 - "01mr211s1nb9hhm6784ibp87g59wifajcclbss3ry7i3qsbvg22j")) + "0bs1rwab7b3d14xr9spqzy54xbfga72aabqz35swb1whi83jz4ch")) (file-name (string-append name "-" version "-checkout")))) (build-system gnu-build-system) (arguments @@ -1070,7 +1070,6 @@ environments.") (wrap-program file `("PATH" ":" prefix (,bin - ,(dirname (which "nproc")) ; used by the agent ;; Support building without sqitch as an input, as it ;; can't be cross-compiled yet ,@(or (and=> (assoc-ref inputs "sqitch") -- cgit v1.2.3 From d3f96ad32296f0da42862b52be7db69f93a5f906 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sat, 2 Jan 2021 21:02:57 +0000 Subject: gnu: guix-data-service: Update to 0.0.1-22.bd83906. This fixes some breakages with the "" -> #f change with NULL values in squee, at least enough to get the package building again. * gnu/packages/web.scm (guix-data-service): Update to 0.0.1-22.bd83906. --- gnu/packages/web.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index d972e21425..46b1c4df5e 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -4643,8 +4643,8 @@ CDF, Atom 0.3, and Atom 1.0 feeds.") (package-with-python2 python-feedparser)) (define-public guix-data-service - (let ((commit "c596a1c6a90bb2fe07da5339b8dc832b81d94194") - (revision "21")) + (let ((commit "bd8390673e073a4d66082e48120cc3c86a255fc8") + (revision "22")) (package (name "guix-data-service") (version (string-append "0.0.1-" revision "." (string-take commit 7))) @@ -4656,7 +4656,7 @@ CDF, Atom 0.3, and Atom 1.0 feeds.") (file-name (git-file-name name version)) (sha256 (base32 - "09gn2imhh3aqkzray0xgkz7slriy567inh5lpkxm74bgmx862g3g")))) + "11kkm3qn1zsri5sz8gwcrcbypa55fj3m0srd9snfrhiadv4sn211")))) (build-system gnu-build-system) (arguments '(#:modules ((guix build utils) -- cgit v1.2.3 From 20d2e1abe85457d1357da0395a67b66c326c9711 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 15:17:37 +0100 Subject: gnu: crypto++: Update to 8.3.0. * gnu/packages/crypto.scm (crypto++): Update to 8.3.0. Signed-off-by: Efraim Flashner --- gnu/packages/crypto.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index 399bc6440f..8226497b81 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -717,7 +717,7 @@ data on your platform, so the seed itself will be as random as possible. (define-public crypto++ (package (name "crypto++") - (version "8.2.0") + (version "8.3.0") (source (origin (method url-fetch/zipbomb) (uri (string-append "https://cryptopp.com/cryptopp" @@ -725,7 +725,7 @@ data on your platform, so the seed itself will be as random as possible. ".zip")) (sha256 (base32 - "0n40hlz5jkvlcp9vxrj0fsrcfp7dm0zmmv6h52dx3f8i5qjf5w03")))) + "16jqxvsyjjpyyb89fj2h8mgb0m07vlqvggifbrk7qcqwddda2f6v")))) (build-system gnu-build-system) (arguments `(#:make-flags -- cgit v1.2.3 From 809b06606c7be47685b8bdcb7d565732d66191d0 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 13:43:17 +0100 Subject: gnu: xen: Update to 4.14.1. * gnu/packages/virtualization.scm (xen): Update to 4.14.1. Signed-off-by: Efraim Flashner --- gnu/packages/virtualization.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index 99c37bc044..b723ae8881 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -1780,7 +1780,7 @@ DOS or Microsoft Windows.") (define-public xen (package (name "xen") - (version "4.14.0") + (version "4.14.1") (source (origin (method git-fetch) (uri (git-reference @@ -1789,7 +1789,7 @@ DOS or Microsoft Windows.") (file-name (git-file-name name version)) (sha256 (base32 - "1s06zhzmkm7wylrxhas5v0sg2ackmmyw01gvv67r9idml55i0dh5")))) + "1r90rvypw76ya9clqw5p02gm1k8hxz73f7gr95ca778nnzvb7xjw")))) (build-system gnu-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 20dda76dfa6a5dbaae8df7646b5a78edde1fd6c4 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sat, 2 Jan 2021 23:43:30 +0200 Subject: Revert "gnu: python-attrs: Update to 20.3.0." python-attrs-bootstrap causes the rebuild of 6000+ packages. This reverts commit 461d81727a554be16a86fe436fca0aab802cedb5. --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0288feb343..0ac95deb1d 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -15224,13 +15224,13 @@ and bit flag values.") (define-public python-attrs (package (name "python-attrs") - (version "20.3.0") + (version "19.3.0") (source (origin (method url-fetch) (uri (pypi-uri "attrs" version)) (sha256 (base32 - "007pchhxk2nh6m2rgflkkij9xjwysq3fl7xr72cy8i4pw76s6al3")))) + "0wky4h28n7xnr6xv69p9z6kv8bzn50d10c3drmd9ds8gawbcxdzp")))) (build-system python-build-system) (arguments `(#:modules ((guix build utils) -- cgit v1.2.3 From c369e032ad9cfc4531c990593ef24c6a23f91029 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:11:05 +0100 Subject: gnu: graphicsmagick: Update to 1.3.36. * gnu/packages/imagemagick.scm (graphicsmagick): Update to 1.3.36. Signed-off-by: Efraim Flashner --- gnu/packages/imagemagick.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/imagemagick.scm b/gnu/packages/imagemagick.scm index a624d7bc6a..6afa67abbb 100644 --- a/gnu/packages/imagemagick.scm +++ b/gnu/packages/imagemagick.scm @@ -189,7 +189,7 @@ script.") (define-public graphicsmagick (package (name "graphicsmagick") - (version "1.3.35") + (version "1.3.36") (source (origin (method url-fetch) @@ -202,7 +202,7 @@ script.") "/GraphicsMagick-" version ".tar.xz"))) (sha256 (base32 - "0l024l4hawm9s3jqrgi2j0lxgm61dqh8sgkj1017ma7y11hqv2hq")))) + "0ilg6fkppb4avzais1dvi3qf6ln7v3mzj7gjm83w7pwwfpg3ynsx")))) (build-system gnu-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 18a342bef42510ebbcb9c2eb3fd6e07efbcabb7a Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 12:16:36 +0100 Subject: gnu: icu4c: Update to 68.2. * gnu/packages/icu4c.scm (icu4c): Update to 68.2. Signed-off-by: Efraim Flashner --- gnu/packages/icu4c.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/icu4c.scm b/gnu/packages/icu4c.scm index 952bb96fd9..bf98fc3a40 100644 --- a/gnu/packages/icu4c.scm +++ b/gnu/packages/icu4c.scm @@ -117,7 +117,7 @@ C/C++ part.") (define-public icu4c-68 (package (inherit icu4c) - (version "68.1") + (version "68.2") (source (origin (method url-fetch) (uri (string-append @@ -128,7 +128,7 @@ C/C++ part.") "-src.tgz")) (sha256 (base32 - "0bcznbxvdvxbfsiv3qj2f2f1rrbf3syhhhwbhx9qwjs3nkcf7wm9")))))) + "09fng7a80xj8d5r1cgbgq8r47dsw5jsr6si9p2cj2ylhwgg974f7")))))) (define-public icu4c-build-root (package -- cgit v1.2.3 From 395489cdc959c3f3c026bf545c3ed95efc9919f0 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 13:13:10 +0100 Subject: gnu: spice-vdagent: Update to 0.20.0. * gnu/packages/spice.scm (spice-vdagent): Update to 0.20.0. [inputs]: Add libdrm. Signed-off-by: Efraim Flashner --- gnu/packages/spice.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/spice.scm b/gnu/packages/spice.scm index 6de99aec86..92aeef7f79 100644 --- a/gnu/packages/spice.scm +++ b/gnu/packages/spice.scm @@ -261,7 +261,7 @@ Internet and from a wide variety of machine architectures.") (define-public spice-vdagent (package (name "spice-vdagent") - (version "0.17.0") + (version "0.20.0") (source (origin (method url-fetch) (uri (string-append @@ -269,7 +269,7 @@ Internet and from a wide variety of machine architectures.") "spice-vdagent-" version ".tar.bz2")) (sha256 (base32 - "0gdkyylyg1hksg0i0anvznqfli2q39335fnrmcd6847frpc8njpi")))) + "0n9k2kna2gd1zi6jv45zsp2jlv439nz5l5jjijirxqaycwi74srf")))) (build-system gnu-build-system) (arguments `(#:configure-flags @@ -294,6 +294,7 @@ Internet and from a wide variety of machine architectures.") `(("alsa-lib" ,alsa-lib) ("dbus" ,dbus) ("glib" ,glib) + ("libdrm" ,libdrm) ("libpciaccess" ,libpciaccess) ("libx11" ,libx11) ("libxext" ,libxext) -- cgit v1.2.3 From c3e6fcde54c4feb8dba65f5ef480f2b6d5d4caa1 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 06:31:49 +0100 Subject: gnu: wireguard-linux-compat: Update to 1.0.20201221. * gnu/packages/vpn.scm (wireguard-linux-compat): Update to 1.0.20201221. --- gnu/packages/vpn.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/vpn.scm b/gnu/packages/vpn.scm index 8b5da1316b..37555d9b45 100644 --- a/gnu/packages/vpn.scm +++ b/gnu/packages/vpn.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2015 Jeff Mickey ;;; Copyright © 2016, 2017, 2019 Efraim Flashner -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Julien Lepiller ;;; Copyright © 2018, 2020 Pierre Langlois ;;; Copyright © 2018 Meiyo Peng @@ -559,7 +559,7 @@ The peer-to-peer VPN implements a Layer 2 (Ethernet) network between the peers (define-public wireguard-linux-compat (package (name "wireguard-linux-compat") - (version "1.0.20201112") + (version "1.0.20201221") (source (origin (method url-fetch) (uri (string-append "https://git.zx2c4.com/wireguard-linux-compat/" @@ -567,7 +567,7 @@ The peer-to-peer VPN implements a Layer 2 (Ethernet) network between the peers ".tar.xz")) (sha256 (base32 - "1qcpg1rcmy4h529a0spjm50qgxjgjy20j29fpbrqsv5xq3qfgsl9")))) + "0ci13in0fqq32n5qamch4qhjgbdq86ygrgmfhc9szsh2nsl8jlkf")))) (build-system linux-module-build-system) (outputs '("out" "kernel-patch")) -- cgit v1.2.3 From 15bffa0cc2470ffc48d40fbc6320b5d5d786373c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 06:55:04 +0100 Subject: gnu: libshout: Update to 2.4.5. * gnu/packages/xiph.scm (libshout): Update to 2.4.5. --- gnu/packages/xiph.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/xiph.scm b/gnu/packages/xiph.scm index 2d80496330..4a3f25e009 100644 --- a/gnu/packages/xiph.scm +++ b/gnu/packages/xiph.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2015 Paul van der Walt ;;; Copyright © 2015, 2016, 2017, 2019 Efraim Flashner ;;; Copyright © 2017, 2018, 2019, 2020 Marius Bakke -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Leo Famulari ;;; Copyright © 2020 Vincent Legoll ;;; @@ -494,7 +494,7 @@ things in between.") (define-public libshout (package (name "libshout") - (version "2.4.4") + (version "2.4.5") (source (origin (method url-fetch) (uri (string-append @@ -502,7 +502,7 @@ things in between.") "libshout-" version ".tar.gz")) (sha256 (base32 - "1hz670a4pfpsb89b0mymy8nw4rx8x0vmh61gq6j1vbg70mfhrscc")))) + "1438da40y73y9068saxrbmm27qq6xqmmzsziwgmr8fb7i9k6irfr")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From 418de55836f28a96fb74b0cd16931e094fa814b3 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 01:36:44 +0100 Subject: gnu: gaupol: Update to 1.9. * gnu/packages/video.scm (gaupol): Update to 1.9. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 28cde06f04..5de3fc4a86 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -4510,7 +4510,7 @@ video from a Wayland session.") (define-public gaupol (package (name "gaupol") - (version "1.8") + (version "1.9") (source (origin (method git-fetch) (uri (git-reference @@ -4519,7 +4519,7 @@ video from a Wayland session.") (file-name (git-file-name name version)) (sha256 (base32 - "00wxdyja0m6l3yrynjgapa010lkwxpkv1xnnjbmrwi4ayhh5l3gg")))) + "1mmjg8nwhif2hmmp8i11643izwzdf839brqdai3ksfg0qkh8rnxk")))) (build-system python-build-system) (native-inputs `(("gettext" ,gettext-minimal) -- cgit v1.2.3 From cea9741b1648732922f3a9c0a4bc79ef3bada4e5 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Fri, 1 Jan 2021 18:32:31 +0100 Subject: gnu: libinfinity: Omit static libraries MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/gobby.scm (libinfinity)[arguments]: Add ‘--disable-static’ to #:configure-flags. --- gnu/packages/gobby.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/gobby.scm b/gnu/packages/gobby.scm index 91cf7a2a29..916324bff4 100644 --- a/gnu/packages/gobby.scm +++ b/gnu/packages/gobby.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2016, 2017 Andy Wingo ;;; Copyright © 2017, 2019 Arun Isaac ;;; Copyright © 2021 Efraim Flashner +;;; Copyright © 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -196,7 +197,8 @@ together over the internet in real-time.") (native-inputs `(("pkg-config" ,pkg-config))) (arguments - `(#:configure-flags (list "--with-inftextgtk" + `(#:configure-flags (list "--disable-static" + "--with-inftextgtk" "--with-infgtk"))) (home-page "https://gobby.github.io/") (synopsis "Infininote protocol implementation") -- cgit v1.2.3 From cc63996063a42d49e0d66907a5058612c85d48eb Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 05:45:25 +0100 Subject: gnu: libnet6: Omit static library. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/gobby.scm (libnet6)[arguments]: Add ‘--disable-static’ to #:configure-flags. --- gnu/packages/gobby.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/gobby.scm b/gnu/packages/gobby.scm index 916324bff4..a29c687158 100644 --- a/gnu/packages/gobby.scm +++ b/gnu/packages/gobby.scm @@ -49,7 +49,9 @@ (native-inputs `(("pkg-config" ,pkg-config))) (arguments - `(#:phases + `(#:configure-flags + (list "--disable-static") + #:phases (modify-phases %standard-phases (add-before 'configure 'update-gnutls-api (lambda _ -- cgit v1.2.3 From c2c954afb2df5b9926f52b5c14d0213827e3401f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 05:46:09 +0100 Subject: gnu: obby: Omit static library. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/gobby.scm (obby)[arguments]: Add ‘--disable-static’ to #:configure-flags. --- gnu/packages/gobby.scm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gnu/packages/gobby.scm b/gnu/packages/gobby.scm index a29c687158..0e1910d7ce 100644 --- a/gnu/packages/gobby.scm +++ b/gnu/packages/gobby.scm @@ -84,6 +84,9 @@ (base32 "0rwvp0kzsb8y6mq73rzb8yk4kvsrz64i2zf4lfqs3kh0x2k7n7bx")))) (build-system gnu-build-system) + (arguments + `(#:configure-flags + (list "--disable-static"))) (native-inputs `(("pkg-config" ,pkg-config))) (inputs -- cgit v1.2.3 From db2016572848a018fe5d5b0389c04494d422146c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 21:25:27 +0100 Subject: gnu: libressl: Update to 3.1.5 [security fix]. * gnu/packages/tls.scm (libressl): Update to 3.1.5. --- gnu/packages/tls.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index a7754fe649..8e438e3a54 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2016 Hartmut Goebel ;;; Copyright © 2017 Ricardo Wurmus ;;; Copyright © 2017, 2018, 2019, 2020 Marius Bakke -;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice +;;; Copyright © 2017–2019, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Rutger Helling ;;; Copyright © 2018 Clément Lassieur ;;; Copyright © 2019 Mathieu Othacehe @@ -553,18 +553,18 @@ required structures.") (define-public libressl (package (name "libressl") - (version "3.1.4") + (version "3.1.5") (source (origin (method url-fetch) (uri (string-append "mirror://openbsd/LibreSSL/" "libressl-" version ".tar.gz")) (sha256 (base32 - "1dnbbnr43jashxivnafmh9gnn57c7ayva788ba03z633k6f18k21")))) + "1504a1sf43frw43j14pij0q1f48rm5q86ggrlxxhw708qp7ds4rc")))) (build-system gnu-build-system) (arguments - ;; Do as if 'getentropy' was missing since older Linux kernels lack it - ;; and libc would return ENOSYS, which is not properly handled. + ;; Do as if 'getentropy' were missing: Linux kernels before 3.17 lack its + ;; underlying 'getrandom' system call and ENOSYS isn't properly handled. ;; See . '(#:configure-flags '("ac_cv_func_getentropy=no" ;; Provide a TLS-enabled netcat. -- cgit v1.2.3 From c15fee61eb630c15fdcf6e6639c32c931c59efbc Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 21:12:14 +0100 Subject: gnu: mame: Update to 0.227. * gnu/packages/emulators.scm (mame): Update to 0.227. --- gnu/packages/emulators.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm index 4543249015..1d94090f48 100644 --- a/gnu/packages/emulators.scm +++ b/gnu/packages/emulators.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2016 Manolis Fragkiskos Ragkousis ;;; Copyright © 2016, 2017, 2018, 2020 Efraim Flashner ;;; Copyright © 2017, 2018, 2019, 2020 Nicolas Goaziou -;;; Copyright © 2017, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017, 2020, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018, 2019 Rutger Helling ;;; Copyright © 2019 Pierre Neidhardt ;;; Copyright © 2019 David Wilson @@ -1552,7 +1552,7 @@ This is a part of the TiLP project.") (define-public mame (package (name "mame") - (version "0.226") + (version "0.227") (source (origin (method git-fetch) @@ -1561,7 +1561,7 @@ This is a part of the TiLP project.") (commit (apply string-append "mame" (string-split version #\.))))) (file-name (git-file-name name version)) (sha256 - (base32 "1yfns42rk1l0qprj5ksj9fqsgqpa23xnzxf29r4434p4n18bb77v")) + (base32 "0p7xhsahmkr5hh3j6hc1mpgi5z4navy77v4k35i0sgpdv1ax4y2l")) (modules '((guix build utils))) (snippet ;; Remove bundled libraries. -- cgit v1.2.3 From f4a809145feac0e3b07fc196b1c75638e8aec02e Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:19:32 +0100 Subject: gnu: geoclue: Update to 2.5.7. * gnu/packages/gnome.scm (geoclue): Update to 2.5.7. --- gnu/packages/gnome.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 6f9fc92246..3ee3a698fd 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -5157,7 +5157,7 @@ output devices.") (define-public geoclue (package (name "geoclue") - (version "2.5.6") + (version "2.5.7") (source (origin (method url-fetch) @@ -5165,7 +5165,7 @@ output devices.") (string-append "https://gitlab.freedesktop.org/geoclue/geoclue/-/archive/" version "/geoclue-" version ".tar.bz2")) (sha256 - (base32 "0a833x5apzabxj80ywvsh8crd635vni2i9v9c1p095f6hvmfc45k")) + (base32 "09ww26a76kanldhgwnn5sqy9ly2940k45zpp68spykkv2zjdpivc")) (patches (search-patches "geoclue-config.patch")))) (build-system meson-build-system) (arguments -- cgit v1.2.3 From a564ff1b61fb3061e0a66f74ae2518c07d8e2dc1 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:22:20 +0100 Subject: gnu: fetchmail: Update to 6.4.14. * gnu/packages/mail.scm (fetchmail): Update to 6.4.14. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 7a634403d4..84b6fa0e76 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -410,7 +410,7 @@ to run without any changes.") (define-public fetchmail (package (name "fetchmail") - (version "6.4.13") + (version "6.4.14") (source (origin (method url-fetch) @@ -418,7 +418,7 @@ to run without any changes.") (version-major+minor version) "/" "fetchmail-" version ".tar.xz")) (sha256 - (base32 "1qablzgwx3a516vdhckx3pv716x9r7nyfyr6fbncif861c3cya3x")))) + (base32 "1jxxb3qyrh7118fwqa3bhirjh97j2w8r71s8vcb6vp3w1wwhfis2")))) (build-system gnu-build-system) (inputs `(("openssl" ,openssl))) -- cgit v1.2.3 From dda16f7c62f882cd0e8997cffcbf51293e0800fe Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:23:35 +0100 Subject: gnu: zabbix-agentd: Update to 5.2.3. * gnu/packages/monitoring.scm (zabbix-agentd): Update to 5.2.3. --- gnu/packages/monitoring.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/monitoring.scm b/gnu/packages/monitoring.scm index 8cd113a092..9ba0e61952 100644 --- a/gnu/packages/monitoring.scm +++ b/gnu/packages/monitoring.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2016 Ludovic Courtès ;;; Copyright © 2018 Sou Bunnbu ;;; Copyright © 2017, 2018, 2019, 2020 Ricardo Wurmus -;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2020, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Gábor Boskovits ;;; Copyright © 2018, 2019, 2020 Oleg Pykhalov ;;; Copyright © 2020 Alex ter Weele @@ -158,7 +158,7 @@ etc. via a Web interface. Features include: (define-public zabbix-agentd (package (name "zabbix-agentd") - (version "5.2.2") + (version "5.2.3") (source (origin (method url-fetch) @@ -166,7 +166,7 @@ etc. via a Web interface. Features include: "https://cdn.zabbix.com/zabbix/sources/stable/" (version-major+minor version) "/zabbix-" version ".tar.gz")) (sha256 - (base32 "16sqx5hrqkciwnl6xs1b8mwf0fz7x9f4214jhj9s86w0mqiscw8g")))) + (base32 "0wlv3jala7xinl03fr6n0y3hmq9yi0wwn27k6snqhz4yyfdwhdnf")))) (build-system gnu-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 868e3088062a2c6e774e73a9e140bd38d1128a7d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:32:14 +0100 Subject: gnu: zabbix-agentd: Enable IPv6. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/monitoring.scm (zabbix-agentd)[arguments]: Add ‘--enable-ipv6’ to #:configure-flags. --- gnu/packages/monitoring.scm | 1 + 1 file changed, 1 insertion(+) diff --git a/gnu/packages/monitoring.scm b/gnu/packages/monitoring.scm index 9ba0e61952..adbd0447d0 100644 --- a/gnu/packages/monitoring.scm +++ b/gnu/packages/monitoring.scm @@ -171,6 +171,7 @@ etc. via a Web interface. Features include: (arguments `(#:configure-flags (list "--enable-agent" + "--enable-ipv6" (string-append "--with-iconv=" (assoc-ref %build-inputs "libiconv")) (string-append "--with-libpcre=" -- cgit v1.2.3 From dd8292df5f49f05014606dabbfd8934e4827d8d1 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:34:39 +0100 Subject: gnu: fldigi: Update to 4.1.17. * gnu/packages/radio.scm (fldigi): Update to 4.1.17. --- gnu/packages/radio.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/radio.scm b/gnu/packages/radio.scm index 70a9762379..0a4b623360 100644 --- a/gnu/packages/radio.scm +++ b/gnu/packages/radio.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2020 Guillaume Le Vaillant ;;; Copyright © 2020 Danny Milosavljevic ;;; Copyright © 2020 Charlie Ritter -;;; Copyright © 2020 Tobias Geerinckx-Rice +;;; Copyright © 2020, 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -577,14 +577,14 @@ using GNU Radio and the Qt GUI toolkit.") (define-public fldigi (package (name "fldigi") - (version "4.1.16") + (version "4.1.17") (source (origin (method url-fetch) (uri (string-append "http://www.w1hkj.com/files/fldigi/fldigi-" version ".tar.gz")) (sha256 - (base32 "1dfkvhs0ri5kbyskk730ik8ix5z138qys26b31p6kixd8jjkw3k4")))) + (base32 "1gzff60sn3h05279f9mdi1rkdws52m28shcil16911lvlq6ki13m")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From 78a9cfa33e66c5647cea66980d83f49a43e27f60 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 2 Jan 2021 20:59:45 +0100 Subject: gnu: perl-search-xapian: Update to 1.2.25.4. * gnu/packages/search.scm (perl-search-xapian): Update to 1.2.25.4. --- gnu/packages/search.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/search.scm b/gnu/packages/search.scm index 0a5fa38b30..8293d562b3 100644 --- a/gnu/packages/search.scm +++ b/gnu/packages/search.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2015, 2016 Eric Bavier ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017 Ricardo Wurmus -;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2020, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Adam Massmann ;;; ;;; This file is part of GNU Guix. @@ -116,15 +116,14 @@ rich set of boolean query operators.") (define-public perl-search-xapian (package (name "perl-search-xapian") - (version "1.2.25.2") + (version "1.2.25.4") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/O/OL/OLLY/" "Search-Xapian-" version ".tar.gz")) (sha256 - (base32 - "0hpa8gi38j0ibq8af6dy69lm1bl5jnq76nsa69dbrzbr88l5m594")))) + (base32 "1pbl8pbgmbs3i8yik4p63g4pd9bhn0dp3d7l667dkvw0kccl66c7")))) (build-system perl-build-system) (native-inputs `(("perl-devel-leak" ,perl-devel-leak))) -- cgit v1.2.3 From 55e8865da24e570f79ff15414ca00b78a13e92fd Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 09:14:21 +0200 Subject: gnu: librsvg-next: Build with current rust. * gnu/packages/gnome.scm (librsvg-next)[arguments]: Remove custom rust variable. --- gnu/packages/gnome.scm | 1 - 1 file changed, 1 deletion(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 3ee3a698fd..97667803e4 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -3283,7 +3283,6 @@ library.") ((guix build cargo-build-system) (guix build utils) ((guix build gnu-build-system) #:prefix gnu:)) - #:rust ,rust-1.40 #:cargo-inputs (("rust-bitflags" ,rust-bitflags-1) ("rust-cairo-rs" ,rust-cairo-rs-0.8) -- cgit v1.2.3 From e43a91a4291b402a0cc87b23cf76cd1a201e4c0e Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 10:51:14 +0200 Subject: gnu: librsvg-next: Update to 2.50.2. * gnu/packages/gnome.scm (librsvg-next): Update to 2.50.2. --- gnu/packages/gnome.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 97667803e4..634b251031 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -11,7 +11,7 @@ ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus ;;; Copyright © 2015, 2016, 2017, 2018 Mark H Weaver ;;; Copyright © 2015 David Thompson -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2016, 2017, 2018 Rene Saavedra ;;; Copyright © 2016 Jochem Raat ;;; Copyright © 2016, 2017, 2019 Kei Kebreau @@ -3263,7 +3263,7 @@ library.") (define-public librsvg-next (package (name "librsvg") - (version "2.50.1") + (version "2.50.2") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/librsvg/" @@ -3271,7 +3271,7 @@ library.") "librsvg-" version ".tar.xz")) (sha256 (base32 - "02csvx2nzygh8kyal2qiy3y6xb7d52vszxxr37dzav704a9pkncv")) + "1lsnl08b5pjf01q3agixjd53islw5rqkc38r31rlmm2crrqz44b2")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "vendor") -- cgit v1.2.3 From b40195e7f3f899ef1d7e8b8852a1540e49839cb5 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:08:47 +0200 Subject: gnu: Add rust-funty-1. * gnu/packages/crates-io.scm (rust-funty-1): New variable. --- gnu/packages/crates-io.scm | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ab90ec141b..e70ea9514f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Ivan Petkov -;;; Copyright © 2019, 2020 Efraim Flashner +;;; Copyright © 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2019, 2020 Nicolas Goaziou ;;; Copyright © 2019 Giacomo Leidi ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice @@ -9947,6 +9947,31 @@ pseudorandom number generator") (description "Low-level Rust bindings for the Zircon kernel.") (license license:bsd-3))) +(define-public rust-funty-1 + (package + (name "rust-funty") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "funty" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "19wx3p3jmv863y0mjb56sr4qf1kvqhl3fsyslkd92zli0p8lrlzy")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-static-assertions" ,rust-static-assertions-1)))) + (home-page "https://github.com/myrrlyn/funty") + (synopsis "Trait generalization over the primitive types") + (description + "Prior to 1.0, Rust had traits for the numeric primitive types to permit +code to generalize over which specific type it accepted. This was never +stabilized, and eventually removed. This library reïnstates these traits.") + (license license:expat))) + (define-public rust-futf-0.1 (package (name "rust-futf") -- cgit v1.2.3 From b571ce1d7af52004bba02eb060a066b7f3044ff3 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:09:30 +0200 Subject: gnu: Add rust-radium-0.5. * gnu/packages/crates-io.scm (rust-radium-0.5): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e70ea9514f..75bc1d4421 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -22818,6 +22818,30 @@ Racer.") fashion. It is mostly used in Racer.") (license license:expat))) +(define-public rust-radium-0.5 + (package + (name "rust-radium") + (version "0.5.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "radium" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1f5vj5zy4kcsw8p87y976dm5pln6v6jfw5f0fkj7qbwfipbsj6wl")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-static-assertions" ,rust-static-assertions-1)))) + (home-page "https://github.com/mystor/radium") + (synopsis "Portable interfaces for maybe-atomic types") + (description + "@code{radium} provides abstractions and graceful degradation for behavior +that must be shared-mutable, but merely may use atomic instructions to do so.") + (license license:expat))) + (define-public rust-radix-fmt-1 (package (name "rust-radix-fmt") -- cgit v1.2.3 From 2c860bf11f3fe85247ee65e308014ce70c89fe90 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:10:00 +0200 Subject: gnu: Add rust-tap-1. * gnu/packages/crates-io.scm (rust-tap-1): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 75bc1d4421..e013cb3a01 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30664,6 +30664,26 @@ that exposes the same functionality at the command line.") "This package provides a small wrapper around option.") (license (list license:asl2.0 license:expat)))) +(define-public rust-tap-1 + (package + (name "rust-tap") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tap" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "13h7rw3zg3qyb4wrri8l6xbd1wrxd2rq29sqxnkd7zqs5mrlwirn")))) + (build-system cargo-build-system) + (home-page "https://github.com/myrrlyn/tap") + (synopsis "Generic extensions for tapping values in Rust") + (description + "This package provides generic extensions for tapping values in Rust.") + (license license:expat))) + (define-public rust-tar-0.4 (package (name "rust-tar") -- cgit v1.2.3 From e3cf342773e75d9390c92814297de9e2fa21755b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:10:30 +0200 Subject: gnu: Add rust-wyz-0.2. * gnu/packages/crates-io.scm (rust-wyz-0.2): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e013cb3a01..f4459b95a5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36444,6 +36444,26 @@ API.") "Contains function definitions for the Windows API library ws2_32.") (license license:expat))) +(define-public rust-wyz-0.2 + (package + (name "rust-wyz") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "wyz" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "05028bk49b2ix1lz22sj65fnlxr0f29j2klkaqjxp6az3c6hprl5")))) + (build-system cargo-build-system) + (home-page "https://myrrlyn.net/crates/wyz") + (synopsis "Collection of utility functions") + (description + "This package provides a collection of utility functions.") + (license license:expat))) + (define-public rust-x86-0.33 (package (name "rust-x86") -- cgit v1.2.3 From 8b9cb0b381cc2eb555dff0cb54453b82cb64f0ca Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:11:12 +0200 Subject: gnu: Add rust-bitvec-0.19. * gnu/packages/crates-io.scm (rust-bitvec-0.19): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f4459b95a5..92a49bc050 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2388,6 +2388,39 @@ behave like a set of bitflags.") "Library for reading/writing un-aligned values from/to streams in big-endian and little-endian formats.") (license (list license:expat license:asl2.0)))) +(define-public rust-bitvec-0.19 + (package + (name "rust-bitvec") + (version "0.19.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "bitvec" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "10bz751jbsy8fj203ibjwil07p2fwfzvx7b326wfssaravlkbfm7")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-funty" ,rust-funty-1) + ("rust-radium" ,rust-radium-0.5) + ("rust-serde" ,rust-serde-1) + ("rust-tap" ,rust-tap-1) + ("rust-wyz" ,rust-wyz-0.2)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.3) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-test" ,rust-serde-test-1) + ("rust-static-assertions" ,rust-static-assertions-1)))) + (home-page "https://myrrlyn.net/crates/bitvec") + (synopsis "Manipulate memory, bit by bit") + (description + "This package provides a crate for manipulating memory, bit by bit.") + (license license:expat))) + (define-public rust-blake2-0.8 (package (name "rust-blake2") -- cgit v1.2.3 From e6e350e6e3f3f2ca45c2f4e8fcff8f8bc05deaa3 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 11:11:45 +0200 Subject: gnu: Add rust-nom-6. * gnu/packages/crates-io.scm (rust-nom-6): New variable. (rust-nom-5): Inherit from rust-nom-6. --- gnu/packages/crates-io.scm | 48 ++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 42 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 92a49bc050..d7be42d7d6 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17741,10 +17741,10 @@ implementation (which is unstable / requires nightly).") (license (list license:asl2.0 license:expat)))) -(define-public rust-nom-5 +(define-public rust-nom-6 (package (name "rust-nom") - (version "5.1.2") + (version "6.0.1") (source (origin (method url-fetch) @@ -17753,20 +17753,21 @@ implementation (which is unstable / requires nightly).") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1br74rwdp3c2ddga03bphnf355spn4mzwf1slg0a30zd4qnjdd7z")))) + "1w0ppq112myzwk23c8m0wmq0nv73xvn0g9gl2kfm83aadgylq0w8")))) (build-system cargo-build-system) (arguments `(#:tests? #f ; Tests require example directory, not included in tarball. #:cargo-inputs - (("rust-lazy-static" ,rust-lazy-static-1) + (("rust-bitvec" ,rust-bitvec-0.19) + ("rust-lazy-static" ,rust-lazy-static-1) ("rust-lexical-core" ,rust-lexical-core-0.7) ("rust-memchr" ,rust-memchr-2) ("rust-regex" ,rust-regex-1) ("rust-version-check" ,rust-version-check-0.9)) #:cargo-development-inputs - (("rust-criterion" ,rust-criterion-0.2) + (("rust-criterion" ,rust-criterion-0.3) ("rust-doc-comment" ,rust-doc-comment-0.3) - ("rust-jemallocator" ,rust-jemallocator-0.1)) + ("rust-jemallocator" ,rust-jemallocator-0.3)) #:phases (modify-phases %standard-phases (add-after 'configure 'override-jemalloc @@ -17785,6 +17786,41 @@ implementation (which is unstable / requires nightly).") combinators library.") (license license:expat))) +(define-public rust-nom-5 + (package + (inherit rust-nom-6) + (name "rust-nom") + (version "5.1.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "nom" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1br74rwdp3c2ddga03bphnf355spn4mzwf1slg0a30zd4qnjdd7z")))) + (arguments + `(#:tests? #f ; Tests require example directory, not included in tarball. + #:cargo-inputs + (("rust-lazy-static" ,rust-lazy-static-1) + ("rust-lexical-core" ,rust-lexical-core-0.7) + ("rust-memchr" ,rust-memchr-2) + ("rust-regex" ,rust-regex-1) + ("rust-version-check" ,rust-version-check-0.9)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.2) + ("rust-doc-comment" ,rust-doc-comment-0.3) + ("rust-jemallocator" ,rust-jemallocator-0.1)) + #:phases + (modify-phases %standard-phases + (add-after 'configure 'override-jemalloc + (lambda* (#:key inputs #:allow-other-keys) + (let ((jemalloc (assoc-ref inputs "jemalloc"))) + (setenv "JEMALLOC_OVERRIDE" + (string-append jemalloc "/lib/libjemalloc_pic.a"))) + #t))))))) + (define-public rust-nom-4.2 (package (inherit rust-nom-5) -- cgit v1.2.3 From 2dc2c232cb9adee042b3492e89a93ff476b10309 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:03:46 +0200 Subject: gnu: Add rust-cxx-test-suite-0.0. * gnu/packages/crates-io.scm (rust-cxx-test-suite-0.0): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d7be42d7d6..8524caca11 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6370,6 +6370,26 @@ ristretto255 and Curve25519") attributes.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cxx-test-suite-0.0.0 + (package + (name "rust-cxx-test-suite") + (version "0.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxx-test-suite" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1pkf4ay1210g9wqyqhkgvlcsv4i6kgdcmgnh19mrymylznv7pcal")))) + (build-system cargo-build-system) + (arguments '(#:skip-build? #t)) ; Not meant to be built independantly. + (home-page "https://github.com/dtolnay/cxx") + (synopsis "Test suite of the cxx crate") + (description "This package provides the test suite of the cxx crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-darling-0.10 (package (name "rust-darling") -- cgit v1.2.3 From 77b8a679f074e62d26cf7ef2555394afca73e275 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:06:05 +0200 Subject: gnu: Add rust-cxxbridge-flags-0.5. * gnu/packages/crates-io.scm (rust-cxxbridge-flags-0.5): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 8524caca11..2eba46d6de 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6390,6 +6390,26 @@ attributes.") (description "This package provides the test suite of the cxx crate.") (license (list license:expat license:asl2.0)))) +(define-public rust-cxxbridge-flags-0.5 + (package + (name "rust-cxxbridge-flags") + (version "0.5.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxxbridge-flags" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0jfwsm85s5kalgqbqlg1kq79zcb5zwk375h0qw7ycz5i6v3c8j0k")))) + (build-system cargo-build-system) + (home-page "https://github.com/dtolnay/cxx") + (synopsis "Compiler configuration of the `cxx` crate") + (description "This package provides a compiler configuration of the `cxx` +crate (implementation detail).") + (license (list license:expat license:asl2.0)))) + (define-public rust-darling-0.10 (package (name "rust-darling") -- cgit v1.2.3 From 74287130acaefba2af9a400901d5e8101354f861 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:07:41 +0200 Subject: gnu: Add rust-fuzzy-matcher-0.3. * gnu/packages/crates-io.scm (rust-fuzzy-matcher-0.3): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2eba46d6de..133d649037 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10641,6 +10641,30 @@ for the futures-rs library.") futures-rs library.") (license (list license:expat license:asl2.0)))) +(define-public rust-fuzzy-matcher-0.3 + (package + (name "rust-fuzzy-matcher") + (version "0.3.7") + (source + (origin + (method url-fetch) + (uri (crate-uri "fuzzy-matcher" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "153csv8rsk2vxagb68kpmiknvdd3bzqj03x805khckck28rllqal")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-thread-local" ,rust-thread-local-1.0)) + #:cargo-development-inputs + (("rust-termion" ,rust-termion-1.5)))) + (home-page "https://github.com/lotabout/fuzzy-matcher") + (synopsis "Fuzzy Matching Library") + (description "This package provides a fuzzy matching library in Rust.") + (license license:expat))) + (define-public rust-fxhash-0.2 (package (name "rust-fxhash") -- cgit v1.2.3 From 5fea1f5cabfbac0b79702ed01f51eafb40152696 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:08:43 +0200 Subject: gnu: Add rust-utf8parse-0.2. * gnu/packages/crates-io.scm (rust-utf8parse-0.2): New variable. (rust-utf8parse-0.1): Inherit from rust-utf8parse-0.2. --- gnu/packages/crates-io.scm | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 133d649037..a12d611537 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -34921,10 +34921,10 @@ Unix users and groups.") first byte.") (license license:expat))) -(define-public rust-utf8parse-0.1 +(define-public rust-utf8parse-0.2 (package (name "rust-utf8parse") - (version "0.1.1") + (version "0.2.0") (source (origin (method url-fetch) @@ -34933,13 +34933,28 @@ first byte.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0zamsj2986shm4x9zncjf2m5qy9scaw7qnxw4f89b2afpg6a8wl7")))) + "0wjkvy22cxg023vkmvq2wwkgqyqam0d4pjld3m13blfg594lnvlk")))) (build-system cargo-build-system) (home-page "https://github.com/jwilm/vte") (synopsis "Table-driven UTF-8 parser") (description "This package provides a table-driven UTF-8 parser.") (license (list license:asl2.0 license:expat)))) +(define-public rust-utf8parse-0.1 + (package + (inherit rust-utf8parse-0.2) + (name "rust-utf8parse") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "utf8parse" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0zamsj2986shm4x9zncjf2m5qy9scaw7qnxw4f89b2afpg6a8wl7")))))) + (define-public rust-uuid-0.8 (package (name "rust-uuid") -- cgit v1.2.3 From 9ef6055c00233973adde5e55f7d89beb87a77622 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:10:23 +0200 Subject: gnu: Add rust-link-cplusplus-1. * gnu/packages/crates-io.scm (rust-link-cplusplus-1): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a12d611537..2f3d7b6911 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15226,6 +15226,28 @@ libraries have. "Efficiently insert line separators.") (license license:asl2.0))) +(define-public rust-link-cplusplus-1 + (package + (name "rust-link-cplusplus") + (version "1.0.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "link-cplusplus" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0m7365ig7r88x7b4gkzj5m7b6wiq42pi1ign7mvyq63jr22sfspr")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs (("rust-cc" ,rust-cc-1)))) + (home-page "https://github.com/dtolnay/link-cplusplus") + (synopsis "Link libstdc++ or libc++ automatically or manually") + (description "This crate helps link to libstdc++ or libc++ automatically or +manually from Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-linked-hash-map-0.5 (package (name "rust-linked-hash-map") -- cgit v1.2.3 From c79834ed374104cc65fdf6a8b514606661f01000 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:12:26 +0200 Subject: gnu: Add rust-rustyline-derive-0.3. * gnu/packages/crates-io.scm (rust-rustyline-derive-0.3): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2f3d7b6911..5e6b437430 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -26147,6 +26147,29 @@ sub-processes using a fork-like interface.") ("rust-tempfile" ,rust-tempfile-3) ("rust-wait-timeout" ,rust-wait-timeout-0.2)))))) +(define-public rust-rustyline-derive-0.3 + (package + (name "rust-rustyline-derive") + (version "0.3.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "rustyline-derive" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0daj9szvfi442vj2fhm7qb92wmzv7g75qsjq9a6ycnqac4lhx9al")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)))) + (home-page "https://github.com/kkawakam/rustyline") + (synopsis "Rustyline macros implementation in Rust") + (description "This package provides Rustyline macros implementation in Rust.") + (license license:expat))) + (define-public rust-ryu-1 (package (name "rust-ryu") -- cgit v1.2.3 From f1d86bf00d864105becd866431708c92b264b804 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:14:06 +0200 Subject: gnu: Add rust-scratch-1. * gnu/packages/crates-io.scm (rust-scratch-1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 5e6b437430..ca452c2cf1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -26494,6 +26494,29 @@ with one of the implemented strategies.") (base32 "09sy9wbqp409pkwmqni40qmwa99ldqpl48pp95m1xw8sc19qy9cl")))))) +(define-public rust-scratch-1 + (package + (name "rust-scratch") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "scratch" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0sff4rvfalp0ip98pl3xa32n7lhzcr4zqn8fgamaalbb64v4a4by")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-fs2" ,rust-fs2-0.4)))) + (home-page "https://github.com/dtolnay/scratch") + (synopsis "Compile-time temporary directory") + (description "This crate exposes a compile-time temporary directory sharable +by multiple crates in a build graph and erased by @code{cargo clean}.") + (license (list license:expat license:asl2.0)))) + (define-public rust-scrypt-0.3 (package (name "rust-scrypt") -- cgit v1.2.3 From e5adfbac4b997786a81369866de9072068476092 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:17:19 +0200 Subject: gnu: Add rust-tuikit-0.2. * gnu/packages/crates-io.scm (rust-tuikit-0.2): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ca452c2cf1..aa9c47801b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -34109,6 +34109,37 @@ extension for the Trust-DNS client to use rustls for TLS.") "Test harness for ui tests of compiler diagnostics.") (license (list license:expat license:asl2.0)))) +(define-public rust-tuikit-0.2 + (package + (name "rust-tuikit") + (version "0.2.9") + (source + (origin + (method url-fetch) + (uri (crate-uri "tuikit" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "19f3jp12kqcx7aaykxbaj1j17zahd4drv049agpxaminr63w2sw4")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #f ; tests fail in the build environment. + #:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-nix" ,rust-nix-0.14) + ("rust-term" ,rust-term-0.5) + ("rust-unicode-width" ,rust-unicode-width-0.1)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.6)))) + (home-page "https://github.com/lotabout/tuikit") + (synopsis "Toolkit for writing TUI applications") + (description + "This package provides a toolkit for writing TUI applications in Rust.") + (license license:expat))) + (define-public rust-typeable-0.1 (package (name "rust-typeable") -- cgit v1.2.3 From 6170f0b4c792b8506f4919c77f34f012bde95444 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:19:02 +0200 Subject: gnu: Add rust-timer-0.2. * gnu/packages/crates-io.scm (rust-timer-0.2): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index aa9c47801b..94301f9b82 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31811,6 +31811,30 @@ crate.") (description "This package provides a timeout mechanism for unit tests.") (license license:asl2.0))) +(define-public rust-timer-0.2 + (package + (name "rust-timer") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "timer" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0srhqyp7fr91d1i43aqs7wc6yn1i3kdkh1pm05bicdw961v23m1i")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-chrono" ,rust-chrono-0.4)))) + (home-page "https://github.com/Yoric/timer.rs") + (synopsis "Simple timer in Rust") + (description + "This package provides a simple timer. Use it to schedule execution of +closures after a delay or at a given timestamp.") + (license license:mpl2.0))) + (define-public rust-tinytemplate-1 (package (name "rust-tinytemplate") -- cgit v1.2.3 From 8d1faae9af76c389b138adda13730053a68bd306 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:20:05 +0200 Subject: gnu: Add rust-nix-0.18. * gnu/packages/crates-io.scm (rust-nix-0.18): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 94301f9b82..b68ef080ac 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -17687,6 +17687,34 @@ The goal is to not provide a 100% unified interface, but to unify what can be while still providing platform specific APIs.") (license license:expat))) +(define-public rust-nix-0.18 + (package + (inherit rust-nix-0.19) + (name "rust-nix") + (version "0.18.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "nix" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0m8h9bskjjqx9sk687z8bxqg2kpwhdh78jq6zfaxsb8llvk0yic3")))) + (arguments + `(#:tests? #f ; test suite hangs + #:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-cc" ,rust-cc-1) + ("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-libc" ,rust-libc-0.2)) + #:cargo-development-inputs + (("rust-bytes" ,rust-bytes-0.4) + ("rust-caps" ,rust-caps-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-rand" ,rust-rand-0.6) + ("rust-semver" ,rust-semver-0.9) + ("rust-sysctl" ,rust-sysctl-0.1) + ("rust-tempfile" ,rust-tempfile-3)))))) + (define-public rust-nix-0.17 (package (inherit rust-nix-0.19) -- cgit v1.2.3 From 9bceb6de87cdf9108da86caa2479ca296002470f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:26:40 +0200 Subject: gnu: Add rust-skim-0.7. * gnu/packages/crates-io.scm (rust-skim-0.7): New variable. --- gnu/packages/crates-io.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b68ef080ac..0e28ad9eb6 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -28811,6 +28811,44 @@ variants in pure Rust.") "Test your Rust markdown documentation via Cargo.") (license (list license:expat license:asl2.0)))) +(define-public rust-skim-0.7 + (package + (name "rust-skim") + (version "0.7.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "skim" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1yiyd6fml5hd2l811sckkzmiiq9bd7018ajk4qk3ai4wyvqnw8mv")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-clap" ,rust-clap-2) + ("rust-derive-builder" ,rust-derive-builder-0.9) + ("rust-env-logger" ,rust-env-logger-0.6) + ("rust-fuzzy-matcher" ,rust-fuzzy-matcher-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-nix" ,rust-nix-0.14) + ("rust-rayon" ,rust-rayon-1) + ("rust-regex" ,rust-regex-1) + ("rust-shlex" ,rust-shlex-0.1) + ("rust-time" ,rust-time-0.1) + ("rust-timer" ,rust-timer-0.2) + ("rust-tuikit" ,rust-tuikit-0.2) + ("rust-unicode-width" ,rust-unicode-width-0.1) + ("rust-vte" ,rust-vte-0.3)))) + (home-page "https://github.com/lotabout/skim") + (synopsis "Fuzzy Finder in Rust") + (description "This package provides a fuzzy finder in Rust.") + (license license:expat))) + (define-public rust-slab-0.4 (package (name "rust-slab") -- cgit v1.2.3 From a4fa18f4e8b316fb41632b1648476c752e618a83 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:27:09 +0200 Subject: gnu: Add rust-rustyline-6. * gnu/packages/crates-io.scm (rust-rustyline-6): New variable. --- gnu/packages/crates-io.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0e28ad9eb6..ebe4f77bb5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -26175,6 +26175,46 @@ sub-processes using a fork-like interface.") ("rust-tempfile" ,rust-tempfile-3) ("rust-wait-timeout" ,rust-wait-timeout-0.2)))))) +(define-public rust-rustyline-6 + (package + (name "rust-rustyline") + (version "6.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "rustyline" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "04w4k0nwsra84h90rvwkr6vmjp3nshjqaj9rakfym8qr09xmw3bg")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-dirs-next" ,rust-dirs-next-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-memchr" ,rust-memchr-2) + ("rust-nix" ,rust-nix-0.18) + ("rust-scopeguard" ,rust-scopeguard-1) + ("rust-skim" ,rust-skim-0.7) + ("rust-unicode-segmentation" ,rust-unicode-segmentation-1.6) + ("rust-unicode-width" ,rust-unicode-width-0.1) + ("rust-utf8parse" ,rust-utf8parse-0.2) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-assert-matches" ,rust-assert-matches-1.3) + ("rust-doc-comment" ,rust-doc-comment-0.3) + ("rust-env-logger" ,rust-env-logger-0.7) + ("rust-rustyline-derive" ,rust-rustyline-derive-0.3) + ("rust-tempfile" ,rust-tempfile-3)))) + (home-page "https://github.com/kkawakam/rustyline") + (synopsis "Readline implementation in Rust") + (description + "Rustyline, a readline implementation based on the linenoise package.") + (license license:expat))) + (define-public rust-rustyline-derive-0.3 (package (name "rust-rustyline-derive") -- cgit v1.2.3 From 684897da139b1dfde0af5cd8669b5d75bd203d23 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:29:17 +0200 Subject: gnu: rust-trybuild-1: Update to 1.0.38. * gnu/packages/crates-io.scm (rust-trybuild-1): Update to 1.0.38. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ebe4f77bb5..e079e95b99 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -34213,7 +34213,7 @@ extension for the Trust-DNS client to use rustls for TLS.") (define-public rust-trybuild-1 (package (name "rust-trybuild") - (version "1.0.23") + (version "1.0.38") (source (origin (method url-fetch) @@ -34222,7 +34222,7 @@ extension for the Trust-DNS client to use rustls for TLS.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "080j808nv6nyr1mmw23vwdp4rkk7r38nmms850rih8lsclc1pzr6")))) + "0l5kicbqkk8b9grdg5l2f2w9l47h0s1kjnv6lywvwk292236zc0p")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From c61ddb6f51cd267a25be332001a60318e2f5607e Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:40:49 +0200 Subject: gnu: Add rust-codespan-reporting-0.9. * gnu/packages/crates-io.scm (rust-codespan-reporting-0.9): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e079e95b99..717e0cb69c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4339,6 +4339,39 @@ CMAKE environmental variable is set.") (base32 "0m6fgdr4d2fp8jhkqvwr23hrqqqjv72g0j9vdgijc58k05j9j1hp")))))) +(define-public rust-codespan-reporting-0.9 + (package + (name "rust-codespan-reporting") + (version "0.9.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "codespan-reporting" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "07g86hv1lp5bbr6w6hsa3mgdmavs36igc7k5pi1fvc86ad2n41vf")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-serde" ,rust-serde-1) + ("rust-termcolor" ,rust-termcolor-1) + ("rust-unicode-width" ,rust-unicode-width-0.1)) + #:cargo-development-inputs + (("rust-anyhow" ,rust-anyhow-1.0) + ("rust-insta" ,rust-insta-0.16) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-peg" ,rust-peg-0.6) + ("rust-rustyline" ,rust-rustyline-6) + ("rust-structopt" ,rust-structopt-0.3) + ("rust-unindent" ,rust-unindent-0.1)))) + (home-page "https://github.com/brendanzab/codespan") + (synopsis "Diagnostic reporting for text-based programming languages") + (description "This package provides diagnostic reporting for text-based +programming languages.") + (license license:asl2.0))) + (define-public rust-color-quant-1.0 (package (name "rust-color-quant") -- cgit v1.2.3 From 69d1b05b5ff1dc2e5424cc102c622b2bc3ecd82b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:43:17 +0200 Subject: gnu: Add rust-cxx-gen-0.6. * gnu/packages/crates-io.scm (rust-cxx-gen-0.6): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 717e0cb69c..1b72425bf0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6403,6 +6403,34 @@ ristretto255 and Curve25519") attributes.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cxx-gen-0.6 + (package + (name "rust-cxx-gen") + (version "0.6.7") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxx-gen" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0avkca16wjy0paplq1ycaf04bj62agfj0awyhyzxyfpdn9rm45j2")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cc" ,rust-cc-1) + ("rust-codespan-reporting" ,rust-codespan-reporting-0.9) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)))) + (home-page "https://cxx.rs") + (synopsis "C++ code generator") + (description + "This package provides a C++ code generator for integrating the @code{cxx} +crate into higher level tools.") + (license (list license:expat license:asl2.0)))) + (define-public rust-cxx-test-suite-0.0.0 (package (name "rust-cxx-test-suite") -- cgit v1.2.3 From f42ae2bd90e2d13872a1845a78a8255a1713fddc Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:44:01 +0200 Subject: gnu: Add rust-cxx-build-0.5. * gnu/packages/crates-io.scm (rust-cxx-build-0.5): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1b72425bf0..7e2e0b44c5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6403,6 +6403,39 @@ ristretto255 and Curve25519") attributes.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cxx-build-0.5 + (package + (name "rust-cxx-build") + (version "0.5.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxx-build" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "01109arjlj8wdq2rcyy3s76a5aidkn7zvhhhvhvkg1cxgqza9p22")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cc" ,rust-cc-1) + ("rust-codespan-reporting" ,rust-codespan-reporting-0.9) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-scratch" ,rust-scratch-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-cxx-gen" ,rust-cxx-gen-0.6) + ("rust-pkg-config" ,rust-pkg-config-0.3)))) + (home-page "https://cxx.rs") + (synopsis "C++ code generator") + (description + "This package provides a C++ code generator for integrating the @code{cxx} +crate into a Cargo build.") + (license (list license:expat license:asl2.0)))) + (define-public rust-cxx-gen-0.6 (package (name "rust-cxx-gen") -- cgit v1.2.3 From abe47269cb1a2382ee20bab56a18a485a1fda541 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:44:42 +0200 Subject: gnu: Add rust-cxx-0.5, rust-cxxbridge-macro-0.5. * gnu/packages/crates-io.scm (rust-cxx-0.5, rust-cxxbridge-macro-0.5): New variables. --- gnu/packages/crates-io.scm | 59 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7e2e0b44c5..08ae5ce7aa 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6403,6 +6403,38 @@ ristretto255 and Curve25519") attributes.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cxx-0.5 + (package + (name "rust-cxx") + (version "0.5.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxx" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1alj19zf8jm5j8c8hynqb36f0vyjqs8yhwmxpcapfmb5lav4ipgb")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #f ; Cannot compile cxx-test-suite. + #:cargo-inputs + (("rust-cc" ,rust-cc-1) + ("rust-cxxbridge-flags" ,rust-cxxbridge-flags-0.5) + ("rust-cxxbridge-macro" ,rust-cxxbridge-macro-0.5) + ("rust-link-cplusplus" ,rust-link-cplusplus-1)) + #:cargo-development-inputs + (("rust-cxx-build" ,rust-cxx-build-0.5) + ("rust-cxx-gen" ,rust-cxx-gen-0.6) + ("rust-cxx-test-suite" ,rust-cxx-test-suite-0.0.0) + ("rust-rustversion" ,rust-rustversion-1) + ("rust-trybuild" ,rust-trybuild-1)))) + (home-page "https://cxx.rs") + (synopsis "Safe interop between Rust and C++") + (description "This package provides a safe interop between Rust and C++.") + (license (list license:expat license:asl2.0)))) + (define-public rust-cxx-build-0.5 (package (name "rust-cxx-build") @@ -6504,6 +6536,33 @@ crate into higher level tools.") crate (implementation detail).") (license (list license:expat license:asl2.0)))) +(define-public rust-cxxbridge-macro-0.5 + (package + (name "rust-cxxbridge-macro") + (version "0.5.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "cxxbridge-macro" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "05mhvchmcb8dpgcqkl5vyxycywp2x42vw1qh2hyxxyi576nmmxsr")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-cxx" ,rust-cxx-0.5)))) + (home-page "https://cxx.rs") + (synopsis "Implementation detail of the `cxx` crate") + (description + "This package provides an implementation detail of the @code{cxx} crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-darling-0.10 (package (name "rust-darling") -- cgit v1.2.3 From aeb24932c50f2a90210021c2bacaddf6c5f15bec Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 12:48:29 +0200 Subject: gnu: newsboat: Update to 2.22. * gnu/packages/syndication.scm (newsboat): Update to 2.22. [arguments]: Remove rust-gettext-sys-0.19, rust-lazy-static-1, rust-nom-5, rust-xdg-2.2 from cargo-inputs. Add rust-cxx-0.5, rust-cxx-build-0.5, rust-nom-6. --- gnu/packages/syndication.scm | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/gnu/packages/syndication.scm b/gnu/packages/syndication.scm index 82d3fa3a21..075fd7e3e6 100644 --- a/gnu/packages/syndication.scm +++ b/gnu/packages/syndication.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2016, 2017, 2019, 2020 Efraim Flashner +;;; Copyright © 2016, 2017, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2020 Vinicius Monego ;;; @@ -53,7 +53,7 @@ (define-public newsboat (package (name "newsboat") - (version "2.21") + (version "2.22") (source (origin (method url-fetch) @@ -61,7 +61,7 @@ "/newsboat-" version ".tar.xz")) (sha256 (base32 - "0ccwbb3maini18453wjqn8m3bd7zzm6dn5a9vpb8smxv8vfv6ihc")))) + "146p3j46hna1m8zlacb9q1ljnldwv6xrjbaplm94f2x0v4azi1jj")))) (build-system cargo-build-system) (native-inputs `(("gettext" ,gettext-minimal) @@ -87,17 +87,16 @@ ("rust-chrono" ,rust-chrono-0.4) ("rust-clap" ,rust-clap-2) ("rust-curl-sys" ,rust-curl-sys-0.4) + ("rust-cxx" ,rust-cxx-0.5) + ("rust-cxx-build" ,rust-cxx-build-0.5) ("rust-gettext-rs" ,rust-gettext-rs-0.5) - ("rust-gettext-sys" ,rust-gettext-sys-0.19) - ("rust-lazy-static" ,rust-lazy-static-1) ("rust-libc" ,rust-libc-0.2) ("rust-natord" ,rust-natord-1.0) - ("rust-nom" ,rust-nom-5) + ("rust-nom" ,rust-nom-6) ("rust-once-cell" ,rust-once-cell-1) ("rust-rand" ,rust-rand-0.7) ("rust-url" ,rust-url-2) - ("rust-unicode-width" ,rust-unicode-width-0.1) - ("rust-xdg" ,rust-xdg-2.2)) + ("rust-unicode-width" ,rust-unicode-width-0.1)) #:cargo-development-inputs (("rust-tempfile" ,rust-tempfile-3) ("rust-proptest" ,rust-proptest-0.9) -- cgit v1.2.3 From f30f9cf93e7b71a51596cb8914b2fed54713cc2a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 12:17:58 +0100 Subject: gnu: Add rust-num-enum-0.4. * gnu/packages/crates-io.scm (rust-num-enum-0.4): New variable. --- gnu/packages/crates-io.scm | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 08ae5ce7aa..3939f178b5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Ivan Petkov ;;; Copyright © 2019, 2020, 2021 Efraim Flashner -;;; Copyright © 2019, 2020 Nicolas Goaziou +;;; Copyright © 2019, 2020, 2021 Nicolas Goaziou ;;; Copyright © 2019 Giacomo Leidi ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2019, 2020 John Soo @@ -18699,6 +18699,31 @@ for Rust") (description "Numeric syntax extensions in Rust.") (license (list license:expat license:asl2.0)))) +(define-public rust-num-enum-0.4 + (package + (name "rust-num-enum") + (version "0.4.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "num_enum" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1r1nisdzm9m7xm0389nwyi85jhx1bnh5pwllai44ngbgy1ymlmna")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;missing files + #:cargo-inputs + (("rust-derivative" ,rust-derivative-2) + ("rust-num-enum" ,rust-num-enum-0.4) + ("rust-num-enum-derive" ,rust-num-enum-derive-0.4)))) + (home-page "https://github.com/illicitonion/num_enum") + (synopsis "Macros easing inter-operation between primitives and enums") + (description + "This library provides procedural macros to make inter-operation between +primitives and enums easier.") + (license license:bsd-3))) + (define-public rust-num-enum-derive-0.4 (package (name "rust-num-enum-derive") -- cgit v1.2.3 From d5bb0e4fa778b3c8e5afc4ecb2ecd615432e27a4 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sun, 3 Jan 2021 12:19:05 +0000 Subject: gnu: guix-build-coordinator: Update to 0-14.5149e4f. * gnu/packages/package-management.scm (guix-build-coordinator): Update to 0-14.5149e4f. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 898f0a1db7..3bce1bd944 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -1028,8 +1028,8 @@ environments.") (license (list license:gpl3+ license:agpl3+ license:silofl1.1)))) (define-public guix-build-coordinator - (let ((commit "3a921d472ebad0600e58abdc8808125771dfc309") - (revision "13")) + (let ((commit "5149e4f322f71d65851c899cc9b8ce4532ca65ee") + (revision "14")) (package (name "guix-build-coordinator") (version (git-version "0" revision commit)) @@ -1040,7 +1040,7 @@ environments.") (commit commit))) (sha256 (base32 - "0bs1rwab7b3d14xr9spqzy54xbfga72aabqz35swb1whi83jz4ch")) + "0ps8zppma9hvyikv9l0kl0k4p9cl499x4lb9vanj7zn99136sd3q")) (file-name (string-append name "-" version "-checkout")))) (build-system gnu-build-system) (arguments -- cgit v1.2.3 From 88c2e72af023fae0325bfdaf7078a1cd263f9ffc Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sun, 3 Jan 2021 13:15:23 +0000 Subject: gnu: guix-data-service: Update to 0.0.1-23.e3878fe. This fixes the system test, which broke when the squee update broke the metrics endpoint. * gnu/packages/web.scm (guix-data-service): Update to 0.0.1-23.e3878fe. --- gnu/packages/web.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 46b1c4df5e..50b6c32663 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -4643,8 +4643,8 @@ CDF, Atom 0.3, and Atom 1.0 feeds.") (package-with-python2 python-feedparser)) (define-public guix-data-service - (let ((commit "bd8390673e073a4d66082e48120cc3c86a255fc8") - (revision "22")) + (let ((commit "e3878fefb4184f3ad45a6e6f434767c0bf109db8") + (revision "23")) (package (name "guix-data-service") (version (string-append "0.0.1-" revision "." (string-take commit 7))) @@ -4656,7 +4656,7 @@ CDF, Atom 0.3, and Atom 1.0 feeds.") (file-name (git-file-name name version)) (sha256 (base32 - "11kkm3qn1zsri5sz8gwcrcbypa55fj3m0srd9snfrhiadv4sn211")))) + "0002ckayjnd6mw7a0m7q307jdwc9vsjgiidp72463xyp0yrnjdjf")))) (build-system gnu-build-system) (arguments '(#:modules ((guix build utils) -- cgit v1.2.3 From 761710957ce714b141f8c60f07bed33ed9bef336 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 3 Jan 2021 16:03:37 +0100 Subject: gnu: guile-picture-language: Update to 0.0.1-3.7e5982a. * gnu/packages/guile-xyz.scm (guile-picture-language): Update to 0.0.1-3.7e5982a. [propagated-inputs]: Add guile-rsvg. [native-inputs]: Remove imagemagick; add librsvg. [license]: Add GPLv3+. --- gnu/packages/guile-xyz.scm | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 0ae870aaf5..9d9904c751 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2014, 2015, 2018 Mark H Weaver ;;; Copyright © 2015, 2017 Christopher Allan Webber ;;; Copyright © 2016 Alex Sassmannshausen -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Ricardo Wurmus ;;; Copyright © 2016 Erik Edrosa ;;; Copyright © 2016, 2019, 2020 Eraim Flashner ;;; Copyright © 2016, 2017 Alex Kost @@ -2501,8 +2501,8 @@ format is also supported.") (deprecated-package "guile3.0-mcron" mcron)) (define-public guile-picture-language - (let ((commit "bf4600bd68af9ab3163253ccb6429fb681753cbc") - (revision "2")) + (let ((commit "7e5982a2788bd79a45ad6f02db46f061f97b6e14") + (revision "3")) (package (name "guile-picture-language") (version (git-version "0.0.1" revision commit)) @@ -2514,14 +2514,16 @@ format is also supported.") (file-name (git-file-name name version)) (sha256 (base32 - "0q05m3b6krc1fsnnbdhvm11v33qdcc3j16m1cs2j09y42jpql5hv")))) + "1y5f14cll4jx33hr43dpgrpd0yy6g0g7lim365kmgb0h0cvja80p")))) (build-system gnu-build-system) (inputs `(("guile" ,guile-3.0))) + (propagated-inputs + `(("guile-rsvg" ,guile-rsvg))) (native-inputs `(("autoconf" ,autoconf) ("automake" ,automake) - ("imagemagick" ,imagemagick) + ("librsvg" ,librsvg) ("pkg-config" ,pkg-config) ("texinfo" ,texinfo))) (home-page "https://git.elephly.net/software/guile-picture-language.git") @@ -2529,7 +2531,9 @@ format is also supported.") (description "This package provides a simple SVG-based picture language for Guile. The picture values can directly be displayed in Geiser.") - (license license:lgpl3+)))) + ;; (pict base64) is under GPLv3+, the rest is under LGPLv3+ + (license (list license:lgpl3+ + license:gpl3+))))) (define-public guile2.2-picture-language (package -- cgit v1.2.3 From e7ff878f755409a89c933691b764f7a8e6f4e021 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antoine=20C=C3=B4t=C3=A9?= Date: Thu, 31 Dec 2020 18:42:15 -0500 Subject: gnu: rav1e: Update to 0.3.5. * gnu/packages/video.scm (rav1e): Update to 0.3.5. Signed-off-by: Efraim Flashner --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 5de3fc4a86..3df1a753ed 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -4741,7 +4741,7 @@ result in several formats: (define-public rav1e (package (name "rav1e") - (version "0.3.4") + (version "0.3.5") (source (origin (method url-fetch) @@ -4750,7 +4750,7 @@ result in several formats: (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1mx6jlx2rdhmyh68h9h34kn9ssa7lv0y97j8fd9qm7qhs2q1n0cj")))) + "0c40gq4qid2apmlgzx98f6826jmn2n61prk0rn7sjxaw7yimw854")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 5e99a02b61ac42b81db33bd40b735f643f67be37 Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Thu, 31 Dec 2020 12:39:05 -0300 Subject: gnu: graphicsmagick: Add dependency on libwebp. * gnu/packages/imagemagick.scm (graphicsmagick): Add dependency on libwebp. [inputs]: Add libwebp. Signed-off-by: Efraim Flashner --- gnu/packages/imagemagick.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/imagemagick.scm b/gnu/packages/imagemagick.scm index 6afa67abbb..1f80abd012 100644 --- a/gnu/packages/imagemagick.scm +++ b/gnu/packages/imagemagick.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2018 Alex Vong ;;; Copyright © 2020 Marius Bakke +;;; Copyright © 2020 Vinicius Monego ;;; ;;; This file is part of GNU Guix. ;;; @@ -224,6 +225,7 @@ script.") ("libtiff" ,libtiff) ("libpng" ,libpng) ("libjpeg" ,libjpeg-turbo) + ("libwebp" ,libwebp) ("freetype" ,freetype) ("bzip2" ,bzip2) ("xz" ,xz) -- cgit v1.2.3 From c729a06382c290c7cf4a653649dc508c5b4b0421 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 28 Dec 2020 13:07:36 +0100 Subject: gnu: sddm: Update to 0.19.0. * gnu/packages/display-managers.scm (sddm): Update to 0.19.0. Signed-off-by: Efraim Flashner --- gnu/packages/display-managers.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/display-managers.scm b/gnu/packages/display-managers.scm index ef6e549d09..b6e5ab7d19 100644 --- a/gnu/packages/display-managers.scm +++ b/gnu/packages/display-managers.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2017, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2020 L p R n d n ;;; Copyright © 2020 Fredrik Salomonsson +;;; Copyright © 2020 Vincent Legoll ;;; ;;; This file is part of GNU Guix. ;;; @@ -57,7 +58,7 @@ (define-public sddm (package (name "sddm") - (version "0.18.1") + (version "0.19.0") (source (origin (method url-fetch) (uri (string-append @@ -66,7 +67,7 @@ "sddm-" version ".tar.xz")) (sha256 (base32 - "0nilrhwlyvkngjgxfc08n73c16azgmw80pvx0a78xqww9y3hv4xh")))) + "0hcdysw8ibr66vk8i7v56l0v5ijvhlq67v4460mc2xf2910g2m72")))) (build-system qt-build-system) (native-inputs `(("extra-cmake-modules" ,extra-cmake-modules) -- cgit v1.2.3 From 7dd1a2174a8376c521dcf271e3b76f64096074fe Mon Sep 17 00:00:00 2001 From: luhux Date: Fri, 1 Jan 2021 08:57:50 +0800 Subject: gnu: sdcv: Add 'STARDICT_DATA_DIR' search path spec. * gnu/packages/dictionaries.scm (sdcv)[native-search-paths]: New field. Signed-off-by: Efraim Flashner --- gnu/packages/dictionaries.scm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gnu/packages/dictionaries.scm b/gnu/packages/dictionaries.scm index 6387132016..b49e287313 100644 --- a/gnu/packages/dictionaries.scm +++ b/gnu/packages/dictionaries.scm @@ -438,6 +438,12 @@ intelligible and easily correctable.") ("ncurses" ,ncurses) ("readline" ,readline) ("zlib" ,zlib))) + ;; If you use Guix to package and install dictionary data, + ;; you need this variable to load them. + (native-search-paths + (list (search-path-specification + (variable "STARDICT_DATA_DIR") + (files '("share/stardict/dic"))))) (home-page "https://dushistov.github.io/sdcv/") (synopsis "Console version of StarDict") (description "sdcv is simple text-based utility for work with dictionaries -- cgit v1.2.3 From b7f47d243bc745c3a9e16de8afe29f3901ae3572 Mon Sep 17 00:00:00 2001 From: Caliph Nomble Date: Fri, 1 Jan 2021 09:53:21 +0000 Subject: gnu: ccid: Fix cross-compilation. * gnu/packages/security-token.scm (ccid)[native-inputs]: Move pcsc-lite back to... [inputs]: ...here. Signed-off-by: Efraim Flashner --- gnu/packages/security-token.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 06e5620cd3..7d822f491f 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm @@ -87,11 +87,11 @@ (("/bin/echo") (which "echo"))) #t))))) (native-inputs - `(("pcsc-lite" ,pcsc-lite) ; only required for headers - ("perl" ,perl) + `(("perl" ,perl) ("pkg-config" ,pkg-config))) (inputs - `(("libusb" ,libusb))) + `(("libusb" ,libusb) + ("pcsc-lite" ,pcsc-lite))) (home-page "https://ccid.apdu.fr/") (synopsis "PC/SC driver for USB smart card devices") (description -- cgit v1.2.3 From 6e95e7d25f27fac4a5d017f6c2ea3e2d16c2f8c4 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 17:34:08 -0500 Subject: gnu: Add go-github-com-leodido-go-urn. * gnu/packages/golang.scm (go-github-com-leodido-go-urn): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index c41ed0bb1a..bbd18cf932 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -487,6 +487,31 @@ jar struct to manage the cookies added to the cookie jar.") (home-page "https://github.com/aki237/nscjar") (license license:expat)))) +(define-public go-github-com-leodido-go-urn + (package + (name "go-github-com-leodido-go-urn") + (version "1.2.0") + (home-page "https://github.com/leodido/go-urn") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1d4g1vkhc1180l1n7q48vl84b27c7cziywml78cyijbcdz2f8vim")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/leodido/go-urn")) + (native-inputs + `(("go-github-com-stretchr-testify" ,go-github-com-stretchr-testify))) + (synopsis "Parser for uniform resource names as seen on RFC 2141") + (description + "This package implements a parser for uniform resource names (URN) as +specified by @uref{https://tools.ietf.org/html/rfc2141, IETF RFC 2141}.") + (license license:expat))) + (define-public go-github.com-jessevdk-go-flags (package (name "go-github.com-jessevdk-go-flags") -- cgit v1.2.3 From 398f5b49a4890e2a3cfd6014bcd6c9975232da88 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 20:37:37 -0500 Subject: gnu: Add go-github-com-go-playground-locales. * gnu/packages/golang.scm (go-github-com-go-playground-locales): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index bbd18cf932..32b89fab33 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -537,6 +537,40 @@ way of specifying command line options.") (home-page "https://github.com/jessevdk/go-flags") (license license:bsd-3))) +(define-public go-github-com-go-playground-locales + (package + (name "go-github-com-go-playground-locales") + (version "0.13.0") + (home-page "https://github.com/go-playground/locales") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0qydcpkvss3mf8mk3xzg6a34n8i69aydrigcl2apifrkx72jw7pf")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/go-playground/locales")) + (synopsis "Set of locales generated from the CLDR Unicode Project") + (description + "This package provides a set of locales generated from the +@uref{http://cldr.unicode.org/, Unicode CLDR Project} which can be used +independently or within an internalization (i18n) package. Its currently +implemented features include + +@itemize +@item Rules generated from the CLDR data, v31.0.3 +@item Contains Cardinal, Ordinal and Range Plural Rules +@item Contains Month, Weekday and Timezone translations built in +@item Contains Date & Time formatting functions +@item Contains Number, Currency, Accounting and Percent formatting functions +@item Supports the \"Gregorian\" calendar only +@end itemize") + (license license:expat))) + (define-public go-github-com-aws-sdk (package (name "go-github-com-aws-sdk") -- cgit v1.2.3 From ac7174b33d8ad587ade32d27f8a5b45ce99280b9 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 20:42:08 -0500 Subject: gnu: Add go-github-com-go-playground-universal-translator. * gnu/packages/golang.scm (go-github-com-go-playground-universal-translator): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 32b89fab33..b122bca378 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -571,6 +571,44 @@ implemented features include @end itemize") (license license:expat))) +(define-public go-github-com-go-playground-universal-translator + (package + (name "go-github-com-go-playground-universal-translator") + (version "0.17.0") + (home-page "https://github.com/go-playground/universal-translator") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1zdiaisb32iv4x93cpbqrgx8ll7sxh4hcd2iibpswy4bwvjbjlz6")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/go-playground/universal-translator")) + (propagated-inputs + `(("go-github-com-go-playground-locales" ,go-github-com-go-playground-locales))) + (synopsis "Translator using Unicode CLDR data and pluralization rules") + (description + "This package offers an Internalization Translator for Go using +@uref{http://cldr.unicode.org/, Unicode CLDR Project} data and pluralization +rules. Its currently implemented features include + +@itemize +@item Rules generated from the CLDR data, v30.0.3 +@item Contains Cardinal, Ordinal and Range Plural Rules +@item Contains Month, Weekday and Timezone translations built in +@item Contains Date & Time formatting functions +@item Contains Number, Currency, Accounting and Percent formatting functions +@item Supports the \"Gregorian\" calendar only +@item Support loading translations from files +@item Exporting translations to file(s), mainly for getting them +professionally translated +@end itemize") + (license license:expat))) + (define-public go-github-com-aws-sdk (package (name "go-github-com-aws-sdk") -- cgit v1.2.3 From 0023c76d68a4ec0145a323b7e90a955d6dc10ce0 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 23:21:41 -0500 Subject: gnu: Add go-gopkg-in-go-playground-assert-v1. * gnu/packages/golang.scm (go-gopkg-in-go-playground-assert-v1): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index b122bca378..5ee70c588b 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -537,6 +537,29 @@ way of specifying command line options.") (home-page "https://github.com/jessevdk/go-flags") (license license:bsd-3))) +(define-public go-gopkg-in-go-playground-assert-v1 + (package + (name "go-gopkg-in-go-playground-assert-v1") + (version "1.2.1") + (home-page "https://github.com/go-playground/assert") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1h4amgykpa0djwi619llr3g55p75ia0mi184h9s5zdl8l4rhn9pm")))) + (build-system go-build-system) + (arguments + '(#:import-path "gopkg.in/go-playground/assert.v1")) + (synopsis "Basic assertion library used alongside native Go testing") + (description + "This package provides bassic assertions along with building blocks for +custom assertions to be used alongside native Go testing.") + (license license:expat))) + (define-public go-github-com-go-playground-locales (package (name "go-github-com-go-playground-locales") -- cgit v1.2.3 From 19be547c47c846778698bcf1375687dda1e41fb5 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 23:42:48 -0500 Subject: gnu: Add go-gopkg-in-go-playground-validator-v9. * gnu/packages/golang.scm (go-gopkg-in-go-playground-validator-v9): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 5ee70c588b..93e431ff0f 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -632,6 +632,55 @@ professionally translated @end itemize") (license license:expat))) +(define-public go-gopkg-in-go-playground-validator-v9 + (package + (name "go-gopkg-in-go-playground-validator-v9") + (version "9.31.0") + (home-page "https://gopkg.in/go-playground/validator.v9") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/go-playground/validator") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1f8c77s8kx9rip2jarv27x5s4xkcmanh4ndyhbcwvrhncs5rq061")))) + (build-system go-build-system) + (arguments + '(#:import-path "gopkg.in/go-playground/validator.v9")) + (native-inputs + `(("go-gopkg-in-go-playground-assert-v1" + ,go-gopkg-in-go-playground-assert-v1))) + (propagated-inputs + `(("go-github-com-go-playground-universal-translator" + ,go-github-com-go-playground-universal-translator) + ("go-github-com-leodido-go-urn" ,go-github-com-leodido-go-urn))) + (synopsis "Validator for structs and individual fields based on tags") + (description + "This package implements value validations for structs and individual +fields based on tags. It has the following unique features: + +@itemize +@item Cross Field and Cross Struct validations by using validation tags or +custom validators +@item Slice, Array and Map diving, which allows any or all levels of a +multidimensional field to be validated +@item Ability to dive into both map keys and values for validation +@item Handles type interface by determining it's underlying type prior to validation +@item Handles custom field types such as sql driver +@uref{https://golang.org/src/database/sql/driver/types.go?s=1210:1293#L29, +Valuer} +@item Alias validation tags, which allows for mapping of several validations +to a single tag for easier defining of validations on structs +@item Extraction of custom defined Field Name e.g. can specify to extract the +JSON name while validating and have it available in the resulting FieldError +@item Customizable i18n aware error messages. +@item Default validator for the @uref{https://github.com/gin-gonic/gin, gin} +web framework +@end itemize") + (license license:expat))) + (define-public go-github-com-aws-sdk (package (name "go-github-com-aws-sdk") -- cgit v1.2.3 From dafcf2fcc015e66a7924597193f0f012dad1d0d6 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 26 Jul 2020 23:55:03 -0500 Subject: gnu: Add go-github-com-goccy-yaml. * gnu/packages/golang.scm (go-github-com-goccy-yaml): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 93e431ff0f..12529439b3 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -6484,6 +6484,43 @@ systems can import this package to enable running programs as services without modifying them.") (license license:zlib))) +(define-public go-github-com-goccy-yaml + (package + (name "go-github-com-goccy-yaml") + (version "1.8.0") + (home-page "https://github.com/goccy/go-yaml") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1nps58dwkd915mx35h5f0dc05b880b4fdl6dcjxpfmmbzyinvg38")))) + (build-system go-build-system) + (arguments + `(#:import-path "github.com/goccy/go-yaml")) + (propagated-inputs + `(("go-github-com-fatih-color" ,go-github-com-fatih-color) + ("go-golang-org-x-xerrors" ,go-golang-org-x-xerrors))) + (native-inputs + `(("go-gopkg-in-go-playground-validator-v9" + ,go-gopkg-in-go-playground-validator-v9))) + (synopsis "YAML support for the Go language") + (description + "This package provides features beyond the +@uref{https://github.com/go-yaml/yaml, defacto YAML library} including: + +@itemize +@item Pretty format for error notifications +@item Support Scanner or Lexer or Parser as public API +@item Support Anchor and Alias to Marshaler +@item Allow referencing elements declared in another file via anchors +@item Extract value or AST by YAMLPath (YAMLPath is like a JSONPath) +@end itemize") + (license license:expat))) + (define-public go-github.com-ulikunitz-xz (package (name "go-github.com-ulikunitz-xz") -- cgit v1.2.3 From 79d5a18116d597df9e3d6b607164947d3aed6c2f Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Mon, 27 Jul 2020 00:12:06 -0500 Subject: gnu: Add go-github-com-songmu-gitconfig. * gnu/packages/golang.scm (go-github-com-songmu-gitconfig): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 12529439b3..60535e07bd 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -6542,3 +6542,29 @@ modifying them.") compressed streams in Go.") (home-page "https://github.com/ulikunitz/xz") (license license:bsd-3))) + +(define-public go-github-com-songmu-gitconfig + (package + (name "go-github-com-songmu-gitconfig") + (version "0.1.0") + (home-page "https://github.com/songmu/gitconfig") + (source + (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1y01h496a7pfj1g2bclls5b0nl3vnj7nz610jj1dzq9kxrwxk7fk")))) + (build-system go-build-system) + (arguments + `(#:import-path "github.com/Songmu/gitconfig" + ;; Package's tests appear to be hardcoded to the author's gitconfig + ;; and require network access. + #:tests? #f)) + (propagated-inputs + `(("go-github-com-goccy-yaml" ,go-github-com-goccy-yaml))) + (synopsis "Go library to get configuration values from gitconfig") + (description "@{gitconfig} is a package to get configuration values from gitconfig.") + (license license:expat))) -- cgit v1.2.3 From 0a7d6e87bb2d56d68cc4e8d09860c9aa494485ac Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 21:35:04 -0600 Subject: gnu: Add go-github-com-golangplus-fmt. * gnu/packages/golang.scm (go-github-com-golangplus-fmt): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 60535e07bd..cd5644bb0f 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -487,6 +487,26 @@ jar struct to manage the cookies added to the cookie jar.") (home-page "https://github.com/aki237/nscjar") (license license:expat)))) +(define-public go-github-com-golangplus-fmt + (package + (name "go-github-com-golangplus-fmt") + (version "1.0.0") + (home-page "https://github.com/golangplus/fmt") + (source (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "07d5kxz0f8ss3v46y0c8jg02sagi0wlaaijhjzzp0r462jyzqii7")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/golangplus/fmt")) + (synopsis "Additions to Go's standard @code{fmt} package") + (description "This package provides additions to Go's stdlib @code{fmt}.") + (license license:bsd-3))) + (define-public go-github-com-leodido-go-urn (package (name "go-github-com-leodido-go-urn") -- cgit v1.2.3 From 0d8f28e9de3e14b5eba58e551b674f54a3294aae Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 21:35:55 -0600 Subject: gnu: Add go-github-com-golangplus-testing. * gnu/packages/golang.scm (go-github-com-golangplus-testing): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index cd5644bb0f..64afc4b48d 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -507,6 +507,28 @@ jar struct to manage the cookies added to the cookie jar.") (description "This package provides additions to Go's stdlib @code{fmt}.") (license license:bsd-3))) +(define-public go-github-com-golangplus-testing + (package + (name "go-github-com-golangplus-testing") + (version "1.0.0") + (home-page "https://github.com/golangplus/testing") + (source (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1a29m4zplf9m14k74lrb55dids2l17vx28sv0g3y3qcv1xygksiv")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/golangplus/testing")) + (propagated-inputs + `(("go-github-com-golangplus-fmt" ,go-github-com-golangplus-fmt))) + (synopsis "Additions to Go's standard testing package") + (description "This package provides additions to Go's stdlib testing.") + (license license:bsd-3))) + (define-public go-github-com-leodido-go-urn (package (name "go-github-com-leodido-go-urn") -- cgit v1.2.3 From da3335b5f6a412f628594c8cc483bb5b1fb88311 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 21:36:52 -0600 Subject: gnu: Add go-github-com-daviddengcn-go-colortext. * gnu/packages/golang.scm (go-github-com-daviddengcn-go-colortext): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 64afc4b48d..e492c6077f 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -507,6 +507,33 @@ jar struct to manage the cookies added to the cookie jar.") (description "This package provides additions to Go's stdlib @code{fmt}.") (license license:bsd-3))) +(define-public go-github-com-daviddengcn-go-colortext + (package + (name "go-github-com-daviddengcn-go-colortext") + (version "1.0.0") + (home-page "https://github.com/daviddengcn/go-colortext") + (source (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0j5ldwg3a768d3nniiglghr9axj4p87k7f7asqxa1a688xvcms48")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/daviddengcn/go-colortext")) + (native-inputs + `(("go-github-com-golangplus-testing" ,go-github-com-golangplus-testing))) + (synopsis "Change the color of console text and background") + (description + "This is a package to change the color of the text and background in the +console, working both under Windows and other systems. + +Under Windows, the console APIs are used. Otherwise, ANSI texts are output.") + ;; dual-licensed + (license (list license:bsd-3 license:expat)))) + (define-public go-github-com-golangplus-testing (package (name "go-github-com-golangplus-testing") -- cgit v1.2.3 From 6296c032a3295a5a1920d432a595897ccd99cf48 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 21:38:18 -0600 Subject: gnu: Add go-github-com-motemen-go-colorine. * gnu/packages/golang.scm (go-github-com-motemen-go-colorine): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index e492c6077f..4cdd6d4e57 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -507,6 +507,31 @@ jar struct to manage the cookies added to the cookie jar.") (description "This package provides additions to Go's stdlib @code{fmt}.") (license license:bsd-3))) +(define-public go-github-com-motemen-go-colorine + (let ((commit "45d19169413a019e4e2be69629dde5c7d92f8706") + (revision "0")) + (package + (name "go-github-com-motemen-go-colorine") + (version (git-version "0.0.0" revision commit)) + (home-page "https://github.com/motemen/go-colorine") + (source (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1mdy6q0926s1frj027nlzlvm2qssmkpjis7ic3l2smajkzh07118")))) + (build-system go-build-system) + (arguments + '(#:import-path "github.com/motemen/go-colorine")) + (inputs + `(("github.com/daviddengcn/go-colortext" ,go-github-com-daviddengcn-go-colortext))) + (synopsis "Simple colorized console logger for golang") + (description + "This package provides simple colorized console logger for golang.") + (license license:expat)))) + (define-public go-github-com-daviddengcn-go-colortext (package (name "go-github-com-daviddengcn-go-colortext") -- cgit v1.2.3 From 289385f0de53cda4583b88ed21c5e3d32af478fd Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 21:52:02 -0600 Subject: gnu: Add go-golang.org-x-net-html. * gnu/packages/golang.scm (go-golang.org-x-net-html): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 4cdd6d4e57..414d671a75 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -1063,6 +1063,18 @@ for the Go language.") (home-page "https://go.googlesource.com/net") (license license:bsd-3)))) +(define-public go-golang-org-x-net-html + (package + (inherit go-golang-org-x-net) + (name "go-golang.org-x-net-html") + (arguments + '(#:import-path "golang.org/x/net/html" + #:unpack-path "golang.org/x/net")) + (synopsis "HTML5-compliant tokenizer and parser") + (description + "This package provides an HTML5-compliant tokenizer and parser.") + (home-page "https://godoc.org/golang.org/x/net/html"))) + (define-public go-golang-org-x-image (let ((commit "58c23975cae11f062d4b3b0c143fe248faac195d") (revision "1")) -- cgit v1.2.3 From 10a8bf02bcc3b41cec13ed1badbbe33dcf53b70d Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 22:00:53 -0600 Subject: gnu: Add go-github-com-urfave-cli-v2. * gnu/packages/golang.scm (go-github-com-urfave-cli-v2): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/golang.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 414d671a75..f9a32d11c0 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -3600,6 +3600,23 @@ building command line apps in Go. The goal is to enable developers to write fast and distributable command line applications in an expressive way.") (license license:expat))) +(define-public go-github-com-urfave-cli-v2 + (package + (inherit go-github-com-urfave-cli) + (name "go-github-com-urfave-cli-v2") + (version "2.3.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/urfave/cli") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "08pvn7gyfznni72xrxfh2x6xxa8ykr7l1ka278js8g8qkh71bj8l")))) + (arguments + '(#:import-path "github.com/urfave/cli/v2")))) + (define-public go-github-com-go-md2man (package (name "go-github-com-go-md2man") -- cgit v1.2.3 From 7c037ce947b3304e4cb65a23e21133b9a114e47d Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 17:00:36 +0200 Subject: gnu: go-github-com-motemen-go-colorine: Propagate inputs. * gnu/packages/golang.scm (go-github-com-motemen-go-colorine)[inputs]: Move go-github-com-daviddengcn-go-colortext ... [propagated-inputs]: ... to here. --- gnu/packages/golang.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index f9a32d11c0..d34bb1acb7 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -525,7 +525,7 @@ jar struct to manage the cookies added to the cookie jar.") (build-system go-build-system) (arguments '(#:import-path "github.com/motemen/go-colorine")) - (inputs + (propagated-inputs `(("github.com/daviddengcn/go-colortext" ,go-github-com-daviddengcn-go-colortext))) (synopsis "Simple colorized console logger for golang") (description -- cgit v1.2.3 From 2cb5ebf7a89b59e3e220b837202e4469e1db38c7 Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Sun, 8 Nov 2020 13:11:51 -0600 Subject: gnu: Add ghq. * gnu/packages/version-control.scm (ghq): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/version-control.scm | 51 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index cc0d8e3148..5eaaf2681e 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -2963,3 +2963,54 @@ commit message side by side If several repos are related, it helps to see their status together.") (license license:expat)))) + +(define-public ghq + (package + (name "ghq") + (version "1.1.5") + (home-page "https://github.com/x-motemen/ghq") + (source (origin + (method git-fetch) + (uri (git-reference + (url home-page) + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "098fik155viylq07az7crzbgswcvhpx0hr68xpvyx0rpri792jbq")))) + (build-system go-build-system) + (arguments + '(#:install-source? #f + #:import-path "github.com/x-motemen/ghq" + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-completions + (lambda* (#:key outputs import-path #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bash-completion (string-append out "/etc/bash_completion.d")) + (zsh-completion (string-append out "/share/zsh/site-functions"))) + (with-directory-excursion (string-append "src/" import-path) + (mkdir-p bash-completion) + (copy-file "misc/bash/_ghq" + (string-append bash-completion "/ghq")) + (mkdir-p zsh-completion) + (copy-file "misc/zsh/_ghq" + (string-append zsh-completion "/_ghq")))) + #t))))) + (native-inputs + `(("git" ,git-minimal))) + (inputs + `(("github.com/songmu/gitconfig" ,go-github-com-songmu-gitconfig) + ("github.com/mattn/go-isatty" ,go-github-com-mattn-go-isatty) + ("github.com/motemen/go-colorine" ,go-github-com-motemen-go-colorine) + ("github.com/saracen/walker" ,go-github-com-saracen-walker) + ("github.com/urfave/cli/v2" ,go-github-com-urfave-cli-v2) + ("golang.org/x/net/html" ,go-golang-org-x-net-html) + ("golang.org/x/sync/errgroup" ,go-golang.org-x-sync-errgroup))) + (synopsis "Manage remote repository clones") + (description + "@code{ghq} provides a way to organize remote repository clones, like +@code{go get} does. When you clone a remote repository by @code{ghq get}, ghq +makes a directory under a specific root directory (by default @file{~/ghq}) +using the remote repository URL's host and path.") + (license license:expat))) -- cgit v1.2.3 From 9d34b04f40aa510ba910a15a64ab8d8c8d1b6fd3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20K=C4=85dzio=C5=82ka?= Date: Fri, 1 Jan 2021 18:26:51 +0100 Subject: /etc/profile.d/guix.sh: Add guix pull profile even when absent * etc/guix-install.sh (sys_create_init_profile): Set PATH and INFOPATH even when $_GUIX_PROFILE does not exist. After initial installation on a foreign distro, the guix pull profile won't be present in path. This means that the first guix pull won't take effect until the shell is restarted. ~/.guix-profile cannot be pre-loaded like this as the relevant paths are stored in ~/.guix-profile/etc/profile, which simply won't exist. However, guix package will output a relevant hint that instructs the user to reload the profile, so this isn't a problem. --- etc/guix-install.sh | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/etc/guix-install.sh b/etc/guix-install.sh index 9015f40bb6..94c04aa646 100755 --- a/etc/guix-install.sh +++ b/etc/guix-install.sh @@ -7,6 +7,7 @@ # Copyright © 2020 Morgan Smith # Copyright © 2020 Simon Tournier # Copyright © 2020 Daniel Brooks +# Copyright © 2021 Jakub Kądziołka # # This file is part of GNU Guix. # @@ -454,14 +455,12 @@ sys_create_init_profile() cat <<"EOF" > /etc/profile.d/guix.sh # _GUIX_PROFILE: `guix pull` profile _GUIX_PROFILE="$HOME/.config/guix/current" -if [ -L $_GUIX_PROFILE ]; then - export PATH="$_GUIX_PROFILE/bin${PATH:+:}$PATH" - # Export INFOPATH so that the updated info pages can be found - # and read by both /usr/bin/info and/or $GUIX_PROFILE/bin/info - # When INFOPATH is unset, add a trailing colon so that Emacs - # searches 'Info-default-directory-list'. - export INFOPATH="$_GUIX_PROFILE/share/info:$INFOPATH" -fi +export PATH="$_GUIX_PROFILE/bin${PATH:+:}$PATH" +# Export INFOPATH so that the updated info pages can be found +# and read by both /usr/bin/info and/or $GUIX_PROFILE/bin/info +# When INFOPATH is unset, add a trailing colon so that Emacs +# searches 'Info-default-directory-list'. +export INFOPATH="$_GUIX_PROFILE/share/info:$INFOPATH" # GUIX_PROFILE: User's default profile GUIX_PROFILE="$HOME/.guix-profile" -- cgit v1.2.3 From 60e1fa208a0a91d7de9e786412d97638268b348c Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 14:59:50 -0500 Subject: gnu: pidgin: Make some cosmetic changes. * gnu/packages/messaging.scm (pidgin): Make some cosmetic changes. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 57 +++++++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 26 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 946be3bfa5..2e3deee971 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -719,14 +719,17 @@ authentication.") (source (origin (method url-fetch) - (uri (string-append "mirror://sourceforge/pidgin/Pidgin/" - version "/pidgin-" version ".tar.bz2")) + (uri + (string-append "mirror://sourceforge/pidgin/Pidgin/" + version "/pidgin-" version ".tar.bz2")) (sha256 (base32 "13vdqj70315p9rzgnbxjp9c51mdzf1l4jg1kvnylc4bidw61air7")) - (patches (search-patches "pidgin-add-search-path.patch" - ;; Remove the snippet and bootstrapping - ;; native-inputs together with this patch. - "pidgin-libnm.patch")) + (patches + (search-patches + "pidgin-add-search-path.patch" + ;; Remove the snippet and bootstrapping + ;; native-inputs together with this patch. + "pidgin-libnm.patch")) (modules '((guix build utils))) (snippet '(begin @@ -741,7 +744,6 @@ authentication.") ("gconf" ,gconf) ("python" ,python-2) ("doxygen" ,doxygen) - ;; For bootstrapping after applying pidgin-libnm.patch. ("autoconf" ,autoconf) ("automake" ,automake) @@ -774,30 +776,33 @@ authentication.") ("startup-notification" ,startup-notification))) (arguments `(#:configure-flags - (list "--disable-gtkspell" - "--disable-tcl" - "--disable-meanwhile" - "--disable-vv" ; XXX remove when we have farstream and gstreamer - "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 - "--enable-cyrus-sasl" - (string-append "--with-ncurses-headers=" - (assoc-ref %build-inputs "ncurses") - "/include")))) + (list + "--disable-gtkspell" + "--disable-tcl" + "--disable-meanwhile" + "--disable-vv" ; XXX remove when we have farstream and gstreamer + "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 + "--enable-cyrus-sasl" + (string-append "--with-ncurses-headers=" + (assoc-ref %build-inputs "ncurses") + "/include")))) (native-search-paths - (list (search-path-specification - (variable "PURPLE_PLUGIN_PATH") - (files (list (string-append "lib/purple-" - (version-major version)) - "lib/pidgin"))))) + (list + (search-path-specification + (variable "PURPLE_PLUGIN_PATH") + (files + (list + (string-append "lib/purple-" + (version-major version)) + "lib/pidgin"))))) (home-page "https://www.pidgin.im/") (synopsis "Graphical multi-protocol instant messaging client") - (description - "Pidgin is a modular instant messaging client that supports many popular -chat protocols.") + (description "Pidgin is a modular instant messaging client that supports +many popular chat protocols.") (license (list - license:gpl2+ ; Most of the code - license:lgpl2.1 ; GG protocol plugin (libpurple/protocols/gg/lib) + license:gpl2+ ; Most of the code + license:lgpl2.1 ; GG protocol plugin (libpurple/protocols/gg/lib) license:lgpl2.0+ ; OSCAR protocol plugin (libpurple/protocols/oscar) ;; The following licenses cover the zephyr protocol plugin: (license:non-copyleft -- cgit v1.2.3 From 7b1dccfb50a54a925998dc4e737e38d0d9a43927 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 15:08:25 -0500 Subject: gnu: pidgin: Re-arrange inputs in alphabetical order. * gnu/packages/messaging.scm (pidgin) [native-inputs]: Re-order. [inputs]: Re-order. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 44 +++++++++++++++++++++----------------------- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 2e3deee971..8b11e2105f 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -738,41 +738,39 @@ authentication.") #t)))) (build-system glib-or-gtk-build-system) (native-inputs - `(("pkg-config" ,pkg-config) - ("check" ,check-0.14) - ("intltool" ,intltool) + `(("autoconf" ,autoconf) ;; For bootstrap + ("automake" ,automake) ;; For bootstrap + ("check" ,check) ("gconf" ,gconf) - ("python" ,python-2) - ("doxygen" ,doxygen) - ;; For bootstrapping after applying pidgin-libnm.patch. - ("autoconf" ,autoconf) - ("automake" ,automake) - ("libtool" ,libtool))) + ("intltool" ,intltool) + ("libtool" ,libtool) ;; For bootstrap + ("pkg-config" ,pkg-config) + ("python" ,python-2))) (inputs - `(("gtk+" ,gtk+-2) - ("libgcrypt" ,libgcrypt) - ("gnutls" ,gnutls) + `(("avahi" ,avahi) ("cyrus-sasl" ,cyrus-sasl) ("dbus" ,dbus) ("dbus-glib" ,dbus-glib) - ("python2-dbus" ,python2-dbus) + ;; farstream + ("gnutls" ,gnutls) + ;; gstreamer + ("gtk+" ,gtk+-2) + ;; gtkspell + ;; libgadu + ("libgcrypt" ,libgcrypt) + ("libice" ,libice) ("libidn" ,libidn) ("libltdl" ,libltdl) + ("libsm" ,libsm) + ;; libxephyr ("libxml2" ,libxml2) - ;; TODO: gstreamer: patches needed to support gstreamer-1.0 or later - ;; TODO: farstream - ;; TODO: meanwhile - ;; TODO: gtkspell - ;; TODO: libxephyr - ;; TODO: libgadu + ("libxscrnsaver" ,libxscrnsaver) ("libxslt" ,libxslt) - ("avahi" ,avahi) + ;; meanwhile ("ncurses" ,ncurses) ("network-manager" ,network-manager) + ("python2-dbus" ,python2-dbus) ("sqlite" ,sqlite) - ("libice" ,libice) - ("libsm" ,libsm) - ("libxscrnsaver" ,libxscrnsaver) ("startup-notification" ,startup-notification))) (arguments `(#:configure-flags -- cgit v1.2.3 From 10f32ae27f85a9c549e4dbb3b87773221915b492 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 23:57:17 -0500 Subject: gnu: pidgin: Add missing inputs. These new inputs are referenced by the package but was missing in the package definition. Some of these inputs might have been used by the package indirectly via propagation from other inputs. * gnu/packages/messaging.scm (pidgin) [native-inputs]: Add graphviz. Move python-2 to ... [inputs]: ... here. Add libgnt, libx11, libxext, nspr, nss, pango and perl. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 31 +++++++++++++++++++++++-------- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 8b11e2105f..62584dab59 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -72,6 +72,7 @@ #:use-module (gnu packages gnome) #:use-module (gnu packages gnupg) #:use-module (gnu packages gperf) + #:use-module (gnu packages graphviz) #:use-module (gnu packages gstreamer) #:use-module (gnu packages gtk) #:use-module (gnu packages guile) @@ -88,6 +89,7 @@ #:use-module (gnu packages mpd) #:use-module (gnu packages ncurses) #:use-module (gnu packages networking) + #:use-module (gnu packages nss) #:use-module (gnu packages pcre) #:use-module (gnu packages perl) #:use-module (gnu packages photo) @@ -741,37 +743,50 @@ authentication.") `(("autoconf" ,autoconf) ;; For bootstrap ("automake" ,automake) ;; For bootstrap ("check" ,check) + ("dot" ,graphviz) ("gconf" ,gconf) ("intltool" ,intltool) ("libtool" ,libtool) ;; For bootstrap - ("pkg-config" ,pkg-config) - ("python" ,python-2))) + ("pkg-config" ,pkg-config))) (inputs `(("avahi" ,avahi) ("cyrus-sasl" ,cyrus-sasl) ("dbus" ,dbus) ("dbus-glib" ,dbus-glib) - ;; farstream + ;; ("evolution-data-server" ,evolution-data-server) + ;; ("farstream" ,farstream) ("gnutls" ,gnutls) - ;; gstreamer + ;; ("gstreamer" ,gstreamer) ("gtk+" ,gtk+-2) - ;; gtkspell - ;; libgadu + ;; ("gtkspell2" ,gtkspell2) + ;; ("libgadu" ,libgadu) ("libgcrypt" ,libgcrypt) + ("libgnt" ,libgnt) ("libice" ,libice) ("libidn" ,libidn) ("libltdl" ,libltdl) ("libsm" ,libsm) - ;; libxephyr + ("libx11" ,libx11) + ("libxext" ,libxext) ("libxml2" ,libxml2) ("libxscrnsaver" ,libxscrnsaver) ("libxslt" ,libxslt) - ;; meanwhile + ;; ("libzephyr" ,libzephyr) + ;; ("meanwhile" ,meanwhile) + ;; ("mono" ,mono) ("ncurses" ,ncurses) ("network-manager" ,network-manager) + ("nspr" ,nspr) + ("nss" ,nss) + ("pango" ,pango) + ("perl" ,perl) + ("python" ,python-2) ("python2-dbus" ,python2-dbus) + ;; ("silc" ,silc-toolkit) ("sqlite" ,sqlite) ("startup-notification" ,startup-notification))) + (propagated-inputs + `(("glib" ,glib))) (arguments `(#:configure-flags (list -- cgit v1.2.3 From d02ada47f81353df544f7583d2a09173d5a66637 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:03:35 -0500 Subject: gnu: pidgin: Enable support for mono. * gnu/packages/messaging.scm (pidgin) [inputs]: Add mono. [arguments]<#:configure-flags>[--enable-mono]: New flag. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 62584dab59..7ae85aba49 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -86,6 +86,7 @@ #:use-module (gnu packages lua) #:use-module (gnu packages man) #:use-module (gnu packages markup) + #:use-module (gnu packages mono) #:use-module (gnu packages mpd) #:use-module (gnu packages ncurses) #:use-module (gnu packages networking) @@ -773,7 +774,7 @@ authentication.") ("libxslt" ,libxslt) ;; ("libzephyr" ,libzephyr) ;; ("meanwhile" ,meanwhile) - ;; ("mono" ,mono) + ("mono" ,mono) ("ncurses" ,ncurses) ("network-manager" ,network-manager) ("nspr" ,nspr) @@ -793,6 +794,7 @@ authentication.") "--disable-gtkspell" "--disable-tcl" "--disable-meanwhile" + "--enable-mono" "--disable-vv" ; XXX remove when we have farstream and gstreamer "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 "--enable-cyrus-sasl" -- cgit v1.2.3 From 80ecda973bbdc9d812958637599999bd66c19f8c Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:05:14 -0500 Subject: gnu: pidgin: Enable meanwhile. * gnu/packages/messaging.scm (pidgin) [inputs]: Add meanwhile. [arguments]<#:configure-flags>[--disable-meanwhile]: Remove flag. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 7ae85aba49..7a3ee030d4 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -773,7 +773,7 @@ authentication.") ("libxscrnsaver" ,libxscrnsaver) ("libxslt" ,libxslt) ;; ("libzephyr" ,libzephyr) - ;; ("meanwhile" ,meanwhile) + ("meanwhile" ,meanwhile) ("mono" ,mono) ("ncurses" ,ncurses) ("network-manager" ,network-manager) @@ -793,7 +793,6 @@ authentication.") (list "--disable-gtkspell" "--disable-tcl" - "--disable-meanwhile" "--enable-mono" "--disable-vv" ; XXX remove when we have farstream and gstreamer "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 -- cgit v1.2.3 From 1b80f6703cedb0325c46edad87f27a44d67d17d0 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:07:24 -0500 Subject: gnu: pidgin: Enable CAP. * gnu/packages/messaging.scm (pidgin) [arguments]<#:configure-flags> [--enable-cap]: New flag. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 7a3ee030d4..eaeec90cdf 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -792,6 +792,8 @@ authentication.") `(#:configure-flags (list "--disable-gtkspell" + ;; "--enable-gevolution" + "--enable-cap" "--disable-tcl" "--enable-mono" "--disable-vv" ; XXX remove when we have farstream and gstreamer -- cgit v1.2.3 From 43ba7a9b1d1c123c43bd2ecb2f123a93b0fadbc6 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:09:56 -0500 Subject: gnu: pidgin: Enable SILC protocol support. * gnu/packages/messaging.scm (pidgin) [inputs]: Add silc-toolkit. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index eaeec90cdf..3208c5e671 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -783,7 +783,7 @@ authentication.") ("perl" ,perl) ("python" ,python-2) ("python2-dbus" ,python2-dbus) - ;; ("silc" ,silc-toolkit) + ("silc" ,silc-toolkit) ("sqlite" ,sqlite) ("startup-notification" ,startup-notification))) (propagated-inputs -- cgit v1.2.3 From 823567803f5afd9edf663b29b4e62ac0581cbfec Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:11:49 -0500 Subject: gnu: pidgin: Enable support for Tcl. * gnu/packages/messaging.scm (pidgin) [inputs]: Add Tcl. [arguments]<#:configure-flags>[--disable-tcl]: Remove flag. [--with-tclconfig]: New flag. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 3208c5e671..7f6b2df834 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -785,7 +785,8 @@ authentication.") ("python2-dbus" ,python2-dbus) ("silc" ,silc-toolkit) ("sqlite" ,sqlite) - ("startup-notification" ,startup-notification))) + ("startup-notification" ,startup-notification) + ("tcl" ,tcl))) (propagated-inputs `(("glib" ,glib))) (arguments @@ -801,7 +802,10 @@ authentication.") "--enable-cyrus-sasl" (string-append "--with-ncurses-headers=" (assoc-ref %build-inputs "ncurses") - "/include")))) + "/include") + (string-append "--with-tclconfig=" + (assoc-ref %build-inputs "tcl") + "/lib")))) (native-search-paths (list (search-path-specification -- cgit v1.2.3 From f0e429a21809d5e5722cd1638ba3f666b3b1edb2 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:14:25 -0500 Subject: gnu: pidgin: Enable support for Tk. * gnu/packages/messaging.scm (pidgin) [inputs]: Add tk. [arguments]<#:configure-flags>[--with-tkconfig]: New flag. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 7f6b2df834..bb449b5c0f 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -786,7 +786,8 @@ authentication.") ("silc" ,silc-toolkit) ("sqlite" ,sqlite) ("startup-notification" ,startup-notification) - ("tcl" ,tcl))) + ("tcl" ,tcl) + ("tk" ,tk))) (propagated-inputs `(("glib" ,glib))) (arguments @@ -795,7 +796,6 @@ authentication.") "--disable-gtkspell" ;; "--enable-gevolution" "--enable-cap" - "--disable-tcl" "--enable-mono" "--disable-vv" ; XXX remove when we have farstream and gstreamer "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 @@ -805,6 +805,9 @@ authentication.") "/include") (string-append "--with-tclconfig=" (assoc-ref %build-inputs "tcl") + "/lib") + (string-append "--with-tkconfig=" + (assoc-ref %build-inputs "tk") "/lib")))) (native-search-paths (list -- cgit v1.2.3 From 89f4f0baa9ff956ba0efe9ec20e1805f01230a54 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Sun, 29 Nov 2020 17:30:04 -0500 Subject: gnu: pidgin: Upgrade to 2.14.1. * gnu/packages/messaging.scm (pidgin) [version]: Modify. [source][sha256]: Modify base32. [patches][pidgin-libnm.patch]: Remove obsolete patch. * gnu/packages/patches/pidgin-libnm.patch: Remove file. * gnu/local.mk (dist_patch_DATA): Remove entry. Signed-off-by: Danny Milosavljevic --- gnu/local.mk | 1 - gnu/packages/messaging.scm | 13 +++---- gnu/packages/patches/pidgin-libnm.patch | 60 --------------------------------- 3 files changed, 5 insertions(+), 69 deletions(-) delete mode 100644 gnu/packages/patches/pidgin-libnm.patch diff --git a/gnu/local.mk b/gnu/local.mk index c03a8b9f51..0aad15740c 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1471,7 +1471,6 @@ dist_patch_DATA = \ %D%/packages/patches/picard-fix-id3-rename-test.patch \ %D%/packages/patches/picprog-non-intel-support.patch \ %D%/packages/patches/pidgin-add-search-path.patch \ - %D%/packages/patches/pidgin-libnm.patch \ %D%/packages/patches/pinball-const-fix.patch \ %D%/packages/patches/pinball-cstddef.patch \ %D%/packages/patches/pinball-missing-separators.patch \ diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index bb449b5c0f..45b6c5e8d0 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -718,25 +718,22 @@ authentication.") (define-public pidgin (package (name "pidgin") - (version "2.13.0") + (version "2.14.1") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/pidgin/Pidgin/" - version "/pidgin-" version ".tar.bz2")) + version "/pidgin-" version ".tar.gz")) (sha256 - (base32 "13vdqj70315p9rzgnbxjp9c51mdzf1l4jg1kvnylc4bidw61air7")) + (base32 "1c4dzxg9c3d9zfqqa7jwijj9rv9fm6w95igmpljwy88lxq7v5w11")) (patches (search-patches - "pidgin-add-search-path.patch" - ;; Remove the snippet and bootstrapping - ;; native-inputs together with this patch. - "pidgin-libnm.patch")) + "pidgin-add-search-path.patch")) (modules '((guix build utils))) (snippet '(begin - ;; Remove stale generated file after applying pidgin-libnm.patch. + ;; Remove stale generated file after applying patches. (delete-file "configure") #t)))) (build-system glib-or-gtk-build-system) diff --git a/gnu/packages/patches/pidgin-libnm.patch b/gnu/packages/patches/pidgin-libnm.patch deleted file mode 100644 index d34af749af..0000000000 --- a/gnu/packages/patches/pidgin-libnm.patch +++ /dev/null @@ -1,60 +0,0 @@ -From: Tobias Geerinckx-Rice -Date: Sun, 24 May 2020 16:11:01 +0200 -Subject: [PATCH] gnu: pidgin: Find libnm. - -Copied verbatim from[0]. - -[0]: https://git.archlinux.org/svntogit/packages.git/plain/trunk/pidgin-nm-1.0.patch?h=packages/pidgin - -diff --git a/configure.ac b/configure.ac -index 04836fa..0a2d451 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -1423,18 +1423,24 @@ fi - dnl Check for NetworkManager.h; if we don't have it, oh well - if test "x$enable_dbus" = "xyes" ; then - if test "x$enable_nm" = "xyes" ; then -- PKG_CHECK_MODULES(NETWORKMANAGER, [NetworkManager >= 0.5.0], [ -+ PKG_CHECK_MODULES(NETWORKMANAGER, [libnm], [ - AC_SUBST(NETWORKMANAGER_CFLAGS) - AC_SUBST(NETWORKMANAGER_LIBS) - AC_DEFINE(HAVE_NETWORKMANAGER, 1, [Define if we have NetworkManager.]) - ], [ -- enable_nm=no -- if test "x$force_deps" = "xyes" ; then -- AC_MSG_ERROR([ -+ PKG_CHECK_MODULES(NETWORKMANAGER, [NetworkManager >= 0.5.0], [ -+ AC_SUBST(NETWORKMANAGER_CFLAGS) -+ AC_SUBST(NETWORKMANAGER_LIBS) -+ AC_DEFINE(HAVE_NETWORKMANAGER, 1, [Define if we have NetworkManager.]) -+ ], [ -+ enable_nm=no -+ if test "x$force_deps" = "xyes" ; then -+ AC_MSG_ERROR([ - NetworkManager development headers not found. - Use --disable-nm if you do not need NetworkManager support. - ]) -- fi]) -+ fi]) -+ ]) - fi - else - enable_nm=no -diff --git a/libpurple/network.c b/libpurple/network.c -index c43e3c7..b17e439 100644 ---- a/libpurple/network.c -+++ b/libpurple/network.c -@@ -939,8 +939,13 @@ nm_update_state(NMState state) - #if NM_CHECK_VERSION(0,8,992) - case NM_STATE_DISCONNECTING: - #endif -+#if NM_CHECK_VERSION(1,0,0) -+ if (prev != NM_STATE_CONNECTED_GLOBAL && prev != NM_STATE_UNKNOWN) -+ break; -+#else - if (prev != NM_STATE_CONNECTED && prev != NM_STATE_UNKNOWN) - break; -+#endif - if (ui_ops != NULL && ui_ops->network_disconnected != NULL) - ui_ops->network_disconnected(); - break; -- cgit v1.2.3 From 554120687687a022e4604ae8a9e33ea5dffeb15c Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:20:56 -0500 Subject: gnu: pidgin: Enable Gadu-Gadu protocol support. * gnu/packages/messaging.scm (pidgin) [inputs]: Add libgadu. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 45b6c5e8d0..99cb3e8f1a 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -757,7 +757,7 @@ authentication.") ;; ("gstreamer" ,gstreamer) ("gtk+" ,gtk+-2) ;; ("gtkspell2" ,gtkspell2) - ;; ("libgadu" ,libgadu) + ("libgadu" ,libgadu) ("libgcrypt" ,libgcrypt) ("libgnt" ,libgnt) ("libice" ,libice) -- cgit v1.2.3 From 3fd4477809caaeb6681999941f21baac14d87e84 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 31 Dec 2020 00:30:09 -0500 Subject: gnu: pidgin: Enable MultiMedia and A/V support. * gnu/packages/messaging.scm (pidgin) [patches] [pidgin-vv-gst.patch]: New patch. [arguments]<#:configure-flags>[--diable-vv]: Remove flag. [--disable-gstreamer]: Remove flag. [CFLAGS]: New flag. [inputs]: Add farstream and gstreamer. Move gtk+-2 to ... [propagated-inputs]: ... here. * gnu/packages/patches/pidgin-vv-gst.patch: New file. * gnu/local.mk (dist_patch_DATA): Add entry. Signed-off-by: Danny Milosavljevic --- gnu/local.mk | 1 + gnu/packages/messaging.scm | 16 ++++++----- gnu/packages/patches/pidgin-vv-gst.patch | 48 ++++++++++++++++++++++++++++++++ 3 files changed, 58 insertions(+), 7 deletions(-) create mode 100644 gnu/packages/patches/pidgin-vv-gst.patch diff --git a/gnu/local.mk b/gnu/local.mk index 0aad15740c..53a67e6ffe 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1471,6 +1471,7 @@ dist_patch_DATA = \ %D%/packages/patches/picard-fix-id3-rename-test.patch \ %D%/packages/patches/picprog-non-intel-support.patch \ %D%/packages/patches/pidgin-add-search-path.patch \ + %D%/packages/patches/pidgin-vv-gst.patch \ %D%/packages/patches/pinball-const-fix.patch \ %D%/packages/patches/pinball-cstddef.patch \ %D%/packages/patches/pinball-missing-separators.patch \ diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 99cb3e8f1a..4a368c0be4 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -729,7 +729,8 @@ authentication.") (base32 "1c4dzxg9c3d9zfqqa7jwijj9rv9fm6w95igmpljwy88lxq7v5w11")) (patches (search-patches - "pidgin-add-search-path.patch")) + "pidgin-add-search-path.patch" + "pidgin-vv-gst.patch")) (modules '((guix build utils))) (snippet '(begin @@ -752,10 +753,9 @@ authentication.") ("dbus" ,dbus) ("dbus-glib" ,dbus-glib) ;; ("evolution-data-server" ,evolution-data-server) - ;; ("farstream" ,farstream) + ("farstream" ,farstream) ("gnutls" ,gnutls) - ;; ("gstreamer" ,gstreamer) - ("gtk+" ,gtk+-2) + ("gstreamer" ,gstreamer) ;; ("gtkspell2" ,gtkspell2) ("libgadu" ,libgadu) ("libgcrypt" ,libgcrypt) @@ -786,16 +786,18 @@ authentication.") ("tcl" ,tcl) ("tk" ,tk))) (propagated-inputs - `(("glib" ,glib))) + `(("glib" ,glib) + ("gtk+" ,gtk+-2))) (arguments `(#:configure-flags (list + (string-append "CFLAGS=-I" + (assoc-ref %build-inputs "gst-plugins-base") + "/include/gstreamer-1.0") "--disable-gtkspell" ;; "--enable-gevolution" "--enable-cap" "--enable-mono" - "--disable-vv" ; XXX remove when we have farstream and gstreamer - "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 "--enable-cyrus-sasl" (string-append "--with-ncurses-headers=" (assoc-ref %build-inputs "ncurses") diff --git a/gnu/packages/patches/pidgin-vv-gst.patch b/gnu/packages/patches/pidgin-vv-gst.patch new file mode 100644 index 0000000000..e0553dd119 --- /dev/null +++ b/gnu/packages/patches/pidgin-vv-gst.patch @@ -0,0 +1,48 @@ +Name: Gary Kramlich +Date: 2020-07-12 +Source: https://keep.imfreedom.org/pidgin/pidgin/rev/39ac50435cfb + +diff --git a/libpurple/mediamanager.c b/libpurple/mediamanager.c +--- a/libpurple/mediamanager.c ++++ b/libpurple/mediamanager.c +@@ -2231,6 +2231,7 @@ + purple_media_manager_unregister_gst_device(PurpleMediaManager *manager, + GstDevice *device) + { ++#ifdef USE_VV + GList *i; + gchar *name; + gchar *device_class; +@@ -2277,6 +2278,7 @@ + + g_free(name); + g_free(device_class); ++#endif /* USE_VV */ + } + + static gboolean +@@ -2304,7 +2306,7 @@ + static void + purple_media_manager_init_device_monitor(PurpleMediaManager *manager) + { +-#if GST_CHECK_VERSION(1, 4, 0) ++#if GST_CHECK_VERSION(1, 4, 0) && defined(USE_VV) + GstBus *bus; + GList *i; + +@@ -2334,6 +2336,7 @@ + PurpleMediaElementType type) + { + GList *result = NULL; ++#ifdef USE_VV + GList *i; + + for (i = manager->priv->elements; i; i = i->next) { +@@ -2347,6 +2350,7 @@ + result = g_list_prepend(result, info); + } + } ++#endif /* USE_VV */ + + return result; + } -- cgit v1.2.3 From 844da71612eb53920c4cc2911ab93d8c9abb3f71 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Mon, 30 Nov 2020 00:48:09 -0500 Subject: gnu: libotr: Make some cosmetic changes. * gnu/packages/messaging.scm (libotr): Make some cosmetic changes. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 49 +++++++++++++++++++++++++--------------------- 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 4a368c0be4..1d89850088 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -378,32 +378,37 @@ powerful, standard and open protocol.") (package (name "libotr") (version "4.1.1") - (source (origin - (method url-fetch) - (uri (string-append "https://otr.cypherpunks.ca/libotr-" - version ".tar.gz")) - (sha256 - (base32 - "1x8rliydhbibmzwdbyr7pd7n87m2jmxnqkpvaalnf4154hj1hfwb")) - (patches (search-patches "libotr-test-auth-fix.patch")))) + (source + (origin + (method url-fetch) + (uri (string-append "https://otr.cypherpunks.ca/libotr-" + version ".tar.gz")) + (sha256 + (base32 "1x8rliydhbibmzwdbyr7pd7n87m2jmxnqkpvaalnf4154hj1hfwb")) + (patches + (search-patches "libotr-test-auth-fix.patch")))) (build-system gnu-build-system) + (native-inputs + `(("perl" ,perl))) ; for the test suite + (inputs + `(("libgpg-error" ,libgpg-error))) (propagated-inputs - `(("libgcrypt" ,libgcrypt))) ; libotr headers include gcrypt.h - (inputs `(("libgpg-error" ,libgpg-error))) - (native-inputs `(("perl" ,perl))) ; for the test suite + `(("libgcrypt" ,libgcrypt))) ; libotr headers include gcrypt.h (synopsis "Off-the-Record (OTR) Messaging Library and Toolkit") - (description - "OTR allows you to have private conversations over instant messaging by -providing: (1) Encryption: No one else can read your instant messages. (2) -Authentication: You are assured the correspondent is who you think it is. (3) -Deniability: The messages you send do not have digital signatures that are -checkable by a third party. Anyone can forge messages after a conversation to -make them look like they came from you. However, during a conversation, your -correspondent is assured the messages he sees are authentic and -unmodified. (4) Perfect forward secrecy: If you lose control of your private -keys, no previous conversation is compromised.") + (description "OTR allows you to have private conversations over instant +messaging by providing: (1) Encryption: No one else can read your instant +messages. (2) Authentication: You are assured the correspondent is who you +think it is. (3) Deniability: The messages you send do not have digital +signatures that are checkable by a third party. Anyone can forge messages +after a conversation to make them look like they came from you. However, +during a conversation, your correspondent is assured the messages he sees are +authentic and unmodified. (4) Perfect forward secrecy: If you lose control of +your private keys, no previous conversation is compromised.") (home-page "https://otr.cypherpunks.ca/") - (license (list license:lgpl2.1 license:gpl2)))) + (license + (list + license:lgpl2.1 + license:gpl2)))) (define-public libsignal-protocol-c (package -- cgit v1.2.3 From d3fb65a83794584b6c59995a6d569d18fc7bfff3 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Mon, 30 Nov 2020 00:49:38 -0500 Subject: gnu: libotr: Update license. * gnu/packages/messaging.scm (libotr) [license]: Modify. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 1d89850088..d202dcef76 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -407,8 +407,10 @@ your private keys, no previous conversation is compromised.") (home-page "https://otr.cypherpunks.ca/") (license (list - license:lgpl2.1 - license:gpl2)))) + ;; Library + license:lgpl2.1+ + ;; Others + license:gpl2+)))) (define-public libsignal-protocol-c (package -- cgit v1.2.3 From 4f1f51898fd6b933328a9c1587c99d780801d972 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 16:02:17 -0500 Subject: gnu: pidgin-otr: Make some cosmetic changes. * gnu/packages/messaging.scm (pidgin-otr): Make some cosmetic changes. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 49 +++++++++++++++++++++++----------------------- 1 file changed, 24 insertions(+), 25 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index d202dcef76..3ed0f51ac3 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -845,38 +845,37 @@ many popular chat protocols.") (package (name "pidgin-otr") (version "4.0.2") - (source (origin - (method url-fetch) - (uri (string-append "https://otr.cypherpunks.ca/" - name "-" version ".tar.gz")) - (sha256 - (base32 - "1i5s9rrgbyss9rszq6c6y53hwqyw1k86s40cpsfx5ccl9bprxdgl")))) + (source + (origin + (method url-fetch) + (uri + (string-append "https://otr.cypherpunks.ca/" + name "-" version ".tar.gz")) + (sha256 + (base32 "1i5s9rrgbyss9rszq6c6y53hwqyw1k86s40cpsfx5ccl9bprxdgl")))) (build-system gnu-build-system) (native-inputs - `(("pkg-config" ,pkg-config) - ("intltool" ,intltool))) + `(("intltool" ,intltool) + ("pkg-config" ,pkg-config))) (inputs - `(("pidgin" ,pidgin) - ("libotr" ,libotr) - ("libgpg-error" ,libgpg-error) + `(("glib" ,glib) + ("gtk+" ,gtk+-2) ("libgcrypt" ,libgcrypt) - ("glib" ,glib) - ("gtk+" ,gtk+-2))) + ("libgpg-error" ,libgpg-error) + ("libotr" ,libotr) + ("pidgin" ,pidgin))) (home-page "https://otr.cypherpunks.ca/") (synopsis "Off-the-Record Messaging plugin for Pidgin") - (description - "Pidgin-OTR is a plugin that adds support for OTR to the Pidgin instant -messaging client. OTR (Off-the-Record) Messaging allows you to have private -conversations over instant messaging by providing: (1) Encryption: No one else -can read your instant messages. (2) Authentication: You are assured the -correspondent is who you think it is. (3) Deniability: The messages you send -do not have digital signatures that are checkable by a third party. Anyone + (description "Pidgin-OTR is a plugin that adds support for OTR to the Pidgin +instant messaging client. OTR (Off-the-Record) Messaging allows you to have +private conversations over instant messaging by providing: (1) Encryption: No +one else can read your instant messages. (2) Authentication: You are assured +the correspondent is who you think it is. (3) Deniability: The messages you +send do not have digital signatures that are checkable by a third party. Anyone can forge messages after a conversation to make them look like they came from -you. However, during a conversation, your correspondent is assured the -messages he sees are authentic and unmodified. (4) Perfect forward secrecy: -If you lose control of your private keys, no previous conversation is -compromised.") +you. However, during a conversation, your correspondent is assured the messages +he sees are authentic and unmodified. (4) Perfect forward secrecy: If you lose +control of your private keys, no previous conversation is compromised.") (license license:gpl2))) (define-public znc -- cgit v1.2.3 From 3fd6fd7283de1ca879a2f7e6cd297244c1ccc2dc Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 16:03:35 -0500 Subject: gnu: pidgin-otr: Update license. * gnu/packages/messaging.scm (pidgin-otr) [license]: Modify. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 3ed0f51ac3..de99e5e256 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -876,7 +876,7 @@ can forge messages after a conversation to make them look like they came from you. However, during a conversation, your correspondent is assured the messages he sees are authentic and unmodified. (4) Perfect forward secrecy: If you lose control of your private keys, no previous conversation is compromised.") - (license license:gpl2))) + (license license:gpl2+))) (define-public znc (package -- cgit v1.2.3 From f2f7395e3e1b8fe0d140c4de547f31b333c92477 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Wed, 30 Dec 2020 16:05:42 -0500 Subject: gnu: pidgin-otr: Add some inputs. * gnu/packages/messaging.scm (pidgin-otr) [native-inputs]: Add gettext-minimal. [inputs]: Add perl. Signed-off-by: Danny Milosavljevic --- gnu/packages/messaging.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index de99e5e256..89d7b8ca83 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -855,7 +855,8 @@ many popular chat protocols.") (base32 "1i5s9rrgbyss9rszq6c6y53hwqyw1k86s40cpsfx5ccl9bprxdgl")))) (build-system gnu-build-system) (native-inputs - `(("intltool" ,intltool) + `(("gettext" ,gettext-minimal) + ("intltool" ,intltool) ("pkg-config" ,pkg-config))) (inputs `(("glib" ,glib) @@ -863,6 +864,7 @@ many popular chat protocols.") ("libgcrypt" ,libgcrypt) ("libgpg-error" ,libgpg-error) ("libotr" ,libotr) + ("perl" ,perl) ("pidgin" ,pidgin))) (home-page "https://otr.cypherpunks.ca/") (synopsis "Off-the-Record Messaging plugin for Pidgin") -- cgit v1.2.3 From 0d72cdc68d2ab51131f35bdab31ca205c3ca6871 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 18:59:07 +0100 Subject: gnu: Add rust-serial-test-derive-0.5. * gnu/packages/crates-io.scm (rust-serial-test-derive-0.5): New variable. (rust-serial-test-derive-0.1): Inherit from above. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++------ 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3939f178b5..31842167e2 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -28135,8 +28135,34 @@ the application/x-www-form-urlencoded format.") "Allows for the creation of serialised Rust tests.") (license license:expat))) +(define-public rust-serial-test-derive-0.5 + (package + (name "rust-serial-test-derive") + (version "0.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "serial_test_derive" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1m8sd97xr8dn6p9by0xwfqm0rz8cbn1ghs5l1fv1xd6xzvgddb5j")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.7)))) + (home-page "https://github.com/palfrey/serial_test") + (synopsis "Helper crate for serial_test") + (description + "This package is an helper crate for @code{rust-serial-test}.") + (license license:expat))) + (define-public rust-serial-test-derive-0.1 (package + (inherit rust-serial-test-derive-0.5) (name "rust-serial-test-derive") (version "0.1.0") (source @@ -28148,15 +28174,10 @@ the application/x-www-form-urlencoded format.") (sha256 (base32 "17fkqrba233sjhdak986y4w3z4yjxa4idjkh46l7zxgcgjlvrnic")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-quote" ,rust-quote-0.6) - ("rust-syn" ,rust-syn-0.15)))) - (home-page "https://github.com/palfrey/serial_test/") - (synopsis "Helper crate for serial_test") - (description "This package provides a helper crate for @code{serial_test}.") - (license license:expat))) + ("rust-syn" ,rust-syn-0.15)))))) (define-public rust-servo-arc-0.1 (package -- cgit v1.2.3 From c1d165ec79dcd4df03a097010e2b8cef19f4ce40 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 19:00:05 +0100 Subject: gnu: Add rust-serial-test-0.5. * gnu/packages/crates-io.scm (rust-serial-test-0.5): New variable. (rust-serial-test-0.1): Inherit from above. --- gnu/packages/crates-io.scm | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 31842167e2..f7f007e7f2 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -28112,8 +28112,33 @@ the application/x-www-form-urlencoded format.") (description "YAML support for Serde.") (license (list license:asl2.0 license:expat)))) +(define-public rust-serial-test-0.5 + (package + (name "rust-serial-test") + (version "0.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "serial-test" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0pchc7imdi9wv8xxnwkb9lzs6cg06ghs0gaajjb834y8837wpg70")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-lazy-static" ,rust-lazy-static-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-serial-test-derive" ,rust-serial-test-derive-0.5)))) + (home-page "https://github.com/palfrey/serial_test") + (synopsis "Allows for the creation of serialised Rust tests") + (description + "This package allows for the creation of serialised Rust tests.") + (license license:expat))) + (define-public rust-serial-test-0.1 (package + (inherit rust-serial-test-0.5) (name "rust-serial-test") (version "0.1.0") (source @@ -28125,15 +28150,9 @@ the application/x-www-form-urlencoded format.") (sha256 (base32 "0qywhzjc4jh6dqqng90maai0mjlmafk9aa5rrl9g3d2g01wdn8ms")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-lazy-static" ,rust-lazy-static-1)))) - (home-page "https://github.com/palfrey/serial_test/") - (synopsis "Serialised Rust tests") - (description - "Allows for the creation of serialised Rust tests.") - (license license:expat))) + (("rust-lazy-static" ,rust-lazy-static-1)))))) (define-public rust-serial-test-derive-0.5 (package -- cgit v1.2.3 From 7323316609b4b34c7c643814f5f34362b5881edd Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Thu, 17 Dec 2020 11:42:42 +0000 Subject: gnu: perl-lwp-protocol-https: Uncomment perl-mozilla-ca input. If there's no explicit SSL configuration, the perl-mozilla-ca library acts as a fallback. Including this as an input fixes the use of HTTPS in things that use perl-lwp-protocol-https, for example get-iplayer. * gnu/packages/web.scm (perl-lwp-protocol-https)[propagated-inputs]: Uncomment perl-mozilla-ca. --- gnu/packages/web.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 50b6c32663..686790f177 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -3876,8 +3876,7 @@ exists it is used instead.") (propagated-inputs `(("perl-io-socket-ssl" ,perl-io-socket-ssl) ("perl-libwww" ,perl-libwww) - ;; Users should instead make sure SSL_ca_path is set properly. - ;; ("perl-mozilla-ca" ,perl-mozilla-ca) + ("perl-mozilla-ca" ,perl-mozilla-ca) ("perl-net-http" ,perl-net-http))) (home-page "https://metacpan.org/release/LWP-Protocol-https") (synopsis "HTTPS support for LWP::UserAgent") -- cgit v1.2.3 From d944f10ddd921a15e6cd17a968ca57f0109a1c36 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Thu, 31 Dec 2020 21:31:22 +0000 Subject: gnu: Add guile2.0-pg. * gnu/packages/guile-xyz.scm (guile2.0-pg): New variable. --- gnu/packages/guile-xyz.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 9d9904c751..135f939ca3 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -887,6 +887,43 @@ Vicare Scheme and IronScheme. Right now it contains: @end itemize\n") (license license:bsd-3))) +(define-public guile2.0-pg + (package + (name "guile2.0-pg") + (version "0.49") + (source (origin + (method url-fetch) + (uri (string-append "mirror://savannah/guile-pg/guile-pg-" + version ".tar.xz")) + (sha256 + (base32 + "1fizcqga96p9n2jjhi9nprhry20hg9wvcl5b8gya4vhzwz6qhysp")))) + (build-system gnu-build-system) + (arguments + '(#:phases + (modify-phases %standard-phases + (add-before 'install 'patch-src/Makefile + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "src/Makefile" + (("\\/share\\/guile\\/site") "/share/guile/site/2.0")) + #t))))) + (native-inputs + `(("procps" ,procps) ; fake-cluster-control uses ps + ("guile" ,guile-2.0) + ("postgresql" ,postgresql))) + (inputs + `(("guile" ,guile-2.0) + ("postgresql" ,postgresql))) + (home-page "https://www.nongnu.org/guile-pg/") + (synopsis "Guile modules for accessing PostgreSQL") + (description + "Guile-PG is a collection of modules for Guile allowing access to the +PostgreSQL RDBMS from Scheme programs. + +This has been tested against PostgreSQL 10 through 13, but currently only +works with Guile 1.4.x to 2.0.x.") + (license license:gpl3+))) + (define-public guile-prometheus (let ((commit "35dc26c0ea44c3d70f1819f240d84e2cbb4b7b4c") (revision "5")) -- cgit v1.2.3 From 700ee27ffa42a16c5136d9b0410d888e48045be2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 19:15:33 +0100 Subject: gnu: Add rust-cbindgen-0.16. * gnu/packages/rust-apps.scm (rust-cbindgen-0.16): New variable. --- gnu/packages/rust-apps.scm | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index c3d1d3bb26..438ca153d3 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2020 Leo Famulari ;;; Copyright © 2020 Mark H Weaver ;;; Copyright © 2020 Gabriel Arazas -;;; Copyright © 2020 Nicolas Goaziou +;;; Copyright © 2020, 2021 Nicolas Goaziou ;;; ;;; This file is part of GNU Guix. ;;; @@ -371,6 +371,35 @@ gitignore rules.") "This package provides a tool for generating C/C++ bindings to Rust code.") (license license:mpl2.0))) +(define-public rust-cbindgen-0.16 + (package + (inherit rust-cbindgen) + (name "rust-cbindgen") + (version "0.16.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "cbindgen" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "049cai626nzw0km03parx4sxwaxgbr7i5ifjbjwnfxkqkj5k2i4k")))) + (arguments + `(#:tests? #false ;missing files + #:cargo-inputs + (("rust-clap" ,rust-clap-2) + ("rust-heck" ,rust-heck-0.3) + ("rust-indexmap" ,rust-indexmap-1) + ("rust-log" ,rust-log-0.4) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-syn" ,rust-syn-1) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-toml" ,rust-toml-0.5)) + #:cargo-development-inputs + (("rust-serial-test" ,rust-serial-test-0.5)))))) + (define-public rust-cbindgen-0.14 (package (inherit rust-cbindgen) -- cgit v1.2.3 From 8ab084951fd2e1d72313096be8d5cb8cf8c6c90b Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 19:14:47 +0100 Subject: gnu: guile-gi: Update to 0.3.1. * gnu/packages/guile-xyz.scm (guile-gi): Update to 0.3.1. --- gnu/packages/guile-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 135f939ca3..10f55184cd 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2852,14 +2852,14 @@ list of components. This module takes care of that for you.") (define-public guile-gi (package (name "guile-gi") - (version "0.3.0") + (version "0.3.1") (source (origin (method url-fetch) (uri (string-append "http://lonelycactus.com/tarball/guile_gi-" version ".tar.gz")) (sha256 (base32 - "05xbwrk50h4f9fh8la8fk2wsxbnm0jcyb9phnpkkjq4sqkhkxlbj")))) + "1ljcfyar1nb6h4jskxnnzrcxcsblawc50qqfdn8cax3zqfskmvzj")))) (build-system glib-or-gtk-build-system) (arguments `(#:configure-flags '("--with-gnu-filesystem-hierarchy") -- cgit v1.2.3 From d414327a2e3466064b1b3efce08c0cda4f7c7bb1 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 19:15:00 +0100 Subject: gnu: guile-gi: Patch all references to libguile-gi. * gnu/packages/guile-xyz.scm (guile-gi)[patch-references-to-extension]: Use find-files to discover all modules. --- gnu/packages/guile-xyz.scm | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 10f55184cd..0b245c424e 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2875,11 +2875,7 @@ list of components. This module takes care of that for you.") (open-pipe* OPEN_READ "guile" "-c" "(display (effective-version))")))) - (substitute* '("module/gi.scm" - "module/gi/oop.scm" - "module/gi/documentation.scm" - "module/gi/types.scm" - "module/gi/repository.scm") + (substitute* (find-files "module" ".*\\.scm") (("\\(load-extension \"libguile-gi\" \"(.*)\"\\)" m arg) (format #f "~s" `(load-extension -- cgit v1.2.3 From 326ec739de90c9de3aad388fe1d7fc701b9abe90 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:29:21 +0100 Subject: gnu: rust-scoped-tls-1: Drop minor version from name. * gnu/packages/crates-io.scm (rust-scoped-tls-1): Drop minor version from name. (rust-loom-0.3): (rust-rayon-core-1): (rust-rustc-ap-rustc-ast-654): (rust-rustc-ap-rustc-span-654): (rust-rustc-rayon-core-0.3): (rust-scoped-tls-0.1): (rust-swc-1): (rust-wasm-bindgen-shared-0.2): (rust-wasm-bindgen-test-0.3): Apply removal. --- gnu/packages/crates-io.scm | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f7f007e7f2..04498a9d72 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15805,7 +15805,7 @@ by inspecting the system for user preference.") (("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-futures-util" ,rust-futures-util-0.3) ("rust-generator" ,rust-generator-0.6) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-serde" ,rust-serde-1) ("rust-serde-json" ,rust-serde-json-1)))) (home-page "https://github.com/tokio-rs/loom") @@ -24018,7 +24018,7 @@ accessors.") (("rust-libc" ,rust-libc-0.2) ("rust-rand" ,rust-rand-0.7) ("rust-rand-xorshift" ,rust-rand-xorshift-0.2) - ("rust-scoped-tls" ,rust-scoped-tls-1.0)))) + ("rust-scoped-tls" ,rust-scoped-tls-1)))) (home-page "https://github.com/rayon-rs/rayon") (synopsis "Core APIs for Rayon") (description "Core APIs for Rayon.") @@ -25419,7 +25419,7 @@ It is automatically published using the compiler repository at ("rust-rustc-ap-rustc-macros" ,rust-rustc-ap-rustc-macros-654) ("rust-rustc-ap-serialize" ,rust-rustc-ap-serialize-654) ("rust-rustc-ap-rustc-span" ,rust-rustc-ap-rustc-span-654) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-smallvec" ,rust-smallvec-1)))) (home-page "https://github.com/alexcrichton/rustc-auto-publish") (synopsis @@ -25583,7 +25583,7 @@ It is automatically published using the compiler repository at ("rust-rustc-ap-rustc-index" ,rust-rustc-ap-rustc-index-654) ("rust-rustc-ap-rustc-macros" ,rust-rustc-ap-rustc-macros-654) ("rust-rustc-ap-serialize" ,rust-rustc-ap-serialize-654) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-sha-1" ,rust-sha-1-0.8) ("rust-unicode-width" ,rust-unicode-width-0.1)))) (home-page "https://github.com/alexcrichton/rustc-auto-publish") @@ -25782,7 +25782,7 @@ should be using the real rayon crate, not rustc-rayon.") (("rust-libc" ,rust-libc-0.2) ("rust-rand" ,rust-rand-0.6) ("rust-rand-xorshift" ,rust-rand-xorshift-0.1) - ("rust-scoped-tls" ,rust-scoped-tls-1.0)))) + ("rust-scoped-tls" ,rust-scoped-tls-1)))) (home-page "https://github.com/rust-lang/rustc-rayon") (synopsis "Core APIs for Rayon - fork for rustc") (description @@ -26651,7 +26651,7 @@ non-'static references in parallel.") (license (list license:asl2.0 license:expat)))) -(define-public rust-scoped-tls-1.0 +(define-public rust-scoped-tls-1 (package (name "rust-scoped-tls") (version "1.0.0") @@ -26675,7 +26675,7 @@ library's old @code{scoped_thread_local!} macro for providing scoped access to (define-public rust-scoped-tls-0.1 (package - (inherit rust-scoped-tls-1.0) + (inherit rust-scoped-tls-1) (name "rust-scoped-tls") (version "0.1.2") (source @@ -30460,7 +30460,7 @@ cryptographic implementations.") ("rust-regex" ,rust-regex-1) ("rust-relative-path" ,rust-relative-path-1) ("rust-retain-mut" ,rust-retain-mut-0.1) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-st-map" ,rust-st-map-0.1) ("rust-string-cache" ,rust-string-cache-0.8) ("rust-walkdir" ,rust-walkdir-2) @@ -36212,7 +36212,7 @@ attribute that is not in the shared backend crate.") `(#:cargo-inputs (("rust-console-error-panic-hook" ,rust-console-error-panic-hook-0.1) ("rust-js-sys" ,rust-js-sys-0.3) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) ("rust-wasm-bindgen-futures" ,rust-wasm-bindgen-futures-0.4) ("rust-wasm-bindgen-test-macro" ,rust-wasm-bindgen-test-macro-0.3)))) @@ -36242,7 +36242,7 @@ attribute that is not in the shared backend crate.") (("rust-console-error-panic-hook" ,rust-console-error-panic-hook-0.1) ("rust-futures" ,rust-futures-0.1) ("rust-js-sys" ,rust-js-sys-0.3) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) ("rust-wasm-bindgen-futures" ,rust-wasm-bindgen-futures-0.3) ("rust-wasm-bindgen-test-macro" ,rust-wasm-bindgen-test-macro-0.2)))))) -- cgit v1.2.3 From e067cc3a98a9c66f4d3d997a19ad75a2b15101b9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 19:28:51 +0100 Subject: gnu: Add rust-loom-0.4. * gnu/packages/crates-io.scm (rust-loom-0.4): New variable. (rust-loom-0.3): Inherit from above. --- gnu/packages/crates-io.scm | 36 ++++++++++++++++++++++++++++++------ 1 file changed, 30 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 04498a9d72..e75af2102d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15788,24 +15788,27 @@ by inspecting the system for user preference.") `(#:cargo-inputs (("rust-log" ,rust-log-0.4)))))) -(define-public rust-loom-0.3 +(define-public rust-loom-0.4 (package (name "rust-loom") - (version "0.3.6") + (version "0.4.0") (source (origin (method url-fetch) (uri (crate-uri "loom" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1vabpqzdhcqy1d64kcyzgfwigiak0dr18whq0lkic8915w7lds50")))) + (base32 "1941ji91nvriqqkgzlx285kq38zg74sw68gb2x4pnjbfcfs76k6l")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs - (("rust-cfg-if" ,rust-cfg-if-0.1) + ;; FIXME: build phase fails with the error: "the + ;; `#[track_caller]` attribute is an experimental feature". + `(#:skip-build? #true + #:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-1) ("rust-futures-util" ,rust-futures-util-0.3) ("rust-generator" ,rust-generator-0.6) - ("rust-scoped-tls" ,rust-scoped-tls-1) + ("rust-scoped-tls" ,rust-scoped-tls-1.0) ("rust-serde" ,rust-serde-1) ("rust-serde-json" ,rust-serde-json-1)))) (home-page "https://github.com/tokio-rs/loom") @@ -15817,6 +15820,27 @@ memory model. It uses state reduction techniques to avoid combinatorial explosion.") (license license:expat))) +(define-public rust-loom-0.3 + (package + (inherit rust-loom-0.4) + (name "rust-loom") + (version "0.3.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "loom" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1vabpqzdhcqy1d64kcyzgfwigiak0dr18whq0lkic8915w7lds50")))) + (arguments + `(#:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-generator" ,rust-generator-0.6) + ("rust-scoped-tls" ,rust-scoped-tls-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1)))))) + (define-public rust-loom-0.2 (package/inherit rust-loom-0.3 (name "rust-loom") -- cgit v1.2.3 From 4c4bac95f5204357c7ad7d8661c26c32e19f1ea8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 19:29:38 +0100 Subject: gnu: Add rust-bytes-1. * gnu/packages/crates-io.scm (rust-bytes-1): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e75af2102d..59b444a538 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3207,29 +3207,48 @@ little-endian.") (("rust-quickcheck" ,rust-quickcheck-0.2) ("rust-rand" ,rust-rand-0.3)))))) -(define-public rust-bytes-0.6 +(define-public rust-bytes-1 (package (name "rust-bytes") - (version "0.6.0") + (version "1.0.0") (source (origin (method url-fetch) (uri (crate-uri "bytes" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "05ivrcbgl4f7z2zzm9hbsi8cy66spi70xlm6fp16zsq4ylsvrp70")))) + (base32 "0wpsy2jwmbrsn7x6vcd00hw9vvz071lv8nrb25wrspvmkna8w7xd")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-serde" ,rust-serde-1)) #:cargo-development-inputs - (("rust-loom" ,rust-loom-0.3) + (("rust-loom" ,rust-loom-0.4) ("rust-serde-test" ,rust-serde-test-1)))) (home-page "https://github.com/tokio-rs/bytes") (synopsis "Types and traits for working with bytes") (description "This package is a utility library for working with bytes.") (license license:expat))) +(define-public rust-bytes-0.6 + (package + (inherit rust-bytes-1) + (name "rust-bytes") + (version "0.6.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "bytes" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "05ivrcbgl4f7z2zzm9hbsi8cy66spi70xlm6fp16zsq4ylsvrp70")))) + (arguments + `(#:cargo-inputs + (("rust-serde" ,rust-serde-1)) + #:cargo-development-inputs + (("rust-loom" ,rust-loom-0.3) + ("rust-serde-test" ,rust-serde-test-1)))))) + (define-public rust-bytes-0.5 (package (inherit rust-bytes-0.6) -- cgit v1.2.3 From eedb5115803ce15cc6dd6bb5e3627abad00814d0 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 19:31:25 +0100 Subject: gnu: rust-loom-0.4: Fix code typo. * gnu/packages/crates-io.scm (rust-loom-0.4): Fix variable name. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 59b444a538..f1607d6f73 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15827,7 +15827,7 @@ by inspecting the system for user preference.") (("rust-cfg-if" ,rust-cfg-if-1) ("rust-futures-util" ,rust-futures-util-0.3) ("rust-generator" ,rust-generator-0.6) - ("rust-scoped-tls" ,rust-scoped-tls-1.0) + ("rust-scoped-tls" ,rust-scoped-tls-1) ("rust-serde" ,rust-serde-1) ("rust-serde-json" ,rust-serde-json-1)))) (home-page "https://github.com/tokio-rs/loom") -- cgit v1.2.3 From 98de21a72148865219dba60ff333d00010c8874c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 10:04:55 +0100 Subject: gnu: rust-autocfg-1: Drop minor version from name. * gnu/packages/crates-io.scm (rust-autocfg-1): Drop minor version from name. (rust-atomic-waker-1): (rust-crossbeam-deque-0.7): (rust-crossbeam-queue-0.2): (rust-if-chain-1): (rust-num-0.2): (rust-num-rational-0.2): (rust-num-bigint-dig-0.6): (rust-num-derive-0.2): (rust-num-enum-derive-0.4): (rust-num-integer-0.1): (rust-num-iter-0.1): (rust-openssl-0.7): (rust-regex-1): (rust-tinytemplate-1): Apply renaming. --- gnu/packages/crates-io.scm | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f1607d6f73..ba5c90cbea 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1294,7 +1294,7 @@ methods.") "This package provides a simple interface for querying atty.") (license license:expat))) -(define-public rust-autocfg-1.0 +(define-public rust-autocfg-1 (package (name "rust-autocfg") (version "1.0.1") @@ -1317,7 +1317,7 @@ methods.") (define-public rust-autocfg-0.1 (package - (inherit rust-autocfg-1.0) + (inherit rust-autocfg-1) (name "rust-autocfg") (version "0.1.7") (source @@ -5704,7 +5704,7 @@ criterion.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-crossbeam-utils" ,rust-crossbeam-utils-0.7) ("rust-lazy-static" ,rust-lazy-static-1) @@ -5809,7 +5809,7 @@ criterion.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-lazy-static" ,rust-lazy-static-1)) #:cargo-development-inputs @@ -13406,7 +13406,7 @@ ignore files such as .gitignore against file paths.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-hashbrown" ,rust-hashbrown-0.9) ("rust-serde" ,rust-serde-1) ("rust-rayon" ,rust-rayon-1)) @@ -18504,7 +18504,7 @@ including bigint, complex, rational, range iterators, generic integers, and more ("rust-quickcheck" ,rust-quickcheck-0.9) ("rust-rand" ,rust-rand-0.7) ("rust-serde" ,rust-serde-1) - ("rust-autocfg" ,rust-autocfg-1.0)))) + ("rust-autocfg" ,rust-autocfg-1)))) (home-page "https://github.com/rust-num/num-bigint") (synopsis "Big integer implementation for Rust") (description @@ -18533,7 +18533,7 @@ including bigint, complex, rational, range iterators, generic integers, and more ("rust-quickcheck-macros" ,rust-quickcheck-macros-0.8) ("rust-rand" ,rust-rand-0.5) ("rust-serde" ,rust-serde-1) - ("rust-autocfg" ,rust-autocfg-1.0)) + ("rust-autocfg" ,rust-autocfg-1)) #:cargo-development-inputs (("rust-serde-test" ,rust-serde-test-1)))))) @@ -18640,7 +18640,7 @@ for Rust") (("rust-num-traits" ,rust-num-traits-0.2) ("rust-rand" ,rust-rand-0.5) ("rust-serde" ,rust-serde-1) - ("rust-autocfg" ,rust-autocfg-1.0)))))) + ("rust-autocfg" ,rust-autocfg-1)))))) (define-public rust-num-complex-0.1 (package @@ -18810,7 +18810,7 @@ primitives and enums easier.") (arguments `(#:cargo-inputs (("rust-num-traits" ,rust-num-traits-0.2) - ("rust-autocfg" ,rust-autocfg-1.0)))) + ("rust-autocfg" ,rust-autocfg-1)))) (home-page "https://github.com/rust-num/num-integer") (synopsis "Integer traits and functions") (description "Integer traits and functions.") @@ -18835,7 +18835,7 @@ primitives and enums easier.") `(#:cargo-inputs (("rust-num-integer" ,rust-num-integer-0.1) ("rust-num-traits" ,rust-num-traits-0.2) - ("rust-autocfg" ,rust-autocfg-1.0)))) + ("rust-autocfg" ,rust-autocfg-1)))) (home-page "https://github.com/rust-num/num-iter") (synopsis "External iterators for generic mathematics") (description @@ -18863,7 +18863,7 @@ primitives and enums easier.") ("rust-num-integer" ,rust-num-integer-0.1) ("rust-num-traits" ,rust-num-traits-0.2) ("rust-serde" ,rust-serde-1) - ("rust-autocfg" ,rust-autocfg-1.0)))) + ("rust-autocfg" ,rust-autocfg-1)))) (home-page "https://github.com/rust-num/num-rational") (synopsis "Rational numbers implementation for Rust") (description @@ -18890,7 +18890,7 @@ primitives and enums easier.") ("rust-num-integer" ,rust-num-integer-0.1) ("rust-num-traits" ,rust-num-traits-0.2) ("rust-serde" ,rust-serde-1) - ("rust-autocfg" ,rust-autocfg-1.0)))))) + ("rust-autocfg" ,rust-autocfg-1)))))) (define-public rust-num-rational-0.1 (package @@ -18930,7 +18930,7 @@ primitives and enums easier.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-libm" ,rust-libm-0.2)))) (home-page "https://github.com/rust-num/num-traits") (synopsis "Numeric traits for generic mathematics") @@ -19585,7 +19585,7 @@ system for OpenSSL.") `(#:cargo-inputs (("rust-libc" ,rust-libc-0.2) ;; Build dependencies: - ("rust-autocfg" ,rust-autocfg-1.0) + ("rust-autocfg" ,rust-autocfg-1) ("rust-cc" ,rust-cc-1) ("rust-pkg-config" ,rust-pkg-config-0.3) ("rust-vcpkg" ,rust-vcpkg-0.2)))) @@ -23994,7 +23994,7 @@ accessors.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-crossbeam-deque" ,rust-crossbeam-deque-0.7) ("rust-either" ,rust-either-1) ("rust-rayon-core" ,rust-rayon-core-1)) @@ -32268,7 +32268,7 @@ closures after a delay or at a given timestamp.") (arguments `(#:tests? #f ;FIXME: fail due to unresolved imports #:cargo-inputs - (("rust-autocfg" ,rust-autocfg-1.0) + (("rust-autocfg" ,rust-autocfg-1) ("rust-bytes" ,rust-bytes-0.6) ("rust-futures-core" ,rust-futures-core-0.3) ("rust-lazy-static" ,rust-lazy-static-1) -- cgit v1.2.3 From d9e4ccd1ec06423fc75af4e88e8ef63ca3d13051 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 15:28:05 +0100 Subject: gnu: youtube-dl: Update to 2021.01.03. * gnu/packages/video.scm (youtube-dl): Update to 2021.01.03. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 3df1a753ed..11d31f776f 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -2197,14 +2197,14 @@ To load this plugin, specify the following option when starting mpv: (define-public youtube-dl (package (name "youtube-dl") - (version "2020.12.31") + (version "2021.01.03") (source (origin (method url-fetch) (uri (string-append "https://youtube-dl.org/downloads/latest/" "youtube-dl-" version ".tar.gz")) (sha256 (base32 - "0ncqkzzaasda2hd89psgc0j34r2jinn1dcsfcapzrsd902qghkh9")) + "0qqixcr748nfhnihkjzayzdja26kgrsds45q5s8krmfm3b79ipli")) (snippet '(begin ;; Delete the pre-generated files, except for the man page -- cgit v1.2.3 From d7bcee2f8308fae482943ee0fd4f763148f06175 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 15:31:25 +0100 Subject: gnu: buku: Update to 4.5. * gnu/packages/web.scm (buku): Update to 4.5. --- gnu/packages/web.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 686790f177..34998b94a5 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -7661,15 +7661,14 @@ HTTrack is fully configurable, and has an integrated help system.") (define-public buku (package (name "buku") - (version "4.4") + (version "4.5") (source (origin (method url-fetch) (uri (pypi-uri "buku" version)) (file-name (git-file-name name version)) (sha256 - (base32 - "1g1xhdskfn72xaraqzz2v8dl2iza7bzfpn17z2wdrzkq3ih7yvgg")))) + (base32 "1bk3h2ya34a5livyf6p7kawh50ikbix5szsq2rkb8cp5bwrzsj5i")))) (build-system python-build-system) (arguments `(#:tests? #f)) ;FIXME: many tests need network access -- cgit v1.2.3 From aa2e420e818d3bb1b81f126a77eadd50d16a9dce Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 15:31:39 +0100 Subject: gnu: dav1d: Update to 0.8.1. * gnu/packages/video.scm (dav1d): Update to 0.8.1. --- gnu/packages/video.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 11d31f776f..2b1b111e97 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -4459,7 +4459,7 @@ transitions, and effects and then export your film to many common formats.") (define-public dav1d (package (name "dav1d") - (version "0.8.0") + (version "0.8.1") (source (origin (method git-fetch) @@ -4468,8 +4468,7 @@ transitions, and effects and then export your film to many common formats.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 - "0mjn87xjdqv0q1gj4s4f6fdmsj504mhk4qmqiyrhq2rs7yqj4csv")))) + (base32 "1820fpmmq1vxjzjmza6ydk4fgxipb8gmcc5skybki64qn7410v7x")))) (build-system meson-build-system) (native-inputs `(("nasm" ,nasm))) (home-page "https://code.videolan.org/videolan/dav1d") -- cgit v1.2.3 From 73023b280a9e153d25dd378ea8153220aba1cbec Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 18:28:02 +0100 Subject: gnu: rust-embed-resource: Update to 1.3.3. * gnu/packages/crates-io.scm (rust-embed-resource): Update to 1.3.3. --- gnu/packages/crates-io.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ba5c90cbea..628246e69a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2019, 2020, 2021 Nicolas Goaziou ;;; Copyright © 2019 Giacomo Leidi -;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2019–2021 Tobias Geerinckx-Rice ;;; Copyright © 2019, 2020 John Soo ;;; Copyright © 2019, 2020 Hartmut Goebel ;;; Copyright © 2020 Jakub Kądziołka @@ -8246,7 +8246,7 @@ signing, and verification in pure Rust.") (define-public rust-embed-resource-1.3 (package (name "rust-embed-resource") - (version "1.3.1") + (version "1.3.3") (source (origin (method url-fetch) @@ -8254,8 +8254,7 @@ signing, and verification in pure Rust.") (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "0v1adsw9mq7gjjjhx4hcjhqppdf4vm0gbcgh7sxirbxh99la9axv")))) + (base32 "0pbif8kl6xcvfnp8gibqsw0w14l28vfkff9k6byw506s0d20nsqz")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From 4d047d19707de647ebbf62cbcdedd8a2d9485dec Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 18:29:34 +0100 Subject: gnu: watchexec: Update to 1.14.1. * gnu/packages/rust-apps.scm (watchexec): Update to 1.14.1. [arguments]: Add rust-embed-resource to, and remove rust-clap & rust-winapi, from #:cargo-inputs. --- gnu/packages/rust-apps.scm | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index 438ca153d3..944c9b82c0 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2020 Mark H Weaver ;;; Copyright © 2020 Gabriel Arazas ;;; Copyright © 2020, 2021 Nicolas Goaziou +;;; Copyright © 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -488,7 +489,7 @@ blanks grouped by language.") (define-public watchexec (package (name "watchexec") - (version "1.14.0") + (version "1.14.1") (source (origin (method url-fetch) @@ -496,8 +497,7 @@ blanks grouped by language.") (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "0bwgqb5fvyqbf2lf0005fxzpbpbwbszc7144g3kg2cmzy5cbrf0w")))) + (base32 "1vqaa462sjpzi0crh12ixqc2wa5bblirc129pnj8jr8iz3xw3gvd")))) (build-system cargo-build-system) (arguments `(#:phases @@ -512,7 +512,7 @@ blanks grouped by language.") (install-file "README.md" doc) #t)))) #:cargo-inputs - (("rust-clap" ,rust-clap-2) + (("rust-embed-resource" ,rust-embed-resource-1.3) ("rust-derive-builder" ,rust-derive-builder-0.9) ("rust-env-logger" ,rust-env-logger-0.7) ("rust-glob" ,rust-glob-0.3) @@ -521,8 +521,7 @@ blanks grouped by language.") ("rust-log" ,rust-log-0.4) ("rust-nix" ,rust-nix-0.17) ("rust-notify" ,rust-notify-4) - ("rust-walkdir" ,rust-walkdir-2) - ("rust-winapi" ,rust-winapi-0.3)))) + ("rust-walkdir" ,rust-walkdir-2)))) (home-page "https://github.com/watchexec/watchexec") (synopsis "Executes commands in response to file modifications") (description -- cgit v1.2.3 From e5b9bdacc40ff9e90bdfae2929250d44ccebb95e Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 07:34:27 +0100 Subject: gnu: xterm: Update to 363. * gnu/packages/xorg.scm (xterm): Update to 363. --- gnu/packages/xorg.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm index 3a26acc802..8f84b894f6 100644 --- a/gnu/packages/xorg.scm +++ b/gnu/packages/xorg.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2017, 2018, 2019, 2020 Marius Bakke ;;; Copyright © 2017, 2018, 2019 Rutger Helling ;;; Copyright © 2017, 2020 Arun Isaac -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Kei Kebreau ;;; Copyright © 2018, 2020 Oleg Pykhalov ;;; Copyright © 2018 Benjamin Slade @@ -6085,7 +6085,7 @@ to answer a question. Xmessage can also exit after a specified time.") (define-public xterm (package (name "xterm") - (version "362") + (version "363") (source (origin (method url-fetch) @@ -6095,7 +6095,7 @@ to answer a question. Xmessage can also exit after a specified time.") (string-append "ftp://ftp.invisible-island.net/xterm/" "xterm-" version ".tgz"))) (sha256 - (base32 "18mch57f5sypgfdbvna22ailcfpnixw0fc5wkf2j3w58dwigwkqx")))) + (base32 "0j0bl5z3kmhahf770mbrj2zwm2nvxkhqpwnwbdvbclk5w8wkc6nq")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--enable-wide-chars" "--enable-load-vt-fonts" -- cgit v1.2.3 From 9c769ace00a49a03d3f3ac6e1d62aaecea8bef21 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 07:55:27 +0100 Subject: gnu: osinfo-db: Update to 20201218. * gnu/packages/virtualization.scm (osinfo-db): Update to 20201218. --- gnu/packages/virtualization.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm index b723ae8881..10eae8ea7d 100644 --- a/gnu/packages/virtualization.scm +++ b/gnu/packages/virtualization.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2017 Alex Vong ;;; Copyright © 2017 Andy Patterson ;;; Copyright © 2017, 2018, 2019 Rutger Helling -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Danny Milosavljevic ;;; Copyright © 2018 Sou Bunnbu ;;; Copyright © 2018 Julien Lepiller @@ -2017,14 +2017,14 @@ administrators and developers in managing the database.") (define-public osinfo-db (package (name "osinfo-db") - (version "20201011") + (version "20201218") (source (origin (method url-fetch) (uri (string-append "https://releases.pagure.org/libosinfo/osinfo-db-" version ".tar.xz")) (sha256 (base32 - "1zzx5gsqgzg2zki6h8vl0h7kpcrk5i2s1qhz7gcb18s7g99px8aj")))) + "0ydbindwgw7kg861rqii5036gq0dbbbmv35dzrmmv937ddfsxwh0")))) (build-system trivial-build-system) (arguments `(#:modules ((guix build utils)) -- cgit v1.2.3 From 2fd79876f3e3b7c1c529dacb9f89f1b5d8895d48 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 07:58:40 +0100 Subject: gnu: libwacom: Update to 1.7. * gnu/packages/xdisorg.scm (libwacom): Update to 1.7. [native-inputs]: Add python. --- gnu/packages/xdisorg.scm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm index 93f23d6722..793150cc5f 100644 --- a/gnu/packages/xdisorg.scm +++ b/gnu/packages/xdisorg.scm @@ -18,7 +18,7 @@ ;;; Copyright © 2016 Petter ;;; Copyright © 2017 Mekeor Melire ;;; Copyright © 2017 Nikita -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Marek Benc ;;; Copyright © 2017 Mike Gerwitz ;;; Copyright © 2018 Thomas Sigurdsen @@ -1126,7 +1126,7 @@ Escape key when Left Control is pressed and released on its own.") (define-public libwacom (package (name "libwacom") - (version "1.6") + (version "1.7") (source (origin (method url-fetch) (uri (string-append @@ -1134,12 +1134,14 @@ Escape key when Left Control is pressed and released on its own.") "libwacom-" version "/libwacom-" version ".tar.bz2")) (sha256 (base32 - "1a5ffxyhl6crspybcfsx5ribgrgkzwfl5w9y32slxbgjwczb473h")))) + "0797gc055dgg2jfqijy9823bd83jwr4wb2z9id992qlcr0xmz1rw")))) (build-system glib-or-gtk-build-system) (arguments `(#:configure-flags '("--disable-static"))) (native-inputs - `(("pkg-config" ,pkg-config))) + `(("pkg-config" ,pkg-config) + ;; For tests. + ("python" ,python))) (inputs `(("gtk+" ,gtk+) ("libgudev" ,libgudev) -- cgit v1.2.3 From eacffb9e68c3b404e256644b74efd7af7ac03bf2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 3 Jan 2021 08:35:41 +0100 Subject: gnu: nix: Update to 2.3.10. * gnu/packages/package-management.scm (nix): Update to 2.3.10. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 3bce1bd944..b731df412e 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2017 Muriithi Frederick Muriuki ;;; Copyright © 2017, 2018 Oleg Pykhalov ;;; Copyright © 2017 Roel Janssen -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Julien Lepiller ;;; Copyright © 2018, 2019 Rutger Helling ;;; Copyright © 2018 Sou Bunnbu @@ -584,14 +584,14 @@ out) and returning a package that uses that as its 'source'." (define-public nix (package (name "nix") - (version "2.3.9") + (version "2.3.10") (source (origin (method url-fetch) (uri (string-append "https://nixos.org/releases/nix/nix-" version "/nix-" version ".tar.xz")) (sha256 (base32 - "1yi2c1fp33sxv9j0pvxlpxs1dhq3axrwkxdwr867ll90lbdiycvj")))) + "1axphwkx270c10bjyn4icq9wlx46npgnw0qkpymigl23vramxa58")))) (build-system gnu-build-system) (arguments `(#:configure-flags '("--sysconfdir=/etc" "--enable-gc") -- cgit v1.2.3 From f186bfb9cb9f26ece397dc046ad86a5d2be4fa90 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 20:50:44 +0200 Subject: gnu: rust-anyhow-1: Update to 1.0.37. * gnu/packages/crates-io.scm (rust-anyhow-1): Update to 1.0.37. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 628246e69a..c0c588f17e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -703,7 +703,7 @@ escape codes.") (define-public rust-anyhow-1.0 (package (name "rust-anyhow") - (version "1.0.34") + (version "1.0.37") (source (origin (method url-fetch) @@ -712,7 +712,7 @@ escape codes.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1mwz0vg77yqz3w616bl890xihh7dsixwgn27nr9qd8ms9ddwp3dz")))) + "11kaqp25lchr2ckyc46zm6blzndnw0w2w8qv0sp8z4xcxqgw2rzf")))) (build-system cargo-build-system) (arguments `(#:skip-build? #t -- cgit v1.2.3 From f7d3d1c81b3b50ff535df4d4e52a81c6c3271953 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 20:51:17 +0200 Subject: gnu: rust-anyhow-1: Don't skip build. * gnu/packages/crates-io.scm (rust-anyhow-1)[arguments]: Don't skip build. --- gnu/packages/crates-io.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c0c588f17e..2054041393 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -715,8 +715,7 @@ escape codes.") "11kaqp25lchr2ckyc46zm6blzndnw0w2w8qv0sp8z4xcxqgw2rzf")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t - #:cargo-development-inputs + `(#:cargo-development-inputs (("rust-futures" ,rust-futures-0.3) ("rust-rustversion" ,rust-rustversion-1) ("rust-thiserror" ,rust-thiserror-1) -- cgit v1.2.3 From d76f073aba307bcf0b277290c161a8c054c1c549 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 20:53:42 +0200 Subject: gnu: rust-anyhow-1: Drop minor version from name. * gnu/packages/crates-io.scm (rust-anyhow-1): Drop minor version from name. (rust-codespan-reporting-0.9) (rust-swc-1) (rust-syn-1) (rust-thiserror-1) (rust-wasm-bindgen-webidl-0.2) (rust-svd-parser-0.9): Adjust accordingly. * gnu/packages/crates-gtk.scm (rust-glib-macros-0.10): Same. * gnu/packages/rust-apps.scm (fd): Same. * gnu/packages/sequoia.scm (sequoia): Same. --- gnu/packages/crates-gtk.scm | 4 ++-- gnu/packages/crates-io.scm | 14 +++++++------- gnu/packages/rust-apps.scm | 4 ++-- gnu/packages/sequoia.scm | 2 +- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/gnu/packages/crates-gtk.scm b/gnu/packages/crates-gtk.scm index ac80a30f38..ebe2a4e45b 100644 --- a/gnu/packages/crates-gtk.scm +++ b/gnu/packages/crates-gtk.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2020 Efraim Flashner +;;; Copyright © 2020, 2021 Efraim Flashner ;;; Copyright © 2020 Nicolas Goaziou ;;; ;;; This file is part of GNU Guix. @@ -773,7 +773,7 @@ (arguments `(#:skip-build? #t #:cargo-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-heck" ,rust-heck-0.3) ("rust-itertools" ,rust-itertools-0.9) ("rust-proc-macro-crate" ,rust-proc-macro-crate-0.1) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2054041393..20de0d644b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -700,7 +700,7 @@ escape codes.") (license (list license:asl2.0 license:expat)))) -(define-public rust-anyhow-1.0 +(define-public rust-anyhow-1 (package (name "rust-anyhow") (version "1.0.37") @@ -4377,7 +4377,7 @@ CMAKE environmental variable is set.") ("rust-termcolor" ,rust-termcolor-1) ("rust-unicode-width" ,rust-unicode-width-0.1)) #:cargo-development-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-insta" ,rust-insta-0.16) ("rust-lazy-static" ,rust-lazy-static-1) ("rust-peg" ,rust-peg-0.6) @@ -30507,7 +30507,7 @@ cryptographic implementations.") ("rust-walkdir" ,rust-walkdir-2) ("rust-wasm-bindgen-futures" ,rust-wasm-bindgen-futures-0.4)) #:cargo-development-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-env-logger" ,rust-env-logger-0.7) ("rust-num-bigint" ,rust-num-bigint-0.2) ("rust-pretty-assertions" ,rust-pretty-assertions-0.6) @@ -30591,7 +30591,7 @@ browsers.") ("rust-proc-macro2" ,rust-proc-macro2-1) ("rust-quote" ,rust-quote-1)) #:cargo-development-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-flate2" ,rust-flate2-1) ("rust-insta" ,rust-insta-0.16) ("rust-rayon" ,rust-rayon-1) @@ -31853,7 +31853,7 @@ handle Unicode characters correctly.") #:cargo-inputs (("rust-thiserror-impl" ,rust-thiserror-impl-1.0)) #:cargo-development-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-ref-cast" ,rust-ref-cast-1.0) ("rust-rustversion" ,rust-rustversion-1) ("rust-trybuild" ,rust-trybuild-1)))) @@ -36395,7 +36395,7 @@ attribute that is not in the shared backend crate.") (arguments `(#:skip-build? #t #:cargo-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-heck" ,rust-heck-0.3) ("rust-log" ,rust-log-0.4) ("rust-proc-macro2" ,rust-proc-macro2-1) @@ -37664,7 +37664,7 @@ formatters with per-field documentation generated for each structure. (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-either" ,rust-either-1) ("rust-serde" ,rust-serde-1) ("rust-thiserror" ,rust-thiserror-1) diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index 944c9b82c0..603f225d96 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019, 2020 John Soo -;;; Copyright © 2019, 2020 Efraim Flashner +;;; Copyright © 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2020 Jakub Kądziołka ;;; Copyright © 2020 Michael Rohleder ;;; Copyright © 2020 Leo Famulari @@ -200,7 +200,7 @@ also knows about symlinks, extended attributes, and Git.") (arguments `(#:cargo-inputs (("rust-ansi-term" ,rust-ansi-term-0.12) - ("rust-anyhow" ,rust-anyhow-1.0) + ("rust-anyhow" ,rust-anyhow-1) ("rust-atty" ,rust-atty-0.2) ("rust-clap" ,rust-clap-2) ("rust-ctrlc" ,rust-ctrlc-3.1) diff --git a/gnu/packages/sequoia.scm b/gnu/packages/sequoia.scm index 6550a71a1a..f07416c315 100644 --- a/gnu/packages/sequoia.scm +++ b/gnu/packages/sequoia.scm @@ -70,7 +70,7 @@ `(#:tests? #f ;; building the tests requires 9.7GB total #:rust ,rust-1.46 #:cargo-inputs - (("rust-anyhow" ,rust-anyhow-1.0) + (("rust-anyhow" ,rust-anyhow-1) ("rust-backtrace" ,rust-backtrace-0.3) ("rust-base64" ,rust-base64-0.13) ;;("rust-buffered-reader" included -- cgit v1.2.3 From 90cb4496c1fe3f62c7944930a75ee5ac5d174356 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 20:58:06 +0200 Subject: gnu: rust-unicode-segmentation-1.6: Drop minor version from name. * gnu/packages/crates-io.scm (rust-unicode-segmentation): Drop minor version from name. (rust-unicode-segmentation-1.3) (rust-rustyline-6): Adjust accordingly. --- gnu/packages/crates-io.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 20de0d644b..02c5d722da 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -26418,7 +26418,7 @@ sub-processes using a fork-like interface.") ("rust-nix" ,rust-nix-0.18) ("rust-scopeguard" ,rust-scopeguard-1) ("rust-skim" ,rust-skim-0.7) - ("rust-unicode-segmentation" ,rust-unicode-segmentation-1.6) + ("rust-unicode-segmentation" ,rust-unicode-segmentation-1) ("rust-unicode-width" ,rust-unicode-width-0.1) ("rust-utf8parse" ,rust-utf8parse-0.2) ("rust-winapi" ,rust-winapi-0.3)) @@ -34912,7 +34912,7 @@ including Canonical and Compatible Decomposition and Recomposition, as described in Unicode Standard Annex #15.") (license (list license:expat license:asl2.0)))) -(define-public rust-unicode-segmentation-1.6 +(define-public rust-unicode-segmentation-1 (package (name "rust-unicode-segmentation") (version "1.6.0") @@ -34938,7 +34938,7 @@ boundaries according to Unicode Standard Annex #29 rules.") (define-public rust-unicode-segmentation-1.3 (package - (inherit rust-unicode-segmentation-1.6) + (inherit rust-unicode-segmentation-1) (name "rust-unicode-segmentation") (version "1.3.0") (source -- cgit v1.2.3 From c10829a52b1bc80e69d24007f65b637022a2a3b4 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 21:00:18 +0200 Subject: gnu: Remove rust-unicode-segmentation-1.3. * gnu/packages/crates-io.scm (rust-unicode-segmentation-1.3): Remove variable. (rust-bstr-0.2) (rust-heck-0.3): Use rust-unicode-segmentation-1. --- gnu/packages/crates-io.scm | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 02c5d722da..e3b56719ed 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2876,7 +2876,7 @@ alphabet.") #:cargo-development-inputs (("rust-quickcheck" ,rust-quickcheck-0.8) ("rust-ucd-parse" ,rust-ucd-parse-0.1) - ("rust-unicode-segmentation" ,rust-unicode-segmentation-1.3)))) + ("rust-unicode-segmentation" ,rust-unicode-segmentation-1)))) (home-page "https://github.com/BurntSushi/bstr") (synopsis "String type that is not required to be valid UTF-8") @@ -12441,7 +12441,7 @@ total runtime size of an object on the heap") (arguments `(#:skip-build? #t #:cargo-inputs - (("rust-unicode-segmentation" ,rust-unicode-segmentation-1.3)))) + (("rust-unicode-segmentation" ,rust-unicode-segmentation-1)))) (home-page "https://github.com/withoutboats/heck") (synopsis "Case conversion library") (description @@ -34936,21 +34936,6 @@ described in Unicode Standard Annex #15.") boundaries according to Unicode Standard Annex #29 rules.") (license (list license:expat license:asl2.0)))) -(define-public rust-unicode-segmentation-1.3 - (package - (inherit rust-unicode-segmentation-1) - (name "rust-unicode-segmentation") - (version "1.3.0") - (source - (origin - (method url-fetch) - (uri (crate-uri "unicode-segmentation" version)) - (file-name - (string-append name "-" version ".tar.gz")) - (sha256 - (base32 - "1a9jqg7rb1yq6w2xc9jgxcs111yk5vxm9afjfvykfnrmzk6z8rqr")))))) - (define-public rust-unicode-width-0.1 (package (name "rust-unicode-width") -- cgit v1.2.3 From dfcca5e98c00c958d9f428dac1373b8f8a79b754 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 3 Jan 2021 21:02:12 +0200 Subject: gnu: rust-unicode-segmentation-1: Update to 1.7.1. * gnu/packages/crates-io.scm (rust-unicode-segmentation-1): Update to 1.7.1. --- gnu/packages/crates-io.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e3b56719ed..ab8084887d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -34915,7 +34915,7 @@ described in Unicode Standard Annex #15.") (define-public rust-unicode-segmentation-1 (package (name "rust-unicode-segmentation") - (version "1.6.0") + (version "1.7.1") (source (origin (method url-fetch) @@ -34924,11 +34924,12 @@ described in Unicode Standard Annex #15.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1h7d48mzpi8hwf5cvnq07warkv86pvapzzzf32hvbjsk20yiagp8")))) + "15n736z0pbj30pj44jb9s9rjavzrmx8v8pzdgsl5yfmfwrxjw3dv")))) (build-system cargo-build-system) (arguments `(#:cargo-development-inputs - (("rust-quickcheck" ,rust-quickcheck-0.7)))) + (("rust-bencher" ,rust-bencher-0.1) + ("rust-quickcheck" ,rust-quickcheck-0.7)))) (home-page "https://github.com/unicode-rs/unicode-segmentation") (synopsis "Grapheme Cluster, Word and Sentence boundaries") (description -- cgit v1.2.3 From 0e4e91869ca40f07f9146b71a448a236d76d93c3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 21:34:34 +0100 Subject: gnu: Add rust-async-stream-impl-0.3. * gnu/packages/crates-io.scm (rust-async-stream-impl-0.3): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ab8084887d..d5d4a976b7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1220,6 +1220,37 @@ standard library.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-stream-impl-0.3 + (package + (name "rust-async-stream-impl") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-stream-impl" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0w0aif9aw103b5wrm1svkqdh7aaihjywa21819d8m3lzzj78nm53")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags '("--release" "--" + "--skip=try_stream" + "--skip=stream") + #:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-tokio" ,rust-tokio-0.2)))) + (home-page "https://github.com/tokio-rs/async-stream") + (synopsis "Proc macros for async-stream crate") + (description + "This package provides proc macros for @code{rust-async-stream} +crate.") + (license license:expat))) + (define-public rust-async-trait-0.1 (package (name "rust-async-trait") -- cgit v1.2.3 From bc67bc081070ad4a760aeb597fe642f36677a382 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 21:35:11 +0100 Subject: gnu: Add rust-async-stream-0.3. * gnu/packages/crates-io.scm (rust-async-stream-0.3): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d5d4a976b7..5652324bb9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1220,6 +1220,34 @@ standard library.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-stream-0.3 + (package + (name "rust-async-stream") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-stream" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0p19qn5igblb86d35lda72q8vimk2iw8hk7r07wjj5y0rdqdyw1n")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-stream-impl" ,rust-async-stream-impl-0.3) + ("rust-futures-core" ,rust-futures-core-0.3)) + #:cargo-development-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-test" ,rust-tokio-test-0.2) + ("rust-trybuild" ,rust-trybuild-1)))) + (home-page "https://github.com/tokio-rs/async-stream") + (synopsis "Asynchronous streams using async & await notation") + (description + "This package provides asynchronous streams using async & await +notation.") + (license license:expat))) + (define-public rust-async-stream-impl-0.3 (package (name "rust-async-stream-impl") -- cgit v1.2.3 From c9c653603b105b90bdcda4796d99150d3a12e814 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 21:38:00 +0100 Subject: gnu: Add rust-tokio-1. * gnu/packages/crates-io.scm (rust-tokio-1): New variable. (rust-tokio-0.3): Inherit from above. (rust-tokio-macros-1): New variable. (rust-tokio-macros-0.3): Inherit from above. (rust-tokio-stream-0.1): New variable. (rust-tokio-test-0.4): New variable. (rust-tokio-test-0.3): Inherit from above. --- gnu/packages/crates-io.scm | 153 ++++++++++++++++++++++++++++++++++++++------- 1 file changed, 131 insertions(+), 22 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 5652324bb9..d20fb158ed 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32310,8 +32310,52 @@ closures after a delay or at a given timestamp.") "A 100% safe crate of vec-like types.") (license (list license:zlib license:asl2.0 license:expat)))) +(define-public rust-tokio-1 + (package + (name "rust-tokio") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1gd6qc9xvm568kicbkch40kjn5w0q2nsn527gcy80v3baqgj4n6j")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;FIXME: unresolved import + #:cargo-inputs + (("rust-autocfg" ,rust-autocfg-1) + ("rust-bytes" ,rust-bytes-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-memchr" ,rust-memchr-2) + ("rust-mio" ,rust-mio-0.7) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) + ("rust-signal-hook-registry" ,rust-signal-hook-registry-1) + ("rust-tokio-macros" ,rust-tokio-macros-1) + ("rust-tracing" ,rust-tracing-0.1) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-async-stream" ,rust-async-stream-0.3) + ("rust-futures" ,rust-futures-0.3) + ("rust-loom" ,rust-loom-0.4) + ("rust-nix" ,rust-nix-0.19) + ("rust-proptest" ,rust-proptest-0.10) + ("rust-tokio-stream" ,rust-tokio-stream-0.1) + ("rust-tokio-test" ,rust-tokio-test-0.4)))) + (home-page "https://tokio.rs") + (synopsis "Event-driven, non-blocking I/O platform") + (description + "This package provides an event-driven, non-blocking I/O platform for +writing asynchronous I/O backed applications.") + (license license:expat))) + (define-public rust-tokio-0.3 (package + (inherit rust-tokio-1) (name "rust-tokio") (version "0.3.5") (source @@ -32321,7 +32365,6 @@ closures after a delay or at a given timestamp.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "0lj26zy5k1dbln0599bn918z5j16wz5iyzs8cjz33hp2ksrkwam1")))) - (build-system cargo-build-system) (arguments `(#:tests? #f ;FIXME: fail due to unresolved imports #:cargo-inputs @@ -32345,13 +32388,7 @@ closures after a delay or at a given timestamp.") ("rust-loom" ,rust-loom-0.3) ("rust-nix" ,rust-nix-0.19) ("rust-proptest" ,rust-proptest-0.10) - ("rust-tokio-test" ,rust-tokio-test-0.3)))) - (home-page "https://tokio.rs") - (synopsis "Event-driven, non-blocking I/O platform") - (description - "This package provides an event-driven, non-blocking I/O platform for -writing asynchronous I/O backed applications.") - (license license:expat))) + ("rust-tokio-test" ,rust-tokio-test-0.3)))))) (define-public rust-tokio-0.2 (package @@ -32713,8 +32750,32 @@ the current thread.") futures efficiently") (license (list license:asl2.0 license:expat)))) +(define-public rust-tokio-macros-1 + (package + (name "rust-tokio-macros") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-macros" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "150l6wfcqw2rcjaf22qk3z6ca794x0s2c68n5ar18cfafllpsla2")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;FIXME: undeclared type `tokio` + #:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)))) + (home-page "https://tokio.rs") + (synopsis "Tokio's proc macros") + (description "This package provides Tokio's proc macros.") + (license license:expat))) + (define-public rust-tokio-macros-0.3 (package + (inherit rust-tokio-macros-1) (name "rust-tokio-macros") (version "0.3.2") (source @@ -32724,18 +32785,13 @@ futures efficiently") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "1dvd3gji7a0i1kgck2lwgbcbklk3qb1bsqgd2v9amj63kyjzzps6")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-proc-macro2" ,rust-proc-macro2-1) ("rust-quote" ,rust-quote-1) ("rust-syn" ,rust-syn-1)) #:cargo-development-inputs - (("rust-tokio" ,rust-tokio-0.3)))) - (home-page "https://tokio.rs") - (synopsis "Tokio's proc macros") - (description "This package provides Tokio's proc macros.") - (license license:expat))) + (("rust-tokio" ,rust-tokio-0.3)))))) (define-public rust-tokio-macros-0.2 (package @@ -33236,6 +33292,36 @@ Rust.") ("rust-once-cell" ,rust-once-cell-1) ("rust-tokio" ,rust-tokio-0.2)))))) +(define-public rust-tokio-stream-0.1 + (package + (name "rust-tokio-stream") + (version "0.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-stream" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0airchgn5zwzynchygdr8m7i4nizhfmifjz0iw6224sbnw9yjfrz")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;FIXME: unresolved import + #:cargo-inputs + (("rust-async-stream" ,rust-async-stream-0.3) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) + ("rust-tokio" ,rust-tokio-1)) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-proptest" ,rust-proptest-0.10) + ("rust-tokio" ,rust-tokio-1)))) + (home-page "https://tokio.rs") + (synopsis "Utilities to work with @code{Stream} and @code{tokio}") + (description + "This package provides utilities to work with @code{Stream} and +@code{tokio}.") + (license license:expat))) + (define-public rust-tokio-sync-0.2 (package (name "rust-tokio-sync") @@ -33285,33 +33371,56 @@ Rust.") ("rust-tokio" ,rust-tokio-0.1) ("rust-tokio-mock-task" ,rust-tokio-mock-task-0.1)))))) -(define-public rust-tokio-test-0.3 +(define-public rust-tokio-test-0.4 (package (name "rust-tokio-test") - (version "0.3.0") + (version "0.4.0") (source (origin (method url-fetch) (uri (crate-uri "tokio-test" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "06nzdkjsxr16pbr5m80zm3vcr8dhcl9amjgb9l9vj4x72cmmmp3y")))) + (base32 "1gwrqdwlfih6ib66wxc7yaaq7a9mlsmnxj2ahag3zc2rdxgj0zbw")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-bytes" ,rust-bytes-0.5) + (("rust-async-stream" ,rust-async-stream-0.3) + ("rust-bytes" ,rust-bytes-1) ("rust-futures-core" ,rust-futures-core-0.3) - ("rust-tokio" ,rust-tokio-0.3)) + ("rust-tokio" ,rust-tokio-1) + ("rust-tokio-stream" ,rust-tokio-stream-0.1)) #:cargo-development-inputs (("rust-futures-util" ,rust-futures-util-0.3) - ("rust-tokio" ,rust-tokio-0.3)))) + ("rust-tokio" ,rust-tokio-1)))) (home-page "https://tokio.rs") (synopsis "Testing utilities for Tokio- and futures-based code") (description - "This package provides testing utilities for Tokio- and futures-based -code.") + "This package provides testing utilities for Tokio- and +futures-based code.") (license license:expat))) +(define-public rust-tokio-test-0.3 + (package + (inherit rust-tokio-test-0.4) + (name "rust-tokio-test") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-test" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "06nzdkjsxr16pbr5m80zm3vcr8dhcl9amjgb9l9vj4x72cmmmp3y")))) + (arguments + `(#:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-tokio" ,rust-tokio-0.3)) + #:cargo-development-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-tokio" ,rust-tokio-0.3)))))) + (define-public rust-tokio-test-0.2 (package (inherit rust-tokio-test-0.3) -- cgit v1.2.3 From 257e0b681793fd1e09b247cdec655ab64d937702 Mon Sep 17 00:00:00 2001 From: John Soo Date: Mon, 26 Oct 2020 07:32:32 -0700 Subject: gnu: Add rust-core-foundation-sys-0.2. * gnu/packages/crates-io.scm (rust-core-foundation-sys-0.2): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/crates-io.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d20fb158ed..e74ca37ff8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5295,6 +5295,24 @@ intrinsics.") (base32 "0fzsw1j9g1x598yhwklg59l15hwzc0pyvs01w9fg2kin4598mjp7")))))) +(define-public rust-core-foundation-sys-0.2 + (package + (inherit rust-core-foundation-sys-0.6) + (name "rust-core-foundation-sys") + (version "0.2.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "core-foundation-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "13f7f3kblyj6yxcxm74yg84vj9ahaprlc1vgblagmj6bzmzmsnh6")))) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-libc" ,rust-libc-0.2)))))) + (define-public rust-core-text-13 (package (name "rust-core-text") -- cgit v1.2.3 From e689bfe230a4ced09eb295045c3804d394356ab1 Mon Sep 17 00:00:00 2001 From: John Soo Date: Mon, 26 Oct 2020 07:34:59 -0700 Subject: gnu: Add rust-core-foundation-0.2. * gnu/packages/crates-io.scm (rust-core-foundation-0.2): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e74ca37ff8..3fc64cd916 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5251,6 +5251,26 @@ intrinsics.") ("rust-libc" ,rust-libc-0.2) ("rust-uuid" ,rust-uuid-0.5)))))) +(define-public rust-core-foundation-0.2 + (package + (inherit rust-core-foundation-0.6) + (name "rust-core-foundation") + (version "0.2.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "core-foundation" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0rvcn7ab5r69wvn7gby745jlpy8pirfywcdxbiypy083s93dggr5")))) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-core-foundation-sys" ,rust-core-foundation-sys-0.2) + ("rust-libc" ,rust-libc-0.2)))))) + (define-public rust-core-foundation-sys-0.8 (package (name "rust-core-foundation-sys") -- cgit v1.2.3 From 9eb94c2471bc30854c4ea32d9052af9ee1b28dbd Mon Sep 17 00:00:00 2001 From: John Soo Date: Mon, 26 Oct 2020 07:40:20 -0700 Subject: gnu: Add rust-security-framework-sys-0.1. * gnu/packages/crates-io.scm (rust-security-framework-sys-0.1): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3fc64cd916..2b8e495be1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -27350,6 +27350,25 @@ macOS and iOS.") (("rust-core-foundation-sys" ,rust-core-foundation-sys-0.6) ("rust-libc" ,rust-libc-0.2)))))) +(define-public rust-security-framework-sys-0.1 + (package + (inherit rust-security-framework-sys-0.2) + (name "rust-security-framework-sys") + (version "0.1.16") + (source + (origin + (method url-fetch) + (uri (crate-uri "security-framework-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1bdy87gvmahiiyfzghsdg2dkhznww3p3d3r676qs0y32hcg648al")))) + (arguments + `(#:skip-build? #t ; MacOS specific + #:cargo-inputs + (("rust-core-foundation-sys" ,rust-core-foundation-sys-0.2) + ("rust-libc" ,rust-libc-0.2)))))) + (define-public rust-selectors-0.22 (package (name "rust-selectors") -- cgit v1.2.3 From 7712500a20ce5c801e732c3fb5549872754df644 Mon Sep 17 00:00:00 2001 From: John Soo Date: Mon, 26 Oct 2020 07:42:28 -0700 Subject: gnu: Add rust-security-framework-0.1. * gnu/packages/crates-io.scm (rust-security-framework-0.1): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2b8e495be1..77e8ad63ed 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -27274,6 +27274,31 @@ macOS and iOS.") (("rust-hex" ,rust-hex-0.3) ("rust-tempdir" ,rust-tempdir-0.3)))))) +(define-public rust-security-framework-0.1 + (package + (inherit rust-security-framework-0.2) + (name "rust-security-framework") + (version "0.1.16") + (source + (origin + (method url-fetch) + (uri (crate-uri "security-framework" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "0ci39ax08h2ngrl1yf1ra9smivhjs6xarmg7kp6fxracqpllx96z")))) + (arguments + `(#:skip-build? #t ; MacOS specific + #:cargo-inputs + (("rust-core-foundation" ,rust-core-foundation-0.2) + ("rust-core-foundation-sys" ,rust-core-foundation-sys-0.2) + ("rust-libc" ,rust-libc-0.2) + ("rust-security-framework-sys" ,rust-security-framework-sys-0.1)) + #:cargo-development-inputs + (("rust-hex" ,rust-hex-0.2) + ("rust-tempdir" ,rust-tempdir-0.3)))))) + (define-public rust-security-framework-sys-2 (package (name "rust-security-framework-sys") -- cgit v1.2.3 From 319e48794c50822e463ad34d23bb1872b0d6b22c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 21:49:26 +0100 Subject: gnu: Add rust-cbindgen-0.15. * gnu/packages/rust-apps.scm (rust-cbindgen-0.15): New variable. --- gnu/packages/rust-apps.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index 603f225d96..3745a8377c 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -401,6 +401,33 @@ gitignore rules.") #:cargo-development-inputs (("rust-serial-test" ,rust-serial-test-0.5)))))) +(define-public rust-cbindgen-0.15 + (package + (inherit rust-cbindgen) + (name "rust-cbindgen") + (version "0.15.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "cbindgen" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0dgf49zij9rxnf0lv4k5gcmx1mxcz16czkk6q63anz0xp8ds3xhx")))) + (arguments + `(#:tests? #false ;missing files + #:cargo-inputs + (("rust-clap" ,rust-clap-2) + ("rust-heck" ,rust-heck-0.3) + ("rust-indexmap" ,rust-indexmap-1) + ("rust-log" ,rust-log-0.4) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-syn" ,rust-syn-1) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-toml" ,rust-toml-0.5)))))) + (define-public rust-cbindgen-0.14 (package (inherit rust-cbindgen) -- cgit v1.2.3 From 6958eb58e9b26e9f3172c40e8115667c9167d05d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 22:46:34 +0100 Subject: gnu: Add rust-tokio-util-0.2. * gnu/packages/crates-io.scm (rust-tokio-util-0.2): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 77e8ad63ed..e0b3ca6a49 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33806,6 +33806,32 @@ implementation of TLS for nonblocking I/O streams.") Tokio.") (license license:expat))) +(define-public rust-tokio-util-0.2 + (package + (inherit rust-tokio-util-0.3) + (name "rust-tokio-util") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "tokio-util" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0c39s4y0kvzkyarn1f9s8khqyajiqn7m4cjsa208f87ch88sa7ap")))) + (arguments + `(#:tests? #f + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.1) + ("rust-tokio" ,rust-tokio-0.2)) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-test" ,rust-tokio-test-0.2)))))) + (define-public rust-toml-0.5 (package (name "rust-toml") -- cgit v1.2.3 From a9b521f499e1991ff629dceedfa73d4da3f2fb98 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 23:50:25 +0100 Subject: gnu: Add rust-async-log-attributes-1. * gnu/packages/crates-io.scm (rust-async-log-attributes-1): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e0b3ca6a49..40f5d80a59 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1220,6 +1220,31 @@ standard library.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-log-attributes-1 + (package + (name "rust-async-log-attributes") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-log-attributes" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0b9nysb5yxf772cinl5rsyhl2zazj2qfhbckv1kjz9qr3gkgi5ys")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-0.4) + ("rust-quote" ,rust-quote-0.6) + ("rust-syn" ,rust-syn-0.15)))) + (home-page "https://github.com/rustasync/runtime") + (synopsis + "Proc Macro attributes for the async-log crate.") + (description + "This package provides proc macro attributes for the @code{async-log} +crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-async-stream-0.3 (package (name "rust-async-stream") -- cgit v1.2.3 From 1f7f45efe573cf8f51d179c943df2edfee5a8199 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 23:53:32 +0100 Subject: gnu: Add rust-async-log-1. * gnu/packages/crates-io.scm (rust-async-log-1): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 40f5d80a59..d9f7ebd6e5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1220,6 +1220,30 @@ standard library.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-log-1 + (package + (name "rust-async-log") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-log" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "16ymra7f8169br9ss9m9n4l6rjcav9ns6r9mv4nr4r9i9wq37fpm")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-log-attributes" ,rust-async-log-attributes-1) + ("rust-backtrace" ,rust-backtrace-0.3) + ("rust-log" ,rust-log-0.4)))) + (home-page "https://github.com/async-rs/async-log") + (synopsis "Async tracing capabilities for the @code{log} crate") + (description + "This crate provides extension types and hooks to @code{log} to enable +asynchronous logging.") + (license (list license:expat license:asl2.0)))) + (define-public rust-async-log-attributes-1 (package (name "rust-async-log-attributes") -- cgit v1.2.3 From a60dca6fcc886e30faa84eb26fae90de3899164a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 19 Dec 2020 23:59:52 +0100 Subject: gnu: Add rust-femme-1. * gnu/packages/crates-io.scm (rust-femme-1): New variable. --- gnu/packages/crates-io.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d9f7ebd6e5..e01b190044 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9368,6 +9368,38 @@ implement features such as look-around and backtracking, which are not supported in purely NFA-based implementations.") (license license:expat))) +(define-public rust-femme-1 + (package + (name "rust-femme") + (version "1.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "femme" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0spf66m22dvnz6x077znybk906lh4p5z30nh8c37mad2c3dc56jd")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false + #:cargo-inputs + (("rust-async-log" ,rust-async-log-1) + ("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-console" ,rust-console-0.7) + ("rust-js-sys" ,rust-js-sys-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-serde" ,rust-serde-1) + ("rust-serde-derive" ,rust-serde-derive-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) + ("rust-web-sys" ,rust-web-sys-0.3)))) + (home-page "https://github.com/lrlna/femme") + (synopsis "Pretty-printer and @code{ndjson} logger for @code{log} crate") + (description + "This package provides a pretty-printer and @code{ndjson} logger for +@code{log} crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-fern-0.6 (package (name "rust-fern") -- cgit v1.2.3 From 02a73fe2eb7a7f42daf672b4e9717e9ee4d5438f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:05:44 +0100 Subject: gnu: Add rust-kv-log-macro-1. * gnu/packages/crates-io.scm (rust-kv-log-macro-1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e01b190044..3bcd84ff3a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14542,6 +14542,29 @@ kernel32.") "The Khronos XML API Registry, exposed as byte string constants.") (license license:asl2.0))) +(define-public rust-kv-log-macro-1 + (package + (name "rust-kv-log-macro") + (version "1.0.7") + (source + (origin + (method url-fetch) + (uri (crate-uri "kv-log-macro" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0zwp4bxkkp87rl7xy2dain77z977rvcry1gmr5bssdbn541v7s0d")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-log" ,rust-log-0.4)) + #:cargo-development-inputs + (("rust-femme" ,rust-femme-1)))) + (home-page "https://github.com/yoshuawuyts/kv-log-macro") + (synopsis "Log macro for log's kv-unstable backend") + (description + "This package provides a Log macro for log's kv-unstable backend.") + (license (list license:expat license:asl2.0)))) + (define-public rust-language-tags-0.2 (package (name "rust-language-tags") -- cgit v1.2.3 From 0f3d491733aa5cc940591abe492647bc6a9c7c62 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:21:15 +0100 Subject: gnu: Add rust-futures-timer-1. * gnu/packages/crates-io.scm (rust-futures-timer-1): New variable. (rust-futures-timer-0.1): Inherit from above. --- gnu/packages/crates-io.scm | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3bcd84ff3a..a2f6906d62 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10893,25 +10893,44 @@ futures-rs library.") components built off futures-rs.") (license (list license:expat license:asl2.0)))) -(define-public rust-futures-timer-0.1 +(define-public rust-futures-timer-1 (package (name "rust-futures-timer") - (version "0.1.1") + (version "1.0.3") (source (origin (method url-fetch) (uri (crate-uri "futures-timer" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0hw0nlyrq5an6l6y8md1rg6r380zrddvmh9cg0h64xfwnvlxzkm5")))) + (base32 "0idyz2k72jbl9z0wj48n15wjv6qgxgsgvs6k8lrhkzr9jj728ikr")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs (("rust-futures" ,rust-futures-0.1)))) + `(#:skip-build? #true + #:cargo-inputs + (("rust-futures-core-preview" ,rust-futures-core-preview-0.3) + ("rust-pin-utils" ,rust-pin-utils-0.1)))) (home-page "https://github.com/async-rs/futures-timer") (synopsis "Timeouts for futures") - (description "Timeouts for futures.") + (description "This package is a general purpose crate for working with +timeouts and delays with futures.") (license (list license:expat license:asl2.0)))) +(define-public rust-futures-timer-0.1 + (package + (inherit rust-futures-timer-1) + (name "rust-futures-timer") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "futures-timer" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0hw0nlyrq5an6l6y8md1rg6r380zrddvmh9cg0h64xfwnvlxzkm5")))) + (arguments + `(#:cargo-inputs (("rust-futures" ,rust-futures-0.1)))))) + (define-public rust-futures-util-0.3 (package (name "rust-futures-util") -- cgit v1.2.3 From 5b4695f729dafd71612271762924978c6c36e01a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:44:26 +0100 Subject: gnu: Add rust-broadcaster-0.2. * gnu/packages/crates-io.scm (rust-broadcaster-0.2): New variable. --- gnu/packages/crates-io.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a2f6906d62..22e52734bd 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2877,6 +2877,35 @@ algorithms. This package is deprecated. Please use block-cipher instead") Bresenham's line algorithm.") (license license:expat))) +(define-public rust-broadcaster-0.2 + (package + (name "rust-broadcaster") + (version "0.2.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "broadcaster" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1848lwapy955rs8kbiv87adj68vdlh6vlj8n4wq10vx541j49887")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-futures-channel-preview" ,rust-futures-channel-preview-0.3) + ("rust-futures-core-preview" ,rust-futures-core-preview-0.3) + ("rust-futures-sink-preview" ,rust-futures-sink-preview-0.3) + ("rust-futures-util-preview" ,rust-futures-util-preview-0.3) + ("rust-parking-lot" ,rust-parking-lot-0.9) + ("rust-slab" ,rust-slab-0.4)) + #:cargo-development-inputs + (("rust-futures-executor-preview" ,rust-futures-executor-preview-0.3)))) + (home-page "https://github.com/leo60228/broadcaster") + (synopsis "Broadcasting futures mpmc channel") + (description + "This package provides a wrapper for any Stream and Sink implementing the +@code{mpsc} pattern to enable broadcasting items.") + (license (list license:expat license:asl2.0)))) + (define-public rust-brotli-3 (package (name "rust-brotli") -- cgit v1.2.3 From 3f87fde02b43875d97121ddb7c30d543e51431b7 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:49:31 +0100 Subject: gnu: Add rust-async-task-1. * gnu/packages/crates-io.scm (rust-async-task-1): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 22e52734bd..2c44ce34fb 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1328,6 +1328,31 @@ notation.") crate.") (license license:expat))) +(define-public rust-async-task-1 + (package + (name "rust-async-task") + (version "1.3.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-task" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0p88087z43zvv924my16a17qd65kdlv1r59h80h73rvrn0bc1hha")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-libc" ,rust-libc-0.2) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-crossbeam" ,rust-crossbeam-0.7) + ("rust-futures" ,rust-futures-0.3)))) + (home-page "https://github.com/stjepang/async-task") + (synopsis "Task abstraction for building executors") + (description + "This package provides a task abstraction for building executors.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-trait-0.1 (package (name "rust-async-trait") -- cgit v1.2.3 From e8cef787589119492668d9709c5eb9ec6c91bb07 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:56:41 +0100 Subject: gnu: rust-futures-preview-0.3: Update to 0.3.0-alpha.19. * gnu/packages/crates-io.scm (rust-futures-preview-0.3): Update to 0.3.0-alpha.19. [arguments]: Add rust-futures-join-macro-preview to Cargo development inputs. [synopsis, description]: Pacify linter. --- gnu/packages/crates-io.scm | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2c44ce34fb..e643c4e8fe 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10798,7 +10798,7 @@ for the futures-rs library.") (define-public rust-futures-preview-0.3 (package (name "rust-futures-preview") - (version "0.3.0-alpha.17") + (version "0.3.0-alpha.19") (source (origin (method url-fetch) @@ -10807,7 +10807,7 @@ for the futures-rs library.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0rsq8d1ciyg37i5ysd9dynwmklwy4sx466z9a72687wsi8fgj9dz")))) + "0vnp63aicm9vgapn4hm45ag9lrsf9f3bma3mzz3abbb708mcw79v")))) (build-system cargo-build-system) (arguments `(#:tests? #f @@ -10817,12 +10817,15 @@ for the futures-rs library.") ("rust-futures-executor-preview" ,rust-futures-executor-preview-0.3) ("rust-futures-io-preview" ,rust-futures-io-preview-0.3) ("rust-futures-sink-preview" ,rust-futures-sink-preview-0.3) - ("rust-futures-util-preview" ,rust-futures-util-preview-0.3)))) + ("rust-futures-util-preview" ,rust-futures-util-preview-0.3)) + #:cargo-development-inputs + (("rust-futures-join-macro-preview" + ,rust-futures-join-macro-preview-0.3)))) (home-page "https://rust-lang-nursery.github.io/futures-rs") - (synopsis "An implementation of futures and streams") + (synopsis "Implementation of futures and streams") (description - "An implementation of futures and streams featuring zero allocations, -composability, and iterator-like interfaces.") + "This package provides an implementation of futures and streams featuring +zero allocations, composability, and iterator-like interfaces.") (license (list license:expat license:asl2.0)))) (define-public rust-futures-select-macro-preview-0.3 -- cgit v1.2.3 From fa660cfbeaebe9bb1d3daf968f4008f83e874456 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 00:59:53 +0100 Subject: gnu: Add rust-async-macros-1. * gnu/packages/crates-io.scm (rust-async-macros-1): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e643c4e8fe..e043ba3d4f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1269,6 +1269,30 @@ asynchronous logging.") crate.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-macros-1 + (package + (name "rust-async-macros") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-macros" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1fib4wxiym9f045xqb8a2gyfa8yym3hb62g4jqjfmzn14jdxa8g4")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false + #:cargo-inputs + (("rust-futures-core-preview" ,rust-futures-core-preview-0.3) + ("rust-pin-utils" ,rust-pin-utils-0.1)) + #:cargo-development-inputs + (("rust-futures-preview" ,rust-futures-preview-0.3)))) + (home-page "https://github.com/async-rs/async-macros") + (synopsis "Macros for async-std") + (description "Macros for async-std.") + (license (list license:expat license:asl2.0)))) + (define-public rust-async-stream-0.3 (package (name "rust-async-stream") -- cgit v1.2.3 From 77905166cec419ceb57af374405bcedb65ac2347 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 01:12:06 +0100 Subject: gnu: Add rust-async-attributes-1 and rust-async-std-0.99. * gnu/packages/crates-io.scm (rust-async-attributes-1): (rust-async-std-0.99): New variables. --- gnu/packages/crates-io.scm | 73 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e043ba3d4f..ade018eb47 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1177,6 +1177,31 @@ standard library.") (description "This package provides a libsyntax ast builder.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-attributes-1 + (package + (name "rust-async-attributes") + (version "1.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-attributes" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "08w41342hybxhln7j7hjsf7v04p3r9d6qdczfwp8d53xj5bd3lzg")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-async-std" ,rust-async-std-0.99)))) + (home-page "https://github.com/async-rs/async-attributes") + (synopsis "Experimental language-level polyfills for Async Rust") + (description + "This package provides experimental language-level polyfills for Async +Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-async-compression-0.3 (package (name "rust-async-compression") @@ -1293,6 +1318,54 @@ crate.") (description "Macros for async-std.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-std-0.99 + (package + (name "rust-async-std") + (version "0.99.12") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-std" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1k34181r1xzalyf7alka0ibnbqll6s5l435ycydm7fv1g6gill24")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags '("--release" "--" "--skip=io_timeout") + #:cargo-inputs + (("rust-async-attributes" ,rust-async-attributes-1) + ("rust-async-macros" ,rust-async-macros-1) + ("rust-async-task" ,rust-async-task-1) + ("rust-broadcaster" ,rust-broadcaster-0.2) + ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.3) + ("rust-crossbeam-deque" ,rust-crossbeam-deque-0.7) + ("rust-crossbeam-utils" ,rust-crossbeam-utils-0.6) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-io" ,rust-futures-io-0.3) + ("rust-futures-timer" ,rust-futures-timer-1) + ("rust-kv-log-macro" ,rust-kv-log-macro-1) + ("rust-log" ,rust-log-0.4) + ("rust-memchr" ,rust-memchr-2) + ("rust-mio" ,rust-mio-0.6) + ("rust-mio-uds" ,rust-mio-uds-0.6) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.1) + ("rust-pin-utils" ,rust-pin-utils-0.1) + ("rust-slab" ,rust-slab-0.4)) + #:cargo-development-inputs + (("rust-femme" ,rust-femme-1) + ("rust-futures" ,rust-futures-0.3) + ("rust-tempdir" ,rust-tempdir-0.3)))) + (home-page "https://async.rs") + (synopsis "Async version of the Rust standard library") + (description + "This crate provides an async version of @code{std}. It provides all the +interfaces you are used to, but in an async version and ready for Rust's +@code{async/await} syntax.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-stream-0.3 (package (name "rust-async-stream") -- cgit v1.2.3 From 974ba2668bdeaac558e8bd84bbe81159bcf2d573 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:42:24 +0100 Subject: gnu: Add rust-femme-2. * gnu/packages/crates-io.scm (rust-femme-2): New variable. (rust-femme-1): Inherit from above. --- gnu/packages/crates-io.scm | 41 +++++++++++++++++++++++++++++++++-------- 1 file changed, 33 insertions(+), 8 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ade018eb47..7cf839675f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9519,8 +9519,40 @@ implement features such as look-around and backtracking, which are not supported in purely NFA-based implementations.") (license license:expat))) +(define-public rust-femme-2 + (package + (name "rust-femme") + (version "2.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "femme" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0d7h1lzbcrqcn8v5l6m7i15lkbbaaz394l6vavbr8nhs757s5w9a")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-js-sys" ,rust-js-sys-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-serde" ,rust-serde-1) + ("rust-serde-derive" ,rust-serde-derive-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) + ("rust-web-sys" ,rust-web-sys-0.3)) + #:cargo-development-inputs + (("rust-kv-log-macro" ,rust-kv-log-macro-1)))) + (home-page "https://github.com/lrlna/femme") + (synopsis "Pretty-printer and @code{ndjson} logger for @code{log} crate") + (description + "This package provides a pretty-printer and @code{ndjson} logger for +@code{log} crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-femme-1 (package + (inherit rust-femme-2) (name "rust-femme") (version "1.3.0") (source @@ -9530,7 +9562,6 @@ supported in purely NFA-based implementations.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "0spf66m22dvnz6x077znybk906lh4p5z30nh8c37mad2c3dc56jd")))) - (build-system cargo-build-system) (arguments `(#:tests? #false #:cargo-inputs @@ -9543,13 +9574,7 @@ supported in purely NFA-based implementations.") ("rust-serde-derive" ,rust-serde-derive-1) ("rust-serde-json" ,rust-serde-json-1) ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) - ("rust-web-sys" ,rust-web-sys-0.3)))) - (home-page "https://github.com/lrlna/femme") - (synopsis "Pretty-printer and @code{ndjson} logger for @code{log} crate") - (description - "This package provides a pretty-printer and @code{ndjson} logger for -@code{log} crate.") - (license (list license:expat license:asl2.0)))) + ("rust-web-sys" ,rust-web-sys-0.3)))))) (define-public rust-fern-0.6 (package -- cgit v1.2.3 From 168103cf1175e8e8eba53491f26384b6c945b3bf Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:47:03 +0100 Subject: gnu: Add rust-atomic-waker-1. * gnu/packages/crates-io.scm (rust-atomic-waker-1): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7cf839675f..9584f2bf83 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1498,6 +1498,27 @@ methods.") (description "This package provides a safe abstraction around AtomicPtr.") (license license:asl2.0))) +(define-public rust-atomic-waker-1 + (package + (name "rust-atomic-waker") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "atomic-waker" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0ansiq5vlw684fhks2x4a4is2rqlbv50q5mi8x0fxxvx5q2p8lq6")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3)))) + (home-page "https://github.com/stjepang/atomic-waker") + (synopsis "Synchronization primitive for task wakeup") + (description + "This package provides a synchronization primitive for task wakeup.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-atty-0.2 (package (name "rust-atty") -- cgit v1.2.3 From 2e08ae8a5606a1e919620c52f2391d90dbdaf4df Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:48:49 +0100 Subject: gnu: Add rust-waker-fn-1. * gnu/packages/crates-io.scm (rust-waker-fn-1): New variable. --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9584f2bf83..f9a1fbe9bc 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36449,6 +36449,25 @@ updated when the crate version changes.") specified across Unix and Windows platforms.") (license (list license:expat license:asl2.0)))) +(define-public rust-waker-fn-1 + (package + (name "rust-waker-fn") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "waker-fn" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1jpfiis0frk2b36krqvk8264kgxk2dyhfzjsr8g3wah1nii2qnwx")))) + (build-system cargo-build-system) + ;; (arguments `(#:skip-build? #t)) + (home-page "https://github.com/stjepang/waker-fn") + (synopsis "Convert closures into wakers") + (description + "This package converts closures into wakers.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-walkdir-2 (package (name "rust-walkdir") -- cgit v1.2.3 From b5d659110cc209eab86c77fe752357aa68425d70 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:51:26 +0100 Subject: gnu: Add rust-easy-parallel-3. * gnu/packages/crates-io.scm (rust-easy-parallel-3): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f9a1fbe9bc..5fd5f202e8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -8450,6 +8450,26 @@ floating-point primitives to an @code{io::Write}.") "This package provides lightweight binding to DirectWrite.") (license license:mpl2.0))) +(define-public rust-easy-parallel-3 + (package + (name "rust-easy-parallel") + (version "3.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "easy-parallel" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1x28z540fc4g8fqm1sbpqbpdfbi40mkas4xr57s3yn0jjbbszm0x")))) + (build-system cargo-build-system) + (home-page "https://github.com/stjepang/easy-parallel") + (synopsis "Run closures in parallel") + (description + "This crate provides a simple primitive for spawning threads in bulk and +waiting for them to complete. Threads are allowed to borrow local variables +from the main thread.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-ed25519-1 (package (name "rust-ed25519") -- cgit v1.2.3 From ed7959b7e4cfd0114270afeec3eb1622742ce4e2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:54:00 +0100 Subject: gnu: Add rust-parking-2. * gnu/packages/crates-io.scm (rust-parking-2): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 5fd5f202e8..09080b4d2e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -20487,6 +20487,27 @@ deserialization, and interpreter in Rust.") (license (list license:asl2.0 license:expat)))) +(define-public rust-parking-2 + (package + (name "rust-parking") + (version "2.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "parking" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0wnxxnizfxlax3n709s5r83f4n8awy3m4a18q4fdk0z7z693hz22")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-easy-parallel" ,rust-easy-parallel-3)))) + (home-page "https://github.com/stjepang/parking") + (synopsis "Thread parking and unparking") + (description "This packages provides methods for thread parking and +unparking.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-parking-lot-0.11 (package (name "rust-parking-lot") -- cgit v1.2.3 From cb0c8d1209e2273b6890cdeea207a384bac571ce Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 12:56:51 +0100 Subject: gnu: Add rust-fastrand-1. * gnu/packages/crates-io.scm (rust-fastrand-1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 09080b4d2e..1371c9f72e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9560,6 +9560,29 @@ implement features such as look-around and backtracking, which are not supported in purely NFA-based implementations.") (license license:expat))) +(define-public rust-fastrand-1 + (package + (name "rust-fastrand") + (version "1.4.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "fastrand" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1qvz1i7g5mb2hcsaawrvxx88b8vwrsr85qr98ffmrkj5fh2sypya")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-instant" ,rust-instant-0.1)) + #:cargo-development-inputs + (("rust-rand" ,rust-rand-0.7)))) + (home-page "https://github.com/stjepang/fastrand") + (synopsis "Simple and fast random number generator") + (description + "This package provides a simple and fast random number generator.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-femme-2 (package (name "rust-femme") -- cgit v1.2.3 From 3fd8fa55cd9855ca3e67b8d96a45189cefa28ab5 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:03:15 +0100 Subject: gnu: Add rust-spin-on-0.1. * gnu/packages/crates-io.scm (rust-spin-on-0.1): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1371c9f72e..662e8a4245 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -29986,6 +29986,30 @@ initializers are available.") "07ywqn1vrpi3c43fmvsx7pawk9h3rb77yyqbnhap2micl454kb6f")))) (arguments '(#:skip-build? #t)))) +(define-public rust-spin-on-0.1 + (package + (name "rust-spin-on") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "spin-on" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "18idc7jfa4m2cap721nh5lva19z3ykjyz1w2hfm6960vshz10vh7")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-pin-utils" ,rust-pin-utils-0.1)))) + (home-page "https://crates.io/crates/spin_on") + (synopsis "Simple, inefficient Future executor") + (description + "This crate contains what aims to be the simplest possible implementation +of a valid executor. Instead of nicely parking the thread and waiting for the +future to wake it up, it continuously polls the future until the future is +ready. This will probably use a lot of CPU, so be careful when you use it.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-spmc-0.3 (package (name "rust-spmc") -- cgit v1.2.3 From 69d22548f4abcfb4a83bd1c36acc278f1bce5467 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:04:52 +0100 Subject: gnu: Add rust-futures-lite-1. * gnu/packages/crates-io.scm (rust-futures-lite-1): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 662e8a4245..dedfcfe55d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10955,6 +10955,37 @@ for the futures-rs library.") @code{try_join!} macro.") (license (list license:expat license:asl2.0)))) +(define-public rust-futures-lite-1 + (package + (name "rust-futures-lite") + (version "1.11.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "futures-lite" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1ywmyvpy4f348jri8rxhpj59a7bvy12pspm59x5207fys061sj5l")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-io" ,rust-futures-io-0.3) + ("rust-memchr" ,rust-memchr-2) + ("rust-parking" ,rust-parking-2) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) + ("rust-waker-fn" ,rust-waker-fn-1)) + #:cargo-development-inputs + (("rust-spin-on" ,rust-spin-on-0.1)))) + (home-page "https://github.com/stjepang/futures-lite") + (synopsis "Futures, streams, and async I/O combinators") + (description + "This crate is a subset of @code{futures} that compiles an order of +magnitude faster, fixes minor warts in its API, fills in some obvious gaps, +and removes almost all unsafe code from it.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-futures-macro-0.3 (package (name "rust-futures-macro") -- cgit v1.2.3 From 28ba48959cb7ad384d958cf606d29a54f0bcdfd9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:09:17 +0100 Subject: gnu: Add rust-cache-padded-1. * gnu/packages/crates-io.scm (rust-cache-padded-1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index dedfcfe55d..d238dbf8e0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3716,6 +3716,29 @@ exposed as Reader/Writer streams.") "The ChaCha family of stream ciphers.") (license (list license:asl2.0 license:expat)))) +(define-public rust-cache-padded-1 + (package + (name "rust-cache-padded") + (version "1.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "cache-padded" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1fkdwv9vjazm6fs3s5v56mm4carwswdmw8fcwm9ygrcvihcya6k3")))) + (build-system cargo-build-system) + (home-page "https://github.com/stjepang/cache-padded") + (synopsis "Prevent once piece of data invalidating other cached data") + (description + "In concurrent programming, sometimes it is desirable to make sure +commonly accessed shared data is not all placed into the same cache line. +Updating an atomic value invalides the whole cache line it belongs to, which +makes the next access to the same cache line slower for other CPU cores. Use +CachePadded to ensure updating one piece of data doesn't invalidate other +cached data.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-cachedir-0.1 (package (name "rust-cachedir") -- cgit v1.2.3 From 316e4ab6788daefb49364cee99c6b4fbe88af986 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:12:13 +0100 Subject: gnu: Add rust-concurrent-queue-1. * gnu/packages/crates-io.scm (rust-concurrent-queue-1): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d238dbf8e0..859ee2b29c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4928,6 +4928,31 @@ harness.") ("rust-rustc-serialize" ,rust-rustc-serialize-0.3) ("rust-tempdir" ,rust-tempdir-0.3)))))) +(define-public rust-concurrent-queue-1 + (package + (name "rust-concurrent-queue") + (version "1.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "concurrent-queue" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "18w6hblcjjk9d0my3657ra1zdj79gwfjmzvc0b3985g01dahgv9h")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cache-padded" ,rust-cache-padded-1)) + #:cargo-development-inputs + (("rust-easy-parallel" ,rust-easy-parallel-3) + ("rust-fastrand" ,rust-fastrand-1)))) + (home-page "https://github.com/stjepang/concurrent-queue") + (synopsis "Concurrent multi-producer multi-consumer queue") + (description + "This package provides a concurrent multi-producer multi-consumer +queue.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-console-0.13 (package (name "rust-console") -- cgit v1.2.3 From d194a3375ef002eb795df74c2c444335ab1ce0b3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:17:37 +0100 Subject: gnu: Add rust-event-listener-2. * gnu/packages/crates-io.scm (rust-event-listener-2): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 859ee2b29c..9516710ea3 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9373,6 +9373,30 @@ variables.") (("rust-serde" ,rust-serde-1) ("rust-serde-json" ,rust-serde-json-1)))))) +(define-public rust-event-listener-2 + (package + (name "rust-event-listener") + (version "2.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "event-listener" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0ndyp41pb2cx7gxijqh4ymnc47nyrvhvir7rvjlw6x09ayb10lzp")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-waker-fn" ,rust-waker-fn-1)))) + (home-page "https://github.com/stjepang/event-listener") + (synopsis "Notify async tasks or threads") + (description + "This is a synchronization primitive similar to @code{eventcounts}. +You can use this crate to turn non-blocking data structures into async or +blocking data structures.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-exitfailure-0.5 (package (name "rust-exitfailure") -- cgit v1.2.3 From bef4a1fc9328e6069882612afb84a52293aa9b92 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:19:44 +0100 Subject: gnu: Add rust-blocking-0.6. * gnu/packages/crates-io.scm (rust-blocking-0.6): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9516710ea3..13474f4e41 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -2998,6 +2998,33 @@ algorithms. This package is deprecated. Please use block-cipher instead") `(#:cargo-inputs (("rust-byte-tools" ,rust-byte-tools-0.3)))))) +(define-public rust-blocking-0.6 + (package + (name "rust-blocking") + (version "0.6.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "blocking" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13g1xlsd1ardf9wxkj1d03baxfy8f8kvgjz55l6zi1q4jn5f0c1z")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-channel" ,rust-async-channel-1) + ("rust-atomic-waker" ,rust-atomic-waker-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-waker-fn" ,rust-waker-fn-1)))) + (home-page "https://github.com/stjepang/blocking") + (synopsis "Thread pool for isolating blocking I/O in async programs") + (description + "This package provides a thread pool for isolating blocking I/O in async +programs.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-bresenham-0.1 (package (name "rust-bresenham") -- cgit v1.2.3 From 2cfceef6460a2017306773805cc2f94d7e3b63a8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:21:10 +0100 Subject: gnu: Add rust-async-channel-1. * gnu/packages/crates-io.scm (rust-async-channel-1): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 13474f4e41..ddca596c9d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1202,6 +1202,33 @@ standard library.") Rust.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-channel-1 + (package + (name "rust-async-channel") + (version "1.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-channel" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1ffn42ig82az8ndgjb545imifarcavwxs9dff6psbdkdjj1hsx2r")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-concurrent-queue" ,rust-concurrent-queue-1) + ("rust-event-listener" ,rust-event-listener-2) + ("rust-futures-core" ,rust-futures-core-0.3)) + #:cargo-development-inputs + (("rust-blocking" ,rust-blocking-0.6) + ("rust-easy-parallel" ,rust-easy-parallel-3) + ("rust-futures-lite" ,rust-futures-lite-1)))) + (home-page "https://github.com/stjepang/async-channel") + (synopsis "Async multi-producer multi-consumer channel") + (description + "Async multi-producer multi-consumer channel") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-compression-0.3 (package (name "rust-async-compression") -- cgit v1.2.3 From b08673dc8704d0a939e52a9dfd831034335e7d51 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:29:23 +0100 Subject: gnu: rust-once-cell: Improve description. * gnu/packages/crates-io.scm (rust-once-cell-1)[descripiton]: Expand description. --- gnu/packages/crates-io.scm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ddca596c9d..328fde1c0f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -19995,7 +19995,10 @@ other crates to create safe wrappers around Oniguruma.") (home-page "https://github.com/matklad/once_cell") (synopsis "Single assignment cells and lazy values") (description - "Single assignment cells and lazy values.") + "This package provides two new cell-like types, @code{unsync::OnceCell} +and @code{sync::OnceCell}. OnceCell might store arbitrary non-copy types, can +be assigned to at most once and provide direct access to the stored +contents.") (license (list license:expat license:asl2.0)))) (define-public rust-once-cell-0.1 -- cgit v1.2.3 From 3e31727b57c73710b9a4d818562ee988c19eea89 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:37:05 +0100 Subject: gnu: rust-tokio-0.3: Update to 0.3.6. * gnu/packages/crates-io.scm (rust-tokio-0.3): Update to 0.3.6. --- gnu/packages/crates-io.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 328fde1c0f..46ce724d11 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33010,25 +33010,25 @@ writing asynchronous I/O backed applications.") (package (inherit rust-tokio-1) (name "rust-tokio") - (version "0.3.5") + (version "0.3.6") (source (origin (method url-fetch) (uri (crate-uri "tokio" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0lj26zy5k1dbln0599bn918z5j16wz5iyzs8cjz33hp2ksrkwam1")))) + (base32 "0z78l7kn4y2qvghsp9dyqgvr1kjvv63pjq3d8nzi31q74lfa42vj")))) (arguments `(#:tests? #f ;FIXME: fail due to unresolved imports #:cargo-inputs (("rust-autocfg" ,rust-autocfg-1) ("rust-bytes" ,rust-bytes-0.6) ("rust-futures-core" ,rust-futures-core-0.3) - ("rust-lazy-static" ,rust-lazy-static-1) ("rust-libc" ,rust-libc-0.2) ("rust-memchr" ,rust-memchr-2) ("rust-mio" ,rust-mio-0.7) ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-once-cell" ,rust-once-cell-1) ("rust-parking-lot" ,rust-parking-lot-0.11) ("rust-pin-project-lite" ,rust-pin-project-lite-0.2) ("rust-signal-hook-registry" ,rust-signal-hook-registry-1) -- cgit v1.2.3 From b9a372066669b863a872efd0a48940f16a0a3698 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 3 Jan 2021 21:18:58 +0100 Subject: gnu: guile-cairo: Compile Scheme sources. * gnu/packages/gtk.scm (guile-cairo)[arguments]: Add phase "install-go-files". --- gnu/packages/gtk.scm | 33 ++++++++++++++++++++++++++++++--- 1 file changed, 30 insertions(+), 3 deletions(-) diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index f15ce07b51..5e090eb5ed 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2015 Sou Bunnbu ;;; Copyright © 2015 Andy Wingo ;;; Copyright © 2015 David Hashe -;;; Coypright © 2015, 2016, 2017, 2018, 2020 Ricardo Wurmus +;;; Coypright © 2015, 2016, 2017, 2018, 2020, 2021 Ricardo Wurmus ;;; Copyright © 2016, 2017, 2020 Efraim Flashner ;;; Copyright © 2016 Fabian Harfert ;;; Copyright © 2016 Kei Kebreau @@ -951,8 +951,35 @@ application suites.") (arguments ;; Uses of 'scm_t_uint8' & co. are deprecated; don't stop the build ;; because of them. - '(#:configure-flags '("--disable-Werror") - #:make-flags '("GUILE_AUTO_COMPILE=0"))) ; to prevent guild warnings + `(#:configure-flags '("--disable-Werror") + #:make-flags '("GUILE_AUTO_COMPILE=0") ; to prevent guild warnings + #:modules ((guix build gnu-build-system) + (guix build utils) + (ice-9 rdelim) + (ice-9 popen)) + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-go-files + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (effective (read-line + (open-pipe* OPEN_READ + "guile" "-c" + "(display (effective-version))"))) + (module-dir (string-append out "/share/guile/site/" + effective)) + (object-dir (string-append out "/lib/guile/" effective + "/site-ccache")) + (prefix (string-length module-dir))) + ;; compile to the destination + (for-each (lambda (file) + (let* ((base (string-drop (string-drop-right file 4) + prefix)) + (go (string-append object-dir base ".go"))) + (invoke "guild" "compile" "-L" module-dir + file "-o" go))) + (find-files module-dir "\\.scm$")) + #t)))))) (inputs `(("guile-lib" ,guile-lib) ("expat" ,expat) -- cgit v1.2.3 From 8caf7939220c464a8982f9bfa44430860067e8aa Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 3 Jan 2021 21:19:46 +0100 Subject: gnu: guile-rsvg: Compile Scheme files. * gnu/packages/gtk.scm (guile-rsvg)[arguments]: Add phase "install-go-files". --- gnu/packages/gtk.scm | 34 ++++++++++++++++++++++++++++++---- 1 file changed, 30 insertions(+), 4 deletions(-) diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index 5e090eb5ed..89efcd61c4 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -1040,10 +1040,36 @@ exceptions, macros, and a dynamic programming environment.") (file-name (string-append name "-" version ".tar.gz")))) (build-system gnu-build-system) (arguments - `(#:phases (modify-phases %standard-phases - (replace 'bootstrap - (lambda _ - (invoke "autoreconf" "-vfi")))))) + `(#:modules ((guix build gnu-build-system) + (guix build utils) + (ice-9 rdelim) + (ice-9 popen)) + #:phases + (modify-phases %standard-phases + (replace 'bootstrap + (lambda _ + (invoke "autoreconf" "-vfi"))) + (add-after 'install 'install-go-files + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (effective (read-line + (open-pipe* OPEN_READ + "guile" "-c" + "(display (effective-version))"))) + (module-dir (string-append out "/share/guile/site/" + effective)) + (object-dir (string-append out "/lib/guile/" effective + "/site-ccache")) + (prefix (string-length module-dir))) + ;; compile to the destination + (for-each (lambda (file) + (let* ((base (string-drop (string-drop-right file 4) + prefix)) + (go (string-append object-dir base ".go"))) + (invoke "guild" "compile" "-L" module-dir + file "-o" go))) + (find-files module-dir "\\.scm$")) + #t)))))) (native-inputs `(("pkg-config" ,pkg-config) ("autoconf" ,autoconf) ("automake" ,automake) -- cgit v1.2.3 From edf0043a2a0e3503c01be863d6681b2c382dfa5e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 3 Jan 2021 22:35:49 +0100 Subject: gnu: guile-studio: Update to 0.1.0-1.93622e7. * gnu/packages/guile-xyz.scm (guile-studio): Update to 0.1.0-1.93622e7. [arguments]: Remove ICONS_DIR from make-flags. [inputs]: Add emacs-all-the-icons-dired. --- gnu/packages/guile-xyz.scm | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 0b245c424e..2e8f6dc066 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -2583,11 +2583,11 @@ The picture values can directly be displayed in Geiser.") guile-picture-language)) (define-public guile-studio - (let ((commit "e9f2b469cc452b384af0243f3eba2f07871090ad") - (revision "2")) + (let ((commit "93622e788e727d3275291f999f7e570de6a5bb35") + (revision "1")) (package (name "guile-studio") - (version (git-version "0.0.4" revision commit)) + (version (git-version "0.1.0" revision commit)) (source (origin (method git-fetch) (uri (git-reference @@ -2596,7 +2596,7 @@ The picture values can directly be displayed in Geiser.") (file-name (git-file-name name version)) (sha256 (base32 - "16hwin8zdfyp25iczz3gr5w7hav6av6r8gw64nplgxgxkyaw53a6")))) + "0n6y0bcmkx50m8rccz7a6h4yxmwq54pf2bfzpd5ndz2bsiwiq13l")))) (build-system gnu-build-system) (arguments `(#:modules @@ -2605,10 +2605,7 @@ The picture values can directly be displayed in Geiser.") ,@%gnu-build-system-modules) #:tests? #f ; there are none #:make-flags - (list (string-append "ICONS_DIR=" - (assoc-ref %build-inputs "adwaita-icon-theme") - "/share/icons/Adwaita/") - (string-append "PICT_DIR=" + (list (string-append "PICT_DIR=" (assoc-ref %build-inputs "guile-picture-language")) (string-append "EMACS_DIR=" (assoc-ref %build-inputs "emacs")) @@ -2633,6 +2630,7 @@ The picture values can directly be displayed in Geiser.") ("emacs-f" ,emacs-f) ; needed by doom-modeline ("emacs-memoize" ,emacs-memoize) ; needed by all-the-icons ("emacs-all-the-icons" ,emacs-all-the-icons) ; needed by doom-modeline + ("emacs-all-the-icons-dired" ,emacs-all-the-icons-dired) ("emacs-dired-sidebar" ,emacs-dired-sidebar) ("emacs-doom-modeline" ,emacs-doom-modeline) ("emacs-modus-themes" ,emacs-modus-themes) @@ -2641,8 +2639,7 @@ The picture values can directly be displayed in Geiser.") ("emacs-ivy" ,emacs-ivy) ("emacs-flycheck" ,emacs-flycheck) ("emacs-flycheck-guile" ,emacs-flycheck-guile) - ("emacs-paren-face" ,emacs-paren-face) - ("adwaita-icon-theme" ,adwaita-icon-theme))) + ("emacs-paren-face" ,emacs-paren-face))) (native-inputs `(("texinfo" ,texinfo))) (home-page "https://gnu.org/software/guile") -- cgit v1.2.3 From dd450f606e3097f17fa4f0de9f569886a8472863 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:18:36 +0100 Subject: gnu: Add rust-jni-sys-0.3. * gnu/packages/crates-io.scm (rust-jni-sys-0.3): New variable. --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 46ce724d11..d1d4ffe3ef 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14820,6 +14820,25 @@ primitives to an @code{io::Write}.") (native-inputs `(("jemalloc" ,jemalloc))))) +(define-public rust-jni-sys-0.3 + (package + (name "rust-jni-sys") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "jni-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0c01zb9ygvwg9wdx2fii2d39myzprnpqqhy7yizxvjqp5p04pbwf")))) + (build-system cargo-build-system) + (home-page "https://github.com/sfackler/rust-jni-sys") + (synopsis "Rust definitions corresponding to @file{jni.h}") + (description + "This package provides Rust definitions corresponding to +@file{jni.h}.") + (license (list license:expat license:asl2.0)))) + (define-public rust-jobserver-0.1 (package (name "rust-jobserver") -- cgit v1.2.3 From 0ec523ef4b32f1f55f56cc6acda09b94782553a6 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:19:16 +0100 Subject: gnu: Add rust-jni-glue-0.0. * gnu/packages/crates-io.scm (rust-jni-glue-0.0): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d1d4ffe3ef..da3bda4d0c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14820,6 +14820,29 @@ primitives to an @code{io::Write}.") (native-inputs `(("jemalloc" ,jemalloc))))) +(define-public rust-jni-glue-0.0 + (package + (name "rust-jni-glue") + (version "0.0.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "jni-glue" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "054kc2hkdfjiihy7ssrn97s9hs35c2v32ph2h0jlv4vkazx39ddb")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-jni-sys" ,rust-jni-sys-0.3) + ("rust-lazy-static" ,rust-lazy-static-1)))) + (home-page "https://github.com/MaulingMonkey/jni-bindgen") + (synopsis "Glue code to accompany the jni-bindgen code generator") + (description + "This package provides manually written glue code to accompany +the jni-bindgen code generator for binding to JVM APIs from Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-jni-sys-0.3 (package (name "rust-jni-sys") -- cgit v1.2.3 From a5d76ec7b9338899e0bbc1d5f5458533b36ce356 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:20:43 +0100 Subject: gnu: Add rust-jni-0.14. * gnu/packages/crates-io.scm (rust-jni-0.14): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index da3bda4d0c..057811eb89 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14820,6 +14820,37 @@ primitives to an @code{io::Write}.") (native-inputs `(("jemalloc" ,jemalloc))))) +(define-public rust-jni-0.14 + (package + (name "rust-jni") + (version "0.14.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "jni" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "00jl4jzzbbcf1nyziras5drp501xsk89g0132pwg194ilh6k308r")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cesu8" ,rust-cesu8-1) + ("rust-combine" ,rust-combine-3) + ("rust-error-chain" ,rust-error-chain-0.12) + ("rust-jni-sys" ,rust-jni-sys-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-walkdir" ,rust-walkdir-2)) + #:cargo-development-inputs + (("rust-lazy-static" ,rust-lazy-static-1)))) + (home-page "https://github.com/jni-rs/jni-rs") + (synopsis "Rust bindings to the JNI") + (description + "This package provides Rust bindings to the JNI. It permits to +implement native Java methods for JVM and Android in Rust, call Java +code from Rust, embed JVM in Rust applications and use any Java +libraries.") + (license (list license:expat license:asl2.0)))) + (define-public rust-jni-glue-0.0 (package (name "rust-jni-glue") -- cgit v1.2.3 From 99fdeba4babc595e8b0ad8b937ca76adb1846b11 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:22:25 +0100 Subject: gnu: Add rust-ndk-0.2. * gnu/packages/crates-io.scm (rust-ndk-0.2): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 057811eb89..91c42bd368 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18368,6 +18368,33 @@ general elements and for numerics.") (license (list license:asl2.0 license:expat)))) +(define-public rust-ndk-0.2 + (package + (name "rust-ndk") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "ndk" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0wvf4hy18lpfkr4bap846qv2cx1vdg3x0d4hcfba9l5yzv0ngcay")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: Android only + #:cargo-inputs + (("rust-jni" ,rust-jni-0.14) + ("rust-jni-glue" ,rust-jni-glue-0.0) + ("rust-jni-sys" ,rust-jni-sys-0.3) + ("rust-ndk-sys" ,rust-ndk-sys-0.2) + ("rust-num-enum" ,rust-num-enum-0.4) + ("rust-thiserror" ,rust-thiserror-1)))) + (home-page "https://github.com/rust-windowing/android-ndk-rs") + (synopsis "Safe Rust bindings to the Android NDK") + (description + "This package provides safe Rust bindings to the Android NDK.") + (license (list license:expat license:asl2.0)))) + (define-public rust-ndk-macro-0.2 (package (name "rust-ndk-macro") -- cgit v1.2.3 From 82946b0583d58daab979a5d883526049517785fc Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:23:51 +0100 Subject: gnu: Add rust-android-log-sys-0.1. * gnu/packages/crates-io.scm (rust-android-log-sys-0.1): New variable. --- gnu/packages/crates-io.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 91c42bd368..1f865f471e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -655,6 +655,24 @@ be used with the stdlib.") (description "This package provides the glue for the Android JNI.") (license license:expat))) +(define-public rust-android-log-sys-0.1 + (package + (name "rust-android-log-sys") + (version "0.1.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "android_log-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0klq7cp4lm74gjf9p12zdjcr159blbicrfvadmaqvfxbi8njw1dq")))) + (arguments `(#:skip-build? #true)) ;XXX: Android only + (build-system cargo-build-system) + (home-page "https://github.com/nercury/android_log-sys-rs") + (synopsis "FFI bindings to Android log Library") + (description "This package provides FFI bindings to Android log Library.") + (license (list license:expat license:asl2.0)))) + (define-public rust-ansi-parser-0.6 (package (name "rust-ansi-parser") -- cgit v1.2.3 From 52afb2f2aae834d3ecce7a523aa15a45011e3d4d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:25:12 +0100 Subject: gnu: Add rust-android-logger-0.8. * gnu/packages/crates-io.scm (rust-android-logger-0.8): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1f865f471e..170b531d51 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -673,6 +673,31 @@ be used with the stdlib.") (description "This package provides FFI bindings to Android log Library.") (license (list license:expat license:asl2.0)))) +(define-public rust-android-logger-0.8 + (package + (name "rust-android-logger") + (version "0.8.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "android_logger" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0kj8i03fqqwxd803hrk27j2399v27ajjj9zxi2nnyml0s4nm9gcc")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-android-log-sys" ,rust-android-log-sys-0.1) + ("rust-env-logger" ,rust-env-logger-0.7) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4)))) + (home-page "https://github.com/Nercury/android_logger-rs") + (synopsis "Logging implementation for @code{log}") + (description + "This library is a drop-in replacement for @code{env_logger}. Instead, +it outputs messages to Android's logcat.") + (license (list license:expat license:asl2.0)))) + (define-public rust-ansi-parser-0.6 (package (name "rust-ansi-parser") -- cgit v1.2.3 From 1670de3910c14d5fa9d2c6cd07aa31088f94b7fe Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 3 Jan 2021 23:26:46 +0100 Subject: gnu: Add rust-ndk-glue-0.2. * gnu/packages/crates-io.scm (rust-ndk-glue-0.2): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 170b531d51..0480c1b53e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18438,6 +18438,34 @@ general elements and for numerics.") "This package provides safe Rust bindings to the Android NDK.") (license (list license:expat license:asl2.0)))) +(define-public rust-ndk-glue-0.2 + (package + (name "rust-ndk-glue") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "ndk-glue" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0hajn6nsg6i3khi7yr2ayafpiznm5z3k5v64afqnz753nyw9kwxx")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: Android only + #:cargo-inputs + (("rust-android-logger" ,rust-android-logger-0.8) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-ndk" ,rust-ndk-0.2) + ("rust-ndk-macro" ,rust-ndk-macro-0.2) + ("rust-ndk-sys" ,rust-ndk-sys-0.2)))) + (home-page "https://github.com/rust-windowing/android-ndk-rs") + (synopsis "Startup code for Android binaries") + (description + "This package provides startup code for Android binaries.") + (license (list license:expat license:asl2.0)))) + (define-public rust-ndk-macro-0.2 (package (name "rust-ndk-macro") -- cgit v1.2.3 From ad911c832178216b0121c6ecb8349d1a9d68526f Mon Sep 17 00:00:00 2001 From: Rovanion Luckey Date: Tue, 15 Dec 2020 12:33:12 +0100 Subject: doc: Running Guix Before It Is Installed: mention ./bootstrap MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * doc/contributing.texi (Running Guix Before It Is Installed): Instruct user to run ./bootstrap before ./configure. Signed-off-by: Jakub Kądziołka --- doc/contributing.texi | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/doc/contributing.texi b/doc/contributing.texi index 4195cb4105..d0ab08336a 100644 --- a/doc/contributing.texi +++ b/doc/contributing.texi @@ -166,14 +166,15 @@ actually installing them. So that you can distinguish between your ``end-user'' hat and your ``motley'' costume. To that end, all the command-line tools can be used even if you have not -run @code{make install}. To do that, you first need to have an environment -with all the dependencies available (@pxref{Building from Git}), and then -simply prefix each command with -@command{./pre-inst-env} (the @file{pre-inst-env} script lives in the -top build tree of Guix; it is generated by @command{./configure}). -As an example, here is how you would build the @code{hello} package as -defined in your working tree (this assumes @command{guix-daemon} is -already running on your system; it's OK if it's a different version): +run @code{make install}. To do that, you first need to have an +environment with all the dependencies available (@pxref{Building from +Git}), and then simply prefix each command with @command{./pre-inst-env} +(the @file{pre-inst-env} script lives in the top build tree of Guix; it +is generated by running @command{./bootstrap} followed by +@command{./configure}). As an example, here is how you would build the +@code{hello} package as defined in your working tree (this assumes +@command{guix-daemon} is already running on your system; it's OK if it's +a different version): @example $ ./pre-inst-env guix build hello -- cgit v1.2.3 From 708a610e45ab06844916c73ca0ea37e7810bd3c4 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Fri, 1 Jan 2021 15:16:07 +0100 Subject: gnu: Add coin3D@4.0.0. * gnu/packages/graphics.scm (coin3D-4): New variable. Signed-off-by: Leo Famulari --- gnu/packages/graphics.scm | 53 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 5672339496..1c46471e08 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -1732,6 +1732,59 @@ standard graphics library for 3D visualization and visual simulation software in the scientific and engineering community.") (license license:bsd-3)))) +(define-public coin3D-4 + (package + (name "coin3D") + (version "4.0.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/coin3d/coin") + (commit (string-append "Coin-" version)) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1ayg0hl8wanhadahm5xbghghxw1qjwqbrs3dl3ngnff027hsyf8p")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Delete binaries + (for-each delete-file + '("cfg/csubst.exe" + "cfg/wrapmsvc.exe")) + ;; Delete references to packaging tool cpack. Otherwise the build + ;; fails with "add_subdirectory given source "cpack.d" which is not + ;; an existing directory." + (substitute* "CMakeLists.txt" + ((".*cpack.d.*") "")) + #t)))) + (build-system cmake-build-system) + (native-inputs + `(("doxygen" ,doxygen) + ("graphviz" ,graphviz))) + (inputs + `(("boost" ,boost) + ("freeglut" ,freeglut) + ("glew" ,glew))) + (arguments + `(#:configure-flags + (list + "-DCOIN_BUILD_DOCUMENTATION_MAN=ON" + (string-append "-DBOOST_ROOT=" + (assoc-ref %build-inputs "boost"))))) + (home-page "https://github.com/coin3d/coin") + (synopsis + "High-level 3D visualization library with Open Inventor 2.1 API") + (description + "Coin is a 3D graphics library with an Application Programming Interface +based on the Open Inventor 2.1 API. For those who are not familiar with Open +Inventor, it is a scene-graph based retain-mode rendering and model interaction +library, written in C++, which has become the de facto standard graphics +library for 3D visualization and visual simulation software in the scientific +and engineering community.") + (license license:bsd-3))) + (define-public superfamiconv (package (name "superfamiconv") -- cgit v1.2.3 From a5f13705cb9261ab66bdf73d1fb4a832714feb31 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Fri, 1 Jan 2021 15:17:06 +0100 Subject: gnu: Add soqt. * gnu/packages/qt.scm (soqt): New variable. Signed-off-by: Leo Famulari --- gnu/packages/qt.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 0b94063373..79d41b3e73 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -67,6 +67,7 @@ #:use-module (gnu packages glib) #:use-module (gnu packages gnupg) #:use-module (gnu packages gperf) + #:use-module (gnu packages graphics) #:use-module (gnu packages gstreamer) #:use-module (gnu packages gtk) #:use-module (gnu packages icu4c) @@ -2850,3 +2851,35 @@ being fully customizable and easy to extend.") ;; According to LICENSE, either version 2 or version 3 of the GNU GPL may ;; be used. (license (list license:gpl2 license:gpl3)))) + + +(define-public soqt + (let ((commit-ref "fb8f655632bb9c9c60e0ff9fa69a5ba22d3ff99d") + (revision "1")) + (package + (name "soqt") + (version (git-version "1.6.0" revision commit-ref)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/coin3d/soqt") + (commit commit-ref) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 "16vikb3fy8rmk10sg5g0gy2c343hi3x7zccsga90ssnkzpq6m032")))) + (build-system cmake-build-system) + (arguments '(#:tests? #f)) ; There are no tests + (native-inputs + `(("pkg-config" ,pkg-config) + ("cmake" ,cmake))) + (inputs + `(("qtbase" ,qtbase) + ("coin3D" ,coin3D-4))) + (home-page "https://github.com/coin3d/soqt") + (synopsis "Qt GUI component toolkit library for Coin") + (description "SoQt is a Qt GUI component toolkit library for Coin. It is +also compatible with SGI and TGS Open Inventor, and the API is based on the API +of the InventorXt GUI component toolkit.") + (license license:bsd-3)))) -- cgit v1.2.3 From ad2469ec86357b1a46dd63dcd17d5831969d5270 Mon Sep 17 00:00:00 2001 From: Ryan Prior via Guix-patches via Date: Mon, 4 Jan 2021 01:47:34 +0000 Subject: gnu: esbuild: Update to 0.8.29. * gnu/packages/web.scm (esbuild): Update to 0.8.29. Signed-off-by: Leo Famulari --- gnu/packages/web.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 34998b94a5..20a40560e2 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -1487,7 +1487,7 @@ used to validate and fix HTML data.") (define-public esbuild (package (name "esbuild") - (version "0.8.27") + (version "0.8.29") (source (origin (method git-fetch) @@ -1496,7 +1496,7 @@ used to validate and fix HTML data.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1n9h6r3q6mik7p5j0cyybh1sdcllig0awbryrx28r03cxv4ip2ij")) + (base32 "142gc21aaqmx0d01vmqsg7zi85pjgi3higr4ba0m52qf3mvxd6as")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 4a829b2d55bc9b0ad5a335c8228a7d2371fa1d9a Mon Sep 17 00:00:00 2001 From: Ryan Prior Date: Fri, 1 Jan 2021 21:19:29 +0000 Subject: gnu: Add wyhash. * gnu/packages/digest.scm (wyhash): New variable. Signed-off-by: Leo Famulari --- gnu/packages/digest.scm | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/gnu/packages/digest.scm b/gnu/packages/digest.scm index a33e238362..986e335861 100644 --- a/gnu/packages/digest.scm +++ b/gnu/packages/digest.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2021 Ryan Prior ;;; ;;; This file is part of GNU Guix. ;;; @@ -21,9 +22,44 @@ #:use-module (guix packages) #:use-module (guix git-download) #:use-module (guix build-system gnu) + #:use-module (guix build-system trivial) #:use-module (guix utils) #:use-module (ice-9 match)) +(define-public wyhash + (package + (name "wyhash") + (version "5") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wangyi-fudan/wyhash") + (commit (string-append "wyhash_v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "03ljs5iw9zrm3bydwggjvpwrcwmsd75h3dv1j4am4hw3h22cjdjc")))) + (build-system trivial-build-system) ;; source-only package + (arguments + `(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (let* ((out (string-append (assoc-ref %outputs "out"))) + (include (string-append out "/include")) + (doc (string-append out "/share/doc/" ,name "-" ,version)) + (source (assoc-ref %build-inputs "source"))) + (with-directory-excursion source + (install-file "wyhash.h" include) + (install-file "LICENSE" doc) + (install-file "README.md" doc)) + #t)))) + (home-page "https://github.com/wangyi-fudan/wyhash") + (synopsis "Embeddable hash function and random number generator") + (description "This package provides a portable hash function and random +number generator suitable for use in data structures. Provided by default in +Zig, V, and Nim programming language standard libraries.") + (license license:unlicense))) + (define-public xxhash (package (name "xxhash") -- cgit v1.2.3 From fdfc1c81ba018dd808b0dfd9827a73262c716808 Mon Sep 17 00:00:00 2001 From: Ellis Kenyo Date: Fri, 1 Jan 2021 14:20:14 +0000 Subject: gnu: Add nordic-theme. * gnu/packages/gnome-xyz.scm (nordic-theme): New variable. Signed-off-by: Leo Famulari --- gnu/packages/gnome-xyz.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 2eb08da50f..10df9bc366 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2020 Ekaitz Zarraga ;;; Copyright © 2020 Tobias Geerinckx-Rice ;;; Copyright © 2020 Ryan Prior +;;; Copyright © 2020 Ellis Kenyo ;;; ;;; This file is part of GNU Guix. ;;; @@ -649,3 +650,31 @@ language specification for the Language Server Protocol (LSP). This tool is used in text editing environments to provide a complete and integrated feature-set for programming Vala effectively.") (license license:lgpl2.1+))) + +(define-public nordic-theme + (let ((commit "07d764c5ebd5706e73d2e573f1a983e37b318915") + (revision "0")) + (package + (name "nordic-theme") + (version (git-version "1.9.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/EliverLara/Nordic") + (commit commit))) + (sha256 + (base32 + "0y2s9d6h1b195s6afp1gb5rb1plfslkpbw2brd30a9d66wfvsqk0")) + (file-name (git-file-name name version)))) + (build-system copy-build-system) + (arguments + `(#:install-plan + `(("." "share/themes/nord" + #:exclude ("README.md" "LICENSE" "Art/" "package.json" + "package-lock.json" "Gulpfile.js"))))) + (home-page "https://github.com/EliverLara/Nordic") + (synopsis "Dark Gtk3.20+ theme using the Nord color pallete") + (description "Nordic is a Gtk3.20+ theme created using the Nord color +pallete.") + (license license:gpl3)))) -- cgit v1.2.3 From 6f365f7c10938fc7bc609f95a79893585843454d Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 4 Jan 2021 10:10:26 +0200 Subject: gnu: elisa: Update to 20.12.0. * gnu/packages/kde-multimedia.scm (elisa): Update to 20.12.0. [source]: Use new upstream source URI. [arguments]: Replace 'check phase. --- gnu/packages/kde-multimedia.scm | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/gnu/packages/kde-multimedia.scm b/gnu/packages/kde-multimedia.scm index cc312b6c40..cb8cc74d33 100644 --- a/gnu/packages/kde-multimedia.scm +++ b/gnu/packages/kde-multimedia.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017, 2019 Hartmut Goebel ;;; Copyright © 2020 Timotej Lazar +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -133,14 +134,14 @@ This package is part of the KDE multimedia module.") (define-public elisa (package (name "elisa") - (version "0.4.2") + (version "20.12.0") (source (origin (method url-fetch) - (uri (string-append "mirror://kde//stable/elisa/0.4.2" - "/elisa-" version ".tar.xz")) + (uri (string-append "mirror://kde/stable/release-service/" version + "/src/elisa-" version ".tar.xz")) (sha256 - (base32 "0v9af6l89pgz1g7naf7gwcnq8znlicyh7z985kxalbdmv359c97w")))) + (base32 "02450lsnbd37fms1i2bb9qc9wir4vym6qqd9p5hr6a6s6qwfs6qf")))) (build-system qt-build-system) (native-inputs `(("extra-cmake-modules" ,extra-cmake-modules) @@ -188,6 +189,12 @@ This package is part of the KDE multimedia module.") (system (string-append (assoc-ref inputs "xorg-server") "/bin/Xvfb :1 -screen 0 640x480x24 &")) (setenv "DISPLAY" ":1") + #t)) + (replace 'check + (lambda* (#:key tests? test-target #:allow-other-keys) + (when tests? + (setenv "CTEST_OUTPUT_ON_FAILURE" "1") + (invoke "dbus-launch" "make" test-target)) #t))))) (home-page "https://kde.org/applications/multimedia/org.kde.elisa") (synopsis "Powerful music player for Plasma 5") -- cgit v1.2.3 From d005f809f8209dfb3e4b4ee02b6f2beeb1d8f2e6 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Sun, 3 Jan 2021 21:45:07 +0000 Subject: gnu: Add cl-db3. * gnu/packages/lisp-xyz.scm (cl-db3, ecl-db3, sbcl-db3): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 2d9ad8c7eb..56ca5b6136 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -9133,6 +9133,35 @@ foreign libraries. " :ecl) \"usocket\"")) #t))))))) +(define-public sbcl-db3 + (let ((commit "38e5ad35f025769fb7f8dcdc6e56df3e8efd8e6d") + (revision "1")) + (package + (name "sbcl-db3") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/dimitri/cl-db3") + (commit commit))) + (file-name (git-file-name "cl-db3" version)) + (sha256 + (base32 "1i7j0mlri6kbklcx1lsm464s8kmyhhij5c4xh4aybrw8m4ixn1s5")))) + (build-system asdf-build-system/sbcl) + (home-page "https://github.com/dimitri/cl-db3") + (synopsis "Common Lisp library to read dBase III database files") + (description + "This is a Common Lisp library for processing data found in dBase III +database files (dbf and db3 files).") + (license license:public-domain)))) + +(define-public ecl-db3 + (sbcl-package->ecl-package sbcl-db3)) + +(define-public cl-db3 + (sbcl-package->cl-source-package sbcl-db3)) + (define-public sbcl-dbi ;; Master includes a breaking change which other packages depend on since ;; Quicklisp decided to follow it: -- cgit v1.2.3 From ed63b7f87e88b0ce9c4a78bf0529599de9172b1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Sun, 3 Jan 2021 21:59:49 +0100 Subject: guix hash: Honor '-H' when used alongside '-r'. * guix/scripts/hash.scm (guix-hash): When 'recursive? is true, use 'open-hash-port' instead of 'open-sha256-port'. * tests/guix-hash.sh: Add test for 'guix hash -r -H sha512'. --- guix/scripts/hash.scm | 5 +++-- tests/guix-hash.sh | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/guix/scripts/hash.scm b/guix/scripts/hash.scm index 797b99f053..b8622373cc 100644 --- a/guix/scripts/hash.scm +++ b/guix/scripts/hash.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2016, 2017, 2020 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2016, 2017, 2020, 2021 Ludovic Courtès ;;; Copyright © 2013 Nikita Karetnikov ;;; Copyright © 2016 Jan Nieuwenhuizen ;;; Copyright © 2018 Tim Gesthuizen @@ -151,7 +151,8 @@ and 'base16' ('hex' and 'hexadecimal' can be used as well).\n")) ;; Catch and gracefully report possible '&nar-error' conditions. (with-error-handling (if (assoc-ref opts 'recursive?) - (let-values (((port get-hash) (open-sha256-port))) + (let-values (((port get-hash) + (open-hash-port (assoc-ref opts 'hash-algorithm)))) (write-file file port #:select? select?) (force-output port) (get-hash)) diff --git a/tests/guix-hash.sh b/tests/guix-hash.sh index 346355539f..c4461fa955 100644 --- a/tests/guix-hash.sh +++ b/tests/guix-hash.sh @@ -1,5 +1,5 @@ # GNU Guix --- Functional package management for GNU -# Copyright © 2013, 2014, 2016, 2020 Ludovic Courtès +# Copyright © 2013, 2014, 2016, 2020, 2021 Ludovic Courtès # Copyright © 2016 Jan Nieuwenhuizen # # This file is part of GNU Guix. @@ -43,6 +43,7 @@ chmod +x "$tmpdir/exe" mkdir "$tmpdir/subdir" test `guix hash -r "$tmpdir"` = 10k1lw41wyrjf9mxydi0is5nkpynlsvgslinics4ppir13g7d74p +test `guix hash -r "$tmpdir" -H sha512` = 301ra58c2vahczzxiyfin41mpyb0ljh4dh9zn3ijvwviaw1j40sfzw5skh9x945da88n3785ggifzig7acd6k72h0mpsc20m1f66m9n # Without '-r', this should fail. ! guix hash "$tmpdir" -- cgit v1.2.3 From 9158020d7853b6e7925802e0d0a082801c680e8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 11:05:58 +0100 Subject: substitute: Handle "invalid session" GnuTLS errors on reused connections. Reported by Christopher Baines at . * guix/scripts/substitute.scm (call-with-cached-connection): Handle 'gnutls-error and ERROR/INVALID-SESSION. --- guix/scripts/substitute.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/guix/scripts/substitute.scm b/guix/scripts/substitute.scm index 8084c89ae5..e53de8c304 100755 --- a/guix/scripts/substitute.scm +++ b/guix/scripts/substitute.scm @@ -43,6 +43,7 @@ (open-connection-for-uri . guix:open-connection-for-uri) store-path-abbreviation byte-count->string)) + #:autoload (gnutls) (error/invalid-session) #:use-module (guix progress) #:use-module ((guix build syscalls) #:select (set-thread-name)) @@ -1054,9 +1055,12 @@ server certificates." ;; If PORT was cached and the server closed the connection in the ;; meantime, we get EPIPE. In that case, open a fresh connection and ;; retry. We might also get 'bad-response or a similar exception from - ;; (web response) later on, once we've sent the request. + ;; (web response) later on, once we've sent the request, or a + ;; ERROR/INVALID-SESSION from GnuTLS. (if (or (and (eq? key 'system-error) (= EPIPE (system-error-errno `(,key ,@args)))) + (and (eq? key 'gnutls-error) + (eq? (first args) error/invalid-session)) (memq key '(bad-response bad-header bad-header-component))) (proc (open-connection uri #:fresh? #t)) (apply throw key args)))))) -- cgit v1.2.3 From 61d8bd56a4644a72b964b680456da4332eb1ef6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 11:29:17 +0100 Subject: machine: ssh: Do not import the host (guix config), really. This is a followup to 70ffa8af1e93ab8a92c4622745e9cb4a2782f3c8, which did not really solve the problem. * gnu/machine/ssh.scm (not-config?): New procedure. (machine-boot-parameters): Use it as an argument to 'source-module-closure'. --- gnu/machine/ssh.scm | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/gnu/machine/ssh.scm b/gnu/machine/ssh.scm index 08c653ba17..997d673e75 100644 --- a/gnu/machine/ssh.scm +++ b/gnu/machine/ssh.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Jakob L. Kreuze -;;; Copyright © 2020 Ludovic Courtès +;;; Copyright © 2020, 2021 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -346,6 +346,14 @@ by MACHINE." ;;; System deployment. ;;; +(define not-config? + ;; Select (guix …) and (gnu …) modules, except (guix config). + (match-lambda + (('guix 'config) #f) + (('guix _ ...) #t) + (('gnu _ ...) #t) + (_ #f))) + (define (machine-boot-parameters machine) "Monadic procedure returning a list of 'boot-parameters' for the generations of MACHINE's system profile, ordered from most recent to oldest." @@ -354,9 +362,10 @@ of MACHINE's system profile, ordered from most recent to oldest." (define remote-exp (with-extensions (list guile-gcrypt) - (with-imported-modules (source-module-closure - `(((guix config) => ,(make-config.scm)) - (guix profiles))) + (with-imported-modules `(((guix config) => ,(make-config.scm)) + ,@(source-module-closure + '((guix profiles)) + #:select? not-config?)) #~(begin (use-modules (guix config) (guix profiles) -- cgit v1.2.3 From 0aed31be661fc6d8811525d7bb7c4a30237ea2c6 Mon Sep 17 00:00:00 2001 From: guy fleury iteriteka Date: Fri, 1 Jan 2021 14:35:11 +0200 Subject: environment: Remove unused modules. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * guix/scripts/environment.scm: Do not use (ice-9 format) and (ice-9 rdelim). Signed-off-by: Ludovic Courtès --- guix/scripts/environment.scm | 2 -- 1 file changed, 2 deletions(-) diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm index e435bf0ce4..fbc202c658 100644 --- a/guix/scripts/environment.scm +++ b/guix/scripts/environment.scm @@ -42,9 +42,7 @@ #:use-module (gnu packages bash) #:use-module ((gnu packages bootstrap) #:select (bootstrap-executable %bootstrap-guile)) - #:use-module (ice-9 format) #:use-module (ice-9 match) - #:use-module (ice-9 rdelim) #:use-module (srfi srfi-1) #:use-module (srfi srfi-11) #:use-module (srfi srfi-26) -- cgit v1.2.3 From 729f582a830dc03a509d1e3ad28bac1d43ba6e2e Mon Sep 17 00:00:00 2001 From: aecepoglu Date: Sat, 26 Dec 2020 01:57:48 +0300 Subject: gnu: Add boxes. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/shellutils.scm (boxes): New variable. Signed-off-by: Ludovic Courtès --- gnu/packages/shellutils.scm | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/gnu/packages/shellutils.scm b/gnu/packages/shellutils.scm index 181a640475..44a1934610 100644 --- a/gnu/packages/shellutils.scm +++ b/gnu/packages/shellutils.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2018 Benjamin Slade ;;; Copyright © 2019 Collin J. Doering ;;; Copyright © 2020 Michael Rohleder +;;; Copyright © 2020 aecepoglu ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,6 +35,8 @@ #:use-module (guix build-system python) #:use-module (gnu packages autotools) #:use-module (gnu packages base) + #:use-module (gnu packages bison) + #:use-module (gnu packages flex) #:use-module (gnu packages golang) #:use-module (gnu packages ncurses) #:use-module (gnu packages pkg-config) @@ -43,6 +46,45 @@ #:use-module (gnu packages shells) #:use-module (gnu packages tmux)) +(define-public boxes + (package + (name "boxes") + (version "1.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ascii-boxes/boxes") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + "0b12rsynrmkldlwcb62drk33kk0aqwbj10mq5y5x3hjf626gjwsi"))) + (build-system gnu-build-system) + (arguments + `(#:test-target "test" + #:make-flags (list (string-append "GLOBALCONF=" + (assoc-ref %outputs "out") + "/etc/boxes-config")) + #:phases + (modify-phases %standard-phases + (delete 'configure) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((dest (assoc-ref outputs "out"))) + (for-each (lambda (x) + (install-file (car x) + (string-append dest "/" (cdr x)))) + '(("src/boxes" . "bin") + ("doc/boxes.1" . "share/man/man1") + ("boxes-config" . "etc/"))) + #t)))))) + (native-inputs `(("flex" ,flex) ("bison" ,bison))) + (synopsis "Command line ASCII boxes") + (description + "This command-line filter program draws ASCII-art boxes around your input +text.") + (home-page "https://boxes.thomasjensen.com/build.html") + (license license:gpl2))) + (define-public zsh-autosuggestions (package (name "zsh-autosuggestions") -- cgit v1.2.3 From 08f35b9b6ca635f439bc2b01965aeb73e7ec282d Mon Sep 17 00:00:00 2001 From: Rovanion Luckey Date: Sun, 3 Jan 2021 19:55:36 +0100 Subject: gnu: Add nomacs photo lounge. * gnu/packages/image-viewers.scm (nomacs): New variable. Signed-off-by: Leo Prikler --- gnu/packages/image-viewers.scm | 64 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) diff --git a/gnu/packages/image-viewers.scm b/gnu/packages/image-viewers.scm index 0a6be77d24..d9ee795b0f 100644 --- a/gnu/packages/image-viewers.scm +++ b/gnu/packages/image-viewers.scm @@ -15,6 +15,7 @@ ;;; Copyright © 2020 Peng Mei Yu ;;; Copyright © 2020 R Veera Kumar ;;; Copyright © 2020 Pierre Neidhardt +;;; Copyright © 2021 Rovanion Luckey ;;; ;;; This file is part of GNU Guix. ;;; @@ -58,6 +59,7 @@ #:use-module (gnu packages gtk) #:use-module (gnu packages graphics) #:use-module (gnu packages image) + #:use-module (gnu packages image-processing) #:use-module (gnu packages imagemagick) #:use-module (gnu packages maths) #:use-module (gnu packages perl) @@ -682,3 +684,65 @@ brightness/contrast/gamma correction, pan with keyboard and mouse, flip, rotate left/right, jump/forward/backward images, filename filter and use it to set X desktop background.") (license license:gpl2))) + +(define-public nomacs + (package + (name "nomacs") + (version "3.16.224") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nomacs/nomacs") + (commit version))) + (sha256 + (base32 + "05d4hqg0gl3g9s2xf1hr7mc7g4cqarcap4nzxxa51fsphw2b8x16")))) + (build-system cmake-build-system) + (arguments + `(#:build-type "Release" ; fails to build with debug info + #:configure-flags (list "-DENABLE_TRANSLATIONS=true" + "-DUSE_SYSTEM_QUAZIP=true" + "-DENABLE_OPENCV=true") + #:tests? #f ; no rule for target 'test' + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'copy-plugins + (lambda* (#:key inputs #:allow-other-keys) + (copy-recursively (assoc-ref inputs "plugins") + "ImageLounge/plugins"))) + (add-after 'copy-plugins 'cd-to-source-dir + (lambda _ (chdir "ImageLounge") #t))))) + (inputs + `(("plugins" + ,(origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nomacs/nomacs-plugins") + (commit "3.16"))) + (sha256 + (base32 + "1cpdwhfvaxm970nwdc1hc13848a85pqqi176m9xpa3krla9qskml")))) + ("exiv2" ,exiv2) + ("libraw" ,libraw) + ("libtiff" ,libtiff) + ("opencv" ,opencv) + ("python" ,python-wrapper) + ("quazip" ,quazip) + ("qtbase" ,qtbase) + ("qtsvg" ,qtsvg) + ("qtlinguist" ,qttools))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (synopsis "Image viewer supporting all common formats") + (description "Nomacs is a simple to use image lounge featuring +semi-transparent widgets that display additional information such as metadata, +thumbnails and histograms. It is able to browse images compressed archives +and add notes to images. + +Nomacs includes image manipulation methods for adjusting brightness, contrast, +saturation, hue, gamma, and exposure. It has a pseudo color function which +allows creating false color images. A unique feature of Nomacs is the +synchronization of multiple instances.") + (home-page "https://nomacs.org/") + (license license:gpl3+))) -- cgit v1.2.3 From a2da6074d041afc22eb9258394c31681711fb16c Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Mon, 4 Jan 2021 16:11:06 +0200 Subject: gnu: suitesparse: Install libraries into /lib. * gnu/packages/maths.scm (suitesparse)[arguments]: Add to configure-flags to install programs built with cmake to use 'lib', not 'lib64.' --- gnu/packages/maths.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 0ba6b3444e..7866bcc6eb 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus ;;; Copyright © 2015 Sou Bunnbu ;;; Copyright © 2015, 2018 Mark H Weaver -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2015 Fabian Harfert ;;; Copyright © 2016 Roel Janssen ;;; Copyright © 2016, 2018, 2020 Kei Kebreau @@ -3928,7 +3928,8 @@ Fresnel integrals, and similar related functions as well.") " -DCMAKE_C_FLAGS_RELEASE=\"$(CFLAGS) $(CPPFLAGS)\"" " -DCMAKE_CXX_FLAGS_RELEASE=\"$(CXXFLAGS) $(CPPFLAGS)\"" " -DCMAKE_SKIP_RPATH=TRUE" - " -DCMAKE_BUILD_TYPE=Release") + " -DCMAKE_BUILD_TYPE=Release" + " -DCMAKE_INSTALL_LIBDIR=lib") (string-append "INSTALL_LIB=" (assoc-ref %outputs "out") "/lib") (string-append "INSTALL_INCLUDE=" -- cgit v1.2.3 From 223d8fb4a0e31957c85ef42ef501c8ed038a7259 Mon Sep 17 00:00:00 2001 From: Paul Garlick Date: Mon, 4 Jan 2021 14:14:46 +0000 Subject: gnu: ikiwiki: Fix build. * gnu/packages/web.scm (ikiwiki)[inputs]: Add perl-yaml-tiny, needed for po4a versions greater than 0.57. See https://github.com/mquinson/po4a/issues/265. --- gnu/packages/web.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index 20a40560e2..0b75a27b0c 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -43,7 +43,7 @@ ;;; Copyright © 2020 Pierre Neidhardt ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2018, 2019, 2020 Björn Höfling -;;; Copyright © 2020 Paul Garlick +;;; Copyright © 2020, 2021 Paul Garlick ;;; Copyright © 2020 Michael Rohleder ;;; Copyright © 2020 Ryan Prior ;;; Copyright © 2020 Alexandru-Sergiu Marton @@ -5135,6 +5135,7 @@ NetSurf project.") ("perl-xml-feed" ,perl-xml-feed) ("perl-xml-sax" ,perl-xml-sax) ("perl-xml-twig" ,perl-xml-twig) + ("perl-yaml-tiny" ,perl-yaml-tiny) ("po4a" ,po4a))) (propagated-inputs `(("perl-cgi-formbuilder" ,perl-cgi-formbuilder) -- cgit v1.2.3 From d72a0d44594bcbd75a2ce4004ebcc27c9e9d6421 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Mon, 4 Jan 2021 17:19:15 +0100 Subject: gnu: dovecot: Update to 2.3.13 [fixes CVE-2020-25275, CVE-2020-24386]. * gnu/packages/mail.scm (dovecot): Update to 2.3.13. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 84b6fa0e76..075fce0d52 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1754,7 +1754,7 @@ facilities for checking incoming mail.") (package (name "dovecot") ;; Also update dovecot-pigeonhole when updating to a new minor version. - (version "2.3.11.3") + (version "2.3.13") (source (origin (method url-fetch) @@ -1762,7 +1762,7 @@ facilities for checking incoming mail.") (version-major+minor version) "/" "dovecot-" version ".tar.gz")) (sha256 - (base32 "1p5gp8jbavcsaara5mfn5cbrnlxssajnchczbgmmfzr7228fmnfk")))) + (base32 "1i7ijss79a23v7b6lycfzaa8r5rh01k0h0b9h0j4a6n11sw7by53")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From 95e7542e6c6e2622b3ad7615a192d4c6af2579e7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Mon, 4 Jan 2021 17:21:48 +0100 Subject: gnu: dovecot-pigeonhole: Update to 0.5.13. * gnu/packages/mail.scm (dovecot-pigeonhole): Update to 0.5.13. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 075fce0d52..aaf474a5e0 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -1823,7 +1823,7 @@ It supports mbox/Maildir and its own dbox/mdbox formats.") (let ((dovecot-version (version-major+minor (package-version dovecot)))) (package (name "dovecot-pigeonhole") - (version "0.5.11") + (version "0.5.13") (source (origin (method url-fetch) @@ -1831,7 +1831,7 @@ It supports mbox/Maildir and its own dbox/mdbox formats.") "https://pigeonhole.dovecot.org/releases/" dovecot-version "/" "dovecot-" dovecot-version "-pigeonhole-" version ".tar.gz")) (sha256 - (base32 "1w5mryv6izh1gv7davnl94rb0pvh5bxl2bydzbfla1b83x22m5qb")) + (base32 "05xz2d82ck6lmv94nbc3qff09j8b60a5640i3fmqwqsvv9kfa7wi")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 9fa21ed5304b25df46506ca397dc26365dff4787 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 13:45:18 +0100 Subject: gnu: Add rust-wepoll-sys-3. * gnu/packages/crates-io.scm (rust-wepoll-sys-3): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0480c1b53e..e719ea0945 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -37645,6 +37645,28 @@ with webpki.") "This package provides a WebIDL Parser.") (license license:expat))) +(define-public rust-wepoll-sys-3 + (package + (name "rust-wepoll-sys") + (version "3.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "wepoll-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1zvpkr4dz3ny0k20mg1wdlp8vawz5p4gnya7h8j24119m7g19jqg")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;missing "winsock.h" + #:cargo-inputs + (("rust-cc" ,rust-cc-1)))) + (home-page "https://gitlab.com/yorickpeterse/wepoll-sys") + (synopsis "Raw bindings to the @code{wepoll} library") + (description + "This crate provides unsafe Rust bindings to the @code{wepoll} library.") + (license license:mpl2.0))) + (define-public rust-which-3 (package (name "rust-which") -- cgit v1.2.3 From e4dad3d42f5c64bc1f25ee76082f5b9c3793eff0 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 14:34:58 +0100 Subject: gnu: Add rust-polling-2. * gnu/packages/crates-io.scm (rust-polling-2): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e719ea0945..5167d26a3c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -22460,6 +22460,34 @@ applications.") "Additional trait for Read and Write to read and write Plain Old Data.") (license (list license:expat license:asl2.0)))) +(define-public rust-polling-2 + (package + (name "rust-polling") + (version "2.0.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "polling" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1r5xm3f6qs84ibg09nw1cz78r883521l3jaiakj35ri959mvr9x2")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-libc" ,rust-libc-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-wepoll-sys" ,rust-wepoll-sys-3) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-easy-parallel" ,rust-easy-parallel-3)))) + (home-page "https://github.com/stjepang/polling") + (synopsis "Portable interface to epoll, kqueue, event ports, and wepoll") + (description + "This package provides a portable interface to @code{epoll}, +@code{kqueue}, @code{event ports}, and @code{wepoll}.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-polyval-0.4 (package (name "rust-polyval") -- cgit v1.2.3 From 24a285acca2a4675df79ef3169088937ab49658c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 14:39:46 +0100 Subject: gnu: Add rust-nb-connect-1. * gnu/packages/crates-io.scm (rust-nb-connect-1): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 5167d26a3c..e2733afb7c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18378,6 +18378,33 @@ IO of Windows's named pipes.") "This package provides a crate to perform natural ordering for Rust.") (license license:expat))) +(define-public rust-nb-connect-1 + (package + (name "rust-nb-connect") + (version "1.0.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "nb-connect" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1649m71wc0cg1rqgl8vbh0489znkhpwgl0isjd5x8mz470ash8w1")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-libc" ,rust-libc-0.2) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-polling" ,rust-polling-2)))) + (home-page "https://github.com/stjepang/nb-connect") + (synopsis "Non-blocking TCP or Unix connect") + (description + "This crate allows you to create a TcpStream or a UnixStream in +a non-blocking way, without waiting for the connection to become fully +established.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-ndarray-0.12 (package (name "rust-ndarray") -- cgit v1.2.3 From 8c4afe8b934b2343da13c9c656e2af5e02cf1122 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 14:43:49 +0100 Subject: gnu: Add rust-vec-arena-1. * gnu/packages/crates-io.scm (rust-vec-arena-1): New variable. --- gnu/packages/crates-io.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e2733afb7c..c97967ec71 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36614,6 +36614,24 @@ first byte.") (license (list license:asl2.0 license:expat)))) +(define-public rust-vec-arena-1 + (package + (name "rust-vec-arena") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "vec-arena" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "07866gmvn4cf2656bjf75nrmbnw4cj0cyqkv2wlmavzw5ndipz7a")))) + (build-system cargo-build-system) + (home-page "https://github.com/smol-rs/vec-arena") + (synopsis "Simple object arena") + (description + "This package provides a simple object arena.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-vec-map-0.8 (package (name "rust-vec-map") -- cgit v1.2.3 From 3daf1cc4c6237f02db58438805063f7cfddd8eff Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 14:59:23 +0100 Subject: gnu: Add rust-spinning-top-0.2. * gnu/packages/crates-io.scm (rust-spinning-top-0.2): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c97967ec71..d50457ff86 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30396,6 +30396,28 @@ future to wake it up, it continuously polls the future until the future is ready. This will probably use a lot of CPU, so be careful when you use it.") (license (list license:asl2.0 license:expat)))) +(define-public rust-spinning-top-0.2 + (package + (name "rust-spinning-top") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "spinning_top" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0dmbb627i05qla1lnxy7r6hpiia76c8kb40zcgrbar0dx1rrslky")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-lock-api" ,rust-lock-api-0.4)))) + (home-page "https://github.com/rust-osdev/spinning_top") + (synopsis "Simple spinlock based on @code{lock_api}") + (description + "This package provides a simple spinlock crate based on the abstractions +provided by @code{lock_api}.") + (license (list license:expat license:asl2.0)))) + (define-public rust-spmc-0.3 (package (name "rust-spmc") -- cgit v1.2.3 From fd9e53bf797dc34d79e0d6108dcfff62f3ec6be7 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 15:37:21 +0100 Subject: gnu: Add rust-getrandom-0.2. * gnu/packages/crates-io.scm (rust-getrandom-0.2): New variable. (rust-getch-0.2): Inherit from above. --- gnu/packages/crates-io.scm | 40 ++++++++++++++++++++++++++++++++-------- 1 file changed, 32 insertions(+), 8 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d50457ff86..724ee6870f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11743,8 +11743,39 @@ API library @code{gdi32}.") (license (list license:asl2.0 license:expat)))) +(define-public rust-getrandom-0.2 + (package + (name "rust-getrandom") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "getrandom" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1x3clmvj5k2h9qv3ihbyif1rns3pf5y5n66f5jjyc5zr6v7jb07f")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-compiler-builtins" ,rust-compiler-builtins-0.1) + ("rust-libc" ,rust-libc-0.2) + ("rust-rustc-std-workspace-core" ,rust-rustc-std-workspace-core-1) + ("rust-stdweb" ,rust-stdweb-0.4) + ("rust-wasi" ,rust-wasi-0.9) + ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2)) + #:cargo-development-inputs + (("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)))) + (home-page "https://github.com/rust-random/getrandom") + (synopsis "Retrieve random data from system source") + (description + "This package provides a small cross-platform library for +retrieving random data from system source.") + (license (list license:expat license:asl2.0)))) + (define-public rust-getrandom-0.1 (package + (inherit rust-getrandom-0.2) (name "rust-getrandom") (version "0.1.14") (source @@ -11756,7 +11787,6 @@ API library @code{gdi32}.") (sha256 (base32 "1sq30li71h19rhnhs1h6576ja68insajx8wvh1nn088r8pc8vg3s")))) - (build-system cargo-build-system) (arguments `(#:skip-build? #t #:cargo-inputs @@ -11767,13 +11797,7 @@ API library @code{gdi32}.") ("rust-log" ,rust-log-0.4) ("rust-stdweb" ,rust-stdweb-0.4) ("rust-wasi" ,rust-wasi-0.9) - ("rust-rustc-std-workspace-core" ,rust-rustc-std-workspace-core-1)))) - (home-page "https://github.com/rust-random/getrandom") - (synopsis "Retrieve random data from system source") - (description - "This package provides a small cross-platform library for -retrieving random data from system source.") - (license (list license:expat license:asl2.0)))) + ("rust-rustc-std-workspace-core" ,rust-rustc-std-workspace-core-1)))))) (define-public rust-gettext-rs-0.5 (package -- cgit v1.2.3 From cf5fdbf3cfe1d0d442417a1e85b4fd4f4edb65b3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 15:48:40 +0100 Subject: gnu: Add rust-random-trait-0.1. * gnu/packages/crates-io.scm (rust-random-trait-0.1): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 724ee6870f..96819b6b77 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24776,6 +24776,28 @@ random number generators.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.6)))))) +(define-public rust-random-trait-0.1 + (package + (name "rust-random-trait") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "random-trait" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0iw4laa9i97x1m1mc72rx0km0j6pjdrb75b0c93fdaq45spqcc8d")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-doc-comment" ,rust-doc-comment-0.3)))) + (home-page "https://crates.io/crates/random-trait") + (synopsis "Rust library for a random trait") + (description + "This package is a Rust library for a random trait meant to produce +random generic types.") + (license (list license:expat license:asl2.0)))) + (define-public rust-raw-cpuid-8 (package (name "rust-raw-cpuid") -- cgit v1.2.3 From 9effe707aef3945784a7a3141c78d995b9f5195b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 15:50:29 +0100 Subject: gnu: Add rust-random-fast-rng-0.1. * gnu/packages/crates-io.scm (rust-random-fast-rng-0.1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 96819b6b77..b1edda5120 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24776,6 +24776,29 @@ random number generators.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.6)))))) +(define-public rust-random-fast-rng-0.1 + (package + (name "rust-random-fast-rng") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "random-fast-rng" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "18q577c8j2j9j044b5fnj1xw1lwkyjrkl3agzp3lvx3iln24wy4m")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-doc-comment" ,rust-doc-comment-0.3) + ("rust-random-trait" ,rust-random-trait-0.1)))) + (home-page "https://github.com/elichai/random-rs") + (synopsis "Library for fast non cryptographic random number generator") + (description + "This package is a Rust library for fast non cryptographic random number +generator.") + (license (list license:expat license:asl2.0)))) + (define-public rust-random-trait-0.1 (package (name "rust-random-trait") -- cgit v1.2.3 From 4f4f2edd329e55d9ae1a5dbfa4cbe7e666f3ce55 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 15:54:57 +0100 Subject: gnu: Add rust-randomize-4. * gnu/packages/crates-io.scm (rust-randomize-4): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b1edda5120..e542a77248 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24821,6 +24821,29 @@ generator.") random generic types.") (license (list license:expat license:asl2.0)))) +(define-public rust-randomize-4 + (package + (name "rust-randomize") + (version "4.0.0-alpha.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "randomize" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0m4vkgm161q51ww9bvf0kram9cxg8j3p80rl9w1fzpgkwcwbqhpm")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true + #:cargo-inputs + (("rust-getrandom" ,rust-getrandom-0.1)))) + (home-page "https://github.com/Lokathor/randomize") + (synopsis "Minimalist randomization library") + (description + "This package provides a minimalist randomization library.") + (license + (list license:zlib license:asl2.0 license:expat)))) + (define-public rust-raw-cpuid-8 (package (name "rust-raw-cpuid") -- cgit v1.2.3 From 8849b7c582f84c7b0d81c4adfee1a08134b7817d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 15:57:34 +0100 Subject: gnu: Add rust-nanorand-0.5. * gnu/packages/crates-io.scm (rust-nanorand-0.5): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e542a77248..b74555934f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18054,6 +18054,36 @@ a default trait implementation you've defined.") libmysqlclient.") (license (list license:expat license:asl2.0)))) +(define-public rust-nanorand-0.5 + (package + (name "rust-nanorand") + (version "0.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "nanorand" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1ryi6jdfsfij4di33f269099g7m32rlr7sv7j4pklnjcj2xxfwri")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;error with pre-release randomize + #:cargo-inputs + (("rust-getrandom" ,rust-getrandom-0.2) + ("rust-zeroize" ,rust-zeroize-1)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.3) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-hex" ,rust-hex-0.4) + ("rust-random-fast-rng" ,rust-random-fast-rng-0.1) + ("rust-randomize" ,rust-randomize-4)))) + (home-page "https://github.com/aspenluxxxy/nanorand-rs") + (synopsis "Tiny, fast, zero-dep library for random number generation") + (description + "This library is meant for fast, random number generation with +quick compile time, and minimal dependencies.") + (license license:zlib))) + (define-public rust-nasm-rs-0.2 (package (name "rust-nasm-rs") -- cgit v1.2.3 From aaf637e6850cd499402724be1ac44ca150448c4b Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 20 Dec 2020 23:52:45 +0100 Subject: gnu: rust-signal-hook-0.1: Update to 0.1.16. * gnu/packages/crates-io.scm (rust-signal-hook-0.1): Update to 0.1.16. [arguments]: Update rust-mio Cargo input. --- gnu/packages/crates-io.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b74555934f..c51a4cad30 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -29810,7 +29810,7 @@ words, like Python's shlex.") (define-public rust-signal-hook-0.1 (package (name "rust-signal-hook") - (version "0.1.13") + (version "0.1.16") (source (origin (method url-fetch) @@ -29819,13 +29819,13 @@ words, like Python's shlex.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0b0yh6hlb5hs5kq6adyk0bn168y1ncymxvlizlygaabad2hz7f8h")))) + "1v85mgs4dbgw0765b9nx0jd8lamv55425aawjbhxz6cb870hhib0")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-futures" ,rust-futures-0.1) ("rust-libc" ,rust-libc-0.2) - ("rust-mio" ,rust-mio-0.6) + ("rust-mio" ,rust-mio-0.7) ("rust-mio-uds" ,rust-mio-uds-0.6) ("rust-signal-hook-registry" ,rust-signal-hook-registry-1) ("rust-tokio-reactor" ,rust-tokio-reactor-0.1)) -- cgit v1.2.3 From 6065b4cfa9b5e674a4e838fe472015f373dc76de Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:00:15 +0100 Subject: gnu: Add rust-inotify-0.8. * gnu/packages/crates-io.scm (rust-inotify-0.8): New variable. (rust-inotify-0.7): Inherit from above. --- gnu/packages/crates-io.scm | 39 ++++++++++++++++++++++++++++++++------- 1 file changed, 32 insertions(+), 7 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c51a4cad30..00eebfccf4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14138,8 +14138,39 @@ deordinalize, demodulize, foreign key, and pluralize/singularize are supported as both traits and pure functions acting on String types.") (license license:bsd-2))) +(define-public rust-inotify-0.8 + (package + (name "rust-inotify") + (version "0.8.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "inotify" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1m74znskinrvfcp0hczwwdxvc7kvnrrailngkivk1iwknfa0mpa6")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-inotify-sys" ,rust-inotify-sys-0.1) + ("rust-libc" ,rust-libc-0.2) + ("rust-mio" ,rust-mio-0.6) + ("rust-tokio" ,rust-tokio-0.2)) + #:cargo-development-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-tempdir" ,rust-tempdir-0.3) + ("rust-tokio" ,rust-tokio-0.2)))) + (home-page "https://github.com/inotify-rs/inotify") + (synopsis "Idiomatic wrapper for inotify") + (description "This package provides an idiomatic wrapper for inotify +written in Rust.") + (license license:isc))) + (define-public rust-inotify-0.7 (package + (inherit rust-inotify-0.8) (name "rust-inotify") (version "0.7.1") (source @@ -14151,7 +14182,6 @@ as both traits and pure functions acting on String types.") (sha256 (base32 "0byhq4x4b2rlbkmfrab5dni39wiq2ls1hv1nhggp7rla5inwc5j8")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-bitflags" ,rust-bitflags-1) @@ -14163,12 +14193,7 @@ as both traits and pure functions acting on String types.") ("rust-tokio-io" ,rust-tokio-io-0.1) ("rust-tokio-reactor" ,rust-tokio-reactor-0.1)) #:cargo-development-inputs - (("rust-tempdir" ,rust-tempdir-0.3)))) - (home-page "https://github.com/inotify-rs/inotify") - (synopsis "Idiomatic wrapper for inotify") - (description "This package provides an idiomatic wrapper for inotify written -in Rust.") - (license license:isc))) + (("rust-tempdir" ,rust-tempdir-0.3)))))) (define-public rust-inotify-0.6 (package -- cgit v1.2.3 From 3a720e6e9866c29c482f2ff7b0e71f03570ade73 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:11:58 +0100 Subject: gnu: Add rust-timerfd-1. * gnu/packages/crates-io.scm (rust-timerfd-1): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 00eebfccf4..44b4e32716 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33307,6 +33307,27 @@ crate.") closures after a delay or at a given timestamp.") (license license:mpl2.0))) +(define-public rust-timerfd-1 + (package + (name "rust-timerfd") + (version "1.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "timerfd" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "14gwkm2c38bm76ccpp4g20qqs77h86d1l81594i76pb751k3xd8b")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs (("rust-libc" ,rust-libc-0.2)))) + (home-page "https://github.com/main--/rust-timerfd") + (synopsis "Rust interface to the Linux kernel's @code{timerfd} API") + (description + "This package provides a Rust interface to the Linux kernel's +@code{timerfd} API.") + (license license:expat))) + (define-public rust-tinytemplate-1 (package (name "rust-tinytemplate") -- cgit v1.2.3 From 6024b046b4e29e7d2aa820a8e5c513aa632d3ab3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:26:20 +0100 Subject: gnu: Add rust-uds-windows-0.1. * gnu/packages/crates-io.scm (rust-uds-windows-0.1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 44b4e32716..d42fa1ef4a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -35990,6 +35990,29 @@ with the Unicode character database.") (license (list license:asl2.0 license:expat)))) +(define-public rust-uds-windows-0.1 + (package + (name "rust-uds-windows") + (version "0.1.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "uds-windows" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0mdv9xyrf8z8zr2py5drbilkncgrkg61axq6h7hcvgggklv9f14z")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-kernel32-sys" ,rust-kernel32-sys-0.2) + ("rust-tempdir" ,rust-tempdir-0.3) + ("rust-winapi" ,rust-winapi-0.2) + ("rust-ws2-32-sys" ,rust-ws2-32-sys-0.2)))) + (home-page "https://github.com/haraldh/rust_uds_windows") + (synopsis "Unix Domain Sockets for Windows") + (description "This library integrates Unix Domain Sockets on Windows.") + (license license:expat))) + (define-public rust-ufmt-0.1 (package (name "rust-ufmt") -- cgit v1.2.3 From ab71cd32f8e0720c6a43d917b756876383e85099 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:33:56 +0100 Subject: gnu: Add rust-flume-0.10. * gnu/packages/crates-io.scm (rust-flume-0.10): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d42fa1ef4a..efe03c9432 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10244,6 +10244,39 @@ streams.") crate.") (license license:asl2.0))) +(define-public rust-flume-0.10 + (package + (name "rust-flume") + (version "0.10.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "flume" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "14dvj6d2r6vgsy3adv4lncbddjwc59rgl0rcwc1kdnsmqkh7lwhy")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: remove when rust-async-std-1 is packaged + #:cargo-inputs + (("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-nanorand" ,rust-nanorand-0.5) + ("rust-spinning-top" ,rust-spinning-top-0.2)) + #:cargo-development-inputs + (;("rust-async-std" ,rust-async-std-1) + ("rust-criterion" ,rust-criterion-0.3) + ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.4) + ("rust-crossbeam-utils" ,rust-crossbeam-utils-0.7) + ("rust-futures" ,rust-futures-0.3) + ("rust-rand" ,rust-rand-0.7) + ("rust-waker-fn" ,rust-waker-fn-1)))) + (home-page "https://github.com/zesterer/flume") + (synopsis "Fast multi-producer channel") + (description + "This package provides a fast multi-producer channel.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-fnv-1 (package (name "rust-fnv") -- cgit v1.2.3 From b5b369011d93860fa0373b148085b076598f358c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:34:32 +0100 Subject: gnu: Add rust-async-task-4. * gnu/packages/crates-io.scm (rust-async-task-4): New variable. (rust-async-task-1): Inherit from above. --- gnu/packages/crates-io.scm | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index efe03c9432..33d0b83360 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1495,8 +1495,32 @@ notation.") crate.") (license license:expat))) +(define-public rust-async-task-4 + (package + (name "rust-async-task") + (version "4.0.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-task" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1w0a1c8jim6s5bvcyiiwg9m4bdv3xnd4hbjm97ndgmphmgg32679")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-development-inputs + (("rust-atomic-waker" ,rust-atomic-waker-1) + ("rust-easy-parallel" ,rust-easy-parallel-3) + ("rust-flume" ,rust-flume-0.10)))) + (home-page "https://github.com/stjepang/async-task") + (synopsis "Task abstraction for building executors") + (description + "This package provides a task abstraction for building executors.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-task-1 (package + (inherit rust-async-task-4) (name "rust-async-task") (version "1.3.1") (source @@ -1506,19 +1530,13 @@ crate.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "0p88087z43zvv924my16a17qd65kdlv1r59h80h73rvrn0bc1hha")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-libc" ,rust-libc-0.2) ("rust-winapi" ,rust-winapi-0.3)) #:cargo-development-inputs (("rust-crossbeam" ,rust-crossbeam-0.7) - ("rust-futures" ,rust-futures-0.3)))) - (home-page "https://github.com/stjepang/async-task") - (synopsis "Task abstraction for building executors") - (description - "This package provides a task abstraction for building executors.") - (license (list license:asl2.0 license:expat)))) + ("rust-futures" ,rust-futures-0.3)))))) (define-public rust-async-trait-0.1 (package -- cgit v1.2.3 From 7b9967176cb3a78e0192f0d6b08950ed19cf5cf9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:35:10 +0100 Subject: gnu: Add rust-blocking-1. * gnu/packages/crates-io.scm (rust-blocking-1): New variable. (rust-blocking-0.6): Inherit from above. --- gnu/packages/crates-io.scm | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 33d0b83360..f3f039605d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3086,26 +3086,26 @@ algorithms. This package is deprecated. Please use block-cipher instead") `(#:cargo-inputs (("rust-byte-tools" ,rust-byte-tools-0.3)))))) -(define-public rust-blocking-0.6 +(define-public rust-blocking-1 (package (name "rust-blocking") - (version "0.6.1") + (version "1.0.2") (source (origin (method url-fetch) (uri (crate-uri "blocking" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "13g1xlsd1ardf9wxkj1d03baxfy8f8kvgjz55l6zi1q4jn5f0c1z")))) + (base32 "1s9myg9gqmwzrbc38p23bh4vkc8w4pbpddqrcrrl1xz1xpdp1qf5")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-async-channel" ,rust-async-channel-1) + ("rust-async-task" ,rust-async-task-4) ("rust-atomic-waker" ,rust-atomic-waker-1) ("rust-fastrand" ,rust-fastrand-1) ("rust-futures-lite" ,rust-futures-lite-1) - ("rust-once-cell" ,rust-once-cell-1) - ("rust-waker-fn" ,rust-waker-fn-1)))) + ("rust-once-cell" ,rust-once-cell-1)))) (home-page "https://github.com/stjepang/blocking") (synopsis "Thread pool for isolating blocking I/O in async programs") (description @@ -3113,6 +3113,27 @@ algorithms. This package is deprecated. Please use block-cipher instead") programs.") (license (list license:asl2.0 license:expat)))) +(define-public rust-blocking-0.6 + (package + (inherit rust-blocking-1) + (name "rust-blocking") + (version "0.6.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "blocking" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13g1xlsd1ardf9wxkj1d03baxfy8f8kvgjz55l6zi1q4jn5f0c1z")))) + (arguments + `(#:cargo-inputs + (("rust-async-channel" ,rust-async-channel-1) + ("rust-atomic-waker" ,rust-atomic-waker-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-waker-fn" ,rust-waker-fn-1)))))) + (define-public rust-bresenham-0.1 (package (name "rust-bresenham") -- cgit v1.2.3 From 5b15b42e3f90aea14bbbba38d2bb26574059daa8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:36:03 +0100 Subject: gnu: Add rust-async-io-1 and rust-async-net-1. * gnu/packages/crates-io.scm (rust-async-io-1): (rust-async-net-1): New variables. --- gnu/packages/crates-io.scm | 67 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f3f039605d..71f8eeb7e9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1315,6 +1315,49 @@ Rust.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-io-1 + (package + (name "rust-async-io") + (version "1.3.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-io" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1zg0bvb58615qar6ih3ddr1cyjh0fsrfdhpy90z1qxjnfpqgh5ck")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-concurrent-queue" ,rust-concurrent-queue-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-nb-connect" ,rust-nb-connect-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-parking" ,rust-parking-2) + ("rust-polling" ,rust-polling-2) + ("rust-vec-arena" ,rust-vec-arena-1) + ("rust-waker-fn" ,rust-waker-fn-1) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-async-channel" ,rust-async-channel-1) + ("rust-async-net" ,rust-async-net-1) + ("rust-inotify" ,rust-inotify-0.8) + ("rust-nix" ,rust-nix-0.18) + ("rust-signal-hook" ,rust-signal-hook-0.1) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-timerfd" ,rust-timerfd-1) + ("rust-uds-windows" ,rust-uds-windows-0.1)))) + (home-page "https://github.com/stjepang/async-io") + (synopsis "Async I/O and timers") + (description + "This crate provides two tools: Async, an adapter for standard networking +types (and many other types) to use in async programs, and Timer, a future +that expires at a point in time.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-log-1 (package (name "rust-async-log") @@ -1388,6 +1431,30 @@ crate.") (description "Macros for async-std.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-net-1 + (package + (name "rust-async-net") + (version "1.5.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-net" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1rgvvqb1l86hawl1j0jfyzq35yracbbh29109131izmghmf4gph6")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-io" ,rust-async-io-1) + ("rust-blocking" ,rust-blocking-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-lite" ,rust-futures-lite-1)))) + (home-page "https://github.com/stjepang/async-net") + (synopsis "Async networking primitives for TCP/UDP/Unix communication") + (description + "Async networking primitives for TCP/UDP/Unix communication") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-std-0.99 (package (name "rust-async-std") -- cgit v1.2.3 From 3bfb1b568d7a81b5bceb50bf083f30088db78285 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:42:45 +0100 Subject: gnu: Add rust-async-executor-1. * gnu/packages/crates-io.scm (rust-async-executor-1): New variable. --- gnu/packages/crates-io.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 71f8eeb7e9..26ccfbdef6 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1315,6 +1315,35 @@ Rust.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-executor-1 + (package + (name "rust-async-executor") + (version "1.4.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-executor" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0ilivvzc082ynr096xxghc8hdmlmacxilcpn738ylh5lqxq7k1zb")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-task" ,rust-async-task-4) + ("rust-concurrent-queue" ,rust-concurrent-queue-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-vec-arena" ,rust-vec-arena-1)) + #:cargo-development-inputs + (("rust-async-channel" ,rust-async-channel-1) + ("rust-async-io" ,rust-async-io-1) + ("rust-easy-parallel" ,rust-easy-parallel-3)))) + (home-page "https://github.com/stjepang/async-executor") + (synopsis "Async executor") + (description "This library provides async executors.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-io-1 (package (name "rust-async-io") -- cgit v1.2.3 From 9ebf57948220861f7fd2a28acf6268a6d817f419 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 00:47:39 +0100 Subject: gnu: Add rust-async-global-executor-1. * gnu/packages/crates-io.scm (rust-async-global-executor-1): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 26ccfbdef6..cdfa8aa473 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1344,6 +1344,37 @@ and Rust's modern asynchronous IO types.") (description "This library provides async executors.") (license (list license:asl2.0 license:expat)))) +(define-public rust-async-global-executor-1 + (package + (name "rust-async-global-executor") + (version "1.4.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-global-executor" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "017s1lik153s587l6q9x5bf9i1n7gxqcg3zn2mdgvf16rm4rn1vk")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-async-executor" ,rust-async-executor-1) + ("rust-async-io" ,rust-async-io-1) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio" ,rust-tokio-0.3)) + #:cargo-development-inputs + (("rust-doc-comment" ,rust-doc-comment-0.3)))) + (home-page "https://github.com/async-rs/async-global-executor") + (synopsis "Global executor built on top of @code{async-executor} and +@code{async-io}") + (description + "This package provides a global executor built on top of +@code{async-executor} and @code{async-io}.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-io-1 (package (name "rust-async-io") -- cgit v1.2.3 From e619b4bec0d702293085ba671bc39ca425b475c9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:04:45 +0100 Subject: gnu: Add rust-wepoll-sys-stjepang-1. * gnu/packages/crates-io.scm (rust-wepoll-sys-stjepang-1): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index cdfa8aa473..74ff0f7f9a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -38152,6 +38152,30 @@ with webpki.") "This crate provides unsafe Rust bindings to the @code{wepoll} library.") (license license:mpl2.0))) +(define-public rust-wepoll-sys-stjepang-1 + (package + (name "rust-wepoll-sys-stjepang") + (version "1.0.8") + (source + (origin + (method url-fetch) + (uri (crate-uri "wepoll-sys-stjepang" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "138pxc8k6wayyywnjcpk5nhywk3vk6h4i39fj8khpjlhy81vppqz")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;missing "winsock.h" + #:cargo-inputs + (("rust-bindgen" ,rust-bindgen-0.53) + ("rust-cc" ,rust-cc-1)))) + (home-page "https://github.com/stjepang/wepoll-sys-stjepang") + (synopsis "Fork of @code{wepoll-sys} with stjepang's patches") + (description + "This crate provides Rust bindings to @code{wepoll}, generated +using @code{bindgen}.") + (license license:mpl2.0))) + (define-public rust-which-3 (package (name "rust-which") -- cgit v1.2.3 From 3047a8b5b692aa07de38ec07d43e1ee0b7fb1887 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:16:36 +0100 Subject: gnu: Add rust-parking-1. * gnu/packages/crates-io.scm (rust-parking-1): New variable. --- gnu/packages/crates-io.scm | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 74ff0f7f9a..01bbfc15a4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -21167,6 +21167,19 @@ deserialization, and interpreter in Rust.") unparking.") (license (list license:asl2.0 license:expat)))) +(define-public rust-parking-1 + (package + (inherit rust-parking-2) + (name "rust-parking") + (version "1.0.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "parking" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0z6q9rxm98vrp3fimw8b5syzwgf8l0pnn6y0cqm4lbblf7r01cvc")))))) + (define-public rust-parking-lot-0.11 (package (name "rust-parking-lot") -- cgit v1.2.3 From 720bb2b03fcf20e0e1465ca89bda90f2e5af2238 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:18:22 +0100 Subject: gnu: Add rust-futures-lite-0.1. * gnu/packages/crates-io.scm (rust-futures-lite-0.1): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 01bbfc15a4..d6e5dcb687 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11354,6 +11354,28 @@ magnitude faster, fixes minor warts in its API, fills in some obvious gaps, and removes almost all unsafe code from it.") (license (list license:asl2.0 license:expat)))) +(define-public rust-futures-lite-0.1 + (package + (inherit rust-futures-lite-1) + (name "rust-futures-lite") + (version "0.1.11") + (source + (origin + (method url-fetch) + (uri (crate-uri "futures-lite" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1lnflz8ysp0vlq1sxzz1sw9cq7s33lh12cm9rc68z04v29q9k6cp")))) + (arguments + `(#:cargo-inputs + (("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-io" ,rust-futures-io-0.3) + ("rust-memchr" ,rust-memchr-2) + ("rust-parking" ,rust-parking-2) + ("rust-pin-project-lite" ,rust-pin-project-lite-0.1) + ("rust-waker-fn" ,rust-waker-fn-1)))))) + (define-public rust-futures-macro-0.3 (package (name "rust-futures-macro") -- cgit v1.2.3 From 9e17c5aed8b02c7709180d7ecac985a13be50b88 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:20:24 +0100 Subject: gnu: Add rust-blocking-0.4. * gnu/packages/crates-io.scm (rust-blocking-0.4): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d6e5dcb687..0986fd19bb 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3261,6 +3261,27 @@ programs.") ("rust-once-cell" ,rust-once-cell-1) ("rust-waker-fn" ,rust-waker-fn-1)))))) +(define-public rust-blocking-0.4 + (package + (inherit rust-blocking-0.6) + (name "rust-blocking") + (version "0.4.7") + (source + (origin + (method url-fetch) + (uri (crate-uri "blocking" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0av1h5p6lb5bpzghmzsksx31icvdwrpxxzkq6r56n1l5pzvqyinj")))) + (arguments + `(#:cargo-inputs + (("rust-async-channel" ,rust-async-channel-1) + ("rust-atomic-waker" ,rust-atomic-waker-1) + ("rust-futures-lite" ,rust-futures-lite-0.1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-parking" ,rust-parking-1) + ("rust-waker-fn" ,rust-waker-fn-1)))))) + (define-public rust-bresenham-0.1 (package (name "rust-bresenham") -- cgit v1.2.3 From 6cb091d9aeb30cfede29f698452f98f01107f1d3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:26:11 +0100 Subject: gnu: Add rust-async-task-3. * gnu/packages/crates-io.scm (rust-async-task-3): New variable. --- gnu/packages/crates-io.scm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0986fd19bb..d35b5edffe 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1645,6 +1645,23 @@ crate.") "This package provides a task abstraction for building executors.") (license (list license:asl2.0 license:expat)))) +(define-public rust-async-task-3 + (package + (inherit rust-async-task-4) + (name "rust-async-task") + (version "3.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-task" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1lrm7cm9dpashmkbqa8mvglbf85gadviqil7qnnrm0pjdqap4xy1")))) + (arguments + `(#:cargo-development-inputs + (("rust-crossbeam" ,rust-crossbeam-0.7) + ("rust-futures" ,rust-futures-0.3)))))) + (define-public rust-async-task-1 (package (inherit rust-async-task-4) -- cgit v1.2.3 From c6e8a56c28212f7440104e6bcc9d9f31f031e4ab Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:40:17 +0100 Subject: gnu: Add rust-piper-0.1. * gnu/packages/crates-io.scm (rust-piper-0.1): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d35b5edffe..fb8596862b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -39250,6 +39250,33 @@ formatters with per-field documentation generated for each structure. ;; User can choose either license. (license (list license:expat license:asl2.0)))) +(define-public rust-piper-0.1 + (package + (name "rust-piper") + (version "0.1.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "piper" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "062zdv9w7l5037g113bh7r72wmygz92ajzr0z41v3bqdd3x8nq01")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false + #:cargo-inputs + (("rust-crossbeam-utils" ,rust-crossbeam-utils-0.7) + ("rust-futures-io" ,rust-futures-io-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-futures-util" ,rust-futures-util-0.3)) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3)))) + (home-page "https://crates.io/crates/piper") + (synopsis "Async pipes, channels, mutexes, and more") + (description + "This crate provides async pipes, channels, mutexes, and more.") + (license (list license:expat license:asl2.0)))) + (define-public rust-xmltree-0.8 (package (name "rust-xmltree") -- cgit v1.2.3 From e6b2be5ed7b862fd7890426830c6db42f8d6f9e9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 01:44:53 +0100 Subject: gnu: Add rust-smol-0.1. * gnu/packages/crates-io.scm (rust-smol-0.1): New variable. --- gnu/packages/crates-io.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index fb8596862b..7a3df64a0a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30604,6 +30604,46 @@ stack.") #:cargo-development-inputs (("rust-bincode" ,rust-bincode-1)))))) +(define-public rust-smol-0.1 + (package + (name "rust-smol") + (version "0.1.18") + (source + (origin + (method url-fetch) + (uri (crate-uri "smol" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1mdflwzgw1jxwrjffqn09lb4hn6d076s1ka8lb9mgnildqybn332")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags + '("--release" "--" "--skip=task::Task>") + #:cargo-inputs + (("rust-async-task" ,rust-async-task-3) + ("rust-blocking" ,rust-blocking-0.4) + ("rust-concurrent-queue" ,rust-concurrent-queue-1) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-futures-io" ,rust-futures-io-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-libc" ,rust-libc-0.2) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-scoped-tls" ,rust-scoped-tls-1) + ("rust-slab" ,rust-slab-0.4) + ("rust-socket2" ,rust-socket2-0.3) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-wepoll-sys-stjepang" ,rust-wepoll-sys-stjepang-1) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.3) + ("rust-futures" ,rust-futures-0.3) + ("rust-piper" ,rust-piper-0.1) + ("rust-tempfile" ,rust-tempfile-3)))) + (home-page "https://github.com/stjepang/smol") + (synopsis "Small and fast async runtime") + (description "This package provides a small and fast async runtime.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-socket2-0.3 (package (name "rust-socket2") -- cgit v1.2.3 From 56e70c04d4be7a0051e865681f965ce40b5f2f27 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 09:41:59 +0100 Subject: gnu: Add rust-futures-intrusive-0.3. * gnu/packages/crates-io.scm (rust-futures-intrusive-0.3): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7a3df64a0a..2b25b8a0e8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -11294,6 +11294,32 @@ the computation on the threads themselves.") library.") (license (list license:expat license:asl2.0)))) +(define-public rust-futures-intrusive-0.3 + (package + (name "rust-futures-intrusive") + (version "0.3.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "futures-intrusive" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "00qpir3q6j7blwpnpffj7ypf1z8wc87ldn62qr7sapymgg82j5dw")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: need rust-async-std-1 + #:cargo-inputs + (("rust-futures-core" ,rust-futures-core-0.3) + ("rust-lock-api" ,rust-lock-api-0.3) + ("rust-parking-lot" ,rust-parking-lot-0.10)))) + (home-page "https://github.com/Matthias247/futures-intrusive") + (synopsis "Futures based on intrusive data structures") + (description + "This crate provides a variety of Futures-based and +@code{async/await} compatible types that are based on the idea of +intrusive collections.") + (license (list license:expat license:asl2.0)))) + (define-public rust-futures-io-0.3 (package (name "rust-futures-io") -- cgit v1.2.3 From 6ede8a178d02284e279aaae257a93ab3b245138f Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 09:48:03 +0100 Subject: gnu: Add rust-async-mutex-1. * gnu/packages/crates-io.scm (rust-async-mutex-1): New variable. --- gnu/packages/crates-io.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2b25b8a0e8..09590ad044 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1491,6 +1491,43 @@ crate.") (description "Macros for async-std.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-mutex-1 + (package + (name "rust-async-mutex") + (version "1.4.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-mutex" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0vhmsscqx48dmxw0yir6az0pbwcq6qjvcv2f43vdpn95vd9bi7a7")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: enable when rust-async-std-1 is packaged + #:cargo-inputs + (("rust-event-listener" ,rust-event-listener-2)) + #:cargo-development-inputs + (;("rust-async-std" ,rust-async-std-1) + ("rust-futures" ,rust-futures-0.3) + ("rust-futures-intrusive" ,rust-futures-intrusive-0.3) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-smol" ,rust-smol-0.1) + ("rust-tokio" ,rust-tokio-0.2)))) + (home-page "https://github.com/stjepang/async-lock") + (synopsis "Async synchronisation primitives") + (description "This crate provides the following async synchronisation +primitives: + +@itemize +@item Barrier: enables tasks to synchronize all together at the same time. +@item Mutex: a mutual exclusion lock. +@item RwLock: a reader-writer lock, allowing any number of readers or a single writer. +@item Semaphore: limits the number of concurrent operations. +@end itemize") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-net-1 (package (name "rust-async-net") -- cgit v1.2.3 From 20e1e22dbe1cad0a7d1810d9923ee69270b22cf4 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 09:57:34 +0100 Subject: gnu: Add rust-async-process-1. * gnu/packages/crates-io.scm (rust-async-process-1): New variable. --- gnu/packages/crates-io.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 09590ad044..f84d8f5054 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1552,6 +1552,44 @@ primitives: "Async networking primitives for TCP/UDP/Unix communication") (license (list license:asl2.0 license:expat)))) +(define-public rust-async-process-1 + (package + (name "rust-async-process") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-process" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1nmvqwqxzy0gv7n8agknaijns9dsxqj81bxms4bs647vq44ym32c")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags '("--release" "--" + "--skip=set_current_dir_works" + "--skip=signal_reported_right" + "--skip=stdin_works") + #:cargo-inputs + (("rust-async-io" ,rust-async-io-1) + ("rust-blocking" ,rust-blocking-1) + ("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-event-listener" ,rust-event-listener-2) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-signal-hook" ,rust-signal-hook-0.1) + ("rust-winapi" ,rust-winapi-0.3)))) + (home-page "https://github.com/stjepang/async-process") + (synopsis "Async interface for working with processes") + (description + "This crate is an async version of @code{std::process}. A background +thread named @code{async-process} is lazily created on first use, which waits +for spawned child processes to exit and then calls the @code{wait()} syscall +to clean up the ``zombie'' processes. + +This is unlike the process API in the standard library, where dropping +a running Child leaks its resources.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-std-0.99 (package (name "rust-async-std") -- cgit v1.2.3 From 6bb934340e6ce1eaf884a41a6432be56b8b41526 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 10:07:47 +0100 Subject: gnu: Add rust-crossbeam-utils-0.8. * gnu/packages/crates-io.scm (rust-crossbeam-utils-0.8): New variable. (rust-crossbeam-utils-0.7): Inherit from above. --- gnu/packages/crates-io.scm | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f84d8f5054..367270bc65 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -6534,8 +6534,35 @@ criterion.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.6)))))) +(define-public rust-crossbeam-utils-0.8 + (package + (name "rust-crossbeam-utils") + (version "0.8.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "crossbeam-utils" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13fvrqlap7bgvlnpqr5gjcxdhx1jv99pkfg5xdlq5xcy30g6vn82")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-autocfg" ,rust-autocfg-1) + ("rust-cfg-if" ,rust-cfg-if-1) + ("rust-lazy-static" ,rust-lazy-static-1)) + #:cargo-development-inputs + (("rust-rand" ,rust-rand-0.7)))) + (home-page + "https://github.com/crossbeam-rs/crossbeam/tree/master/crossbeam-utils") + (synopsis "Utilities for concurrent programming") + (description + "This crate provides miscellaneous tools for concurrent programming.") + (license (list license:expat license:asl2.0)))) + (define-public rust-crossbeam-utils-0.7 (package + (inherit rust-crossbeam-utils-0.8) (name "rust-crossbeam-utils") (version "0.7.2") (source @@ -6547,20 +6574,13 @@ criterion.") (sha256 (base32 "1a31wbrda1320gj2a6az1lin2d34xfc3xf88da4c17qy5lxcgiy3")))) - (build-system cargo-build-system) (arguments `(#:cargo-inputs (("rust-autocfg" ,rust-autocfg-1) ("rust-cfg-if" ,rust-cfg-if-0.1) ("rust-lazy-static" ,rust-lazy-static-1)) #:cargo-development-inputs - (("rust-rand" ,rust-rand-0.6)))) - (home-page - "https://github.com/crossbeam-rs/crossbeam/tree/master/crossbeam-utils") - (synopsis "Utilities for concurrent programming") - (description - "Utilities for concurrent programming.") - (license (list license:expat license:asl2.0)))) + (("rust-rand" ,rust-rand-0.6)))))) (define-public rust-crossbeam-utils-0.6 (package -- cgit v1.2.3 From 7144a2614c785c3aa0ec15d40c17cd3ea3f06169 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 10:39:57 +0100 Subject: gnu: Add rust-gloo-timers-0.2. * gnu/packages/crates-io.scm (rust-gloo-timers-0.2): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 367270bc65..5b19476e42 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -12642,6 +12642,36 @@ open file descriptors.") (("rust-docmatic" ,rust-docmatic-0.1) ("rust-tempdir" ,rust-tempdir-0.3)))))) +(define-public rust-gloo-timers-0.2 + (package + (name "rust-gloo-timers") + (version "0.2.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "gloo-timers" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "07w999jm1r1i8r574qbmsa3l4w3gxhyx04cbllg0m4pzm934l827")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-js-sys" ,rust-js-sys-0.3) + ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2) + ("rust-web-sys" ,rust-web-sys-0.3)) + #:cargo-development-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-wasm-bindgen-futures" ,rust-wasm-bindgen-futures-0.4) + ("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)))) + (home-page "https://github.com/rustwasm/gloo") + (synopsis "Convenience crate for working with JavaScript timers") + (description + "This package is a convenience crate for working with JavaScript +timers.") + (license (list license:expat license:asl2.0)))) + (define-public rust-goblin-0.2 (package (name "rust-goblin") -- cgit v1.2.3 From 6054b7d89dbbed5450f275d8559d1779d6e9db1f Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Mon, 4 Jan 2021 20:24:53 +0100 Subject: gnu: boxes: Properly wrap hash. * gnu/packages/shellutils.scm (boxes)[sha256]: Use (base32 hash). --- gnu/packages/shellutils.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/shellutils.scm b/gnu/packages/shellutils.scm index 44a1934610..c7a941dfa6 100644 --- a/gnu/packages/shellutils.scm +++ b/gnu/packages/shellutils.scm @@ -57,7 +57,8 @@ (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - "0b12rsynrmkldlwcb62drk33kk0aqwbj10mq5y5x3hjf626gjwsi"))) + (base32 + "0b12rsynrmkldlwcb62drk33kk0aqwbj10mq5y5x3hjf626gjwsi")))) (build-system gnu-build-system) (arguments `(#:test-target "test" -- cgit v1.2.3 From bab4e482be563521f9eca9b68bcfcb1cf12e05e6 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Sun, 3 Jan 2021 18:38:40 -0500 Subject: gnu: Add python-pivy. * gnu/packages/python-xyz.scm (python-pivy): New variable. Signed-off-by: Leo Famulari --- gnu/packages/python-xyz.scm | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 0ac95deb1d..c4fbadb42b 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -177,6 +177,7 @@ #:use-module (gnu packages shells) #:use-module (gnu packages sphinx) #:use-module (gnu packages ssh) + #:use-module (gnu packages swig) #:use-module (gnu packages terminals) #:use-module (gnu packages tex) #:use-module (gnu packages texinfo) @@ -23404,3 +23405,47 @@ Qt applications.") "Bitstring is a library for simple construction, analysis and modification of binary data.") (license license:expat))) + +(define-public python-pivy + (package + (name "python-pivy") + (version "0.6.5") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/coin3d/pivy") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0vids7sxk8w5vr73xdnf8xdci71a7syl6cd35aiisppbqyyfmykx")))) + (build-system python-build-system) + (arguments + `(;; The test suite fails due to an import cycle between 'pivy' and '_coin' + #:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-cmake-include-dirs + (lambda _ + ;; Patch buildsystem to respect Coin3D include directory + (substitute* "CMakeLists.txt" + (("\\$\\{SoQt_INCLUDE_DIRS}") + "${Coin_INCLUDE_DIR};${SoQt_INCLUDE_DIRS}")) + #t))))) + (native-inputs + `(("cmake" ,cmake) + ("swig" ,swig))) + (inputs + `(("python-wrapper" ,python-wrapper) + ("qtbase" ,qtbase) + ("libxi" ,libxi) + ("libice" ,libice) + ("soqt" ,soqt) + ("glew" ,glew) + ("coin3D" ,coin3D-4))) + (home-page "https://github.com/coin3d/pivy") + (synopsis "Python bindings to Coin3D") + (description + "Pivy provides python bindings for Coin, a 3D graphics library with an +Application Programming Interface based on the Open Inventor 2.1 API.") + (license license:isc))) -- cgit v1.2.3 From ed2e0b1b50587a38ad26574585f73979874e56f0 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Fri, 1 Jan 2021 15:22:02 +0100 Subject: gnu: FreeCad: Update to 0.18.5-1.7616153. Fixes "Draft module import errors" and other runtime errors. * gnu/packages/engineering.scm (freecad): Update to 0.18.5-1.7616153. [inputs]: Add python-pivy and qtwebkit. Move python-pyside-2-tools... [native-inputs]: ... to here. Signed-off-by: Leo Famulari --- gnu/packages/engineering.scm | 209 ++++++++++++++++++++----------------------- 1 file changed, 99 insertions(+), 110 deletions(-) diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm index fbec628c0e..5166a4635c 100644 --- a/gnu/packages/engineering.scm +++ b/gnu/packages/engineering.scm @@ -2514,121 +2514,110 @@ full programmatic control over your models.") (license license:gpl2+))) (define-public freecad - (package - (name "freecad") - (version "0.18.5") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/FreeCAD/FreeCAD") - (commit version))) - (modules '((guix build utils))) - (snippet - '(begin - ;; Fix build with Python 3.8, see - ;; . - (substitute* "src/Base/swigpyrun.inl" - (("PyObject \\*modules = interp->modules;") - "PyObject *modules = PyEval_GetBuiltins();")) - #t)) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0r31jzzkamf76l19fb175hhv48irk06fpi8ldxdlr31w8c1ix4aa")))) - (build-system qt-build-system) - (native-inputs - `(("doxygen" ,doxygen) - ("graphviz" ,graphviz) - ("qttools" ,qttools) - ("pkg-config" ,pkg-config) - ("swig" ,swig))) - (inputs - `(("boost" ,boost) - ("coin3D" ,coin3D) - ("eigen" ,eigen) - ("freetype" ,freetype) - ("glew" ,glew) - ("hdf5" ,hdf5-1.10) - ("libarea" ,libarea) - ("libmedfile" ,libmedfile) - ("libspnav" ,libspnav) - ("libxi" ,libxi) - ("libxmu" ,libxmu) - ("openmpi" ,openmpi) - ("opencascade-occt" ,opencascade-occt) - ("python-matplotlib" ,python-matplotlib) - ("python-pyside-2" ,python-pyside-2) - ("python-pyside-2-tools" ,python-pyside-2-tools) - ("python-shiboken-2" ,python-shiboken-2) - ("python-wrapper" ,python-wrapper) - ("qtbase" ,qtbase) - ("qtsvg" ,qtsvg) - ("qtx11extras" ,qtx11extras) - ("qtxmlpatterns" ,qtxmlpatterns) - ;; qtwebkit is optional. We remove it currently, because it takes - ;; much time to compile and substitutes are often unavailable - ;;("qtwebkit" ,qtwebkit) - ("tbb" ,tbb) - ("vtk" ,vtk) - ("xerces-c" ,xerces-c) - ("zlib" ,zlib))) - (arguments - `(#:tests? #f - #:configure-flags - (list - "-DBUILD_QT5=ON" - (string-append "-DCMAKE_INSTALL_LIBDIR=" (assoc-ref %outputs "out") "/lib") - - (string-append "-DPYSIDE2UICBINARY=" - (assoc-ref %build-inputs "python-pyside-2-tools") - "/bin/uic") - (string-append "-DPYSIDE2RCCBINARY=" - (assoc-ref %build-inputs "python-pyside-2-tools") - "/bin/rcc") - - "-DPYSIDE_LIBRARY=PySide2::pyside2" - (string-append - "-DPYSIDE_INCLUDE_DIR=" - (assoc-ref %build-inputs "python-pyside-2") "/include;" - (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2;" - (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtCore;" - (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtWidgets;" - (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtGui;") - - "-DSHIBOKEN_LIBRARY=Shiboken2::libshiboken" - (string-append "-DSHIBOKEN_INCLUDE_DIR=" - (assoc-ref %build-inputs "python-shiboken-2") - "/include/shiboken2")) - #:phases - (modify-phases %standard-phases - (add-before 'configure 'restore-pythonpath - (lambda _ - (substitute* "src/Main/MainGui.cpp" - (("_?putenv\\(\"PYTHONPATH=\"\\);") "")) - #t)) - (add-after 'install 'wrap-pythonpath - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (wrap-program (string-append out "/bin/FreeCAD") - (list "PYTHONPATH" - 'prefix (list (getenv "PYTHONPATH"))))) - #t))))) - (home-page "https://www.freecadweb.org/") - (synopsis "Your Own 3D Parametric Modeler") - (description - "FreeCAD is a general purpose feature-based, parametric 3D modeler for + (let ((commit-ref "7616153b3c31ace006169cdc2fdafab484498858") + (revision "1")) + (package + (name "freecad") + (version (git-version "0.18.5" revision commit-ref)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/FreeCAD/FreeCAD") + (commit commit-ref))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "16965yxnp2pq7nm8z3p0pjkzjdyq62vfrj8j3nk26bwc898czyn2")))) + (build-system qt-build-system) + (native-inputs + `(("doxygen" ,doxygen) + ("graphviz" ,graphviz) + ("qttools" ,qttools) + ("pkg-config" ,pkg-config) + ("python-pyside-2-tools" ,python-pyside-2-tools) + ("swig" ,swig))) + (inputs + `(("boost" ,boost) + ("coin3D" ,coin3D) + ("eigen" ,eigen) + ("freetype" ,freetype) + ("glew" ,glew) + ("hdf5" ,hdf5-1.10) + ("libarea" ,libarea) + ("libmedfile" ,libmedfile) + ("libspnav" ,libspnav) + ("libxi" ,libxi) + ("libxmu" ,libxmu) + ("openmpi" ,openmpi) + ("opencascade-occt" ,opencascade-occt) + ("python-matplotlib" ,python-matplotlib) + ("python-pyside-2" ,python-pyside-2) + ("python-shiboken-2" ,python-shiboken-2) + ("python-pivy" ,python-pivy) + ("python-wrapper" ,python-wrapper) + ("qtbase" ,qtbase) + ("qtsvg" ,qtsvg) + ("qtx11extras" ,qtx11extras) + ("qtxmlpatterns" ,qtxmlpatterns) + ("qtwebkit" ,qtwebkit) + ("tbb" ,tbb) + ("vtk" ,vtk) + ("xerces-c" ,xerces-c) + ("zlib" ,zlib))) + (arguments + `(#:tests? #f + #:configure-flags + (list + "-DBUILD_QT5=ON" + (string-append "-DCMAKE_INSTALL_LIBDIR=" (assoc-ref %outputs "out") "/lib") + (string-append "-DPYSIDE2UICBINARY=" + (assoc-ref %build-inputs "python-pyside-2-tools") + "/bin/uic") + (string-append "-DPYSIDE2RCCBINARY=" + (assoc-ref %build-inputs "python-pyside-2-tools") + "/bin/rcc") + "-DPYSIDE_LIBRARY=PySide2::pyside2" + (string-append + "-DPYSIDE_INCLUDE_DIR=" + (assoc-ref %build-inputs "python-pyside-2") "/include;" + (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2;" + (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtCore;" + (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtWidgets;" + (assoc-ref %build-inputs "python-pyside-2") "/include/PySide2/QtGui;") + "-DSHIBOKEN_LIBRARY=Shiboken2::libshiboken" + (string-append "-DSHIBOKEN_INCLUDE_DIR=" + (assoc-ref %build-inputs "python-shiboken-2") + "/include/shiboken2")) + #:phases + (modify-phases %standard-phases + (add-before 'configure 'restore-pythonpath + (lambda _ + (substitute* "src/Main/MainGui.cpp" + (("_?putenv\\(\"PYTHONPATH=\"\\);") "")) + #t)) + (add-after 'install 'wrap-pythonpath + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (wrap-program (string-append out "/bin/FreeCAD") + (list "PYTHONPATH" + 'prefix (list (getenv "PYTHONPATH"))))) + #t))))) + (home-page "https://www.freecadweb.org/") + (synopsis "Your Own 3D Parametric Modeler") + (description + "FreeCAD is a general purpose feature-based, parametric 3D modeler for CAD, MCAD, CAx, CAE and PLM, aimed directly at mechanical engineering and product design but also fits a wider range of uses in engineering, such as architecture or other engineering specialties. It is 100% Open Source (LGPL2+ license) and extremely modular, allowing for very advanced extension and customization.") - (license - (list - license:lgpl2.1+ - license:lgpl2.0+ - license:gpl3+ - license:bsd-3)))) + (license + (list + license:lgpl2.1+ + license:lgpl2.0+ + license:gpl3+ + license:bsd-3))))) (define-public libmedfile (package -- cgit v1.2.3 From 475c3278df4f9dc1bc708e1092e8c93d0618711a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 15:18:11 +0100 Subject: gnu: emacsy: Partially unbreak build and switch to Guile 3.0. Previously it would fail to build. Now it fails tests. * gnu/packages/guile-xyz.scm (emacsy)[source]: Adjust 'uri'. Add 'snippet' and 'modules'. [native-inputs]: Remove AUTOCONF and AUTOMAKE. Replace GUILE-2.2 by GUILE-3.0. [inputs]: Replace GUILE-2.2 by GUILE-3.0. --- gnu/packages/guile-xyz.scm | 37 +++++++++++++++++++++++++++---------- 1 file changed, 27 insertions(+), 10 deletions(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 2e8f6dc066..cfb6397c80 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2014, 2015, 2018 Mark H Weaver ;;; Copyright © 2015, 2017 Christopher Allan Webber ;;; Copyright © 2016 Alex Sassmannshausen @@ -3078,18 +3078,35 @@ API.") (version "0.4.1") (source (origin (method url-fetch) - (uri (string-append - "https://download.savannah.nongnu.org/releases/" - name "/" name "-" version ".tar.gz")) + (uri (string-append "mirror://savannah/emacsy/emacsy-" + version ".tar.gz")) (sha256 (base32 - "1cpb85dl1nibd34c2x2h7vfmjpkgh353p5b1w20v6cs6gmvgg4np")))) + "1cpb85dl1nibd34c2x2h7vfmjpkgh353p5b1w20v6cs6gmvgg4np")) + (modules '((guix build utils))) + (snippet + '(begin + (substitute* "configure" + ;; Allow builds with Guile 3.0. + (("2\\.2 2\\.0") + "3.0 2.2 2.0") + + ;; Freeglut 3.2 provides 'glut.pc', not 'freeglut.pc'. + (("freeglut >= ") + "glut >= ")) + + (substitute* '("emacsy/emacsy.c" + "example/hello-emacsy.c") + (("#include ") + (string-append "#include \n" + "#include \n" + "#include \n" + "#include \n" + "#include \n"))))))) (build-system gnu-build-system) (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("bzip2" ,bzip2) - ("guile" ,guile-2.2) + `(("bzip2" ,bzip2) + ("guile" ,guile-3.0) ("gettext" ,gettext-minimal) ("libtool" ,libtool) ("perl" ,perl) @@ -3098,7 +3115,7 @@ API.") ("texlive" ,(texlive-union (list texlive-generic-epsf))))) (inputs `(("dbus-glib" ,dbus-glib) - ("guile" ,guile-2.2) + ("guile" ,guile-3.0) ("guile-lib" ,guile-lib) ("guile-readline" ,guile-readline) ("freeglut" ,freeglut) -- cgit v1.2.3 From 6c3690fc572bf3231ae60743671b357ffd243017 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 16:43:20 +0100 Subject: guix system: Add '--graph-backend'. * guix/scripts/system.scm (lookup-backend): New procedure. (export-extension-graph, export-shepherd-graph): Add #:backend parameter and honor it. (show-help, %options): Add "--graph-backend". (%default-options): Add 'graph-backend'. (process-action): Pass #:backend to 'export-extension-graph' and 'export-shepherd-graph'. * doc/guix.texi (Invoking guix system): Document '--graph-backend'. --- doc/guix.texi | 13 +++++++++---- guix/scripts/system.scm | 43 ++++++++++++++++++++++++++++++++++--------- 2 files changed, 43 insertions(+), 13 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 1081ed26a3..0f6e95a65a 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -21,7 +21,7 @@ @set SUBSTITUTE-URL https://@value{SUBSTITUTE-SERVER} @copying -Copyright @copyright{} 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès@* +Copyright @copyright{} 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès@* Copyright @copyright{} 2013, 2014, 2016 Andreas Enge@* Copyright @copyright{} 2013 Nikita Karetnikov@* Copyright @copyright{} 2014, 2015, 2016 Alex Kost@* @@ -31548,10 +31548,12 @@ each other: @table @code @item extension-graph -Emit in Dot/Graphviz format to standard output the @dfn{service +Emit to standard output the @dfn{service extension graph} of the operating system defined in @var{file} (@pxref{Service Composition}, for more information on service -extensions). +extensions). By default the output is in Dot/Graphviz format, but you +can choose a different format with @option{--graph-backend}, as with +@command{guix graph} (@pxref{Invoking guix graph, @option{--backend}}): The command: @@ -31563,11 +31565,14 @@ shows the extension relations among services. @anchor{system-shepherd-graph} @item shepherd-graph -Emit in Dot/Graphviz format to standard output the @dfn{dependency +Emit to standard output the @dfn{dependency graph} of shepherd services of the operating system defined in @var{file}. @xref{Shepherd Services}, for more information and for an example graph. +Again, the default output format is Dot/Graphviz, but you can pass +@option{--graph-backend} to select a different one. + @end table @node Invoking guix deploy diff --git a/guix/scripts/system.scm b/guix/scripts/system.scm index 0dcf2b3afe..51c8cf2f76 100644 --- a/guix/scripts/system.scm +++ b/guix/scripts/system.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2016 Alex Kost ;;; Copyright © 2016, 2017, 2018 Chris Marusich ;;; Copyright © 2017, 2019 Mathieu Othacehe @@ -48,7 +48,8 @@ #:autoload (guix scripts package) (delete-generations delete-matching-generations) #:autoload (guix scripts pull) (channel-commit-hyperlink) - #:use-module (guix graph) + #:autoload (guix graph) (export-graph node-type + graph-backend-name %graph-backends) #:use-module (guix scripts graph) #:use-module (guix scripts system reconfigure) #:use-module (guix build utils) @@ -887,18 +888,28 @@ Run 'herd status' to view the list of services on your system.\n")))))) (register-root* (list output) gc-root)) (return output))))))))) -(define (export-extension-graph os port) - "Export the service extension graph of OS to PORT." +(define (lookup-backend name) ;TODO: factorize + "Return the graph backend called NAME. Raise an error if it is not found." + (or (find (lambda (backend) + (string=? (graph-backend-name backend) name)) + %graph-backends) + (leave (G_ "~a: unknown backend~%") name))) + +(define* (export-extension-graph os port + #:key (backend (lookup-backend "graphviz"))) + "Export the service extension graph of OS to PORT using BACKEND." (let* ((services (operating-system-services os)) (system (find (lambda (service) (eq? (service-kind service) system-service-type)) services))) (export-graph (list system) (current-output-port) + #:backend backend #:node-type (service-node-type services) #:reverse-edges? #t))) -(define (export-shepherd-graph os port) - "Export the graph of shepherd services of OS to PORT." +(define* (export-shepherd-graph os port + #:key (backend (lookup-backend "graphviz"))) + "Export the graph of shepherd services of OS to PORT using BACKEND." (let* ((services (operating-system-services os)) (pid1 (fold-services services #:target-type shepherd-root-service-type)) @@ -907,6 +918,7 @@ Run 'herd status' to view the list of services on your system.\n")))))) (null? (shepherd-service-requirement service))) shepherds))) (export-graph sinks (current-output-port) + #:backend backend #:node-type (shepherd-service-node-type shepherds) #:reverse-edges? #t))) @@ -1014,6 +1026,10 @@ Some ACTIONS support additional ARGS.\n")) (display (G_ " -v, --verbosity=LEVEL use the given verbosity LEVEL")) (newline) + (display (G_ " + --graph-backend=BACKEND + use BACKEND for 'extension-graphs' and 'shepherd-graph'")) + (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " @@ -1109,6 +1125,9 @@ Some ACTIONS support additional ARGS.\n")) (option '(#\r "root") #t #f (lambda (opt name arg result) (alist-cons 'gc-root arg result))) + (option '("graph-backend") #t #f + (lambda (opt name arg result) + (alist-cons 'graph-backend arg result))) %standard-build-options)) (define %default-options @@ -1128,7 +1147,8 @@ Some ACTIONS support additional ARGS.\n")) (image-size . guess) (install-bootloader? . #t) (label . #f) - (volatile-root? . #f))) + (volatile-root? . #f) + (graph-backend . "graphviz"))) (define (verbosity-level opts) "Return the verbosity level based on OPTS, the alist of parsed options." @@ -1191,6 +1211,9 @@ resulting from command-line parsing." (bootloader-configuration-target (operating-system-bootloader os))))) + (define (graph-backend) + (lookup-backend (assoc-ref opts 'graph-backend))) + (with-store store (set-build-options-from-command-line store opts) @@ -1205,9 +1228,11 @@ resulting from command-line parsing." (set-guile-for-build (default-guile)) (case action ((extension-graph) - (export-extension-graph os (current-output-port))) + (export-extension-graph os (current-output-port) + #:backend (graph-backend))) ((shepherd-graph) - (export-shepherd-graph os (current-output-port))) + (export-shepherd-graph os (current-output-port) + #:backend (graph-backend))) (else (unless (memq action '(build init)) (warn-about-old-distro #:suggested-command -- cgit v1.2.3 From fa42774742fb1ddcb9f9424d8150d26f4033d426 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 16:51:13 +0100 Subject: ui: It's 2021 now! * guix/ui.scm (show-version-and-exit): Change year to 2021. --- guix/ui.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guix/ui.scm b/guix/ui.scm index fce2878354..0a1c9bd615 100644 --- a/guix/ui.scm +++ b/guix/ui.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2013, 2018 Mark H Weaver ;;; Copyright © 2013 Nikita Karetnikov ;;; Copyright © 2014 Cyril Roelandt @@ -528,7 +528,7 @@ See the \"Application Setup\" section in the manual, for more info.\n")) "Display version information for COMMAND and `(exit 0)'." (simple-format #t "~a (~a) ~a~%" command %guix-package-name %guix-version) - (format #t "Copyright ~a 2020 ~a" + (format #t "Copyright ~a 2021 ~a" ;; TRANSLATORS: Translate "(C)" to the copyright symbol ;; (C-in-a-circle), if this symbol is available in the user's ;; locale. Otherwise, do not translate "(C)"; leave it as-is. */ -- cgit v1.2.3 From 10612d61540228d48c998ba5b56f50da22534157 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Mon, 4 Jan 2021 22:10:49 +0100 Subject: graph: Install JavaScript files. Until now, 'guix graph --backend=d3js' wouldn't work outside the build tree. * d3.v3.js: Move to... * guix/d3.v3.js: ... here. * graph.js: Move to... * guix/graph.js: ... here. * Makefile.am (nobase_dist_guilemodule_DATA): Add them. (EXTRA_DIST): Remove them. * guix/graph.scm (emit-d3js-prologue, emit-d3js-epilogue): Adjust 'search-path' argument accordingly. * guix/self.scm (compiled-guix)[*extra-modules*]: Pass them via #:extra-files. --- Makefile.am | 6 +- d3.v3.js | 9584 -------------------------------------------------------- graph.js | 129 - guix/d3.v3.js | 9584 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ guix/graph.js | 129 + guix/graph.scm | 6 +- guix/self.scm | 7 +- 7 files changed, 9725 insertions(+), 9720 deletions(-) delete mode 100644 d3.v3.js delete mode 100644 graph.js create mode 100644 guix/d3.v3.js create mode 100644 guix/graph.js diff --git a/Makefile.am b/Makefile.am index aec2bb1474..51ff9c9ec9 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,5 +1,5 @@ # GNU Guix --- Functional package management for GNU -# Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +# Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès # Copyright © 2013 Andreas Enge # Copyright © 2015, 2017 Alex Kost # Copyright © 2016, 2018 Mathieu Lirzin @@ -397,6 +397,8 @@ EXAMPLES = \ GOBJECTS = $(MODULES:%.scm=%.go) guix/config.go $(dist_noinst_DATA:%.scm=%.go) nobase_dist_guilemodule_DATA = \ + guix/d3.v3.js \ + guix/graph.js \ guix/store/schema.sql \ $(MODULES) $(MODULES_NOT_COMPILED) $(AUX_FILES) $(EXAMPLES) \ $(MISC_DISTRO_FILES) @@ -611,8 +613,6 @@ EXTRA_DIST += \ build-aux/test-driver.scm \ build-aux/update-guix-package.scm \ build-aux/update-NEWS.scm \ - d3.v3.js \ - graph.js \ tests/test.drv \ tests/signing-key.pub \ tests/signing-key.sec \ diff --git a/d3.v3.js b/d3.v3.js deleted file mode 100644 index d234c4ec86..0000000000 --- a/d3.v3.js +++ /dev/null @@ -1,9584 +0,0 @@ -// Downloaded from http://d3js.org/d3.v3.js -// -// Copyright 2010-2016 Mike Bostock -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// * Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// * Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// * Neither the name of the author nor the names of contributors may be used to -// endorse or promote products derived from this software without specific prior -// written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -!function() { - var d3 = { - version: "3.5.17" - }; - var d3_arraySlice = [].slice, d3_array = function(list) { - return d3_arraySlice.call(list); - }; - var d3_document = this.document; - function d3_documentElement(node) { - return node && (node.ownerDocument || node.document || node).documentElement; - } - function d3_window(node) { - return node && (node.ownerDocument && node.ownerDocument.defaultView || node.document && node || node.defaultView); - } - if (d3_document) { - try { - d3_array(d3_document.documentElement.childNodes)[0].nodeType; - } catch (e) { - d3_array = function(list) { - var i = list.length, array = new Array(i); - while (i--) array[i] = list[i]; - return array; - }; - } - } - if (!Date.now) Date.now = function() { - return +new Date(); - }; - if (d3_document) { - try { - d3_document.createElement("DIV").style.setProperty("opacity", 0, ""); - } catch (error) { - var d3_element_prototype = this.Element.prototype, d3_element_setAttribute = d3_element_prototype.setAttribute, d3_element_setAttributeNS = d3_element_prototype.setAttributeNS, d3_style_prototype = this.CSSStyleDeclaration.prototype, d3_style_setProperty = d3_style_prototype.setProperty; - d3_element_prototype.setAttribute = function(name, value) { - d3_element_setAttribute.call(this, name, value + ""); - }; - d3_element_prototype.setAttributeNS = function(space, local, value) { - d3_element_setAttributeNS.call(this, space, local, value + ""); - }; - d3_style_prototype.setProperty = function(name, value, priority) { - d3_style_setProperty.call(this, name, value + "", priority); - }; - } - } - d3.ascending = d3_ascending; - function d3_ascending(a, b) { - return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN; - } - d3.descending = function(a, b) { - return b < a ? -1 : b > a ? 1 : b >= a ? 0 : NaN; - }; - d3.min = function(array, f) { - var i = -1, n = array.length, a, b; - if (arguments.length === 1) { - while (++i < n) if ((b = array[i]) != null && b >= b) { - a = b; - break; - } - while (++i < n) if ((b = array[i]) != null && a > b) a = b; - } else { - while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { - a = b; - break; - } - while (++i < n) if ((b = f.call(array, array[i], i)) != null && a > b) a = b; - } - return a; - }; - d3.max = function(array, f) { - var i = -1, n = array.length, a, b; - if (arguments.length === 1) { - while (++i < n) if ((b = array[i]) != null && b >= b) { - a = b; - break; - } - while (++i < n) if ((b = array[i]) != null && b > a) a = b; - } else { - while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { - a = b; - break; - } - while (++i < n) if ((b = f.call(array, array[i], i)) != null && b > a) a = b; - } - return a; - }; - d3.extent = function(array, f) { - var i = -1, n = array.length, a, b, c; - if (arguments.length === 1) { - while (++i < n) if ((b = array[i]) != null && b >= b) { - a = c = b; - break; - } - while (++i < n) if ((b = array[i]) != null) { - if (a > b) a = b; - if (c < b) c = b; - } - } else { - while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { - a = c = b; - break; - } - while (++i < n) if ((b = f.call(array, array[i], i)) != null) { - if (a > b) a = b; - if (c < b) c = b; - } - } - return [ a, c ]; - }; - function d3_number(x) { - return x === null ? NaN : +x; - } - function d3_numeric(x) { - return !isNaN(x); - } - d3.sum = function(array, f) { - var s = 0, n = array.length, a, i = -1; - if (arguments.length === 1) { - while (++i < n) if (d3_numeric(a = +array[i])) s += a; - } else { - while (++i < n) if (d3_numeric(a = +f.call(array, array[i], i))) s += a; - } - return s; - }; - d3.mean = function(array, f) { - var s = 0, n = array.length, a, i = -1, j = n; - if (arguments.length === 1) { - while (++i < n) if (d3_numeric(a = d3_number(array[i]))) s += a; else --j; - } else { - while (++i < n) if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) s += a; else --j; - } - if (j) return s / j; - }; - d3.quantile = function(values, p) { - var H = (values.length - 1) * p + 1, h = Math.floor(H), v = +values[h - 1], e = H - h; - return e ? v + e * (values[h] - v) : v; - }; - d3.median = function(array, f) { - var numbers = [], n = array.length, a, i = -1; - if (arguments.length === 1) { - while (++i < n) if (d3_numeric(a = d3_number(array[i]))) numbers.push(a); - } else { - while (++i < n) if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) numbers.push(a); - } - if (numbers.length) return d3.quantile(numbers.sort(d3_ascending), .5); - }; - d3.variance = function(array, f) { - var n = array.length, m = 0, a, d, s = 0, i = -1, j = 0; - if (arguments.length === 1) { - while (++i < n) { - if (d3_numeric(a = d3_number(array[i]))) { - d = a - m; - m += d / ++j; - s += d * (a - m); - } - } - } else { - while (++i < n) { - if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) { - d = a - m; - m += d / ++j; - s += d * (a - m); - } - } - } - if (j > 1) return s / (j - 1); - }; - d3.deviation = function() { - var v = d3.variance.apply(this, arguments); - return v ? Math.sqrt(v) : v; - }; - function d3_bisector(compare) { - return { - left: function(a, x, lo, hi) { - if (arguments.length < 3) lo = 0; - if (arguments.length < 4) hi = a.length; - while (lo < hi) { - var mid = lo + hi >>> 1; - if (compare(a[mid], x) < 0) lo = mid + 1; else hi = mid; - } - return lo; - }, - right: function(a, x, lo, hi) { - if (arguments.length < 3) lo = 0; - if (arguments.length < 4) hi = a.length; - while (lo < hi) { - var mid = lo + hi >>> 1; - if (compare(a[mid], x) > 0) hi = mid; else lo = mid + 1; - } - return lo; - } - }; - } - var d3_bisect = d3_bisector(d3_ascending); - d3.bisectLeft = d3_bisect.left; - d3.bisect = d3.bisectRight = d3_bisect.right; - d3.bisector = function(f) { - return d3_bisector(f.length === 1 ? function(d, x) { - return d3_ascending(f(d), x); - } : f); - }; - d3.shuffle = function(array, i0, i1) { - if ((m = arguments.length) < 3) { - i1 = array.length; - if (m < 2) i0 = 0; - } - var m = i1 - i0, t, i; - while (m) { - i = Math.random() * m-- | 0; - t = array[m + i0], array[m + i0] = array[i + i0], array[i + i0] = t; - } - return array; - }; - d3.permute = function(array, indexes) { - var i = indexes.length, permutes = new Array(i); - while (i--) permutes[i] = array[indexes[i]]; - return permutes; - }; - d3.pairs = function(array) { - var i = 0, n = array.length - 1, p0, p1 = array[0], pairs = new Array(n < 0 ? 0 : n); - while (i < n) pairs[i] = [ p0 = p1, p1 = array[++i] ]; - return pairs; - }; - d3.transpose = function(matrix) { - if (!(n = matrix.length)) return []; - for (var i = -1, m = d3.min(matrix, d3_transposeLength), transpose = new Array(m); ++i < m; ) { - for (var j = -1, n, row = transpose[i] = new Array(n); ++j < n; ) { - row[j] = matrix[j][i]; - } - } - return transpose; - }; - function d3_transposeLength(d) { - return d.length; - } - d3.zip = function() { - return d3.transpose(arguments); - }; - d3.keys = function(map) { - var keys = []; - for (var key in map) keys.push(key); - return keys; - }; - d3.values = function(map) { - var values = []; - for (var key in map) values.push(map[key]); - return values; - }; - d3.entries = function(map) { - var entries = []; - for (var key in map) entries.push({ - key: key, - value: map[key] - }); - return entries; - }; - d3.merge = function(arrays) { - var n = arrays.length, m, i = -1, j = 0, merged, array; - while (++i < n) j += arrays[i].length; - merged = new Array(j); - while (--n >= 0) { - array = arrays[n]; - m = array.length; - while (--m >= 0) { - merged[--j] = array[m]; - } - } - return merged; - }; - var abs = Math.abs; - d3.range = function(start, stop, step) { - if (arguments.length < 3) { - step = 1; - if (arguments.length < 2) { - stop = start; - start = 0; - } - } - if ((stop - start) / step === Infinity) throw new Error("infinite range"); - var range = [], k = d3_range_integerScale(abs(step)), i = -1, j; - start *= k, stop *= k, step *= k; - if (step < 0) while ((j = start + step * ++i) > stop) range.push(j / k); else while ((j = start + step * ++i) < stop) range.push(j / k); - return range; - }; - function d3_range_integerScale(x) { - var k = 1; - while (x * k % 1) k *= 10; - return k; - } - function d3_class(ctor, properties) { - for (var key in properties) { - Object.defineProperty(ctor.prototype, key, { - value: properties[key], - enumerable: false - }); - } - } - d3.map = function(object, f) { - var map = new d3_Map(); - if (object instanceof d3_Map) { - object.forEach(function(key, value) { - map.set(key, value); - }); - } else if (Array.isArray(object)) { - var i = -1, n = object.length, o; - if (arguments.length === 1) while (++i < n) map.set(i, object[i]); else while (++i < n) map.set(f.call(object, o = object[i], i), o); - } else { - for (var key in object) map.set(key, object[key]); - } - return map; - }; - function d3_Map() { - this._ = Object.create(null); - } - var d3_map_proto = "__proto__", d3_map_zero = "\x00"; - d3_class(d3_Map, { - has: d3_map_has, - get: function(key) { - return this._[d3_map_escape(key)]; - }, - set: function(key, value) { - return this._[d3_map_escape(key)] = value; - }, - remove: d3_map_remove, - keys: d3_map_keys, - values: function() { - var values = []; - for (var key in this._) values.push(this._[key]); - return values; - }, - entries: function() { - var entries = []; - for (var key in this._) entries.push({ - key: d3_map_unescape(key), - value: this._[key] - }); - return entries; - }, - size: d3_map_size, - empty: d3_map_empty, - forEach: function(f) { - for (var key in this._) f.call(this, d3_map_unescape(key), this._[key]); - } - }); - function d3_map_escape(key) { - return (key += "") === d3_map_proto || key[0] === d3_map_zero ? d3_map_zero + key : key; - } - function d3_map_unescape(key) { - return (key += "")[0] === d3_map_zero ? key.slice(1) : key; - } - function d3_map_has(key) { - return d3_map_escape(key) in this._; - } - function d3_map_remove(key) { - return (key = d3_map_escape(key)) in this._ && delete this._[key]; - } - function d3_map_keys() { - var keys = []; - for (var key in this._) keys.push(d3_map_unescape(key)); - return keys; - } - function d3_map_size() { - var size = 0; - for (var key in this._) ++size; - return size; - } - function d3_map_empty() { - for (var key in this._) return false; - return true; - } - d3.nest = function() { - var nest = {}, keys = [], sortKeys = [], sortValues, rollup; - function map(mapType, array, depth) { - if (depth >= keys.length) return rollup ? rollup.call(nest, array) : sortValues ? array.sort(sortValues) : array; - var i = -1, n = array.length, key = keys[depth++], keyValue, object, setter, valuesByKey = new d3_Map(), values; - while (++i < n) { - if (values = valuesByKey.get(keyValue = key(object = array[i]))) { - values.push(object); - } else { - valuesByKey.set(keyValue, [ object ]); - } - } - if (mapType) { - object = mapType(); - setter = function(keyValue, values) { - object.set(keyValue, map(mapType, values, depth)); - }; - } else { - object = {}; - setter = function(keyValue, values) { - object[keyValue] = map(mapType, values, depth); - }; - } - valuesByKey.forEach(setter); - return object; - } - function entries(map, depth) { - if (depth >= keys.length) return map; - var array = [], sortKey = sortKeys[depth++]; - map.forEach(function(key, keyMap) { - array.push({ - key: key, - values: entries(keyMap, depth) - }); - }); - return sortKey ? array.sort(function(a, b) { - return sortKey(a.key, b.key); - }) : array; - } - nest.map = function(array, mapType) { - return map(mapType, array, 0); - }; - nest.entries = function(array) { - return entries(map(d3.map, array, 0), 0); - }; - nest.key = function(d) { - keys.push(d); - return nest; - }; - nest.sortKeys = function(order) { - sortKeys[keys.length - 1] = order; - return nest; - }; - nest.sortValues = function(order) { - sortValues = order; - return nest; - }; - nest.rollup = function(f) { - rollup = f; - return nest; - }; - return nest; - }; - d3.set = function(array) { - var set = new d3_Set(); - if (array) for (var i = 0, n = array.length; i < n; ++i) set.add(array[i]); - return set; - }; - function d3_Set() { - this._ = Object.create(null); - } - d3_class(d3_Set, { - has: d3_map_has, - add: function(key) { - this._[d3_map_escape(key += "")] = true; - return key; - }, - remove: d3_map_remove, - values: d3_map_keys, - size: d3_map_size, - empty: d3_map_empty, - forEach: function(f) { - for (var key in this._) f.call(this, d3_map_unescape(key)); - } - }); - d3.behavior = {}; - function d3_identity(d) { - return d; - } - d3.rebind = function(target, source) { - var i = 1, n = arguments.length, method; - while (++i < n) target[method = arguments[i]] = d3_rebind(target, source, source[method]); - return target; - }; - function d3_rebind(target, source, method) { - return function() { - var value = method.apply(source, arguments); - return value === source ? target : value; - }; - } - function d3_vendorSymbol(object, name) { - if (name in object) return name; - name = name.charAt(0).toUpperCase() + name.slice(1); - for (var i = 0, n = d3_vendorPrefixes.length; i < n; ++i) { - var prefixName = d3_vendorPrefixes[i] + name; - if (prefixName in object) return prefixName; - } - } - var d3_vendorPrefixes = [ "webkit", "ms", "moz", "Moz", "o", "O" ]; - function d3_noop() {} - d3.dispatch = function() { - var dispatch = new d3_dispatch(), i = -1, n = arguments.length; - while (++i < n) dispatch[arguments[i]] = d3_dispatch_event(dispatch); - return dispatch; - }; - function d3_dispatch() {} - d3_dispatch.prototype.on = function(type, listener) { - var i = type.indexOf("."), name = ""; - if (i >= 0) { - name = type.slice(i + 1); - type = type.slice(0, i); - } - if (type) return arguments.length < 2 ? this[type].on(name) : this[type].on(name, listener); - if (arguments.length === 2) { - if (listener == null) for (type in this) { - if (this.hasOwnProperty(type)) this[type].on(name, null); - } - return this; - } - }; - function d3_dispatch_event(dispatch) { - var listeners = [], listenerByName = new d3_Map(); - function event() { - var z = listeners, i = -1, n = z.length, l; - while (++i < n) if (l = z[i].on) l.apply(this, arguments); - return dispatch; - } - event.on = function(name, listener) { - var l = listenerByName.get(name), i; - if (arguments.length < 2) return l && l.on; - if (l) { - l.on = null; - listeners = listeners.slice(0, i = listeners.indexOf(l)).concat(listeners.slice(i + 1)); - listenerByName.remove(name); - } - if (listener) listeners.push(listenerByName.set(name, { - on: listener - })); - return dispatch; - }; - return event; - } - d3.event = null; - function d3_eventPreventDefault() { - d3.event.preventDefault(); - } - function d3_eventSource() { - var e = d3.event, s; - while (s = e.sourceEvent) e = s; - return e; - } - function d3_eventDispatch(target) { - var dispatch = new d3_dispatch(), i = 0, n = arguments.length; - while (++i < n) dispatch[arguments[i]] = d3_dispatch_event(dispatch); - dispatch.of = function(thiz, argumentz) { - return function(e1) { - try { - var e0 = e1.sourceEvent = d3.event; - e1.target = target; - d3.event = e1; - dispatch[e1.type].apply(thiz, argumentz); - } finally { - d3.event = e0; - } - }; - }; - return dispatch; - } - d3.requote = function(s) { - return s.replace(d3_requote_re, "\\$&"); - }; - var d3_requote_re = /[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g; - var d3_subclass = {}.__proto__ ? function(object, prototype) { - object.__proto__ = prototype; - } : function(object, prototype) { - for (var property in prototype) object[property] = prototype[property]; - }; - function d3_selection(groups) { - d3_subclass(groups, d3_selectionPrototype); - return groups; - } - var d3_select = function(s, n) { - return n.querySelector(s); - }, d3_selectAll = function(s, n) { - return n.querySelectorAll(s); - }, d3_selectMatches = function(n, s) { - var d3_selectMatcher = n.matches || n[d3_vendorSymbol(n, "matchesSelector")]; - d3_selectMatches = function(n, s) { - return d3_selectMatcher.call(n, s); - }; - return d3_selectMatches(n, s); - }; - if (typeof Sizzle === "function") { - d3_select = function(s, n) { - return Sizzle(s, n)[0] || null; - }; - d3_selectAll = Sizzle; - d3_selectMatches = Sizzle.matchesSelector; - } - d3.selection = function() { - return d3.select(d3_document.documentElement); - }; - var d3_selectionPrototype = d3.selection.prototype = []; - d3_selectionPrototype.select = function(selector) { - var subgroups = [], subgroup, subnode, group, node; - selector = d3_selection_selector(selector); - for (var j = -1, m = this.length; ++j < m; ) { - subgroups.push(subgroup = []); - subgroup.parentNode = (group = this[j]).parentNode; - for (var i = -1, n = group.length; ++i < n; ) { - if (node = group[i]) { - subgroup.push(subnode = selector.call(node, node.__data__, i, j)); - if (subnode && "__data__" in node) subnode.__data__ = node.__data__; - } else { - subgroup.push(null); - } - } - } - return d3_selection(subgroups); - }; - function d3_selection_selector(selector) { - return typeof selector === "function" ? selector : function() { - return d3_select(selector, this); - }; - } - d3_selectionPrototype.selectAll = function(selector) { - var subgroups = [], subgroup, node; - selector = d3_selection_selectorAll(selector); - for (var j = -1, m = this.length; ++j < m; ) { - for (var group = this[j], i = -1, n = group.length; ++i < n; ) { - if (node = group[i]) { - subgroups.push(subgroup = d3_array(selector.call(node, node.__data__, i, j))); - subgroup.parentNode = node; - } - } - } - return d3_selection(subgroups); - }; - function d3_selection_selectorAll(selector) { - return typeof selector === "function" ? selector : function() { - return d3_selectAll(selector, this); - }; - } - var d3_nsXhtml = "http://www.w3.org/1999/xhtml"; - var d3_nsPrefix = { - svg: "http://www.w3.org/2000/svg", - xhtml: d3_nsXhtml, - xlink: "http://www.w3.org/1999/xlink", - xml: "http://www.w3.org/XML/1998/namespace", - xmlns: "http://www.w3.org/2000/xmlns/" - }; - d3.ns = { - prefix: d3_nsPrefix, - qualify: function(name) { - var i = name.indexOf(":"), prefix = name; - if (i >= 0 && (prefix = name.slice(0, i)) !== "xmlns") name = name.slice(i + 1); - return d3_nsPrefix.hasOwnProperty(prefix) ? { - space: d3_nsPrefix[prefix], - local: name - } : name; - } - }; - d3_selectionPrototype.attr = function(name, value) { - if (arguments.length < 2) { - if (typeof name === "string") { - var node = this.node(); - name = d3.ns.qualify(name); - return name.local ? node.getAttributeNS(name.space, name.local) : node.getAttribute(name); - } - for (value in name) this.each(d3_selection_attr(value, name[value])); - return this; - } - return this.each(d3_selection_attr(name, value)); - }; - function d3_selection_attr(name, value) { - name = d3.ns.qualify(name); - function attrNull() { - this.removeAttribute(name); - } - function attrNullNS() { - this.removeAttributeNS(name.space, name.local); - } - function attrConstant() { - this.setAttribute(name, value); - } - function attrConstantNS() { - this.setAttributeNS(name.space, name.local, value); - } - function attrFunction() { - var x = value.apply(this, arguments); - if (x == null) this.removeAttribute(name); else this.setAttribute(name, x); - } - function attrFunctionNS() { - var x = value.apply(this, arguments); - if (x == null) this.removeAttributeNS(name.space, name.local); else this.setAttributeNS(name.space, name.local, x); - } - return value == null ? name.local ? attrNullNS : attrNull : typeof value === "function" ? name.local ? attrFunctionNS : attrFunction : name.local ? attrConstantNS : attrConstant; - } - function d3_collapse(s) { - return s.trim().replace(/\s+/g, " "); - } - d3_selectionPrototype.classed = function(name, value) { - if (arguments.length < 2) { - if (typeof name === "string") { - var node = this.node(), n = (name = d3_selection_classes(name)).length, i = -1; - if (value = node.classList) { - while (++i < n) if (!value.contains(name[i])) return false; - } else { - value = node.getAttribute("class"); - while (++i < n) if (!d3_selection_classedRe(name[i]).test(value)) return false; - } - return true; - } - for (value in name) this.each(d3_selection_classed(value, name[value])); - return this; - } - return this.each(d3_selection_classed(name, value)); - }; - function d3_selection_classedRe(name) { - return new RegExp("(?:^|\\s+)" + d3.requote(name) + "(?:\\s+|$)", "g"); - } - function d3_selection_classes(name) { - return (name + "").trim().split(/^|\s+/); - } - function d3_selection_classed(name, value) { - name = d3_selection_classes(name).map(d3_selection_classedName); - var n = name.length; - function classedConstant() { - var i = -1; - while (++i < n) name[i](this, value); - } - function classedFunction() { - var i = -1, x = value.apply(this, arguments); - while (++i < n) name[i](this, x); - } - return typeof value === "function" ? classedFunction : classedConstant; - } - function d3_selection_classedName(name) { - var re = d3_selection_classedRe(name); - return function(node, value) { - if (c = node.classList) return value ? c.add(name) : c.remove(name); - var c = node.getAttribute("class") || ""; - if (value) { - re.lastIndex = 0; - if (!re.test(c)) node.setAttribute("class", d3_collapse(c + " " + name)); - } else { - node.setAttribute("class", d3_collapse(c.replace(re, " "))); - } - }; - } - d3_selectionPrototype.style = function(name, value, priority) { - var n = arguments.length; - if (n < 3) { - if (typeof name !== "string") { - if (n < 2) value = ""; - for (priority in name) this.each(d3_selection_style(priority, name[priority], value)); - return this; - } - if (n < 2) { - var node = this.node(); - return d3_window(node).getComputedStyle(node, null).getPropertyValue(name); - } - priority = ""; - } - return this.each(d3_selection_style(name, value, priority)); - }; - function d3_selection_style(name, value, priority) { - function styleNull() { - this.style.removeProperty(name); - } - function styleConstant() { - this.style.setProperty(name, value, priority); - } - function styleFunction() { - var x = value.apply(this, arguments); - if (x == null) this.style.removeProperty(name); else this.style.setProperty(name, x, priority); - } - return value == null ? styleNull : typeof value === "function" ? styleFunction : styleConstant; - } - d3_selectionPrototype.property = function(name, value) { - if (arguments.length < 2) { - if (typeof name === "string") return this.node()[name]; - for (value in name) this.each(d3_selection_property(value, name[value])); - return this; - } - return this.each(d3_selection_property(name, value)); - }; - function d3_selection_property(name, value) { - function propertyNull() { - delete this[name]; - } - function propertyConstant() { - this[name] = value; - } - function propertyFunction() { - var x = value.apply(this, arguments); - if (x == null) delete this[name]; else this[name] = x; - } - return value == null ? propertyNull : typeof value === "function" ? propertyFunction : propertyConstant; - } - d3_selectionPrototype.text = function(value) { - return arguments.length ? this.each(typeof value === "function" ? function() { - var v = value.apply(this, arguments); - this.textContent = v == null ? "" : v; - } : value == null ? function() { - this.textContent = ""; - } : function() { - this.textContent = value; - }) : this.node().textContent; - }; - d3_selectionPrototype.html = function(value) { - return arguments.length ? this.each(typeof value === "function" ? function() { - var v = value.apply(this, arguments); - this.innerHTML = v == null ? "" : v; - } : value == null ? function() { - this.innerHTML = ""; - } : function() { - this.innerHTML = value; - }) : this.node().innerHTML; - }; - d3_selectionPrototype.append = function(name) { - name = d3_selection_creator(name); - return this.select(function() { - return this.appendChild(name.apply(this, arguments)); - }); - }; - function d3_selection_creator(name) { - function create() { - var document = this.ownerDocument, namespace = this.namespaceURI; - return namespace === d3_nsXhtml && document.documentElement.namespaceURI === d3_nsXhtml ? document.createElement(name) : document.createElementNS(namespace, name); - } - function createNS() { - return this.ownerDocument.createElementNS(name.space, name.local); - } - return typeof name === "function" ? name : (name = d3.ns.qualify(name)).local ? createNS : create; - } - d3_selectionPrototype.insert = function(name, before) { - name = d3_selection_creator(name); - before = d3_selection_selector(before); - return this.select(function() { - return this.insertBefore(name.apply(this, arguments), before.apply(this, arguments) || null); - }); - }; - d3_selectionPrototype.remove = function() { - return this.each(d3_selectionRemove); - }; - function d3_selectionRemove() { - var parent = this.parentNode; - if (parent) parent.removeChild(this); - } - d3_selectionPrototype.data = function(value, key) { - var i = -1, n = this.length, group, node; - if (!arguments.length) { - value = new Array(n = (group = this[0]).length); - while (++i < n) { - if (node = group[i]) { - value[i] = node.__data__; - } - } - return value; - } - function bind(group, groupData) { - var i, n = group.length, m = groupData.length, n0 = Math.min(n, m), updateNodes = new Array(m), enterNodes = new Array(m), exitNodes = new Array(n), node, nodeData; - if (key) { - var nodeByKeyValue = new d3_Map(), keyValues = new Array(n), keyValue; - for (i = -1; ++i < n; ) { - if (node = group[i]) { - if (nodeByKeyValue.has(keyValue = key.call(node, node.__data__, i))) { - exitNodes[i] = node; - } else { - nodeByKeyValue.set(keyValue, node); - } - keyValues[i] = keyValue; - } - } - for (i = -1; ++i < m; ) { - if (!(node = nodeByKeyValue.get(keyValue = key.call(groupData, nodeData = groupData[i], i)))) { - enterNodes[i] = d3_selection_dataNode(nodeData); - } else if (node !== true) { - updateNodes[i] = node; - node.__data__ = nodeData; - } - nodeByKeyValue.set(keyValue, true); - } - for (i = -1; ++i < n; ) { - if (i in keyValues && nodeByKeyValue.get(keyValues[i]) !== true) { - exitNodes[i] = group[i]; - } - } - } else { - for (i = -1; ++i < n0; ) { - node = group[i]; - nodeData = groupData[i]; - if (node) { - node.__data__ = nodeData; - updateNodes[i] = node; - } else { - enterNodes[i] = d3_selection_dataNode(nodeData); - } - } - for (;i < m; ++i) { - enterNodes[i] = d3_selection_dataNode(groupData[i]); - } - for (;i < n; ++i) { - exitNodes[i] = group[i]; - } - } - enterNodes.update = updateNodes; - enterNodes.parentNode = updateNodes.parentNode = exitNodes.parentNode = group.parentNode; - enter.push(enterNodes); - update.push(updateNodes); - exit.push(exitNodes); - } - var enter = d3_selection_enter([]), update = d3_selection([]), exit = d3_selection([]); - if (typeof value === "function") { - while (++i < n) { - bind(group = this[i], value.call(group, group.parentNode.__data__, i)); - } - } else { - while (++i < n) { - bind(group = this[i], value); - } - } - update.enter = function() { - return enter; - }; - update.exit = function() { - return exit; - }; - return update; - }; - function d3_selection_dataNode(data) { - return { - __data__: data - }; - } - d3_selectionPrototype.datum = function(value) { - return arguments.length ? this.property("__data__", value) : this.property("__data__"); - }; - d3_selectionPrototype.filter = function(filter) { - var subgroups = [], subgroup, group, node; - if (typeof filter !== "function") filter = d3_selection_filter(filter); - for (var j = 0, m = this.length; j < m; j++) { - subgroups.push(subgroup = []); - subgroup.parentNode = (group = this[j]).parentNode; - for (var i = 0, n = group.length; i < n; i++) { - if ((node = group[i]) && filter.call(node, node.__data__, i, j)) { - subgroup.push(node); - } - } - } - return d3_selection(subgroups); - }; - function d3_selection_filter(selector) { - return function() { - return d3_selectMatches(this, selector); - }; - } - d3_selectionPrototype.order = function() { - for (var j = -1, m = this.length; ++j < m; ) { - for (var group = this[j], i = group.length - 1, next = group[i], node; --i >= 0; ) { - if (node = group[i]) { - if (next && next !== node.nextSibling) next.parentNode.insertBefore(node, next); - next = node; - } - } - } - return this; - }; - d3_selectionPrototype.sort = function(comparator) { - comparator = d3_selection_sortComparator.apply(this, arguments); - for (var j = -1, m = this.length; ++j < m; ) this[j].sort(comparator); - return this.order(); - }; - function d3_selection_sortComparator(comparator) { - if (!arguments.length) comparator = d3_ascending; - return function(a, b) { - return a && b ? comparator(a.__data__, b.__data__) : !a - !b; - }; - } - d3_selectionPrototype.each = function(callback) { - return d3_selection_each(this, function(node, i, j) { - callback.call(node, node.__data__, i, j); - }); - }; - function d3_selection_each(groups, callback) { - for (var j = 0, m = groups.length; j < m; j++) { - for (var group = groups[j], i = 0, n = group.length, node; i < n; i++) { - if (node = group[i]) callback(node, i, j); - } - } - return groups; - } - d3_selectionPrototype.call = function(callback) { - var args = d3_array(arguments); - callback.apply(args[0] = this, args); - return this; - }; - d3_selectionPrototype.empty = function() { - return !this.node(); - }; - d3_selectionPrototype.node = function() { - for (var j = 0, m = this.length; j < m; j++) { - for (var group = this[j], i = 0, n = group.length; i < n; i++) { - var node = group[i]; - if (node) return node; - } - } - return null; - }; - d3_selectionPrototype.size = function() { - var n = 0; - d3_selection_each(this, function() { - ++n; - }); - return n; - }; - function d3_selection_enter(selection) { - d3_subclass(selection, d3_selection_enterPrototype); - return selection; - } - var d3_selection_enterPrototype = []; - d3.selection.enter = d3_selection_enter; - d3.selection.enter.prototype = d3_selection_enterPrototype; - d3_selection_enterPrototype.append = d3_selectionPrototype.append; - d3_selection_enterPrototype.empty = d3_selectionPrototype.empty; - d3_selection_enterPrototype.node = d3_selectionPrototype.node; - d3_selection_enterPrototype.call = d3_selectionPrototype.call; - d3_selection_enterPrototype.size = d3_selectionPrototype.size; - d3_selection_enterPrototype.select = function(selector) { - var subgroups = [], subgroup, subnode, upgroup, group, node; - for (var j = -1, m = this.length; ++j < m; ) { - upgroup = (group = this[j]).update; - subgroups.push(subgroup = []); - subgroup.parentNode = group.parentNode; - for (var i = -1, n = group.length; ++i < n; ) { - if (node = group[i]) { - subgroup.push(upgroup[i] = subnode = selector.call(group.parentNode, node.__data__, i, j)); - subnode.__data__ = node.__data__; - } else { - subgroup.push(null); - } - } - } - return d3_selection(subgroups); - }; - d3_selection_enterPrototype.insert = function(name, before) { - if (arguments.length < 2) before = d3_selection_enterInsertBefore(this); - return d3_selectionPrototype.insert.call(this, name, before); - }; - function d3_selection_enterInsertBefore(enter) { - var i0, j0; - return function(d, i, j) { - var group = enter[j].update, n = group.length, node; - if (j != j0) j0 = j, i0 = 0; - if (i >= i0) i0 = i + 1; - while (!(node = group[i0]) && ++i0 < n) ; - return node; - }; - } - d3.select = function(node) { - var group; - if (typeof node === "string") { - group = [ d3_select(node, d3_document) ]; - group.parentNode = d3_document.documentElement; - } else { - group = [ node ]; - group.parentNode = d3_documentElement(node); - } - return d3_selection([ group ]); - }; - d3.selectAll = function(nodes) { - var group; - if (typeof nodes === "string") { - group = d3_array(d3_selectAll(nodes, d3_document)); - group.parentNode = d3_document.documentElement; - } else { - group = d3_array(nodes); - group.parentNode = null; - } - return d3_selection([ group ]); - }; - d3_selectionPrototype.on = function(type, listener, capture) { - var n = arguments.length; - if (n < 3) { - if (typeof type !== "string") { - if (n < 2) listener = false; - for (capture in type) this.each(d3_selection_on(capture, type[capture], listener)); - return this; - } - if (n < 2) return (n = this.node()["__on" + type]) && n._; - capture = false; - } - return this.each(d3_selection_on(type, listener, capture)); - }; - function d3_selection_on(type, listener, capture) { - var name = "__on" + type, i = type.indexOf("."), wrap = d3_selection_onListener; - if (i > 0) type = type.slice(0, i); - var filter = d3_selection_onFilters.get(type); - if (filter) type = filter, wrap = d3_selection_onFilter; - function onRemove() { - var l = this[name]; - if (l) { - this.removeEventListener(type, l, l.$); - delete this[name]; - } - } - function onAdd() { - var l = wrap(listener, d3_array(arguments)); - onRemove.call(this); - this.addEventListener(type, this[name] = l, l.$ = capture); - l._ = listener; - } - function removeAll() { - var re = new RegExp("^__on([^.]+)" + d3.requote(type) + "$"), match; - for (var name in this) { - if (match = name.match(re)) { - var l = this[name]; - this.removeEventListener(match[1], l, l.$); - delete this[name]; - } - } - } - return i ? listener ? onAdd : onRemove : listener ? d3_noop : removeAll; - } - var d3_selection_onFilters = d3.map({ - mouseenter: "mouseover", - mouseleave: "mouseout" - }); - if (d3_document) { - d3_selection_onFilters.forEach(function(k) { - if ("on" + k in d3_document) d3_selection_onFilters.remove(k); - }); - } - function d3_selection_onListener(listener, argumentz) { - return function(e) { - var o = d3.event; - d3.event = e; - argumentz[0] = this.__data__; - try { - listener.apply(this, argumentz); - } finally { - d3.event = o; - } - }; - } - function d3_selection_onFilter(listener, argumentz) { - var l = d3_selection_onListener(listener, argumentz); - return function(e) { - var target = this, related = e.relatedTarget; - if (!related || related !== target && !(related.compareDocumentPosition(target) & 8)) { - l.call(target, e); - } - }; - } - var d3_event_dragSelect, d3_event_dragId = 0; - function d3_event_dragSuppress(node) { - var name = ".dragsuppress-" + ++d3_event_dragId, click = "click" + name, w = d3.select(d3_window(node)).on("touchmove" + name, d3_eventPreventDefault).on("dragstart" + name, d3_eventPreventDefault).on("selectstart" + name, d3_eventPreventDefault); - if (d3_event_dragSelect == null) { - d3_event_dragSelect = "onselectstart" in node ? false : d3_vendorSymbol(node.style, "userSelect"); - } - if (d3_event_dragSelect) { - var style = d3_documentElement(node).style, select = style[d3_event_dragSelect]; - style[d3_event_dragSelect] = "none"; - } - return function(suppressClick) { - w.on(name, null); - if (d3_event_dragSelect) style[d3_event_dragSelect] = select; - if (suppressClick) { - var off = function() { - w.on(click, null); - }; - w.on(click, function() { - d3_eventPreventDefault(); - off(); - }, true); - setTimeout(off, 0); - } - }; - } - d3.mouse = function(container) { - return d3_mousePoint(container, d3_eventSource()); - }; - var d3_mouse_bug44083 = this.navigator && /WebKit/.test(this.navigator.userAgent) ? -1 : 0; - function d3_mousePoint(container, e) { - if (e.changedTouches) e = e.changedTouches[0]; - var svg = container.ownerSVGElement || container; - if (svg.createSVGPoint) { - var point = svg.createSVGPoint(); - if (d3_mouse_bug44083 < 0) { - var window = d3_window(container); - if (window.scrollX || window.scrollY) { - svg = d3.select("body").append("svg").style({ - position: "absolute", - top: 0, - left: 0, - margin: 0, - padding: 0, - border: "none" - }, "important"); - var ctm = svg[0][0].getScreenCTM(); - d3_mouse_bug44083 = !(ctm.f || ctm.e); - svg.remove(); - } - } - if (d3_mouse_bug44083) point.x = e.pageX, point.y = e.pageY; else point.x = e.clientX, - point.y = e.clientY; - point = point.matrixTransform(container.getScreenCTM().inverse()); - return [ point.x, point.y ]; - } - var rect = container.getBoundingClientRect(); - return [ e.clientX - rect.left - container.clientLeft, e.clientY - rect.top - container.clientTop ]; - } - d3.touch = function(container, touches, identifier) { - if (arguments.length < 3) identifier = touches, touches = d3_eventSource().changedTouches; - if (touches) for (var i = 0, n = touches.length, touch; i < n; ++i) { - if ((touch = touches[i]).identifier === identifier) { - return d3_mousePoint(container, touch); - } - } - }; - d3.behavior.drag = function() { - var event = d3_eventDispatch(drag, "drag", "dragstart", "dragend"), origin = null, mousedown = dragstart(d3_noop, d3.mouse, d3_window, "mousemove", "mouseup"), touchstart = dragstart(d3_behavior_dragTouchId, d3.touch, d3_identity, "touchmove", "touchend"); - function drag() { - this.on("mousedown.drag", mousedown).on("touchstart.drag", touchstart); - } - function dragstart(id, position, subject, move, end) { - return function() { - var that = this, target = d3.event.target.correspondingElement || d3.event.target, parent = that.parentNode, dispatch = event.of(that, arguments), dragged = 0, dragId = id(), dragName = ".drag" + (dragId == null ? "" : "-" + dragId), dragOffset, dragSubject = d3.select(subject(target)).on(move + dragName, moved).on(end + dragName, ended), dragRestore = d3_event_dragSuppress(target), position0 = position(parent, dragId); - if (origin) { - dragOffset = origin.apply(that, arguments); - dragOffset = [ dragOffset.x - position0[0], dragOffset.y - position0[1] ]; - } else { - dragOffset = [ 0, 0 ]; - } - dispatch({ - type: "dragstart" - }); - function moved() { - var position1 = position(parent, dragId), dx, dy; - if (!position1) return; - dx = position1[0] - position0[0]; - dy = position1[1] - position0[1]; - dragged |= dx | dy; - position0 = position1; - dispatch({ - type: "drag", - x: position1[0] + dragOffset[0], - y: position1[1] + dragOffset[1], - dx: dx, - dy: dy - }); - } - function ended() { - if (!position(parent, dragId)) return; - dragSubject.on(move + dragName, null).on(end + dragName, null); - dragRestore(dragged); - dispatch({ - type: "dragend" - }); - } - }; - } - drag.origin = function(x) { - if (!arguments.length) return origin; - origin = x; - return drag; - }; - return d3.rebind(drag, event, "on"); - }; - function d3_behavior_dragTouchId() { - return d3.event.changedTouches[0].identifier; - } - d3.touches = function(container, touches) { - if (arguments.length < 2) touches = d3_eventSource().touches; - return touches ? d3_array(touches).map(function(touch) { - var point = d3_mousePoint(container, touch); - point.identifier = touch.identifier; - return point; - }) : []; - }; - var ε = 1e-6, ε2 = ε * ε, π = Math.PI, τ = 2 * π, τε = τ - ε, halfπ = π / 2, d3_radians = π / 180, d3_degrees = 180 / π; - function d3_sgn(x) { - return x > 0 ? 1 : x < 0 ? -1 : 0; - } - function d3_cross2d(a, b, c) { - return (b[0] - a[0]) * (c[1] - a[1]) - (b[1] - a[1]) * (c[0] - a[0]); - } - function d3_acos(x) { - return x > 1 ? 0 : x < -1 ? π : Math.acos(x); - } - function d3_asin(x) { - return x > 1 ? halfπ : x < -1 ? -halfπ : Math.asin(x); - } - function d3_sinh(x) { - return ((x = Math.exp(x)) - 1 / x) / 2; - } - function d3_cosh(x) { - return ((x = Math.exp(x)) + 1 / x) / 2; - } - function d3_tanh(x) { - return ((x = Math.exp(2 * x)) - 1) / (x + 1); - } - function d3_haversin(x) { - return (x = Math.sin(x / 2)) * x; - } - var ρ = Math.SQRT2, ρ2 = 2, ρ4 = 4; - d3.interpolateZoom = function(p0, p1) { - var ux0 = p0[0], uy0 = p0[1], w0 = p0[2], ux1 = p1[0], uy1 = p1[1], w1 = p1[2], dx = ux1 - ux0, dy = uy1 - uy0, d2 = dx * dx + dy * dy, i, S; - if (d2 < ε2) { - S = Math.log(w1 / w0) / ρ; - i = function(t) { - return [ ux0 + t * dx, uy0 + t * dy, w0 * Math.exp(ρ * t * S) ]; - }; - } else { - var d1 = Math.sqrt(d2), b0 = (w1 * w1 - w0 * w0 + ρ4 * d2) / (2 * w0 * ρ2 * d1), b1 = (w1 * w1 - w0 * w0 - ρ4 * d2) / (2 * w1 * ρ2 * d1), r0 = Math.log(Math.sqrt(b0 * b0 + 1) - b0), r1 = Math.log(Math.sqrt(b1 * b1 + 1) - b1); - S = (r1 - r0) / ρ; - i = function(t) { - var s = t * S, coshr0 = d3_cosh(r0), u = w0 / (ρ2 * d1) * (coshr0 * d3_tanh(ρ * s + r0) - d3_sinh(r0)); - return [ ux0 + u * dx, uy0 + u * dy, w0 * coshr0 / d3_cosh(ρ * s + r0) ]; - }; - } - i.duration = S * 1e3; - return i; - }; - d3.behavior.zoom = function() { - var view = { - x: 0, - y: 0, - k: 1 - }, translate0, center0, center, size = [ 960, 500 ], scaleExtent = d3_behavior_zoomInfinity, duration = 250, zooming = 0, mousedown = "mousedown.zoom", mousemove = "mousemove.zoom", mouseup = "mouseup.zoom", mousewheelTimer, touchstart = "touchstart.zoom", touchtime, event = d3_eventDispatch(zoom, "zoomstart", "zoom", "zoomend"), x0, x1, y0, y1; - if (!d3_behavior_zoomWheel) { - d3_behavior_zoomWheel = "onwheel" in d3_document ? (d3_behavior_zoomDelta = function() { - return -d3.event.deltaY * (d3.event.deltaMode ? 120 : 1); - }, "wheel") : "onmousewheel" in d3_document ? (d3_behavior_zoomDelta = function() { - return d3.event.wheelDelta; - }, "mousewheel") : (d3_behavior_zoomDelta = function() { - return -d3.event.detail; - }, "MozMousePixelScroll"); - } - function zoom(g) { - g.on(mousedown, mousedowned).on(d3_behavior_zoomWheel + ".zoom", mousewheeled).on("dblclick.zoom", dblclicked).on(touchstart, touchstarted); - } - zoom.event = function(g) { - g.each(function() { - var dispatch = event.of(this, arguments), view1 = view; - if (d3_transitionInheritId) { - d3.select(this).transition().each("start.zoom", function() { - view = this.__chart__ || { - x: 0, - y: 0, - k: 1 - }; - zoomstarted(dispatch); - }).tween("zoom:zoom", function() { - var dx = size[0], dy = size[1], cx = center0 ? center0[0] : dx / 2, cy = center0 ? center0[1] : dy / 2, i = d3.interpolateZoom([ (cx - view.x) / view.k, (cy - view.y) / view.k, dx / view.k ], [ (cx - view1.x) / view1.k, (cy - view1.y) / view1.k, dx / view1.k ]); - return function(t) { - var l = i(t), k = dx / l[2]; - this.__chart__ = view = { - x: cx - l[0] * k, - y: cy - l[1] * k, - k: k - }; - zoomed(dispatch); - }; - }).each("interrupt.zoom", function() { - zoomended(dispatch); - }).each("end.zoom", function() { - zoomended(dispatch); - }); - } else { - this.__chart__ = view; - zoomstarted(dispatch); - zoomed(dispatch); - zoomended(dispatch); - } - }); - }; - zoom.translate = function(_) { - if (!arguments.length) return [ view.x, view.y ]; - view = { - x: +_[0], - y: +_[1], - k: view.k - }; - rescale(); - return zoom; - }; - zoom.scale = function(_) { - if (!arguments.length) return view.k; - view = { - x: view.x, - y: view.y, - k: null - }; - scaleTo(+_); - rescale(); - return zoom; - }; - zoom.scaleExtent = function(_) { - if (!arguments.length) return scaleExtent; - scaleExtent = _ == null ? d3_behavior_zoomInfinity : [ +_[0], +_[1] ]; - return zoom; - }; - zoom.center = function(_) { - if (!arguments.length) return center; - center = _ && [ +_[0], +_[1] ]; - return zoom; - }; - zoom.size = function(_) { - if (!arguments.length) return size; - size = _ && [ +_[0], +_[1] ]; - return zoom; - }; - zoom.duration = function(_) { - if (!arguments.length) return duration; - duration = +_; - return zoom; - }; - zoom.x = function(z) { - if (!arguments.length) return x1; - x1 = z; - x0 = z.copy(); - view = { - x: 0, - y: 0, - k: 1 - }; - return zoom; - }; - zoom.y = function(z) { - if (!arguments.length) return y1; - y1 = z; - y0 = z.copy(); - view = { - x: 0, - y: 0, - k: 1 - }; - return zoom; - }; - function location(p) { - return [ (p[0] - view.x) / view.k, (p[1] - view.y) / view.k ]; - } - function point(l) { - return [ l[0] * view.k + view.x, l[1] * view.k + view.y ]; - } - function scaleTo(s) { - view.k = Math.max(scaleExtent[0], Math.min(scaleExtent[1], s)); - } - function translateTo(p, l) { - l = point(l); - view.x += p[0] - l[0]; - view.y += p[1] - l[1]; - } - function zoomTo(that, p, l, k) { - that.__chart__ = { - x: view.x, - y: view.y, - k: view.k - }; - scaleTo(Math.pow(2, k)); - translateTo(center0 = p, l); - that = d3.select(that); - if (duration > 0) that = that.transition().duration(duration); - that.call(zoom.event); - } - function rescale() { - if (x1) x1.domain(x0.range().map(function(x) { - return (x - view.x) / view.k; - }).map(x0.invert)); - if (y1) y1.domain(y0.range().map(function(y) { - return (y - view.y) / view.k; - }).map(y0.invert)); - } - function zoomstarted(dispatch) { - if (!zooming++) dispatch({ - type: "zoomstart" - }); - } - function zoomed(dispatch) { - rescale(); - dispatch({ - type: "zoom", - scale: view.k, - translate: [ view.x, view.y ] - }); - } - function zoomended(dispatch) { - if (!--zooming) dispatch({ - type: "zoomend" - }), center0 = null; - } - function mousedowned() { - var that = this, dispatch = event.of(that, arguments), dragged = 0, subject = d3.select(d3_window(that)).on(mousemove, moved).on(mouseup, ended), location0 = location(d3.mouse(that)), dragRestore = d3_event_dragSuppress(that); - d3_selection_interrupt.call(that); - zoomstarted(dispatch); - function moved() { - dragged = 1; - translateTo(d3.mouse(that), location0); - zoomed(dispatch); - } - function ended() { - subject.on(mousemove, null).on(mouseup, null); - dragRestore(dragged); - zoomended(dispatch); - } - } - function touchstarted() { - var that = this, dispatch = event.of(that, arguments), locations0 = {}, distance0 = 0, scale0, zoomName = ".zoom-" + d3.event.changedTouches[0].identifier, touchmove = "touchmove" + zoomName, touchend = "touchend" + zoomName, targets = [], subject = d3.select(that), dragRestore = d3_event_dragSuppress(that); - started(); - zoomstarted(dispatch); - subject.on(mousedown, null).on(touchstart, started); - function relocate() { - var touches = d3.touches(that); - scale0 = view.k; - touches.forEach(function(t) { - if (t.identifier in locations0) locations0[t.identifier] = location(t); - }); - return touches; - } - function started() { - var target = d3.event.target; - d3.select(target).on(touchmove, moved).on(touchend, ended); - targets.push(target); - var changed = d3.event.changedTouches; - for (var i = 0, n = changed.length; i < n; ++i) { - locations0[changed[i].identifier] = null; - } - var touches = relocate(), now = Date.now(); - if (touches.length === 1) { - if (now - touchtime < 500) { - var p = touches[0]; - zoomTo(that, p, locations0[p.identifier], Math.floor(Math.log(view.k) / Math.LN2) + 1); - d3_eventPreventDefault(); - } - touchtime = now; - } else if (touches.length > 1) { - var p = touches[0], q = touches[1], dx = p[0] - q[0], dy = p[1] - q[1]; - distance0 = dx * dx + dy * dy; - } - } - function moved() { - var touches = d3.touches(that), p0, l0, p1, l1; - d3_selection_interrupt.call(that); - for (var i = 0, n = touches.length; i < n; ++i, l1 = null) { - p1 = touches[i]; - if (l1 = locations0[p1.identifier]) { - if (l0) break; - p0 = p1, l0 = l1; - } - } - if (l1) { - var distance1 = (distance1 = p1[0] - p0[0]) * distance1 + (distance1 = p1[1] - p0[1]) * distance1, scale1 = distance0 && Math.sqrt(distance1 / distance0); - p0 = [ (p0[0] + p1[0]) / 2, (p0[1] + p1[1]) / 2 ]; - l0 = [ (l0[0] + l1[0]) / 2, (l0[1] + l1[1]) / 2 ]; - scaleTo(scale1 * scale0); - } - touchtime = null; - translateTo(p0, l0); - zoomed(dispatch); - } - function ended() { - if (d3.event.touches.length) { - var changed = d3.event.changedTouches; - for (var i = 0, n = changed.length; i < n; ++i) { - delete locations0[changed[i].identifier]; - } - for (var identifier in locations0) { - return void relocate(); - } - } - d3.selectAll(targets).on(zoomName, null); - subject.on(mousedown, mousedowned).on(touchstart, touchstarted); - dragRestore(); - zoomended(dispatch); - } - } - function mousewheeled() { - var dispatch = event.of(this, arguments); - if (mousewheelTimer) clearTimeout(mousewheelTimer); else d3_selection_interrupt.call(this), - translate0 = location(center0 = center || d3.mouse(this)), zoomstarted(dispatch); - mousewheelTimer = setTimeout(function() { - mousewheelTimer = null; - zoomended(dispatch); - }, 50); - d3_eventPreventDefault(); - scaleTo(Math.pow(2, d3_behavior_zoomDelta() * .002) * view.k); - translateTo(center0, translate0); - zoomed(dispatch); - } - function dblclicked() { - var p = d3.mouse(this), k = Math.log(view.k) / Math.LN2; - zoomTo(this, p, location(p), d3.event.shiftKey ? Math.ceil(k) - 1 : Math.floor(k) + 1); - } - return d3.rebind(zoom, event, "on"); - }; - var d3_behavior_zoomInfinity = [ 0, Infinity ], d3_behavior_zoomDelta, d3_behavior_zoomWheel; - d3.color = d3_color; - function d3_color() {} - d3_color.prototype.toString = function() { - return this.rgb() + ""; - }; - d3.hsl = d3_hsl; - function d3_hsl(h, s, l) { - return this instanceof d3_hsl ? void (this.h = +h, this.s = +s, this.l = +l) : arguments.length < 2 ? h instanceof d3_hsl ? new d3_hsl(h.h, h.s, h.l) : d3_rgb_parse("" + h, d3_rgb_hsl, d3_hsl) : new d3_hsl(h, s, l); - } - var d3_hslPrototype = d3_hsl.prototype = new d3_color(); - d3_hslPrototype.brighter = function(k) { - k = Math.pow(.7, arguments.length ? k : 1); - return new d3_hsl(this.h, this.s, this.l / k); - }; - d3_hslPrototype.darker = function(k) { - k = Math.pow(.7, arguments.length ? k : 1); - return new d3_hsl(this.h, this.s, k * this.l); - }; - d3_hslPrototype.rgb = function() { - return d3_hsl_rgb(this.h, this.s, this.l); - }; - function d3_hsl_rgb(h, s, l) { - var m1, m2; - h = isNaN(h) ? 0 : (h %= 360) < 0 ? h + 360 : h; - s = isNaN(s) ? 0 : s < 0 ? 0 : s > 1 ? 1 : s; - l = l < 0 ? 0 : l > 1 ? 1 : l; - m2 = l <= .5 ? l * (1 + s) : l + s - l * s; - m1 = 2 * l - m2; - function v(h) { - if (h > 360) h -= 360; else if (h < 0) h += 360; - if (h < 60) return m1 + (m2 - m1) * h / 60; - if (h < 180) return m2; - if (h < 240) return m1 + (m2 - m1) * (240 - h) / 60; - return m1; - } - function vv(h) { - return Math.round(v(h) * 255); - } - return new d3_rgb(vv(h + 120), vv(h), vv(h - 120)); - } - d3.hcl = d3_hcl; - function d3_hcl(h, c, l) { - return this instanceof d3_hcl ? void (this.h = +h, this.c = +c, this.l = +l) : arguments.length < 2 ? h instanceof d3_hcl ? new d3_hcl(h.h, h.c, h.l) : h instanceof d3_lab ? d3_lab_hcl(h.l, h.a, h.b) : d3_lab_hcl((h = d3_rgb_lab((h = d3.rgb(h)).r, h.g, h.b)).l, h.a, h.b) : new d3_hcl(h, c, l); - } - var d3_hclPrototype = d3_hcl.prototype = new d3_color(); - d3_hclPrototype.brighter = function(k) { - return new d3_hcl(this.h, this.c, Math.min(100, this.l + d3_lab_K * (arguments.length ? k : 1))); - }; - d3_hclPrototype.darker = function(k) { - return new d3_hcl(this.h, this.c, Math.max(0, this.l - d3_lab_K * (arguments.length ? k : 1))); - }; - d3_hclPrototype.rgb = function() { - return d3_hcl_lab(this.h, this.c, this.l).rgb(); - }; - function d3_hcl_lab(h, c, l) { - if (isNaN(h)) h = 0; - if (isNaN(c)) c = 0; - return new d3_lab(l, Math.cos(h *= d3_radians) * c, Math.sin(h) * c); - } - d3.lab = d3_lab; - function d3_lab(l, a, b) { - return this instanceof d3_lab ? void (this.l = +l, this.a = +a, this.b = +b) : arguments.length < 2 ? l instanceof d3_lab ? new d3_lab(l.l, l.a, l.b) : l instanceof d3_hcl ? d3_hcl_lab(l.h, l.c, l.l) : d3_rgb_lab((l = d3_rgb(l)).r, l.g, l.b) : new d3_lab(l, a, b); - } - var d3_lab_K = 18; - var d3_lab_X = .95047, d3_lab_Y = 1, d3_lab_Z = 1.08883; - var d3_labPrototype = d3_lab.prototype = new d3_color(); - d3_labPrototype.brighter = function(k) { - return new d3_lab(Math.min(100, this.l + d3_lab_K * (arguments.length ? k : 1)), this.a, this.b); - }; - d3_labPrototype.darker = function(k) { - return new d3_lab(Math.max(0, this.l - d3_lab_K * (arguments.length ? k : 1)), this.a, this.b); - }; - d3_labPrototype.rgb = function() { - return d3_lab_rgb(this.l, this.a, this.b); - }; - function d3_lab_rgb(l, a, b) { - var y = (l + 16) / 116, x = y + a / 500, z = y - b / 200; - x = d3_lab_xyz(x) * d3_lab_X; - y = d3_lab_xyz(y) * d3_lab_Y; - z = d3_lab_xyz(z) * d3_lab_Z; - return new d3_rgb(d3_xyz_rgb(3.2404542 * x - 1.5371385 * y - .4985314 * z), d3_xyz_rgb(-.969266 * x + 1.8760108 * y + .041556 * z), d3_xyz_rgb(.0556434 * x - .2040259 * y + 1.0572252 * z)); - } - function d3_lab_hcl(l, a, b) { - return l > 0 ? new d3_hcl(Math.atan2(b, a) * d3_degrees, Math.sqrt(a * a + b * b), l) : new d3_hcl(NaN, NaN, l); - } - function d3_lab_xyz(x) { - return x > .206893034 ? x * x * x : (x - 4 / 29) / 7.787037; - } - function d3_xyz_lab(x) { - return x > .008856 ? Math.pow(x, 1 / 3) : 7.787037 * x + 4 / 29; - } - function d3_xyz_rgb(r) { - return Math.round(255 * (r <= .00304 ? 12.92 * r : 1.055 * Math.pow(r, 1 / 2.4) - .055)); - } - d3.rgb = d3_rgb; - function d3_rgb(r, g, b) { - return this instanceof d3_rgb ? void (this.r = ~~r, this.g = ~~g, this.b = ~~b) : arguments.length < 2 ? r instanceof d3_rgb ? new d3_rgb(r.r, r.g, r.b) : d3_rgb_parse("" + r, d3_rgb, d3_hsl_rgb) : new d3_rgb(r, g, b); - } - function d3_rgbNumber(value) { - return new d3_rgb(value >> 16, value >> 8 & 255, value & 255); - } - function d3_rgbString(value) { - return d3_rgbNumber(value) + ""; - } - var d3_rgbPrototype = d3_rgb.prototype = new d3_color(); - d3_rgbPrototype.brighter = function(k) { - k = Math.pow(.7, arguments.length ? k : 1); - var r = this.r, g = this.g, b = this.b, i = 30; - if (!r && !g && !b) return new d3_rgb(i, i, i); - if (r && r < i) r = i; - if (g && g < i) g = i; - if (b && b < i) b = i; - return new d3_rgb(Math.min(255, r / k), Math.min(255, g / k), Math.min(255, b / k)); - }; - d3_rgbPrototype.darker = function(k) { - k = Math.pow(.7, arguments.length ? k : 1); - return new d3_rgb(k * this.r, k * this.g, k * this.b); - }; - d3_rgbPrototype.hsl = function() { - return d3_rgb_hsl(this.r, this.g, this.b); - }; - d3_rgbPrototype.toString = function() { - return "#" + d3_rgb_hex(this.r) + d3_rgb_hex(this.g) + d3_rgb_hex(this.b); - }; - function d3_rgb_hex(v) { - return v < 16 ? "0" + Math.max(0, v).toString(16) : Math.min(255, v).toString(16); - } - function d3_rgb_parse(format, rgb, hsl) { - var r = 0, g = 0, b = 0, m1, m2, color; - m1 = /([a-z]+)\((.*)\)/.exec(format = format.toLowerCase()); - if (m1) { - m2 = m1[2].split(","); - switch (m1[1]) { - case "hsl": - { - return hsl(parseFloat(m2[0]), parseFloat(m2[1]) / 100, parseFloat(m2[2]) / 100); - } - - case "rgb": - { - return rgb(d3_rgb_parseNumber(m2[0]), d3_rgb_parseNumber(m2[1]), d3_rgb_parseNumber(m2[2])); - } - } - } - if (color = d3_rgb_names.get(format)) { - return rgb(color.r, color.g, color.b); - } - if (format != null && format.charAt(0) === "#" && !isNaN(color = parseInt(format.slice(1), 16))) { - if (format.length === 4) { - r = (color & 3840) >> 4; - r = r >> 4 | r; - g = color & 240; - g = g >> 4 | g; - b = color & 15; - b = b << 4 | b; - } else if (format.length === 7) { - r = (color & 16711680) >> 16; - g = (color & 65280) >> 8; - b = color & 255; - } - } - return rgb(r, g, b); - } - function d3_rgb_hsl(r, g, b) { - var min = Math.min(r /= 255, g /= 255, b /= 255), max = Math.max(r, g, b), d = max - min, h, s, l = (max + min) / 2; - if (d) { - s = l < .5 ? d / (max + min) : d / (2 - max - min); - if (r == max) h = (g - b) / d + (g < b ? 6 : 0); else if (g == max) h = (b - r) / d + 2; else h = (r - g) / d + 4; - h *= 60; - } else { - h = NaN; - s = l > 0 && l < 1 ? 0 : h; - } - return new d3_hsl(h, s, l); - } - function d3_rgb_lab(r, g, b) { - r = d3_rgb_xyz(r); - g = d3_rgb_xyz(g); - b = d3_rgb_xyz(b); - var x = d3_xyz_lab((.4124564 * r + .3575761 * g + .1804375 * b) / d3_lab_X), y = d3_xyz_lab((.2126729 * r + .7151522 * g + .072175 * b) / d3_lab_Y), z = d3_xyz_lab((.0193339 * r + .119192 * g + .9503041 * b) / d3_lab_Z); - return d3_lab(116 * y - 16, 500 * (x - y), 200 * (y - z)); - } - function d3_rgb_xyz(r) { - return (r /= 255) <= .04045 ? r / 12.92 : Math.pow((r + .055) / 1.055, 2.4); - } - function d3_rgb_parseNumber(c) { - var f = parseFloat(c); - return c.charAt(c.length - 1) === "%" ? Math.round(f * 2.55) : f; - } - var d3_rgb_names = d3.map({ - aliceblue: 15792383, - antiquewhite: 16444375, - aqua: 65535, - aquamarine: 8388564, - azure: 15794175, - beige: 16119260, - bisque: 16770244, - black: 0, - blanchedalmond: 16772045, - blue: 255, - blueviolet: 9055202, - brown: 10824234, - burlywood: 14596231, - cadetblue: 6266528, - chartreuse: 8388352, - chocolate: 13789470, - coral: 16744272, - cornflowerblue: 6591981, - cornsilk: 16775388, - crimson: 14423100, - cyan: 65535, - darkblue: 139, - darkcyan: 35723, - darkgoldenrod: 12092939, - darkgray: 11119017, - darkgreen: 25600, - darkgrey: 11119017, - darkkhaki: 12433259, - darkmagenta: 9109643, - darkolivegreen: 5597999, - darkorange: 16747520, - darkorchid: 10040012, - darkred: 9109504, - darksalmon: 15308410, - darkseagreen: 9419919, - darkslateblue: 4734347, - darkslategray: 3100495, - darkslategrey: 3100495, - darkturquoise: 52945, - darkviolet: 9699539, - deeppink: 16716947, - deepskyblue: 49151, - dimgray: 6908265, - dimgrey: 6908265, - dodgerblue: 2003199, - firebrick: 11674146, - floralwhite: 16775920, - forestgreen: 2263842, - fuchsia: 16711935, - gainsboro: 14474460, - ghostwhite: 16316671, - gold: 16766720, - goldenrod: 14329120, - gray: 8421504, - green: 32768, - greenyellow: 11403055, - grey: 8421504, - honeydew: 15794160, - hotpink: 16738740, - indianred: 13458524, - indigo: 4915330, - ivory: 16777200, - khaki: 15787660, - lavender: 15132410, - lavenderblush: 16773365, - lawngreen: 8190976, - lemonchiffon: 16775885, - lightblue: 11393254, - lightcoral: 15761536, - lightcyan: 14745599, - lightgoldenrodyellow: 16448210, - lightgray: 13882323, - lightgreen: 9498256, - lightgrey: 13882323, - lightpink: 16758465, - lightsalmon: 16752762, - lightseagreen: 2142890, - lightskyblue: 8900346, - lightslategray: 7833753, - lightslategrey: 7833753, - lightsteelblue: 11584734, - lightyellow: 16777184, - lime: 65280, - limegreen: 3329330, - linen: 16445670, - magenta: 16711935, - maroon: 8388608, - mediumaquamarine: 6737322, - mediumblue: 205, - mediumorchid: 12211667, - mediumpurple: 9662683, - mediumseagreen: 3978097, - mediumslateblue: 8087790, - mediumspringgreen: 64154, - mediumturquoise: 4772300, - mediumvioletred: 13047173, - midnightblue: 1644912, - mintcream: 16121850, - mistyrose: 16770273, - moccasin: 16770229, - navajowhite: 16768685, - navy: 128, - oldlace: 16643558, - olive: 8421376, - olivedrab: 7048739, - orange: 16753920, - orangered: 16729344, - orchid: 14315734, - palegoldenrod: 15657130, - palegreen: 10025880, - paleturquoise: 11529966, - palevioletred: 14381203, - papayawhip: 16773077, - peachpuff: 16767673, - peru: 13468991, - pink: 16761035, - plum: 14524637, - powderblue: 11591910, - purple: 8388736, - rebeccapurple: 6697881, - red: 16711680, - rosybrown: 12357519, - royalblue: 4286945, - saddlebrown: 9127187, - salmon: 16416882, - sandybrown: 16032864, - seagreen: 3050327, - seashell: 16774638, - sienna: 10506797, - silver: 12632256, - skyblue: 8900331, - slateblue: 6970061, - slategray: 7372944, - slategrey: 7372944, - snow: 16775930, - springgreen: 65407, - steelblue: 4620980, - tan: 13808780, - teal: 32896, - thistle: 14204888, - tomato: 16737095, - turquoise: 4251856, - violet: 15631086, - wheat: 16113331, - white: 16777215, - whitesmoke: 16119285, - yellow: 16776960, - yellowgreen: 10145074 - }); - d3_rgb_names.forEach(function(key, value) { - d3_rgb_names.set(key, d3_rgbNumber(value)); - }); - function d3_functor(v) { - return typeof v === "function" ? v : function() { - return v; - }; - } - d3.functor = d3_functor; - d3.xhr = d3_xhrType(d3_identity); - function d3_xhrType(response) { - return function(url, mimeType, callback) { - if (arguments.length === 2 && typeof mimeType === "function") callback = mimeType, - mimeType = null; - return d3_xhr(url, mimeType, response, callback); - }; - } - function d3_xhr(url, mimeType, response, callback) { - var xhr = {}, dispatch = d3.dispatch("beforesend", "progress", "load", "error"), headers = {}, request = new XMLHttpRequest(), responseType = null; - if (this.XDomainRequest && !("withCredentials" in request) && /^(http(s)?:)?\/\//.test(url)) request = new XDomainRequest(); - "onload" in request ? request.onload = request.onerror = respond : request.onreadystatechange = function() { - request.readyState > 3 && respond(); - }; - function respond() { - var status = request.status, result; - if (!status && d3_xhrHasResponse(request) || status >= 200 && status < 300 || status === 304) { - try { - result = response.call(xhr, request); - } catch (e) { - dispatch.error.call(xhr, e); - return; - } - dispatch.load.call(xhr, result); - } else { - dispatch.error.call(xhr, request); - } - } - request.onprogress = function(event) { - var o = d3.event; - d3.event = event; - try { - dispatch.progress.call(xhr, request); - } finally { - d3.event = o; - } - }; - xhr.header = function(name, value) { - name = (name + "").toLowerCase(); - if (arguments.length < 2) return headers[name]; - if (value == null) delete headers[name]; else headers[name] = value + ""; - return xhr; - }; - xhr.mimeType = function(value) { - if (!arguments.length) return mimeType; - mimeType = value == null ? null : value + ""; - return xhr; - }; - xhr.responseType = function(value) { - if (!arguments.length) return responseType; - responseType = value; - return xhr; - }; - xhr.response = function(value) { - response = value; - return xhr; - }; - [ "get", "post" ].forEach(function(method) { - xhr[method] = function() { - return xhr.send.apply(xhr, [ method ].concat(d3_array(arguments))); - }; - }); - xhr.send = function(method, data, callback) { - if (arguments.length === 2 && typeof data === "function") callback = data, data = null; - request.open(method, url, true); - if (mimeType != null && !("accept" in headers)) headers["accept"] = mimeType + ",*/*"; - if (request.setRequestHeader) for (var name in headers) request.setRequestHeader(name, headers[name]); - if (mimeType != null && request.overrideMimeType) request.overrideMimeType(mimeType); - if (responseType != null) request.responseType = responseType; - if (callback != null) xhr.on("error", callback).on("load", function(request) { - callback(null, request); - }); - dispatch.beforesend.call(xhr, request); - request.send(data == null ? null : data); - return xhr; - }; - xhr.abort = function() { - request.abort(); - return xhr; - }; - d3.rebind(xhr, dispatch, "on"); - return callback == null ? xhr : xhr.get(d3_xhr_fixCallback(callback)); - } - function d3_xhr_fixCallback(callback) { - return callback.length === 1 ? function(error, request) { - callback(error == null ? request : null); - } : callback; - } - function d3_xhrHasResponse(request) { - var type = request.responseType; - return type && type !== "text" ? request.response : request.responseText; - } - d3.dsv = function(delimiter, mimeType) { - var reFormat = new RegExp('["' + delimiter + "\n]"), delimiterCode = delimiter.charCodeAt(0); - function dsv(url, row, callback) { - if (arguments.length < 3) callback = row, row = null; - var xhr = d3_xhr(url, mimeType, row == null ? response : typedResponse(row), callback); - xhr.row = function(_) { - return arguments.length ? xhr.response((row = _) == null ? response : typedResponse(_)) : row; - }; - return xhr; - } - function response(request) { - return dsv.parse(request.responseText); - } - function typedResponse(f) { - return function(request) { - return dsv.parse(request.responseText, f); - }; - } - dsv.parse = function(text, f) { - var o; - return dsv.parseRows(text, function(row, i) { - if (o) return o(row, i - 1); - var a = new Function("d", "return {" + row.map(function(name, i) { - return JSON.stringify(name) + ": d[" + i + "]"; - }).join(",") + "}"); - o = f ? function(row, i) { - return f(a(row), i); - } : a; - }); - }; - dsv.parseRows = function(text, f) { - var EOL = {}, EOF = {}, rows = [], N = text.length, I = 0, n = 0, t, eol; - function token() { - if (I >= N) return EOF; - if (eol) return eol = false, EOL; - var j = I; - if (text.charCodeAt(j) === 34) { - var i = j; - while (i++ < N) { - if (text.charCodeAt(i) === 34) { - if (text.charCodeAt(i + 1) !== 34) break; - ++i; - } - } - I = i + 2; - var c = text.charCodeAt(i + 1); - if (c === 13) { - eol = true; - if (text.charCodeAt(i + 2) === 10) ++I; - } else if (c === 10) { - eol = true; - } - return text.slice(j + 1, i).replace(/""/g, '"'); - } - while (I < N) { - var c = text.charCodeAt(I++), k = 1; - if (c === 10) eol = true; else if (c === 13) { - eol = true; - if (text.charCodeAt(I) === 10) ++I, ++k; - } else if (c !== delimiterCode) continue; - return text.slice(j, I - k); - } - return text.slice(j); - } - while ((t = token()) !== EOF) { - var a = []; - while (t !== EOL && t !== EOF) { - a.push(t); - t = token(); - } - if (f && (a = f(a, n++)) == null) continue; - rows.push(a); - } - return rows; - }; - dsv.format = function(rows) { - if (Array.isArray(rows[0])) return dsv.formatRows(rows); - var fieldSet = new d3_Set(), fields = []; - rows.forEach(function(row) { - for (var field in row) { - if (!fieldSet.has(field)) { - fields.push(fieldSet.add(field)); - } - } - }); - return [ fields.map(formatValue).join(delimiter) ].concat(rows.map(function(row) { - return fields.map(function(field) { - return formatValue(row[field]); - }).join(delimiter); - })).join("\n"); - }; - dsv.formatRows = function(rows) { - return rows.map(formatRow).join("\n"); - }; - function formatRow(row) { - return row.map(formatValue).join(delimiter); - } - function formatValue(text) { - return reFormat.test(text) ? '"' + text.replace(/\"/g, '""') + '"' : text; - } - return dsv; - }; - d3.csv = d3.dsv(",", "text/csv"); - d3.tsv = d3.dsv(" ", "text/tab-separated-values"); - var d3_timer_queueHead, d3_timer_queueTail, d3_timer_interval, d3_timer_timeout, d3_timer_frame = this[d3_vendorSymbol(this, "requestAnimationFrame")] || function(callback) { - setTimeout(callback, 17); - }; - d3.timer = function() { - d3_timer.apply(this, arguments); - }; - function d3_timer(callback, delay, then) { - var n = arguments.length; - if (n < 2) delay = 0; - if (n < 3) then = Date.now(); - var time = then + delay, timer = { - c: callback, - t: time, - n: null - }; - if (d3_timer_queueTail) d3_timer_queueTail.n = timer; else d3_timer_queueHead = timer; - d3_timer_queueTail = timer; - if (!d3_timer_interval) { - d3_timer_timeout = clearTimeout(d3_timer_timeout); - d3_timer_interval = 1; - d3_timer_frame(d3_timer_step); - } - return timer; - } - function d3_timer_step() { - var now = d3_timer_mark(), delay = d3_timer_sweep() - now; - if (delay > 24) { - if (isFinite(delay)) { - clearTimeout(d3_timer_timeout); - d3_timer_timeout = setTimeout(d3_timer_step, delay); - } - d3_timer_interval = 0; - } else { - d3_timer_interval = 1; - d3_timer_frame(d3_timer_step); - } - } - d3.timer.flush = function() { - d3_timer_mark(); - d3_timer_sweep(); - }; - function d3_timer_mark() { - var now = Date.now(), timer = d3_timer_queueHead; - while (timer) { - if (now >= timer.t && timer.c(now - timer.t)) timer.c = null; - timer = timer.n; - } - return now; - } - function d3_timer_sweep() { - var t0, t1 = d3_timer_queueHead, time = Infinity; - while (t1) { - if (t1.c) { - if (t1.t < time) time = t1.t; - t1 = (t0 = t1).n; - } else { - t1 = t0 ? t0.n = t1.n : d3_timer_queueHead = t1.n; - } - } - d3_timer_queueTail = t0; - return time; - } - function d3_format_precision(x, p) { - return p - (x ? Math.ceil(Math.log(x) / Math.LN10) : 1); - } - d3.round = function(x, n) { - return n ? Math.round(x * (n = Math.pow(10, n))) / n : Math.round(x); - }; - var d3_formatPrefixes = [ "y", "z", "a", "f", "p", "n", "µ", "m", "", "k", "M", "G", "T", "P", "E", "Z", "Y" ].map(d3_formatPrefix); - d3.formatPrefix = function(value, precision) { - var i = 0; - if (value = +value) { - if (value < 0) value *= -1; - if (precision) value = d3.round(value, d3_format_precision(value, precision)); - i = 1 + Math.floor(1e-12 + Math.log(value) / Math.LN10); - i = Math.max(-24, Math.min(24, Math.floor((i - 1) / 3) * 3)); - } - return d3_formatPrefixes[8 + i / 3]; - }; - function d3_formatPrefix(d, i) { - var k = Math.pow(10, abs(8 - i) * 3); - return { - scale: i > 8 ? function(d) { - return d / k; - } : function(d) { - return d * k; - }, - symbol: d - }; - } - function d3_locale_numberFormat(locale) { - var locale_decimal = locale.decimal, locale_thousands = locale.thousands, locale_grouping = locale.grouping, locale_currency = locale.currency, formatGroup = locale_grouping && locale_thousands ? function(value, width) { - var i = value.length, t = [], j = 0, g = locale_grouping[0], length = 0; - while (i > 0 && g > 0) { - if (length + g + 1 > width) g = Math.max(1, width - length); - t.push(value.substring(i -= g, i + g)); - if ((length += g + 1) > width) break; - g = locale_grouping[j = (j + 1) % locale_grouping.length]; - } - return t.reverse().join(locale_thousands); - } : d3_identity; - return function(specifier) { - var match = d3_format_re.exec(specifier), fill = match[1] || " ", align = match[2] || ">", sign = match[3] || "-", symbol = match[4] || "", zfill = match[5], width = +match[6], comma = match[7], precision = match[8], type = match[9], scale = 1, prefix = "", suffix = "", integer = false, exponent = true; - if (precision) precision = +precision.substring(1); - if (zfill || fill === "0" && align === "=") { - zfill = fill = "0"; - align = "="; - } - switch (type) { - case "n": - comma = true; - type = "g"; - break; - - case "%": - scale = 100; - suffix = "%"; - type = "f"; - break; - - case "p": - scale = 100; - suffix = "%"; - type = "r"; - break; - - case "b": - case "o": - case "x": - case "X": - if (symbol === "#") prefix = "0" + type.toLowerCase(); - - case "c": - exponent = false; - - case "d": - integer = true; - precision = 0; - break; - - case "s": - scale = -1; - type = "r"; - break; - } - if (symbol === "$") prefix = locale_currency[0], suffix = locale_currency[1]; - if (type == "r" && !precision) type = "g"; - if (precision != null) { - if (type == "g") precision = Math.max(1, Math.min(21, precision)); else if (type == "e" || type == "f") precision = Math.max(0, Math.min(20, precision)); - } - type = d3_format_types.get(type) || d3_format_typeDefault; - var zcomma = zfill && comma; - return function(value) { - var fullSuffix = suffix; - if (integer && value % 1) return ""; - var negative = value < 0 || value === 0 && 1 / value < 0 ? (value = -value, "-") : sign === "-" ? "" : sign; - if (scale < 0) { - var unit = d3.formatPrefix(value, precision); - value = unit.scale(value); - fullSuffix = unit.symbol + suffix; - } else { - value *= scale; - } - value = type(value, precision); - var i = value.lastIndexOf("."), before, after; - if (i < 0) { - var j = exponent ? value.lastIndexOf("e") : -1; - if (j < 0) before = value, after = ""; else before = value.substring(0, j), after = value.substring(j); - } else { - before = value.substring(0, i); - after = locale_decimal + value.substring(i + 1); - } - if (!zfill && comma) before = formatGroup(before, Infinity); - var length = prefix.length + before.length + after.length + (zcomma ? 0 : negative.length), padding = length < width ? new Array(length = width - length + 1).join(fill) : ""; - if (zcomma) before = formatGroup(padding + before, padding.length ? width - after.length : Infinity); - negative += prefix; - value = before + after; - return (align === "<" ? negative + value + padding : align === ">" ? padding + negative + value : align === "^" ? padding.substring(0, length >>= 1) + negative + value + padding.substring(length) : negative + (zcomma ? value : padding + value)) + fullSuffix; - }; - }; - } - var d3_format_re = /(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i; - var d3_format_types = d3.map({ - b: function(x) { - return x.toString(2); - }, - c: function(x) { - return String.fromCharCode(x); - }, - o: function(x) { - return x.toString(8); - }, - x: function(x) { - return x.toString(16); - }, - X: function(x) { - return x.toString(16).toUpperCase(); - }, - g: function(x, p) { - return x.toPrecision(p); - }, - e: function(x, p) { - return x.toExponential(p); - }, - f: function(x, p) { - return x.toFixed(p); - }, - r: function(x, p) { - return (x = d3.round(x, d3_format_precision(x, p))).toFixed(Math.max(0, Math.min(20, d3_format_precision(x * (1 + 1e-15), p)))); - } - }); - function d3_format_typeDefault(x) { - return x + ""; - } - var d3_time = d3.time = {}, d3_date = Date; - function d3_date_utc() { - this._ = new Date(arguments.length > 1 ? Date.UTC.apply(this, arguments) : arguments[0]); - } - d3_date_utc.prototype = { - getDate: function() { - return this._.getUTCDate(); - }, - getDay: function() { - return this._.getUTCDay(); - }, - getFullYear: function() { - return this._.getUTCFullYear(); - }, - getHours: function() { - return this._.getUTCHours(); - }, - getMilliseconds: function() { - return this._.getUTCMilliseconds(); - }, - getMinutes: function() { - return this._.getUTCMinutes(); - }, - getMonth: function() { - return this._.getUTCMonth(); - }, - getSeconds: function() { - return this._.getUTCSeconds(); - }, - getTime: function() { - return this._.getTime(); - }, - getTimezoneOffset: function() { - return 0; - }, - valueOf: function() { - return this._.valueOf(); - }, - setDate: function() { - d3_time_prototype.setUTCDate.apply(this._, arguments); - }, - setDay: function() { - d3_time_prototype.setUTCDay.apply(this._, arguments); - }, - setFullYear: function() { - d3_time_prototype.setUTCFullYear.apply(this._, arguments); - }, - setHours: function() { - d3_time_prototype.setUTCHours.apply(this._, arguments); - }, - setMilliseconds: function() { - d3_time_prototype.setUTCMilliseconds.apply(this._, arguments); - }, - setMinutes: function() { - d3_time_prototype.setUTCMinutes.apply(this._, arguments); - }, - setMonth: function() { - d3_time_prototype.setUTCMonth.apply(this._, arguments); - }, - setSeconds: function() { - d3_time_prototype.setUTCSeconds.apply(this._, arguments); - }, - setTime: function() { - d3_time_prototype.setTime.apply(this._, arguments); - } - }; - var d3_time_prototype = Date.prototype; - function d3_time_interval(local, step, number) { - function round(date) { - var d0 = local(date), d1 = offset(d0, 1); - return date - d0 < d1 - date ? d0 : d1; - } - function ceil(date) { - step(date = local(new d3_date(date - 1)), 1); - return date; - } - function offset(date, k) { - step(date = new d3_date(+date), k); - return date; - } - function range(t0, t1, dt) { - var time = ceil(t0), times = []; - if (dt > 1) { - while (time < t1) { - if (!(number(time) % dt)) times.push(new Date(+time)); - step(time, 1); - } - } else { - while (time < t1) times.push(new Date(+time)), step(time, 1); - } - return times; - } - function range_utc(t0, t1, dt) { - try { - d3_date = d3_date_utc; - var utc = new d3_date_utc(); - utc._ = t0; - return range(utc, t1, dt); - } finally { - d3_date = Date; - } - } - local.floor = local; - local.round = round; - local.ceil = ceil; - local.offset = offset; - local.range = range; - var utc = local.utc = d3_time_interval_utc(local); - utc.floor = utc; - utc.round = d3_time_interval_utc(round); - utc.ceil = d3_time_interval_utc(ceil); - utc.offset = d3_time_interval_utc(offset); - utc.range = range_utc; - return local; - } - function d3_time_interval_utc(method) { - return function(date, k) { - try { - d3_date = d3_date_utc; - var utc = new d3_date_utc(); - utc._ = date; - return method(utc, k)._; - } finally { - d3_date = Date; - } - }; - } - d3_time.year = d3_time_interval(function(date) { - date = d3_time.day(date); - date.setMonth(0, 1); - return date; - }, function(date, offset) { - date.setFullYear(date.getFullYear() + offset); - }, function(date) { - return date.getFullYear(); - }); - d3_time.years = d3_time.year.range; - d3_time.years.utc = d3_time.year.utc.range; - d3_time.day = d3_time_interval(function(date) { - var day = new d3_date(2e3, 0); - day.setFullYear(date.getFullYear(), date.getMonth(), date.getDate()); - return day; - }, function(date, offset) { - date.setDate(date.getDate() + offset); - }, function(date) { - return date.getDate() - 1; - }); - d3_time.days = d3_time.day.range; - d3_time.days.utc = d3_time.day.utc.range; - d3_time.dayOfYear = function(date) { - var year = d3_time.year(date); - return Math.floor((date - year - (date.getTimezoneOffset() - year.getTimezoneOffset()) * 6e4) / 864e5); - }; - [ "sunday", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday" ].forEach(function(day, i) { - i = 7 - i; - var interval = d3_time[day] = d3_time_interval(function(date) { - (date = d3_time.day(date)).setDate(date.getDate() - (date.getDay() + i) % 7); - return date; - }, function(date, offset) { - date.setDate(date.getDate() + Math.floor(offset) * 7); - }, function(date) { - var day = d3_time.year(date).getDay(); - return Math.floor((d3_time.dayOfYear(date) + (day + i) % 7) / 7) - (day !== i); - }); - d3_time[day + "s"] = interval.range; - d3_time[day + "s"].utc = interval.utc.range; - d3_time[day + "OfYear"] = function(date) { - var day = d3_time.year(date).getDay(); - return Math.floor((d3_time.dayOfYear(date) + (day + i) % 7) / 7); - }; - }); - d3_time.week = d3_time.sunday; - d3_time.weeks = d3_time.sunday.range; - d3_time.weeks.utc = d3_time.sunday.utc.range; - d3_time.weekOfYear = d3_time.sundayOfYear; - function d3_locale_timeFormat(locale) { - var locale_dateTime = locale.dateTime, locale_date = locale.date, locale_time = locale.time, locale_periods = locale.periods, locale_days = locale.days, locale_shortDays = locale.shortDays, locale_months = locale.months, locale_shortMonths = locale.shortMonths; - function d3_time_format(template) { - var n = template.length; - function format(date) { - var string = [], i = -1, j = 0, c, p, f; - while (++i < n) { - if (template.charCodeAt(i) === 37) { - string.push(template.slice(j, i)); - if ((p = d3_time_formatPads[c = template.charAt(++i)]) != null) c = template.charAt(++i); - if (f = d3_time_formats[c]) c = f(date, p == null ? c === "e" ? " " : "0" : p); - string.push(c); - j = i + 1; - } - } - string.push(template.slice(j, i)); - return string.join(""); - } - format.parse = function(string) { - var d = { - y: 1900, - m: 0, - d: 1, - H: 0, - M: 0, - S: 0, - L: 0, - Z: null - }, i = d3_time_parse(d, template, string, 0); - if (i != string.length) return null; - if ("p" in d) d.H = d.H % 12 + d.p * 12; - var localZ = d.Z != null && d3_date !== d3_date_utc, date = new (localZ ? d3_date_utc : d3_date)(); - if ("j" in d) date.setFullYear(d.y, 0, d.j); else if ("W" in d || "U" in d) { - if (!("w" in d)) d.w = "W" in d ? 1 : 0; - date.setFullYear(d.y, 0, 1); - date.setFullYear(d.y, 0, "W" in d ? (d.w + 6) % 7 + d.W * 7 - (date.getDay() + 5) % 7 : d.w + d.U * 7 - (date.getDay() + 6) % 7); - } else date.setFullYear(d.y, d.m, d.d); - date.setHours(d.H + (d.Z / 100 | 0), d.M + d.Z % 100, d.S, d.L); - return localZ ? date._ : date; - }; - format.toString = function() { - return template; - }; - return format; - } - function d3_time_parse(date, template, string, j) { - var c, p, t, i = 0, n = template.length, m = string.length; - while (i < n) { - if (j >= m) return -1; - c = template.charCodeAt(i++); - if (c === 37) { - t = template.charAt(i++); - p = d3_time_parsers[t in d3_time_formatPads ? template.charAt(i++) : t]; - if (!p || (j = p(date, string, j)) < 0) return -1; - } else if (c != string.charCodeAt(j++)) { - return -1; - } - } - return j; - } - d3_time_format.utc = function(template) { - var local = d3_time_format(template); - function format(date) { - try { - d3_date = d3_date_utc; - var utc = new d3_date(); - utc._ = date; - return local(utc); - } finally { - d3_date = Date; - } - } - format.parse = function(string) { - try { - d3_date = d3_date_utc; - var date = local.parse(string); - return date && date._; - } finally { - d3_date = Date; - } - }; - format.toString = local.toString; - return format; - }; - d3_time_format.multi = d3_time_format.utc.multi = d3_time_formatMulti; - var d3_time_periodLookup = d3.map(), d3_time_dayRe = d3_time_formatRe(locale_days), d3_time_dayLookup = d3_time_formatLookup(locale_days), d3_time_dayAbbrevRe = d3_time_formatRe(locale_shortDays), d3_time_dayAbbrevLookup = d3_time_formatLookup(locale_shortDays), d3_time_monthRe = d3_time_formatRe(locale_months), d3_time_monthLookup = d3_time_formatLookup(locale_months), d3_time_monthAbbrevRe = d3_time_formatRe(locale_shortMonths), d3_time_monthAbbrevLookup = d3_time_formatLookup(locale_shortMonths); - locale_periods.forEach(function(p, i) { - d3_time_periodLookup.set(p.toLowerCase(), i); - }); - var d3_time_formats = { - a: function(d) { - return locale_shortDays[d.getDay()]; - }, - A: function(d) { - return locale_days[d.getDay()]; - }, - b: function(d) { - return locale_shortMonths[d.getMonth()]; - }, - B: function(d) { - return locale_months[d.getMonth()]; - }, - c: d3_time_format(locale_dateTime), - d: function(d, p) { - return d3_time_formatPad(d.getDate(), p, 2); - }, - e: function(d, p) { - return d3_time_formatPad(d.getDate(), p, 2); - }, - H: function(d, p) { - return d3_time_formatPad(d.getHours(), p, 2); - }, - I: function(d, p) { - return d3_time_formatPad(d.getHours() % 12 || 12, p, 2); - }, - j: function(d, p) { - return d3_time_formatPad(1 + d3_time.dayOfYear(d), p, 3); - }, - L: function(d, p) { - return d3_time_formatPad(d.getMilliseconds(), p, 3); - }, - m: function(d, p) { - return d3_time_formatPad(d.getMonth() + 1, p, 2); - }, - M: function(d, p) { - return d3_time_formatPad(d.getMinutes(), p, 2); - }, - p: function(d) { - return locale_periods[+(d.getHours() >= 12)]; - }, - S: function(d, p) { - return d3_time_formatPad(d.getSeconds(), p, 2); - }, - U: function(d, p) { - return d3_time_formatPad(d3_time.sundayOfYear(d), p, 2); - }, - w: function(d) { - return d.getDay(); - }, - W: function(d, p) { - return d3_time_formatPad(d3_time.mondayOfYear(d), p, 2); - }, - x: d3_time_format(locale_date), - X: d3_time_format(locale_time), - y: function(d, p) { - return d3_time_formatPad(d.getFullYear() % 100, p, 2); - }, - Y: function(d, p) { - return d3_time_formatPad(d.getFullYear() % 1e4, p, 4); - }, - Z: d3_time_zone, - "%": function() { - return "%"; - } - }; - var d3_time_parsers = { - a: d3_time_parseWeekdayAbbrev, - A: d3_time_parseWeekday, - b: d3_time_parseMonthAbbrev, - B: d3_time_parseMonth, - c: d3_time_parseLocaleFull, - d: d3_time_parseDay, - e: d3_time_parseDay, - H: d3_time_parseHour24, - I: d3_time_parseHour24, - j: d3_time_parseDayOfYear, - L: d3_time_parseMilliseconds, - m: d3_time_parseMonthNumber, - M: d3_time_parseMinutes, - p: d3_time_parseAmPm, - S: d3_time_parseSeconds, - U: d3_time_parseWeekNumberSunday, - w: d3_time_parseWeekdayNumber, - W: d3_time_parseWeekNumberMonday, - x: d3_time_parseLocaleDate, - X: d3_time_parseLocaleTime, - y: d3_time_parseYear, - Y: d3_time_parseFullYear, - Z: d3_time_parseZone, - "%": d3_time_parseLiteralPercent - }; - function d3_time_parseWeekdayAbbrev(date, string, i) { - d3_time_dayAbbrevRe.lastIndex = 0; - var n = d3_time_dayAbbrevRe.exec(string.slice(i)); - return n ? (date.w = d3_time_dayAbbrevLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; - } - function d3_time_parseWeekday(date, string, i) { - d3_time_dayRe.lastIndex = 0; - var n = d3_time_dayRe.exec(string.slice(i)); - return n ? (date.w = d3_time_dayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; - } - function d3_time_parseMonthAbbrev(date, string, i) { - d3_time_monthAbbrevRe.lastIndex = 0; - var n = d3_time_monthAbbrevRe.exec(string.slice(i)); - return n ? (date.m = d3_time_monthAbbrevLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; - } - function d3_time_parseMonth(date, string, i) { - d3_time_monthRe.lastIndex = 0; - var n = d3_time_monthRe.exec(string.slice(i)); - return n ? (date.m = d3_time_monthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; - } - function d3_time_parseLocaleFull(date, string, i) { - return d3_time_parse(date, d3_time_formats.c.toString(), string, i); - } - function d3_time_parseLocaleDate(date, string, i) { - return d3_time_parse(date, d3_time_formats.x.toString(), string, i); - } - function d3_time_parseLocaleTime(date, string, i) { - return d3_time_parse(date, d3_time_formats.X.toString(), string, i); - } - function d3_time_parseAmPm(date, string, i) { - var n = d3_time_periodLookup.get(string.slice(i, i += 2).toLowerCase()); - return n == null ? -1 : (date.p = n, i); - } - return d3_time_format; - } - var d3_time_formatPads = { - "-": "", - _: " ", - "0": "0" - }, d3_time_numberRe = /^\s*\d+/, d3_time_percentRe = /^%/; - function d3_time_formatPad(value, fill, width) { - var sign = value < 0 ? "-" : "", string = (sign ? -value : value) + "", length = string.length; - return sign + (length < width ? new Array(width - length + 1).join(fill) + string : string); - } - function d3_time_formatRe(names) { - return new RegExp("^(?:" + names.map(d3.requote).join("|") + ")", "i"); - } - function d3_time_formatLookup(names) { - var map = new d3_Map(), i = -1, n = names.length; - while (++i < n) map.set(names[i].toLowerCase(), i); - return map; - } - function d3_time_parseWeekdayNumber(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 1)); - return n ? (date.w = +n[0], i + n[0].length) : -1; - } - function d3_time_parseWeekNumberSunday(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i)); - return n ? (date.U = +n[0], i + n[0].length) : -1; - } - function d3_time_parseWeekNumberMonday(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i)); - return n ? (date.W = +n[0], i + n[0].length) : -1; - } - function d3_time_parseFullYear(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 4)); - return n ? (date.y = +n[0], i + n[0].length) : -1; - } - function d3_time_parseYear(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.y = d3_time_expandYear(+n[0]), i + n[0].length) : -1; - } - function d3_time_parseZone(date, string, i) { - return /^[+-]\d{4}$/.test(string = string.slice(i, i + 5)) ? (date.Z = -string, - i + 5) : -1; - } - function d3_time_expandYear(d) { - return d + (d > 68 ? 1900 : 2e3); - } - function d3_time_parseMonthNumber(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.m = n[0] - 1, i + n[0].length) : -1; - } - function d3_time_parseDay(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.d = +n[0], i + n[0].length) : -1; - } - function d3_time_parseDayOfYear(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 3)); - return n ? (date.j = +n[0], i + n[0].length) : -1; - } - function d3_time_parseHour24(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.H = +n[0], i + n[0].length) : -1; - } - function d3_time_parseMinutes(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.M = +n[0], i + n[0].length) : -1; - } - function d3_time_parseSeconds(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 2)); - return n ? (date.S = +n[0], i + n[0].length) : -1; - } - function d3_time_parseMilliseconds(date, string, i) { - d3_time_numberRe.lastIndex = 0; - var n = d3_time_numberRe.exec(string.slice(i, i + 3)); - return n ? (date.L = +n[0], i + n[0].length) : -1; - } - function d3_time_zone(d) { - var z = d.getTimezoneOffset(), zs = z > 0 ? "-" : "+", zh = abs(z) / 60 | 0, zm = abs(z) % 60; - return zs + d3_time_formatPad(zh, "0", 2) + d3_time_formatPad(zm, "0", 2); - } - function d3_time_parseLiteralPercent(date, string, i) { - d3_time_percentRe.lastIndex = 0; - var n = d3_time_percentRe.exec(string.slice(i, i + 1)); - return n ? i + n[0].length : -1; - } - function d3_time_formatMulti(formats) { - var n = formats.length, i = -1; - while (++i < n) formats[i][0] = this(formats[i][0]); - return function(date) { - var i = 0, f = formats[i]; - while (!f[1](date)) f = formats[++i]; - return f[0](date); - }; - } - d3.locale = function(locale) { - return { - numberFormat: d3_locale_numberFormat(locale), - timeFormat: d3_locale_timeFormat(locale) - }; - }; - var d3_locale_enUS = d3.locale({ - decimal: ".", - thousands: ",", - grouping: [ 3 ], - currency: [ "$", "" ], - dateTime: "%a %b %e %X %Y", - date: "%m/%d/%Y", - time: "%H:%M:%S", - periods: [ "AM", "PM" ], - days: [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], - shortDays: [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], - months: [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ], - shortMonths: [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ] - }); - d3.format = d3_locale_enUS.numberFormat; - d3.geo = {}; - function d3_adder() {} - d3_adder.prototype = { - s: 0, - t: 0, - add: function(y) { - d3_adderSum(y, this.t, d3_adderTemp); - d3_adderSum(d3_adderTemp.s, this.s, this); - if (this.s) this.t += d3_adderTemp.t; else this.s = d3_adderTemp.t; - }, - reset: function() { - this.s = this.t = 0; - }, - valueOf: function() { - return this.s; - } - }; - var d3_adderTemp = new d3_adder(); - function d3_adderSum(a, b, o) { - var x = o.s = a + b, bv = x - a, av = x - bv; - o.t = a - av + (b - bv); - } - d3.geo.stream = function(object, listener) { - if (object && d3_geo_streamObjectType.hasOwnProperty(object.type)) { - d3_geo_streamObjectType[object.type](object, listener); - } else { - d3_geo_streamGeometry(object, listener); - } - }; - function d3_geo_streamGeometry(geometry, listener) { - if (geometry && d3_geo_streamGeometryType.hasOwnProperty(geometry.type)) { - d3_geo_streamGeometryType[geometry.type](geometry, listener); - } - } - var d3_geo_streamObjectType = { - Feature: function(feature, listener) { - d3_geo_streamGeometry(feature.geometry, listener); - }, - FeatureCollection: function(object, listener) { - var features = object.features, i = -1, n = features.length; - while (++i < n) d3_geo_streamGeometry(features[i].geometry, listener); - } - }; - var d3_geo_streamGeometryType = { - Sphere: function(object, listener) { - listener.sphere(); - }, - Point: function(object, listener) { - object = object.coordinates; - listener.point(object[0], object[1], object[2]); - }, - MultiPoint: function(object, listener) { - var coordinates = object.coordinates, i = -1, n = coordinates.length; - while (++i < n) object = coordinates[i], listener.point(object[0], object[1], object[2]); - }, - LineString: function(object, listener) { - d3_geo_streamLine(object.coordinates, listener, 0); - }, - MultiLineString: function(object, listener) { - var coordinates = object.coordinates, i = -1, n = coordinates.length; - while (++i < n) d3_geo_streamLine(coordinates[i], listener, 0); - }, - Polygon: function(object, listener) { - d3_geo_streamPolygon(object.coordinates, listener); - }, - MultiPolygon: function(object, listener) { - var coordinates = object.coordinates, i = -1, n = coordinates.length; - while (++i < n) d3_geo_streamPolygon(coordinates[i], listener); - }, - GeometryCollection: function(object, listener) { - var geometries = object.geometries, i = -1, n = geometries.length; - while (++i < n) d3_geo_streamGeometry(geometries[i], listener); - } - }; - function d3_geo_streamLine(coordinates, listener, closed) { - var i = -1, n = coordinates.length - closed, coordinate; - listener.lineStart(); - while (++i < n) coordinate = coordinates[i], listener.point(coordinate[0], coordinate[1], coordinate[2]); - listener.lineEnd(); - } - function d3_geo_streamPolygon(coordinates, listener) { - var i = -1, n = coordinates.length; - listener.polygonStart(); - while (++i < n) d3_geo_streamLine(coordinates[i], listener, 1); - listener.polygonEnd(); - } - d3.geo.area = function(object) { - d3_geo_areaSum = 0; - d3.geo.stream(object, d3_geo_area); - return d3_geo_areaSum; - }; - var d3_geo_areaSum, d3_geo_areaRingSum = new d3_adder(); - var d3_geo_area = { - sphere: function() { - d3_geo_areaSum += 4 * π; - }, - point: d3_noop, - lineStart: d3_noop, - lineEnd: d3_noop, - polygonStart: function() { - d3_geo_areaRingSum.reset(); - d3_geo_area.lineStart = d3_geo_areaRingStart; - }, - polygonEnd: function() { - var area = 2 * d3_geo_areaRingSum; - d3_geo_areaSum += area < 0 ? 4 * π + area : area; - d3_geo_area.lineStart = d3_geo_area.lineEnd = d3_geo_area.point = d3_noop; - } - }; - function d3_geo_areaRingStart() { - var λ00, φ00, λ0, cosφ0, sinφ0; - d3_geo_area.point = function(λ, φ) { - d3_geo_area.point = nextPoint; - λ0 = (λ00 = λ) * d3_radians, cosφ0 = Math.cos(φ = (φ00 = φ) * d3_radians / 2 + π / 4), - sinφ0 = Math.sin(φ); - }; - function nextPoint(λ, φ) { - λ *= d3_radians; - φ = φ * d3_radians / 2 + π / 4; - var dλ = λ - λ0, sdλ = dλ >= 0 ? 1 : -1, adλ = sdλ * dλ, cosφ = Math.cos(φ), sinφ = Math.sin(φ), k = sinφ0 * sinφ, u = cosφ0 * cosφ + k * Math.cos(adλ), v = k * sdλ * Math.sin(adλ); - d3_geo_areaRingSum.add(Math.atan2(v, u)); - λ0 = λ, cosφ0 = cosφ, sinφ0 = sinφ; - } - d3_geo_area.lineEnd = function() { - nextPoint(λ00, φ00); - }; - } - function d3_geo_cartesian(spherical) { - var λ = spherical[0], φ = spherical[1], cosφ = Math.cos(φ); - return [ cosφ * Math.cos(λ), cosφ * Math.sin(λ), Math.sin(φ) ]; - } - function d3_geo_cartesianDot(a, b) { - return a[0] * b[0] + a[1] * b[1] + a[2] * b[2]; - } - function d3_geo_cartesianCross(a, b) { - return [ a[1] * b[2] - a[2] * b[1], a[2] * b[0] - a[0] * b[2], a[0] * b[1] - a[1] * b[0] ]; - } - function d3_geo_cartesianAdd(a, b) { - a[0] += b[0]; - a[1] += b[1]; - a[2] += b[2]; - } - function d3_geo_cartesianScale(vector, k) { - return [ vector[0] * k, vector[1] * k, vector[2] * k ]; - } - function d3_geo_cartesianNormalize(d) { - var l = Math.sqrt(d[0] * d[0] + d[1] * d[1] + d[2] * d[2]); - d[0] /= l; - d[1] /= l; - d[2] /= l; - } - function d3_geo_spherical(cartesian) { - return [ Math.atan2(cartesian[1], cartesian[0]), d3_asin(cartesian[2]) ]; - } - function d3_geo_sphericalEqual(a, b) { - return abs(a[0] - b[0]) < ε && abs(a[1] - b[1]) < ε; - } - d3.geo.bounds = function() { - var λ0, φ0, λ1, φ1, λ_, λ__, φ__, p0, dλSum, ranges, range; - var bound = { - point: point, - lineStart: lineStart, - lineEnd: lineEnd, - polygonStart: function() { - bound.point = ringPoint; - bound.lineStart = ringStart; - bound.lineEnd = ringEnd; - dλSum = 0; - d3_geo_area.polygonStart(); - }, - polygonEnd: function() { - d3_geo_area.polygonEnd(); - bound.point = point; - bound.lineStart = lineStart; - bound.lineEnd = lineEnd; - if (d3_geo_areaRingSum < 0) λ0 = -(λ1 = 180), φ0 = -(φ1 = 90); else if (dλSum > ε) φ1 = 90; else if (dλSum < -ε) φ0 = -90; - range[0] = λ0, range[1] = λ1; - } - }; - function point(λ, φ) { - ranges.push(range = [ λ0 = λ, λ1 = λ ]); - if (φ < φ0) φ0 = φ; - if (φ > φ1) φ1 = φ; - } - function linePoint(λ, φ) { - var p = d3_geo_cartesian([ λ * d3_radians, φ * d3_radians ]); - if (p0) { - var normal = d3_geo_cartesianCross(p0, p), equatorial = [ normal[1], -normal[0], 0 ], inflection = d3_geo_cartesianCross(equatorial, normal); - d3_geo_cartesianNormalize(inflection); - inflection = d3_geo_spherical(inflection); - var dλ = λ - λ_, s = dλ > 0 ? 1 : -1, λi = inflection[0] * d3_degrees * s, antimeridian = abs(dλ) > 180; - if (antimeridian ^ (s * λ_ < λi && λi < s * λ)) { - var φi = inflection[1] * d3_degrees; - if (φi > φ1) φ1 = φi; - } else if (λi = (λi + 360) % 360 - 180, antimeridian ^ (s * λ_ < λi && λi < s * λ)) { - var φi = -inflection[1] * d3_degrees; - if (φi < φ0) φ0 = φi; - } else { - if (φ < φ0) φ0 = φ; - if (φ > φ1) φ1 = φ; - } - if (antimeridian) { - if (λ < λ_) { - if (angle(λ0, λ) > angle(λ0, λ1)) λ1 = λ; - } else { - if (angle(λ, λ1) > angle(λ0, λ1)) λ0 = λ; - } - } else { - if (λ1 >= λ0) { - if (λ < λ0) λ0 = λ; - if (λ > λ1) λ1 = λ; - } else { - if (λ > λ_) { - if (angle(λ0, λ) > angle(λ0, λ1)) λ1 = λ; - } else { - if (angle(λ, λ1) > angle(λ0, λ1)) λ0 = λ; - } - } - } - } else { - point(λ, φ); - } - p0 = p, λ_ = λ; - } - function lineStart() { - bound.point = linePoint; - } - function lineEnd() { - range[0] = λ0, range[1] = λ1; - bound.point = point; - p0 = null; - } - function ringPoint(λ, φ) { - if (p0) { - var dλ = λ - λ_; - dλSum += abs(dλ) > 180 ? dλ + (dλ > 0 ? 360 : -360) : dλ; - } else λ__ = λ, φ__ = φ; - d3_geo_area.point(λ, φ); - linePoint(λ, φ); - } - function ringStart() { - d3_geo_area.lineStart(); - } - function ringEnd() { - ringPoint(λ__, φ__); - d3_geo_area.lineEnd(); - if (abs(dλSum) > ε) λ0 = -(λ1 = 180); - range[0] = λ0, range[1] = λ1; - p0 = null; - } - function angle(λ0, λ1) { - return (λ1 -= λ0) < 0 ? λ1 + 360 : λ1; - } - function compareRanges(a, b) { - return a[0] - b[0]; - } - function withinRange(x, range) { - return range[0] <= range[1] ? range[0] <= x && x <= range[1] : x < range[0] || range[1] < x; - } - return function(feature) { - φ1 = λ1 = -(λ0 = φ0 = Infinity); - ranges = []; - d3.geo.stream(feature, bound); - var n = ranges.length; - if (n) { - ranges.sort(compareRanges); - for (var i = 1, a = ranges[0], b, merged = [ a ]; i < n; ++i) { - b = ranges[i]; - if (withinRange(b[0], a) || withinRange(b[1], a)) { - if (angle(a[0], b[1]) > angle(a[0], a[1])) a[1] = b[1]; - if (angle(b[0], a[1]) > angle(a[0], a[1])) a[0] = b[0]; - } else { - merged.push(a = b); - } - } - var best = -Infinity, dλ; - for (var n = merged.length - 1, i = 0, a = merged[n], b; i <= n; a = b, ++i) { - b = merged[i]; - if ((dλ = angle(a[1], b[0])) > best) best = dλ, λ0 = b[0], λ1 = a[1]; - } - } - ranges = range = null; - return λ0 === Infinity || φ0 === Infinity ? [ [ NaN, NaN ], [ NaN, NaN ] ] : [ [ λ0, φ0 ], [ λ1, φ1 ] ]; - }; - }(); - d3.geo.centroid = function(object) { - d3_geo_centroidW0 = d3_geo_centroidW1 = d3_geo_centroidX0 = d3_geo_centroidY0 = d3_geo_centroidZ0 = d3_geo_centroidX1 = d3_geo_centroidY1 = d3_geo_centroidZ1 = d3_geo_centroidX2 = d3_geo_centroidY2 = d3_geo_centroidZ2 = 0; - d3.geo.stream(object, d3_geo_centroid); - var x = d3_geo_centroidX2, y = d3_geo_centroidY2, z = d3_geo_centroidZ2, m = x * x + y * y + z * z; - if (m < ε2) { - x = d3_geo_centroidX1, y = d3_geo_centroidY1, z = d3_geo_centroidZ1; - if (d3_geo_centroidW1 < ε) x = d3_geo_centroidX0, y = d3_geo_centroidY0, z = d3_geo_centroidZ0; - m = x * x + y * y + z * z; - if (m < ε2) return [ NaN, NaN ]; - } - return [ Math.atan2(y, x) * d3_degrees, d3_asin(z / Math.sqrt(m)) * d3_degrees ]; - }; - var d3_geo_centroidW0, d3_geo_centroidW1, d3_geo_centroidX0, d3_geo_centroidY0, d3_geo_centroidZ0, d3_geo_centroidX1, d3_geo_centroidY1, d3_geo_centroidZ1, d3_geo_centroidX2, d3_geo_centroidY2, d3_geo_centroidZ2; - var d3_geo_centroid = { - sphere: d3_noop, - point: d3_geo_centroidPoint, - lineStart: d3_geo_centroidLineStart, - lineEnd: d3_geo_centroidLineEnd, - polygonStart: function() { - d3_geo_centroid.lineStart = d3_geo_centroidRingStart; - }, - polygonEnd: function() { - d3_geo_centroid.lineStart = d3_geo_centroidLineStart; - } - }; - function d3_geo_centroidPoint(λ, φ) { - λ *= d3_radians; - var cosφ = Math.cos(φ *= d3_radians); - d3_geo_centroidPointXYZ(cosφ * Math.cos(λ), cosφ * Math.sin(λ), Math.sin(φ)); - } - function d3_geo_centroidPointXYZ(x, y, z) { - ++d3_geo_centroidW0; - d3_geo_centroidX0 += (x - d3_geo_centroidX0) / d3_geo_centroidW0; - d3_geo_centroidY0 += (y - d3_geo_centroidY0) / d3_geo_centroidW0; - d3_geo_centroidZ0 += (z - d3_geo_centroidZ0) / d3_geo_centroidW0; - } - function d3_geo_centroidLineStart() { - var x0, y0, z0; - d3_geo_centroid.point = function(λ, φ) { - λ *= d3_radians; - var cosφ = Math.cos(φ *= d3_radians); - x0 = cosφ * Math.cos(λ); - y0 = cosφ * Math.sin(λ); - z0 = Math.sin(φ); - d3_geo_centroid.point = nextPoint; - d3_geo_centroidPointXYZ(x0, y0, z0); - }; - function nextPoint(λ, φ) { - λ *= d3_radians; - var cosφ = Math.cos(φ *= d3_radians), x = cosφ * Math.cos(λ), y = cosφ * Math.sin(λ), z = Math.sin(φ), w = Math.atan2(Math.sqrt((w = y0 * z - z0 * y) * w + (w = z0 * x - x0 * z) * w + (w = x0 * y - y0 * x) * w), x0 * x + y0 * y + z0 * z); - d3_geo_centroidW1 += w; - d3_geo_centroidX1 += w * (x0 + (x0 = x)); - d3_geo_centroidY1 += w * (y0 + (y0 = y)); - d3_geo_centroidZ1 += w * (z0 + (z0 = z)); - d3_geo_centroidPointXYZ(x0, y0, z0); - } - } - function d3_geo_centroidLineEnd() { - d3_geo_centroid.point = d3_geo_centroidPoint; - } - function d3_geo_centroidRingStart() { - var λ00, φ00, x0, y0, z0; - d3_geo_centroid.point = function(λ, φ) { - λ00 = λ, φ00 = φ; - d3_geo_centroid.point = nextPoint; - λ *= d3_radians; - var cosφ = Math.cos(φ *= d3_radians); - x0 = cosφ * Math.cos(λ); - y0 = cosφ * Math.sin(λ); - z0 = Math.sin(φ); - d3_geo_centroidPointXYZ(x0, y0, z0); - }; - d3_geo_centroid.lineEnd = function() { - nextPoint(λ00, φ00); - d3_geo_centroid.lineEnd = d3_geo_centroidLineEnd; - d3_geo_centroid.point = d3_geo_centroidPoint; - }; - function nextPoint(λ, φ) { - λ *= d3_radians; - var cosφ = Math.cos(φ *= d3_radians), x = cosφ * Math.cos(λ), y = cosφ * Math.sin(λ), z = Math.sin(φ), cx = y0 * z - z0 * y, cy = z0 * x - x0 * z, cz = x0 * y - y0 * x, m = Math.sqrt(cx * cx + cy * cy + cz * cz), u = x0 * x + y0 * y + z0 * z, v = m && -d3_acos(u) / m, w = Math.atan2(m, u); - d3_geo_centroidX2 += v * cx; - d3_geo_centroidY2 += v * cy; - d3_geo_centroidZ2 += v * cz; - d3_geo_centroidW1 += w; - d3_geo_centroidX1 += w * (x0 + (x0 = x)); - d3_geo_centroidY1 += w * (y0 + (y0 = y)); - d3_geo_centroidZ1 += w * (z0 + (z0 = z)); - d3_geo_centroidPointXYZ(x0, y0, z0); - } - } - function d3_geo_compose(a, b) { - function compose(x, y) { - return x = a(x, y), b(x[0], x[1]); - } - if (a.invert && b.invert) compose.invert = function(x, y) { - return x = b.invert(x, y), x && a.invert(x[0], x[1]); - }; - return compose; - } - function d3_true() { - return true; - } - function d3_geo_clipPolygon(segments, compare, clipStartInside, interpolate, listener) { - var subject = [], clip = []; - segments.forEach(function(segment) { - if ((n = segment.length - 1) <= 0) return; - var n, p0 = segment[0], p1 = segment[n]; - if (d3_geo_sphericalEqual(p0, p1)) { - listener.lineStart(); - for (var i = 0; i < n; ++i) listener.point((p0 = segment[i])[0], p0[1]); - listener.lineEnd(); - return; - } - var a = new d3_geo_clipPolygonIntersection(p0, segment, null, true), b = new d3_geo_clipPolygonIntersection(p0, null, a, false); - a.o = b; - subject.push(a); - clip.push(b); - a = new d3_geo_clipPolygonIntersection(p1, segment, null, false); - b = new d3_geo_clipPolygonIntersection(p1, null, a, true); - a.o = b; - subject.push(a); - clip.push(b); - }); - clip.sort(compare); - d3_geo_clipPolygonLinkCircular(subject); - d3_geo_clipPolygonLinkCircular(clip); - if (!subject.length) return; - for (var i = 0, entry = clipStartInside, n = clip.length; i < n; ++i) { - clip[i].e = entry = !entry; - } - var start = subject[0], points, point; - while (1) { - var current = start, isSubject = true; - while (current.v) if ((current = current.n) === start) return; - points = current.z; - listener.lineStart(); - do { - current.v = current.o.v = true; - if (current.e) { - if (isSubject) { - for (var i = 0, n = points.length; i < n; ++i) listener.point((point = points[i])[0], point[1]); - } else { - interpolate(current.x, current.n.x, 1, listener); - } - current = current.n; - } else { - if (isSubject) { - points = current.p.z; - for (var i = points.length - 1; i >= 0; --i) listener.point((point = points[i])[0], point[1]); - } else { - interpolate(current.x, current.p.x, -1, listener); - } - current = current.p; - } - current = current.o; - points = current.z; - isSubject = !isSubject; - } while (!current.v); - listener.lineEnd(); - } - } - function d3_geo_clipPolygonLinkCircular(array) { - if (!(n = array.length)) return; - var n, i = 0, a = array[0], b; - while (++i < n) { - a.n = b = array[i]; - b.p = a; - a = b; - } - a.n = b = array[0]; - b.p = a; - } - function d3_geo_clipPolygonIntersection(point, points, other, entry) { - this.x = point; - this.z = points; - this.o = other; - this.e = entry; - this.v = false; - this.n = this.p = null; - } - function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { - return function(rotate, listener) { - var line = clipLine(listener), rotatedClipStart = rotate.invert(clipStart[0], clipStart[1]); - var clip = { - point: point, - lineStart: lineStart, - lineEnd: lineEnd, - polygonStart: function() { - clip.point = pointRing; - clip.lineStart = ringStart; - clip.lineEnd = ringEnd; - segments = []; - polygon = []; - }, - polygonEnd: function() { - clip.point = point; - clip.lineStart = lineStart; - clip.lineEnd = lineEnd; - segments = d3.merge(segments); - var clipStartInside = d3_geo_pointInPolygon(rotatedClipStart, polygon); - if (segments.length) { - if (!polygonStarted) listener.polygonStart(), polygonStarted = true; - d3_geo_clipPolygon(segments, d3_geo_clipSort, clipStartInside, interpolate, listener); - } else if (clipStartInside) { - if (!polygonStarted) listener.polygonStart(), polygonStarted = true; - listener.lineStart(); - interpolate(null, null, 1, listener); - listener.lineEnd(); - } - if (polygonStarted) listener.polygonEnd(), polygonStarted = false; - segments = polygon = null; - }, - sphere: function() { - listener.polygonStart(); - listener.lineStart(); - interpolate(null, null, 1, listener); - listener.lineEnd(); - listener.polygonEnd(); - } - }; - function point(λ, φ) { - var point = rotate(λ, φ); - if (pointVisible(λ = point[0], φ = point[1])) listener.point(λ, φ); - } - function pointLine(λ, φ) { - var point = rotate(λ, φ); - line.point(point[0], point[1]); - } - function lineStart() { - clip.point = pointLine; - line.lineStart(); - } - function lineEnd() { - clip.point = point; - line.lineEnd(); - } - var segments; - var buffer = d3_geo_clipBufferListener(), ringListener = clipLine(buffer), polygonStarted = false, polygon, ring; - function pointRing(λ, φ) { - ring.push([ λ, φ ]); - var point = rotate(λ, φ); - ringListener.point(point[0], point[1]); - } - function ringStart() { - ringListener.lineStart(); - ring = []; - } - function ringEnd() { - pointRing(ring[0][0], ring[0][1]); - ringListener.lineEnd(); - var clean = ringListener.clean(), ringSegments = buffer.buffer(), segment, n = ringSegments.length; - ring.pop(); - polygon.push(ring); - ring = null; - if (!n) return; - if (clean & 1) { - segment = ringSegments[0]; - var n = segment.length - 1, i = -1, point; - if (n > 0) { - if (!polygonStarted) listener.polygonStart(), polygonStarted = true; - listener.lineStart(); - while (++i < n) listener.point((point = segment[i])[0], point[1]); - listener.lineEnd(); - } - return; - } - if (n > 1 && clean & 2) ringSegments.push(ringSegments.pop().concat(ringSegments.shift())); - segments.push(ringSegments.filter(d3_geo_clipSegmentLength1)); - } - return clip; - }; - } - function d3_geo_clipSegmentLength1(segment) { - return segment.length > 1; - } - function d3_geo_clipBufferListener() { - var lines = [], line; - return { - lineStart: function() { - lines.push(line = []); - }, - point: function(λ, φ) { - line.push([ λ, φ ]); - }, - lineEnd: d3_noop, - buffer: function() { - var buffer = lines; - lines = []; - line = null; - return buffer; - }, - rejoin: function() { - if (lines.length > 1) lines.push(lines.pop().concat(lines.shift())); - } - }; - } - function d3_geo_clipSort(a, b) { - return ((a = a.x)[0] < 0 ? a[1] - halfπ - ε : halfπ - a[1]) - ((b = b.x)[0] < 0 ? b[1] - halfπ - ε : halfπ - b[1]); - } - var d3_geo_clipAntimeridian = d3_geo_clip(d3_true, d3_geo_clipAntimeridianLine, d3_geo_clipAntimeridianInterpolate, [ -π, -π / 2 ]); - function d3_geo_clipAntimeridianLine(listener) { - var λ0 = NaN, φ0 = NaN, sλ0 = NaN, clean; - return { - lineStart: function() { - listener.lineStart(); - clean = 1; - }, - point: function(λ1, φ1) { - var sλ1 = λ1 > 0 ? π : -π, dλ = abs(λ1 - λ0); - if (abs(dλ - π) < ε) { - listener.point(λ0, φ0 = (φ0 + φ1) / 2 > 0 ? halfπ : -halfπ); - listener.point(sλ0, φ0); - listener.lineEnd(); - listener.lineStart(); - listener.point(sλ1, φ0); - listener.point(λ1, φ0); - clean = 0; - } else if (sλ0 !== sλ1 && dλ >= π) { - if (abs(λ0 - sλ0) < ε) λ0 -= sλ0 * ε; - if (abs(λ1 - sλ1) < ε) λ1 -= sλ1 * ε; - φ0 = d3_geo_clipAntimeridianIntersect(λ0, φ0, λ1, φ1); - listener.point(sλ0, φ0); - listener.lineEnd(); - listener.lineStart(); - listener.point(sλ1, φ0); - clean = 0; - } - listener.point(λ0 = λ1, φ0 = φ1); - sλ0 = sλ1; - }, - lineEnd: function() { - listener.lineEnd(); - λ0 = φ0 = NaN; - }, - clean: function() { - return 2 - clean; - } - }; - } - function d3_geo_clipAntimeridianIntersect(λ0, φ0, λ1, φ1) { - var cosφ0, cosφ1, sinλ0_λ1 = Math.sin(λ0 - λ1); - return abs(sinλ0_λ1) > ε ? Math.atan((Math.sin(φ0) * (cosφ1 = Math.cos(φ1)) * Math.sin(λ1) - Math.sin(φ1) * (cosφ0 = Math.cos(φ0)) * Math.sin(λ0)) / (cosφ0 * cosφ1 * sinλ0_λ1)) : (φ0 + φ1) / 2; - } - function d3_geo_clipAntimeridianInterpolate(from, to, direction, listener) { - var φ; - if (from == null) { - φ = direction * halfπ; - listener.point(-π, φ); - listener.point(0, φ); - listener.point(π, φ); - listener.point(π, 0); - listener.point(π, -φ); - listener.point(0, -φ); - listener.point(-π, -φ); - listener.point(-π, 0); - listener.point(-π, φ); - } else if (abs(from[0] - to[0]) > ε) { - var s = from[0] < to[0] ? π : -π; - φ = direction * s / 2; - listener.point(-s, φ); - listener.point(0, φ); - listener.point(s, φ); - } else { - listener.point(to[0], to[1]); - } - } - function d3_geo_pointInPolygon(point, polygon) { - var meridian = point[0], parallel = point[1], meridianNormal = [ Math.sin(meridian), -Math.cos(meridian), 0 ], polarAngle = 0, winding = 0; - d3_geo_areaRingSum.reset(); - for (var i = 0, n = polygon.length; i < n; ++i) { - var ring = polygon[i], m = ring.length; - if (!m) continue; - var point0 = ring[0], λ0 = point0[0], φ0 = point0[1] / 2 + π / 4, sinφ0 = Math.sin(φ0), cosφ0 = Math.cos(φ0), j = 1; - while (true) { - if (j === m) j = 0; - point = ring[j]; - var λ = point[0], φ = point[1] / 2 + π / 4, sinφ = Math.sin(φ), cosφ = Math.cos(φ), dλ = λ - λ0, sdλ = dλ >= 0 ? 1 : -1, adλ = sdλ * dλ, antimeridian = adλ > π, k = sinφ0 * sinφ; - d3_geo_areaRingSum.add(Math.atan2(k * sdλ * Math.sin(adλ), cosφ0 * cosφ + k * Math.cos(adλ))); - polarAngle += antimeridian ? dλ + sdλ * τ : dλ; - if (antimeridian ^ λ0 >= meridian ^ λ >= meridian) { - var arc = d3_geo_cartesianCross(d3_geo_cartesian(point0), d3_geo_cartesian(point)); - d3_geo_cartesianNormalize(arc); - var intersection = d3_geo_cartesianCross(meridianNormal, arc); - d3_geo_cartesianNormalize(intersection); - var φarc = (antimeridian ^ dλ >= 0 ? -1 : 1) * d3_asin(intersection[2]); - if (parallel > φarc || parallel === φarc && (arc[0] || arc[1])) { - winding += antimeridian ^ dλ >= 0 ? 1 : -1; - } - } - if (!j++) break; - λ0 = λ, sinφ0 = sinφ, cosφ0 = cosφ, point0 = point; - } - } - return (polarAngle < -ε || polarAngle < ε && d3_geo_areaRingSum < -ε) ^ winding & 1; - } - function d3_geo_clipCircle(radius) { - var cr = Math.cos(radius), smallRadius = cr > 0, notHemisphere = abs(cr) > ε, interpolate = d3_geo_circleInterpolate(radius, 6 * d3_radians); - return d3_geo_clip(visible, clipLine, interpolate, smallRadius ? [ 0, -radius ] : [ -π, radius - π ]); - function visible(λ, φ) { - return Math.cos(λ) * Math.cos(φ) > cr; - } - function clipLine(listener) { - var point0, c0, v0, v00, clean; - return { - lineStart: function() { - v00 = v0 = false; - clean = 1; - }, - point: function(λ, φ) { - var point1 = [ λ, φ ], point2, v = visible(λ, φ), c = smallRadius ? v ? 0 : code(λ, φ) : v ? code(λ + (λ < 0 ? π : -π), φ) : 0; - if (!point0 && (v00 = v0 = v)) listener.lineStart(); - if (v !== v0) { - point2 = intersect(point0, point1); - if (d3_geo_sphericalEqual(point0, point2) || d3_geo_sphericalEqual(point1, point2)) { - point1[0] += ε; - point1[1] += ε; - v = visible(point1[0], point1[1]); - } - } - if (v !== v0) { - clean = 0; - if (v) { - listener.lineStart(); - point2 = intersect(point1, point0); - listener.point(point2[0], point2[1]); - } else { - point2 = intersect(point0, point1); - listener.point(point2[0], point2[1]); - listener.lineEnd(); - } - point0 = point2; - } else if (notHemisphere && point0 && smallRadius ^ v) { - var t; - if (!(c & c0) && (t = intersect(point1, point0, true))) { - clean = 0; - if (smallRadius) { - listener.lineStart(); - listener.point(t[0][0], t[0][1]); - listener.point(t[1][0], t[1][1]); - listener.lineEnd(); - } else { - listener.point(t[1][0], t[1][1]); - listener.lineEnd(); - listener.lineStart(); - listener.point(t[0][0], t[0][1]); - } - } - } - if (v && (!point0 || !d3_geo_sphericalEqual(point0, point1))) { - listener.point(point1[0], point1[1]); - } - point0 = point1, v0 = v, c0 = c; - }, - lineEnd: function() { - if (v0) listener.lineEnd(); - point0 = null; - }, - clean: function() { - return clean | (v00 && v0) << 1; - } - }; - } - function intersect(a, b, two) { - var pa = d3_geo_cartesian(a), pb = d3_geo_cartesian(b); - var n1 = [ 1, 0, 0 ], n2 = d3_geo_cartesianCross(pa, pb), n2n2 = d3_geo_cartesianDot(n2, n2), n1n2 = n2[0], determinant = n2n2 - n1n2 * n1n2; - if (!determinant) return !two && a; - var c1 = cr * n2n2 / determinant, c2 = -cr * n1n2 / determinant, n1xn2 = d3_geo_cartesianCross(n1, n2), A = d3_geo_cartesianScale(n1, c1), B = d3_geo_cartesianScale(n2, c2); - d3_geo_cartesianAdd(A, B); - var u = n1xn2, w = d3_geo_cartesianDot(A, u), uu = d3_geo_cartesianDot(u, u), t2 = w * w - uu * (d3_geo_cartesianDot(A, A) - 1); - if (t2 < 0) return; - var t = Math.sqrt(t2), q = d3_geo_cartesianScale(u, (-w - t) / uu); - d3_geo_cartesianAdd(q, A); - q = d3_geo_spherical(q); - if (!two) return q; - var λ0 = a[0], λ1 = b[0], φ0 = a[1], φ1 = b[1], z; - if (λ1 < λ0) z = λ0, λ0 = λ1, λ1 = z; - var δλ = λ1 - λ0, polar = abs(δλ - π) < ε, meridian = polar || δλ < ε; - if (!polar && φ1 < φ0) z = φ0, φ0 = φ1, φ1 = z; - if (meridian ? polar ? φ0 + φ1 > 0 ^ q[1] < (abs(q[0] - λ0) < ε ? φ0 : φ1) : φ0 <= q[1] && q[1] <= φ1 : δλ > π ^ (λ0 <= q[0] && q[0] <= λ1)) { - var q1 = d3_geo_cartesianScale(u, (-w + t) / uu); - d3_geo_cartesianAdd(q1, A); - return [ q, d3_geo_spherical(q1) ]; - } - } - function code(λ, φ) { - var r = smallRadius ? radius : π - radius, code = 0; - if (λ < -r) code |= 1; else if (λ > r) code |= 2; - if (φ < -r) code |= 4; else if (φ > r) code |= 8; - return code; - } - } - function d3_geom_clipLine(x0, y0, x1, y1) { - return function(line) { - var a = line.a, b = line.b, ax = a.x, ay = a.y, bx = b.x, by = b.y, t0 = 0, t1 = 1, dx = bx - ax, dy = by - ay, r; - r = x0 - ax; - if (!dx && r > 0) return; - r /= dx; - if (dx < 0) { - if (r < t0) return; - if (r < t1) t1 = r; - } else if (dx > 0) { - if (r > t1) return; - if (r > t0) t0 = r; - } - r = x1 - ax; - if (!dx && r < 0) return; - r /= dx; - if (dx < 0) { - if (r > t1) return; - if (r > t0) t0 = r; - } else if (dx > 0) { - if (r < t0) return; - if (r < t1) t1 = r; - } - r = y0 - ay; - if (!dy && r > 0) return; - r /= dy; - if (dy < 0) { - if (r < t0) return; - if (r < t1) t1 = r; - } else if (dy > 0) { - if (r > t1) return; - if (r > t0) t0 = r; - } - r = y1 - ay; - if (!dy && r < 0) return; - r /= dy; - if (dy < 0) { - if (r > t1) return; - if (r > t0) t0 = r; - } else if (dy > 0) { - if (r < t0) return; - if (r < t1) t1 = r; - } - if (t0 > 0) line.a = { - x: ax + t0 * dx, - y: ay + t0 * dy - }; - if (t1 < 1) line.b = { - x: ax + t1 * dx, - y: ay + t1 * dy - }; - return line; - }; - } - var d3_geo_clipExtentMAX = 1e9; - d3.geo.clipExtent = function() { - var x0, y0, x1, y1, stream, clip, clipExtent = { - stream: function(output) { - if (stream) stream.valid = false; - stream = clip(output); - stream.valid = true; - return stream; - }, - extent: function(_) { - if (!arguments.length) return [ [ x0, y0 ], [ x1, y1 ] ]; - clip = d3_geo_clipExtent(x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1]); - if (stream) stream.valid = false, stream = null; - return clipExtent; - } - }; - return clipExtent.extent([ [ 0, 0 ], [ 960, 500 ] ]); - }; - function d3_geo_clipExtent(x0, y0, x1, y1) { - return function(listener) { - var listener_ = listener, bufferListener = d3_geo_clipBufferListener(), clipLine = d3_geom_clipLine(x0, y0, x1, y1), segments, polygon, ring; - var clip = { - point: point, - lineStart: lineStart, - lineEnd: lineEnd, - polygonStart: function() { - listener = bufferListener; - segments = []; - polygon = []; - clean = true; - }, - polygonEnd: function() { - listener = listener_; - segments = d3.merge(segments); - var clipStartInside = insidePolygon([ x0, y1 ]), inside = clean && clipStartInside, visible = segments.length; - if (inside || visible) { - listener.polygonStart(); - if (inside) { - listener.lineStart(); - interpolate(null, null, 1, listener); - listener.lineEnd(); - } - if (visible) { - d3_geo_clipPolygon(segments, compare, clipStartInside, interpolate, listener); - } - listener.polygonEnd(); - } - segments = polygon = ring = null; - } - }; - function insidePolygon(p) { - var wn = 0, n = polygon.length, y = p[1]; - for (var i = 0; i < n; ++i) { - for (var j = 1, v = polygon[i], m = v.length, a = v[0], b; j < m; ++j) { - b = v[j]; - if (a[1] <= y) { - if (b[1] > y && d3_cross2d(a, b, p) > 0) ++wn; - } else { - if (b[1] <= y && d3_cross2d(a, b, p) < 0) --wn; - } - a = b; - } - } - return wn !== 0; - } - function interpolate(from, to, direction, listener) { - var a = 0, a1 = 0; - if (from == null || (a = corner(from, direction)) !== (a1 = corner(to, direction)) || comparePoints(from, to) < 0 ^ direction > 0) { - do { - listener.point(a === 0 || a === 3 ? x0 : x1, a > 1 ? y1 : y0); - } while ((a = (a + direction + 4) % 4) !== a1); - } else { - listener.point(to[0], to[1]); - } - } - function pointVisible(x, y) { - return x0 <= x && x <= x1 && y0 <= y && y <= y1; - } - function point(x, y) { - if (pointVisible(x, y)) listener.point(x, y); - } - var x__, y__, v__, x_, y_, v_, first, clean; - function lineStart() { - clip.point = linePoint; - if (polygon) polygon.push(ring = []); - first = true; - v_ = false; - x_ = y_ = NaN; - } - function lineEnd() { - if (segments) { - linePoint(x__, y__); - if (v__ && v_) bufferListener.rejoin(); - segments.push(bufferListener.buffer()); - } - clip.point = point; - if (v_) listener.lineEnd(); - } - function linePoint(x, y) { - x = Math.max(-d3_geo_clipExtentMAX, Math.min(d3_geo_clipExtentMAX, x)); - y = Math.max(-d3_geo_clipExtentMAX, Math.min(d3_geo_clipExtentMAX, y)); - var v = pointVisible(x, y); - if (polygon) ring.push([ x, y ]); - if (first) { - x__ = x, y__ = y, v__ = v; - first = false; - if (v) { - listener.lineStart(); - listener.point(x, y); - } - } else { - if (v && v_) listener.point(x, y); else { - var l = { - a: { - x: x_, - y: y_ - }, - b: { - x: x, - y: y - } - }; - if (clipLine(l)) { - if (!v_) { - listener.lineStart(); - listener.point(l.a.x, l.a.y); - } - listener.point(l.b.x, l.b.y); - if (!v) listener.lineEnd(); - clean = false; - } else if (v) { - listener.lineStart(); - listener.point(x, y); - clean = false; - } - } - } - x_ = x, y_ = y, v_ = v; - } - return clip; - }; - function corner(p, direction) { - return abs(p[0] - x0) < ε ? direction > 0 ? 0 : 3 : abs(p[0] - x1) < ε ? direction > 0 ? 2 : 1 : abs(p[1] - y0) < ε ? direction > 0 ? 1 : 0 : direction > 0 ? 3 : 2; - } - function compare(a, b) { - return comparePoints(a.x, b.x); - } - function comparePoints(a, b) { - var ca = corner(a, 1), cb = corner(b, 1); - return ca !== cb ? ca - cb : ca === 0 ? b[1] - a[1] : ca === 1 ? a[0] - b[0] : ca === 2 ? a[1] - b[1] : b[0] - a[0]; - } - } - function d3_geo_conic(projectAt) { - var φ0 = 0, φ1 = π / 3, m = d3_geo_projectionMutator(projectAt), p = m(φ0, φ1); - p.parallels = function(_) { - if (!arguments.length) return [ φ0 / π * 180, φ1 / π * 180 ]; - return m(φ0 = _[0] * π / 180, φ1 = _[1] * π / 180); - }; - return p; - } - function d3_geo_conicEqualArea(φ0, φ1) { - var sinφ0 = Math.sin(φ0), n = (sinφ0 + Math.sin(φ1)) / 2, C = 1 + sinφ0 * (2 * n - sinφ0), ρ0 = Math.sqrt(C) / n; - function forward(λ, φ) { - var ρ = Math.sqrt(C - 2 * n * Math.sin(φ)) / n; - return [ ρ * Math.sin(λ *= n), ρ0 - ρ * Math.cos(λ) ]; - } - forward.invert = function(x, y) { - var ρ0_y = ρ0 - y; - return [ Math.atan2(x, ρ0_y) / n, d3_asin((C - (x * x + ρ0_y * ρ0_y) * n * n) / (2 * n)) ]; - }; - return forward; - } - (d3.geo.conicEqualArea = function() { - return d3_geo_conic(d3_geo_conicEqualArea); - }).raw = d3_geo_conicEqualArea; - d3.geo.albers = function() { - return d3.geo.conicEqualArea().rotate([ 96, 0 ]).center([ -.6, 38.7 ]).parallels([ 29.5, 45.5 ]).scale(1070); - }; - d3.geo.albersUsa = function() { - var lower48 = d3.geo.albers(); - var alaska = d3.geo.conicEqualArea().rotate([ 154, 0 ]).center([ -2, 58.5 ]).parallels([ 55, 65 ]); - var hawaii = d3.geo.conicEqualArea().rotate([ 157, 0 ]).center([ -3, 19.9 ]).parallels([ 8, 18 ]); - var point, pointStream = { - point: function(x, y) { - point = [ x, y ]; - } - }, lower48Point, alaskaPoint, hawaiiPoint; - function albersUsa(coordinates) { - var x = coordinates[0], y = coordinates[1]; - point = null; - (lower48Point(x, y), point) || (alaskaPoint(x, y), point) || hawaiiPoint(x, y); - return point; - } - albersUsa.invert = function(coordinates) { - var k = lower48.scale(), t = lower48.translate(), x = (coordinates[0] - t[0]) / k, y = (coordinates[1] - t[1]) / k; - return (y >= .12 && y < .234 && x >= -.425 && x < -.214 ? alaska : y >= .166 && y < .234 && x >= -.214 && x < -.115 ? hawaii : lower48).invert(coordinates); - }; - albersUsa.stream = function(stream) { - var lower48Stream = lower48.stream(stream), alaskaStream = alaska.stream(stream), hawaiiStream = hawaii.stream(stream); - return { - point: function(x, y) { - lower48Stream.point(x, y); - alaskaStream.point(x, y); - hawaiiStream.point(x, y); - }, - sphere: function() { - lower48Stream.sphere(); - alaskaStream.sphere(); - hawaiiStream.sphere(); - }, - lineStart: function() { - lower48Stream.lineStart(); - alaskaStream.lineStart(); - hawaiiStream.lineStart(); - }, - lineEnd: function() { - lower48Stream.lineEnd(); - alaskaStream.lineEnd(); - hawaiiStream.lineEnd(); - }, - polygonStart: function() { - lower48Stream.polygonStart(); - alaskaStream.polygonStart(); - hawaiiStream.polygonStart(); - }, - polygonEnd: function() { - lower48Stream.polygonEnd(); - alaskaStream.polygonEnd(); - hawaiiStream.polygonEnd(); - } - }; - }; - albersUsa.precision = function(_) { - if (!arguments.length) return lower48.precision(); - lower48.precision(_); - alaska.precision(_); - hawaii.precision(_); - return albersUsa; - }; - albersUsa.scale = function(_) { - if (!arguments.length) return lower48.scale(); - lower48.scale(_); - alaska.scale(_ * .35); - hawaii.scale(_); - return albersUsa.translate(lower48.translate()); - }; - albersUsa.translate = function(_) { - if (!arguments.length) return lower48.translate(); - var k = lower48.scale(), x = +_[0], y = +_[1]; - lower48Point = lower48.translate(_).clipExtent([ [ x - .455 * k, y - .238 * k ], [ x + .455 * k, y + .238 * k ] ]).stream(pointStream).point; - alaskaPoint = alaska.translate([ x - .307 * k, y + .201 * k ]).clipExtent([ [ x - .425 * k + ε, y + .12 * k + ε ], [ x - .214 * k - ε, y + .234 * k - ε ] ]).stream(pointStream).point; - hawaiiPoint = hawaii.translate([ x - .205 * k, y + .212 * k ]).clipExtent([ [ x - .214 * k + ε, y + .166 * k + ε ], [ x - .115 * k - ε, y + .234 * k - ε ] ]).stream(pointStream).point; - return albersUsa; - }; - return albersUsa.scale(1070); - }; - var d3_geo_pathAreaSum, d3_geo_pathAreaPolygon, d3_geo_pathArea = { - point: d3_noop, - lineStart: d3_noop, - lineEnd: d3_noop, - polygonStart: function() { - d3_geo_pathAreaPolygon = 0; - d3_geo_pathArea.lineStart = d3_geo_pathAreaRingStart; - }, - polygonEnd: function() { - d3_geo_pathArea.lineStart = d3_geo_pathArea.lineEnd = d3_geo_pathArea.point = d3_noop; - d3_geo_pathAreaSum += abs(d3_geo_pathAreaPolygon / 2); - } - }; - function d3_geo_pathAreaRingStart() { - var x00, y00, x0, y0; - d3_geo_pathArea.point = function(x, y) { - d3_geo_pathArea.point = nextPoint; - x00 = x0 = x, y00 = y0 = y; - }; - function nextPoint(x, y) { - d3_geo_pathAreaPolygon += y0 * x - x0 * y; - x0 = x, y0 = y; - } - d3_geo_pathArea.lineEnd = function() { - nextPoint(x00, y00); - }; - } - var d3_geo_pathBoundsX0, d3_geo_pathBoundsY0, d3_geo_pathBoundsX1, d3_geo_pathBoundsY1; - var d3_geo_pathBounds = { - point: d3_geo_pathBoundsPoint, - lineStart: d3_noop, - lineEnd: d3_noop, - polygonStart: d3_noop, - polygonEnd: d3_noop - }; - function d3_geo_pathBoundsPoint(x, y) { - if (x < d3_geo_pathBoundsX0) d3_geo_pathBoundsX0 = x; - if (x > d3_geo_pathBoundsX1) d3_geo_pathBoundsX1 = x; - if (y < d3_geo_pathBoundsY0) d3_geo_pathBoundsY0 = y; - if (y > d3_geo_pathBoundsY1) d3_geo_pathBoundsY1 = y; - } - function d3_geo_pathBuffer() { - var pointCircle = d3_geo_pathBufferCircle(4.5), buffer = []; - var stream = { - point: point, - lineStart: function() { - stream.point = pointLineStart; - }, - lineEnd: lineEnd, - polygonStart: function() { - stream.lineEnd = lineEndPolygon; - }, - polygonEnd: function() { - stream.lineEnd = lineEnd; - stream.point = point; - }, - pointRadius: function(_) { - pointCircle = d3_geo_pathBufferCircle(_); - return stream; - }, - result: function() { - if (buffer.length) { - var result = buffer.join(""); - buffer = []; - return result; - } - } - }; - function point(x, y) { - buffer.push("M", x, ",", y, pointCircle); - } - function pointLineStart(x, y) { - buffer.push("M", x, ",", y); - stream.point = pointLine; - } - function pointLine(x, y) { - buffer.push("L", x, ",", y); - } - function lineEnd() { - stream.point = point; - } - function lineEndPolygon() { - buffer.push("Z"); - } - return stream; - } - function d3_geo_pathBufferCircle(radius) { - return "m0," + radius + "a" + radius + "," + radius + " 0 1,1 0," + -2 * radius + "a" + radius + "," + radius + " 0 1,1 0," + 2 * radius + "z"; - } - var d3_geo_pathCentroid = { - point: d3_geo_pathCentroidPoint, - lineStart: d3_geo_pathCentroidLineStart, - lineEnd: d3_geo_pathCentroidLineEnd, - polygonStart: function() { - d3_geo_pathCentroid.lineStart = d3_geo_pathCentroidRingStart; - }, - polygonEnd: function() { - d3_geo_pathCentroid.point = d3_geo_pathCentroidPoint; - d3_geo_pathCentroid.lineStart = d3_geo_pathCentroidLineStart; - d3_geo_pathCentroid.lineEnd = d3_geo_pathCentroidLineEnd; - } - }; - function d3_geo_pathCentroidPoint(x, y) { - d3_geo_centroidX0 += x; - d3_geo_centroidY0 += y; - ++d3_geo_centroidZ0; - } - function d3_geo_pathCentroidLineStart() { - var x0, y0; - d3_geo_pathCentroid.point = function(x, y) { - d3_geo_pathCentroid.point = nextPoint; - d3_geo_pathCentroidPoint(x0 = x, y0 = y); - }; - function nextPoint(x, y) { - var dx = x - x0, dy = y - y0, z = Math.sqrt(dx * dx + dy * dy); - d3_geo_centroidX1 += z * (x0 + x) / 2; - d3_geo_centroidY1 += z * (y0 + y) / 2; - d3_geo_centroidZ1 += z; - d3_geo_pathCentroidPoint(x0 = x, y0 = y); - } - } - function d3_geo_pathCentroidLineEnd() { - d3_geo_pathCentroid.point = d3_geo_pathCentroidPoint; - } - function d3_geo_pathCentroidRingStart() { - var x00, y00, x0, y0; - d3_geo_pathCentroid.point = function(x, y) { - d3_geo_pathCentroid.point = nextPoint; - d3_geo_pathCentroidPoint(x00 = x0 = x, y00 = y0 = y); - }; - function nextPoint(x, y) { - var dx = x - x0, dy = y - y0, z = Math.sqrt(dx * dx + dy * dy); - d3_geo_centroidX1 += z * (x0 + x) / 2; - d3_geo_centroidY1 += z * (y0 + y) / 2; - d3_geo_centroidZ1 += z; - z = y0 * x - x0 * y; - d3_geo_centroidX2 += z * (x0 + x); - d3_geo_centroidY2 += z * (y0 + y); - d3_geo_centroidZ2 += z * 3; - d3_geo_pathCentroidPoint(x0 = x, y0 = y); - } - d3_geo_pathCentroid.lineEnd = function() { - nextPoint(x00, y00); - }; - } - function d3_geo_pathContext(context) { - var pointRadius = 4.5; - var stream = { - point: point, - lineStart: function() { - stream.point = pointLineStart; - }, - lineEnd: lineEnd, - polygonStart: function() { - stream.lineEnd = lineEndPolygon; - }, - polygonEnd: function() { - stream.lineEnd = lineEnd; - stream.point = point; - }, - pointRadius: function(_) { - pointRadius = _; - return stream; - }, - result: d3_noop - }; - function point(x, y) { - context.moveTo(x + pointRadius, y); - context.arc(x, y, pointRadius, 0, τ); - } - function pointLineStart(x, y) { - context.moveTo(x, y); - stream.point = pointLine; - } - function pointLine(x, y) { - context.lineTo(x, y); - } - function lineEnd() { - stream.point = point; - } - function lineEndPolygon() { - context.closePath(); - } - return stream; - } - function d3_geo_resample(project) { - var δ2 = .5, cosMinDistance = Math.cos(30 * d3_radians), maxDepth = 16; - function resample(stream) { - return (maxDepth ? resampleRecursive : resampleNone)(stream); - } - function resampleNone(stream) { - return d3_geo_transformPoint(stream, function(x, y) { - x = project(x, y); - stream.point(x[0], x[1]); - }); - } - function resampleRecursive(stream) { - var λ00, φ00, x00, y00, a00, b00, c00, λ0, x0, y0, a0, b0, c0; - var resample = { - point: point, - lineStart: lineStart, - lineEnd: lineEnd, - polygonStart: function() { - stream.polygonStart(); - resample.lineStart = ringStart; - }, - polygonEnd: function() { - stream.polygonEnd(); - resample.lineStart = lineStart; - } - }; - function point(x, y) { - x = project(x, y); - stream.point(x[0], x[1]); - } - function lineStart() { - x0 = NaN; - resample.point = linePoint; - stream.lineStart(); - } - function linePoint(λ, φ) { - var c = d3_geo_cartesian([ λ, φ ]), p = project(λ, φ); - resampleLineTo(x0, y0, λ0, a0, b0, c0, x0 = p[0], y0 = p[1], λ0 = λ, a0 = c[0], b0 = c[1], c0 = c[2], maxDepth, stream); - stream.point(x0, y0); - } - function lineEnd() { - resample.point = point; - stream.lineEnd(); - } - function ringStart() { - lineStart(); - resample.point = ringPoint; - resample.lineEnd = ringEnd; - } - function ringPoint(λ, φ) { - linePoint(λ00 = λ, φ00 = φ), x00 = x0, y00 = y0, a00 = a0, b00 = b0, c00 = c0; - resample.point = linePoint; - } - function ringEnd() { - resampleLineTo(x0, y0, λ0, a0, b0, c0, x00, y00, λ00, a00, b00, c00, maxDepth, stream); - resample.lineEnd = lineEnd; - lineEnd(); - } - return resample; - } - function resampleLineTo(x0, y0, λ0, a0, b0, c0, x1, y1, λ1, a1, b1, c1, depth, stream) { - var dx = x1 - x0, dy = y1 - y0, d2 = dx * dx + dy * dy; - if (d2 > 4 * δ2 && depth--) { - var a = a0 + a1, b = b0 + b1, c = c0 + c1, m = Math.sqrt(a * a + b * b + c * c), φ2 = Math.asin(c /= m), λ2 = abs(abs(c) - 1) < ε || abs(λ0 - λ1) < ε ? (λ0 + λ1) / 2 : Math.atan2(b, a), p = project(λ2, φ2), x2 = p[0], y2 = p[1], dx2 = x2 - x0, dy2 = y2 - y0, dz = dy * dx2 - dx * dy2; - if (dz * dz / d2 > δ2 || abs((dx * dx2 + dy * dy2) / d2 - .5) > .3 || a0 * a1 + b0 * b1 + c0 * c1 < cosMinDistance) { - resampleLineTo(x0, y0, λ0, a0, b0, c0, x2, y2, λ2, a /= m, b /= m, c, depth, stream); - stream.point(x2, y2); - resampleLineTo(x2, y2, λ2, a, b, c, x1, y1, λ1, a1, b1, c1, depth, stream); - } - } - } - resample.precision = function(_) { - if (!arguments.length) return Math.sqrt(δ2); - maxDepth = (δ2 = _ * _) > 0 && 16; - return resample; - }; - return resample; - } - d3.geo.path = function() { - var pointRadius = 4.5, projection, context, projectStream, contextStream, cacheStream; - function path(object) { - if (object) { - if (typeof pointRadius === "function") contextStream.pointRadius(+pointRadius.apply(this, arguments)); - if (!cacheStream || !cacheStream.valid) cacheStream = projectStream(contextStream); - d3.geo.stream(object, cacheStream); - } - return contextStream.result(); - } - path.area = function(object) { - d3_geo_pathAreaSum = 0; - d3.geo.stream(object, projectStream(d3_geo_pathArea)); - return d3_geo_pathAreaSum; - }; - path.centroid = function(object) { - d3_geo_centroidX0 = d3_geo_centroidY0 = d3_geo_centroidZ0 = d3_geo_centroidX1 = d3_geo_centroidY1 = d3_geo_centroidZ1 = d3_geo_centroidX2 = d3_geo_centroidY2 = d3_geo_centroidZ2 = 0; - d3.geo.stream(object, projectStream(d3_geo_pathCentroid)); - return d3_geo_centroidZ2 ? [ d3_geo_centroidX2 / d3_geo_centroidZ2, d3_geo_centroidY2 / d3_geo_centroidZ2 ] : d3_geo_centroidZ1 ? [ d3_geo_centroidX1 / d3_geo_centroidZ1, d3_geo_centroidY1 / d3_geo_centroidZ1 ] : d3_geo_centroidZ0 ? [ d3_geo_centroidX0 / d3_geo_centroidZ0, d3_geo_centroidY0 / d3_geo_centroidZ0 ] : [ NaN, NaN ]; - }; - path.bounds = function(object) { - d3_geo_pathBoundsX1 = d3_geo_pathBoundsY1 = -(d3_geo_pathBoundsX0 = d3_geo_pathBoundsY0 = Infinity); - d3.geo.stream(object, projectStream(d3_geo_pathBounds)); - return [ [ d3_geo_pathBoundsX0, d3_geo_pathBoundsY0 ], [ d3_geo_pathBoundsX1, d3_geo_pathBoundsY1 ] ]; - }; - path.projection = function(_) { - if (!arguments.length) return projection; - projectStream = (projection = _) ? _.stream || d3_geo_pathProjectStream(_) : d3_identity; - return reset(); - }; - path.context = function(_) { - if (!arguments.length) return context; - contextStream = (context = _) == null ? new d3_geo_pathBuffer() : new d3_geo_pathContext(_); - if (typeof pointRadius !== "function") contextStream.pointRadius(pointRadius); - return reset(); - }; - path.pointRadius = function(_) { - if (!arguments.length) return pointRadius; - pointRadius = typeof _ === "function" ? _ : (contextStream.pointRadius(+_), +_); - return path; - }; - function reset() { - cacheStream = null; - return path; - } - return path.projection(d3.geo.albersUsa()).context(null); - }; - function d3_geo_pathProjectStream(project) { - var resample = d3_geo_resample(function(x, y) { - return project([ x * d3_degrees, y * d3_degrees ]); - }); - return function(stream) { - return d3_geo_projectionRadians(resample(stream)); - }; - } - d3.geo.transform = function(methods) { - return { - stream: function(stream) { - var transform = new d3_geo_transform(stream); - for (var k in methods) transform[k] = methods[k]; - return transform; - } - }; - }; - function d3_geo_transform(stream) { - this.stream = stream; - } - d3_geo_transform.prototype = { - point: function(x, y) { - this.stream.point(x, y); - }, - sphere: function() { - this.stream.sphere(); - }, - lineStart: function() { - this.stream.lineStart(); - }, - lineEnd: function() { - this.stream.lineEnd(); - }, - polygonStart: function() { - this.stream.polygonStart(); - }, - polygonEnd: function() { - this.stream.polygonEnd(); - } - }; - function d3_geo_transformPoint(stream, point) { - return { - point: point, - sphere: function() { - stream.sphere(); - }, - lineStart: function() { - stream.lineStart(); - }, - lineEnd: function() { - stream.lineEnd(); - }, - polygonStart: function() { - stream.polygonStart(); - }, - polygonEnd: function() { - stream.polygonEnd(); - } - }; - } - d3.geo.projection = d3_geo_projection; - d3.geo.projectionMutator = d3_geo_projectionMutator; - function d3_geo_projection(project) { - return d3_geo_projectionMutator(function() { - return project; - })(); - } - function d3_geo_projectionMutator(projectAt) { - var project, rotate, projectRotate, projectResample = d3_geo_resample(function(x, y) { - x = project(x, y); - return [ x[0] * k + δx, δy - x[1] * k ]; - }), k = 150, x = 480, y = 250, λ = 0, φ = 0, δλ = 0, δφ = 0, δγ = 0, δx, δy, preclip = d3_geo_clipAntimeridian, postclip = d3_identity, clipAngle = null, clipExtent = null, stream; - function projection(point) { - point = projectRotate(point[0] * d3_radians, point[1] * d3_radians); - return [ point[0] * k + δx, δy - point[1] * k ]; - } - function invert(point) { - point = projectRotate.invert((point[0] - δx) / k, (δy - point[1]) / k); - return point && [ point[0] * d3_degrees, point[1] * d3_degrees ]; - } - projection.stream = function(output) { - if (stream) stream.valid = false; - stream = d3_geo_projectionRadians(preclip(rotate, projectResample(postclip(output)))); - stream.valid = true; - return stream; - }; - projection.clipAngle = function(_) { - if (!arguments.length) return clipAngle; - preclip = _ == null ? (clipAngle = _, d3_geo_clipAntimeridian) : d3_geo_clipCircle((clipAngle = +_) * d3_radians); - return invalidate(); - }; - projection.clipExtent = function(_) { - if (!arguments.length) return clipExtent; - clipExtent = _; - postclip = _ ? d3_geo_clipExtent(_[0][0], _[0][1], _[1][0], _[1][1]) : d3_identity; - return invalidate(); - }; - projection.scale = function(_) { - if (!arguments.length) return k; - k = +_; - return reset(); - }; - projection.translate = function(_) { - if (!arguments.length) return [ x, y ]; - x = +_[0]; - y = +_[1]; - return reset(); - }; - projection.center = function(_) { - if (!arguments.length) return [ λ * d3_degrees, φ * d3_degrees ]; - λ = _[0] % 360 * d3_radians; - φ = _[1] % 360 * d3_radians; - return reset(); - }; - projection.rotate = function(_) { - if (!arguments.length) return [ δλ * d3_degrees, δφ * d3_degrees, δγ * d3_degrees ]; - δλ = _[0] % 360 * d3_radians; - δφ = _[1] % 360 * d3_radians; - δγ = _.length > 2 ? _[2] % 360 * d3_radians : 0; - return reset(); - }; - d3.rebind(projection, projectResample, "precision"); - function reset() { - projectRotate = d3_geo_compose(rotate = d3_geo_rotation(δλ, δφ, δγ), project); - var center = project(λ, φ); - δx = x - center[0] * k; - δy = y + center[1] * k; - return invalidate(); - } - function invalidate() { - if (stream) stream.valid = false, stream = null; - return projection; - } - return function() { - project = projectAt.apply(this, arguments); - projection.invert = project.invert && invert; - return reset(); - }; - } - function d3_geo_projectionRadians(stream) { - return d3_geo_transformPoint(stream, function(x, y) { - stream.point(x * d3_radians, y * d3_radians); - }); - } - function d3_geo_equirectangular(λ, φ) { - return [ λ, φ ]; - } - (d3.geo.equirectangular = function() { - return d3_geo_projection(d3_geo_equirectangular); - }).raw = d3_geo_equirectangular.invert = d3_geo_equirectangular; - d3.geo.rotation = function(rotate) { - rotate = d3_geo_rotation(rotate[0] % 360 * d3_radians, rotate[1] * d3_radians, rotate.length > 2 ? rotate[2] * d3_radians : 0); - function forward(coordinates) { - coordinates = rotate(coordinates[0] * d3_radians, coordinates[1] * d3_radians); - return coordinates[0] *= d3_degrees, coordinates[1] *= d3_degrees, coordinates; - } - forward.invert = function(coordinates) { - coordinates = rotate.invert(coordinates[0] * d3_radians, coordinates[1] * d3_radians); - return coordinates[0] *= d3_degrees, coordinates[1] *= d3_degrees, coordinates; - }; - return forward; - }; - function d3_geo_identityRotation(λ, φ) { - return [ λ > π ? λ - τ : λ < -π ? λ + τ : λ, φ ]; - } - d3_geo_identityRotation.invert = d3_geo_equirectangular; - function d3_geo_rotation(δλ, δφ, δγ) { - return δλ ? δφ || δγ ? d3_geo_compose(d3_geo_rotationλ(δλ), d3_geo_rotationφγ(δφ, δγ)) : d3_geo_rotationλ(δλ) : δφ || δγ ? d3_geo_rotationφγ(δφ, δγ) : d3_geo_identityRotation; - } - function d3_geo_forwardRotationλ(δλ) { - return function(λ, φ) { - return λ += δλ, [ λ > π ? λ - τ : λ < -π ? λ + τ : λ, φ ]; - }; - } - function d3_geo_rotationλ(δλ) { - var rotation = d3_geo_forwardRotationλ(δλ); - rotation.invert = d3_geo_forwardRotationλ(-δλ); - return rotation; - } - function d3_geo_rotationφγ(δφ, δγ) { - var cosδφ = Math.cos(δφ), sinδφ = Math.sin(δφ), cosδγ = Math.cos(δγ), sinδγ = Math.sin(δγ); - function rotation(λ, φ) { - var cosφ = Math.cos(φ), x = Math.cos(λ) * cosφ, y = Math.sin(λ) * cosφ, z = Math.sin(φ), k = z * cosδφ + x * sinδφ; - return [ Math.atan2(y * cosδγ - k * sinδγ, x * cosδφ - z * sinδφ), d3_asin(k * cosδγ + y * sinδγ) ]; - } - rotation.invert = function(λ, φ) { - var cosφ = Math.cos(φ), x = Math.cos(λ) * cosφ, y = Math.sin(λ) * cosφ, z = Math.sin(φ), k = z * cosδγ - y * sinδγ; - return [ Math.atan2(y * cosδγ + z * sinδγ, x * cosδφ + k * sinδφ), d3_asin(k * cosδφ - x * sinδφ) ]; - }; - return rotation; - } - d3.geo.circle = function() { - var origin = [ 0, 0 ], angle, precision = 6, interpolate; - function circle() { - var center = typeof origin === "function" ? origin.apply(this, arguments) : origin, rotate = d3_geo_rotation(-center[0] * d3_radians, -center[1] * d3_radians, 0).invert, ring = []; - interpolate(null, null, 1, { - point: function(x, y) { - ring.push(x = rotate(x, y)); - x[0] *= d3_degrees, x[1] *= d3_degrees; - } - }); - return { - type: "Polygon", - coordinates: [ ring ] - }; - } - circle.origin = function(x) { - if (!arguments.length) return origin; - origin = x; - return circle; - }; - circle.angle = function(x) { - if (!arguments.length) return angle; - interpolate = d3_geo_circleInterpolate((angle = +x) * d3_radians, precision * d3_radians); - return circle; - }; - circle.precision = function(_) { - if (!arguments.length) return precision; - interpolate = d3_geo_circleInterpolate(angle * d3_radians, (precision = +_) * d3_radians); - return circle; - }; - return circle.angle(90); - }; - function d3_geo_circleInterpolate(radius, precision) { - var cr = Math.cos(radius), sr = Math.sin(radius); - return function(from, to, direction, listener) { - var step = direction * precision; - if (from != null) { - from = d3_geo_circleAngle(cr, from); - to = d3_geo_circleAngle(cr, to); - if (direction > 0 ? from < to : from > to) from += direction * τ; - } else { - from = radius + direction * τ; - to = radius - .5 * step; - } - for (var point, t = from; direction > 0 ? t > to : t < to; t -= step) { - listener.point((point = d3_geo_spherical([ cr, -sr * Math.cos(t), -sr * Math.sin(t) ]))[0], point[1]); - } - }; - } - function d3_geo_circleAngle(cr, point) { - var a = d3_geo_cartesian(point); - a[0] -= cr; - d3_geo_cartesianNormalize(a); - var angle = d3_acos(-a[1]); - return ((-a[2] < 0 ? -angle : angle) + 2 * Math.PI - ε) % (2 * Math.PI); - } - d3.geo.distance = function(a, b) { - var Δλ = (b[0] - a[0]) * d3_radians, φ0 = a[1] * d3_radians, φ1 = b[1] * d3_radians, sinΔλ = Math.sin(Δλ), cosΔλ = Math.cos(Δλ), sinφ0 = Math.sin(φ0), cosφ0 = Math.cos(φ0), sinφ1 = Math.sin(φ1), cosφ1 = Math.cos(φ1), t; - return Math.atan2(Math.sqrt((t = cosφ1 * sinΔλ) * t + (t = cosφ0 * sinφ1 - sinφ0 * cosφ1 * cosΔλ) * t), sinφ0 * sinφ1 + cosφ0 * cosφ1 * cosΔλ); - }; - d3.geo.graticule = function() { - var x1, x0, X1, X0, y1, y0, Y1, Y0, dx = 10, dy = dx, DX = 90, DY = 360, x, y, X, Y, precision = 2.5; - function graticule() { - return { - type: "MultiLineString", - coordinates: lines() - }; - } - function lines() { - return d3.range(Math.ceil(X0 / DX) * DX, X1, DX).map(X).concat(d3.range(Math.ceil(Y0 / DY) * DY, Y1, DY).map(Y)).concat(d3.range(Math.ceil(x0 / dx) * dx, x1, dx).filter(function(x) { - return abs(x % DX) > ε; - }).map(x)).concat(d3.range(Math.ceil(y0 / dy) * dy, y1, dy).filter(function(y) { - return abs(y % DY) > ε; - }).map(y)); - } - graticule.lines = function() { - return lines().map(function(coordinates) { - return { - type: "LineString", - coordinates: coordinates - }; - }); - }; - graticule.outline = function() { - return { - type: "Polygon", - coordinates: [ X(X0).concat(Y(Y1).slice(1), X(X1).reverse().slice(1), Y(Y0).reverse().slice(1)) ] - }; - }; - graticule.extent = function(_) { - if (!arguments.length) return graticule.minorExtent(); - return graticule.majorExtent(_).minorExtent(_); - }; - graticule.majorExtent = function(_) { - if (!arguments.length) return [ [ X0, Y0 ], [ X1, Y1 ] ]; - X0 = +_[0][0], X1 = +_[1][0]; - Y0 = +_[0][1], Y1 = +_[1][1]; - if (X0 > X1) _ = X0, X0 = X1, X1 = _; - if (Y0 > Y1) _ = Y0, Y0 = Y1, Y1 = _; - return graticule.precision(precision); - }; - graticule.minorExtent = function(_) { - if (!arguments.length) return [ [ x0, y0 ], [ x1, y1 ] ]; - x0 = +_[0][0], x1 = +_[1][0]; - y0 = +_[0][1], y1 = +_[1][1]; - if (x0 > x1) _ = x0, x0 = x1, x1 = _; - if (y0 > y1) _ = y0, y0 = y1, y1 = _; - return graticule.precision(precision); - }; - graticule.step = function(_) { - if (!arguments.length) return graticule.minorStep(); - return graticule.majorStep(_).minorStep(_); - }; - graticule.majorStep = function(_) { - if (!arguments.length) return [ DX, DY ]; - DX = +_[0], DY = +_[1]; - return graticule; - }; - graticule.minorStep = function(_) { - if (!arguments.length) return [ dx, dy ]; - dx = +_[0], dy = +_[1]; - return graticule; - }; - graticule.precision = function(_) { - if (!arguments.length) return precision; - precision = +_; - x = d3_geo_graticuleX(y0, y1, 90); - y = d3_geo_graticuleY(x0, x1, precision); - X = d3_geo_graticuleX(Y0, Y1, 90); - Y = d3_geo_graticuleY(X0, X1, precision); - return graticule; - }; - return graticule.majorExtent([ [ -180, -90 + ε ], [ 180, 90 - ε ] ]).minorExtent([ [ -180, -80 - ε ], [ 180, 80 + ε ] ]); - }; - function d3_geo_graticuleX(y0, y1, dy) { - var y = d3.range(y0, y1 - ε, dy).concat(y1); - return function(x) { - return y.map(function(y) { - return [ x, y ]; - }); - }; - } - function d3_geo_graticuleY(x0, x1, dx) { - var x = d3.range(x0, x1 - ε, dx).concat(x1); - return function(y) { - return x.map(function(x) { - return [ x, y ]; - }); - }; - } - function d3_source(d) { - return d.source; - } - function d3_target(d) { - return d.target; - } - d3.geo.greatArc = function() { - var source = d3_source, source_, target = d3_target, target_; - function greatArc() { - return { - type: "LineString", - coordinates: [ source_ || source.apply(this, arguments), target_ || target.apply(this, arguments) ] - }; - } - greatArc.distance = function() { - return d3.geo.distance(source_ || source.apply(this, arguments), target_ || target.apply(this, arguments)); - }; - greatArc.source = function(_) { - if (!arguments.length) return source; - source = _, source_ = typeof _ === "function" ? null : _; - return greatArc; - }; - greatArc.target = function(_) { - if (!arguments.length) return target; - target = _, target_ = typeof _ === "function" ? null : _; - return greatArc; - }; - greatArc.precision = function() { - return arguments.length ? greatArc : 0; - }; - return greatArc; - }; - d3.geo.interpolate = function(source, target) { - return d3_geo_interpolate(source[0] * d3_radians, source[1] * d3_radians, target[0] * d3_radians, target[1] * d3_radians); - }; - function d3_geo_interpolate(x0, y0, x1, y1) { - var cy0 = Math.cos(y0), sy0 = Math.sin(y0), cy1 = Math.cos(y1), sy1 = Math.sin(y1), kx0 = cy0 * Math.cos(x0), ky0 = cy0 * Math.sin(x0), kx1 = cy1 * Math.cos(x1), ky1 = cy1 * Math.sin(x1), d = 2 * Math.asin(Math.sqrt(d3_haversin(y1 - y0) + cy0 * cy1 * d3_haversin(x1 - x0))), k = 1 / Math.sin(d); - var interpolate = d ? function(t) { - var B = Math.sin(t *= d) * k, A = Math.sin(d - t) * k, x = A * kx0 + B * kx1, y = A * ky0 + B * ky1, z = A * sy0 + B * sy1; - return [ Math.atan2(y, x) * d3_degrees, Math.atan2(z, Math.sqrt(x * x + y * y)) * d3_degrees ]; - } : function() { - return [ x0 * d3_degrees, y0 * d3_degrees ]; - }; - interpolate.distance = d; - return interpolate; - } - d3.geo.length = function(object) { - d3_geo_lengthSum = 0; - d3.geo.stream(object, d3_geo_length); - return d3_geo_lengthSum; - }; - var d3_geo_lengthSum; - var d3_geo_length = { - sphere: d3_noop, - point: d3_noop, - lineStart: d3_geo_lengthLineStart, - lineEnd: d3_noop, - polygonStart: d3_noop, - polygonEnd: d3_noop - }; - function d3_geo_lengthLineStart() { - var λ0, sinφ0, cosφ0; - d3_geo_length.point = function(λ, φ) { - λ0 = λ * d3_radians, sinφ0 = Math.sin(φ *= d3_radians), cosφ0 = Math.cos(φ); - d3_geo_length.point = nextPoint; - }; - d3_geo_length.lineEnd = function() { - d3_geo_length.point = d3_geo_length.lineEnd = d3_noop; - }; - function nextPoint(λ, φ) { - var sinφ = Math.sin(φ *= d3_radians), cosφ = Math.cos(φ), t = abs((λ *= d3_radians) - λ0), cosΔλ = Math.cos(t); - d3_geo_lengthSum += Math.atan2(Math.sqrt((t = cosφ * Math.sin(t)) * t + (t = cosφ0 * sinφ - sinφ0 * cosφ * cosΔλ) * t), sinφ0 * sinφ + cosφ0 * cosφ * cosΔλ); - λ0 = λ, sinφ0 = sinφ, cosφ0 = cosφ; - } - } - function d3_geo_azimuthal(scale, angle) { - function azimuthal(λ, φ) { - var cosλ = Math.cos(λ), cosφ = Math.cos(φ), k = scale(cosλ * cosφ); - return [ k * cosφ * Math.sin(λ), k * Math.sin(φ) ]; - } - azimuthal.invert = function(x, y) { - var ρ = Math.sqrt(x * x + y * y), c = angle(ρ), sinc = Math.sin(c), cosc = Math.cos(c); - return [ Math.atan2(x * sinc, ρ * cosc), Math.asin(ρ && y * sinc / ρ) ]; - }; - return azimuthal; - } - var d3_geo_azimuthalEqualArea = d3_geo_azimuthal(function(cosλcosφ) { - return Math.sqrt(2 / (1 + cosλcosφ)); - }, function(ρ) { - return 2 * Math.asin(ρ / 2); - }); - (d3.geo.azimuthalEqualArea = function() { - return d3_geo_projection(d3_geo_azimuthalEqualArea); - }).raw = d3_geo_azimuthalEqualArea; - var d3_geo_azimuthalEquidistant = d3_geo_azimuthal(function(cosλcosφ) { - var c = Math.acos(cosλcosφ); - return c && c / Math.sin(c); - }, d3_identity); - (d3.geo.azimuthalEquidistant = function() { - return d3_geo_projection(d3_geo_azimuthalEquidistant); - }).raw = d3_geo_azimuthalEquidistant; - function d3_geo_conicConformal(φ0, φ1) { - var cosφ0 = Math.cos(φ0), t = function(φ) { - return Math.tan(π / 4 + φ / 2); - }, n = φ0 === φ1 ? Math.sin(φ0) : Math.log(cosφ0 / Math.cos(φ1)) / Math.log(t(φ1) / t(φ0)), F = cosφ0 * Math.pow(t(φ0), n) / n; - if (!n) return d3_geo_mercator; - function forward(λ, φ) { - if (F > 0) { - if (φ < -halfπ + ε) φ = -halfπ + ε; - } else { - if (φ > halfπ - ε) φ = halfπ - ε; - } - var ρ = F / Math.pow(t(φ), n); - return [ ρ * Math.sin(n * λ), F - ρ * Math.cos(n * λ) ]; - } - forward.invert = function(x, y) { - var ρ0_y = F - y, ρ = d3_sgn(n) * Math.sqrt(x * x + ρ0_y * ρ0_y); - return [ Math.atan2(x, ρ0_y) / n, 2 * Math.atan(Math.pow(F / ρ, 1 / n)) - halfπ ]; - }; - return forward; - } - (d3.geo.conicConformal = function() { - return d3_geo_conic(d3_geo_conicConformal); - }).raw = d3_geo_conicConformal; - function d3_geo_conicEquidistant(φ0, φ1) { - var cosφ0 = Math.cos(φ0), n = φ0 === φ1 ? Math.sin(φ0) : (cosφ0 - Math.cos(φ1)) / (φ1 - φ0), G = cosφ0 / n + φ0; - if (abs(n) < ε) return d3_geo_equirectangular; - function forward(λ, φ) { - var ρ = G - φ; - return [ ρ * Math.sin(n * λ), G - ρ * Math.cos(n * λ) ]; - } - forward.invert = function(x, y) { - var ρ0_y = G - y; - return [ Math.atan2(x, ρ0_y) / n, G - d3_sgn(n) * Math.sqrt(x * x + ρ0_y * ρ0_y) ]; - }; - return forward; - } - (d3.geo.conicEquidistant = function() { - return d3_geo_conic(d3_geo_conicEquidistant); - }).raw = d3_geo_conicEquidistant; - var d3_geo_gnomonic = d3_geo_azimuthal(function(cosλcosφ) { - return 1 / cosλcosφ; - }, Math.atan); - (d3.geo.gnomonic = function() { - return d3_geo_projection(d3_geo_gnomonic); - }).raw = d3_geo_gnomonic; - function d3_geo_mercator(λ, φ) { - return [ λ, Math.log(Math.tan(π / 4 + φ / 2)) ]; - } - d3_geo_mercator.invert = function(x, y) { - return [ x, 2 * Math.atan(Math.exp(y)) - halfπ ]; - }; - function d3_geo_mercatorProjection(project) { - var m = d3_geo_projection(project), scale = m.scale, translate = m.translate, clipExtent = m.clipExtent, clipAuto; - m.scale = function() { - var v = scale.apply(m, arguments); - return v === m ? clipAuto ? m.clipExtent(null) : m : v; - }; - m.translate = function() { - var v = translate.apply(m, arguments); - return v === m ? clipAuto ? m.clipExtent(null) : m : v; - }; - m.clipExtent = function(_) { - var v = clipExtent.apply(m, arguments); - if (v === m) { - if (clipAuto = _ == null) { - var k = π * scale(), t = translate(); - clipExtent([ [ t[0] - k, t[1] - k ], [ t[0] + k, t[1] + k ] ]); - } - } else if (clipAuto) { - v = null; - } - return v; - }; - return m.clipExtent(null); - } - (d3.geo.mercator = function() { - return d3_geo_mercatorProjection(d3_geo_mercator); - }).raw = d3_geo_mercator; - var d3_geo_orthographic = d3_geo_azimuthal(function() { - return 1; - }, Math.asin); - (d3.geo.orthographic = function() { - return d3_geo_projection(d3_geo_orthographic); - }).raw = d3_geo_orthographic; - var d3_geo_stereographic = d3_geo_azimuthal(function(cosλcosφ) { - return 1 / (1 + cosλcosφ); - }, function(ρ) { - return 2 * Math.atan(ρ); - }); - (d3.geo.stereographic = function() { - return d3_geo_projection(d3_geo_stereographic); - }).raw = d3_geo_stereographic; - function d3_geo_transverseMercator(λ, φ) { - return [ Math.log(Math.tan(π / 4 + φ / 2)), -λ ]; - } - d3_geo_transverseMercator.invert = function(x, y) { - return [ -y, 2 * Math.atan(Math.exp(x)) - halfπ ]; - }; - (d3.geo.transverseMercator = function() { - var projection = d3_geo_mercatorProjection(d3_geo_transverseMercator), center = projection.center, rotate = projection.rotate; - projection.center = function(_) { - return _ ? center([ -_[1], _[0] ]) : (_ = center(), [ _[1], -_[0] ]); - }; - projection.rotate = function(_) { - return _ ? rotate([ _[0], _[1], _.length > 2 ? _[2] + 90 : 90 ]) : (_ = rotate(), - [ _[0], _[1], _[2] - 90 ]); - }; - return rotate([ 0, 0, 90 ]); - }).raw = d3_geo_transverseMercator; - d3.geom = {}; - function d3_geom_pointX(d) { - return d[0]; - } - function d3_geom_pointY(d) { - return d[1]; - } - d3.geom.hull = function(vertices) { - var x = d3_geom_pointX, y = d3_geom_pointY; - if (arguments.length) return hull(vertices); - function hull(data) { - if (data.length < 3) return []; - var fx = d3_functor(x), fy = d3_functor(y), i, n = data.length, points = [], flippedPoints = []; - for (i = 0; i < n; i++) { - points.push([ +fx.call(this, data[i], i), +fy.call(this, data[i], i), i ]); - } - points.sort(d3_geom_hullOrder); - for (i = 0; i < n; i++) flippedPoints.push([ points[i][0], -points[i][1] ]); - var upper = d3_geom_hullUpper(points), lower = d3_geom_hullUpper(flippedPoints); - var skipLeft = lower[0] === upper[0], skipRight = lower[lower.length - 1] === upper[upper.length - 1], polygon = []; - for (i = upper.length - 1; i >= 0; --i) polygon.push(data[points[upper[i]][2]]); - for (i = +skipLeft; i < lower.length - skipRight; ++i) polygon.push(data[points[lower[i]][2]]); - return polygon; - } - hull.x = function(_) { - return arguments.length ? (x = _, hull) : x; - }; - hull.y = function(_) { - return arguments.length ? (y = _, hull) : y; - }; - return hull; - }; - function d3_geom_hullUpper(points) { - var n = points.length, hull = [ 0, 1 ], hs = 2; - for (var i = 2; i < n; i++) { - while (hs > 1 && d3_cross2d(points[hull[hs - 2]], points[hull[hs - 1]], points[i]) <= 0) --hs; - hull[hs++] = i; - } - return hull.slice(0, hs); - } - function d3_geom_hullOrder(a, b) { - return a[0] - b[0] || a[1] - b[1]; - } - d3.geom.polygon = function(coordinates) { - d3_subclass(coordinates, d3_geom_polygonPrototype); - return coordinates; - }; - var d3_geom_polygonPrototype = d3.geom.polygon.prototype = []; - d3_geom_polygonPrototype.area = function() { - var i = -1, n = this.length, a, b = this[n - 1], area = 0; - while (++i < n) { - a = b; - b = this[i]; - area += a[1] * b[0] - a[0] * b[1]; - } - return area * .5; - }; - d3_geom_polygonPrototype.centroid = function(k) { - var i = -1, n = this.length, x = 0, y = 0, a, b = this[n - 1], c; - if (!arguments.length) k = -1 / (6 * this.area()); - while (++i < n) { - a = b; - b = this[i]; - c = a[0] * b[1] - b[0] * a[1]; - x += (a[0] + b[0]) * c; - y += (a[1] + b[1]) * c; - } - return [ x * k, y * k ]; - }; - d3_geom_polygonPrototype.clip = function(subject) { - var input, closed = d3_geom_polygonClosed(subject), i = -1, n = this.length - d3_geom_polygonClosed(this), j, m, a = this[n - 1], b, c, d; - while (++i < n) { - input = subject.slice(); - subject.length = 0; - b = this[i]; - c = input[(m = input.length - closed) - 1]; - j = -1; - while (++j < m) { - d = input[j]; - if (d3_geom_polygonInside(d, a, b)) { - if (!d3_geom_polygonInside(c, a, b)) { - subject.push(d3_geom_polygonIntersect(c, d, a, b)); - } - subject.push(d); - } else if (d3_geom_polygonInside(c, a, b)) { - subject.push(d3_geom_polygonIntersect(c, d, a, b)); - } - c = d; - } - if (closed) subject.push(subject[0]); - a = b; - } - return subject; - }; - function d3_geom_polygonInside(p, a, b) { - return (b[0] - a[0]) * (p[1] - a[1]) < (b[1] - a[1]) * (p[0] - a[0]); - } - function d3_geom_polygonIntersect(c, d, a, b) { - var x1 = c[0], x3 = a[0], x21 = d[0] - x1, x43 = b[0] - x3, y1 = c[1], y3 = a[1], y21 = d[1] - y1, y43 = b[1] - y3, ua = (x43 * (y1 - y3) - y43 * (x1 - x3)) / (y43 * x21 - x43 * y21); - return [ x1 + ua * x21, y1 + ua * y21 ]; - } - function d3_geom_polygonClosed(coordinates) { - var a = coordinates[0], b = coordinates[coordinates.length - 1]; - return !(a[0] - b[0] || a[1] - b[1]); - } - var d3_geom_voronoiEdges, d3_geom_voronoiCells, d3_geom_voronoiBeaches, d3_geom_voronoiBeachPool = [], d3_geom_voronoiFirstCircle, d3_geom_voronoiCircles, d3_geom_voronoiCirclePool = []; - function d3_geom_voronoiBeach() { - d3_geom_voronoiRedBlackNode(this); - this.edge = this.site = this.circle = null; - } - function d3_geom_voronoiCreateBeach(site) { - var beach = d3_geom_voronoiBeachPool.pop() || new d3_geom_voronoiBeach(); - beach.site = site; - return beach; - } - function d3_geom_voronoiDetachBeach(beach) { - d3_geom_voronoiDetachCircle(beach); - d3_geom_voronoiBeaches.remove(beach); - d3_geom_voronoiBeachPool.push(beach); - d3_geom_voronoiRedBlackNode(beach); - } - function d3_geom_voronoiRemoveBeach(beach) { - var circle = beach.circle, x = circle.x, y = circle.cy, vertex = { - x: x, - y: y - }, previous = beach.P, next = beach.N, disappearing = [ beach ]; - d3_geom_voronoiDetachBeach(beach); - var lArc = previous; - while (lArc.circle && abs(x - lArc.circle.x) < ε && abs(y - lArc.circle.cy) < ε) { - previous = lArc.P; - disappearing.unshift(lArc); - d3_geom_voronoiDetachBeach(lArc); - lArc = previous; - } - disappearing.unshift(lArc); - d3_geom_voronoiDetachCircle(lArc); - var rArc = next; - while (rArc.circle && abs(x - rArc.circle.x) < ε && abs(y - rArc.circle.cy) < ε) { - next = rArc.N; - disappearing.push(rArc); - d3_geom_voronoiDetachBeach(rArc); - rArc = next; - } - disappearing.push(rArc); - d3_geom_voronoiDetachCircle(rArc); - var nArcs = disappearing.length, iArc; - for (iArc = 1; iArc < nArcs; ++iArc) { - rArc = disappearing[iArc]; - lArc = disappearing[iArc - 1]; - d3_geom_voronoiSetEdgeEnd(rArc.edge, lArc.site, rArc.site, vertex); - } - lArc = disappearing[0]; - rArc = disappearing[nArcs - 1]; - rArc.edge = d3_geom_voronoiCreateEdge(lArc.site, rArc.site, null, vertex); - d3_geom_voronoiAttachCircle(lArc); - d3_geom_voronoiAttachCircle(rArc); - } - function d3_geom_voronoiAddBeach(site) { - var x = site.x, directrix = site.y, lArc, rArc, dxl, dxr, node = d3_geom_voronoiBeaches._; - while (node) { - dxl = d3_geom_voronoiLeftBreakPoint(node, directrix) - x; - if (dxl > ε) node = node.L; else { - dxr = x - d3_geom_voronoiRightBreakPoint(node, directrix); - if (dxr > ε) { - if (!node.R) { - lArc = node; - break; - } - node = node.R; - } else { - if (dxl > -ε) { - lArc = node.P; - rArc = node; - } else if (dxr > -ε) { - lArc = node; - rArc = node.N; - } else { - lArc = rArc = node; - } - break; - } - } - } - var newArc = d3_geom_voronoiCreateBeach(site); - d3_geom_voronoiBeaches.insert(lArc, newArc); - if (!lArc && !rArc) return; - if (lArc === rArc) { - d3_geom_voronoiDetachCircle(lArc); - rArc = d3_geom_voronoiCreateBeach(lArc.site); - d3_geom_voronoiBeaches.insert(newArc, rArc); - newArc.edge = rArc.edge = d3_geom_voronoiCreateEdge(lArc.site, newArc.site); - d3_geom_voronoiAttachCircle(lArc); - d3_geom_voronoiAttachCircle(rArc); - return; - } - if (!rArc) { - newArc.edge = d3_geom_voronoiCreateEdge(lArc.site, newArc.site); - return; - } - d3_geom_voronoiDetachCircle(lArc); - d3_geom_voronoiDetachCircle(rArc); - var lSite = lArc.site, ax = lSite.x, ay = lSite.y, bx = site.x - ax, by = site.y - ay, rSite = rArc.site, cx = rSite.x - ax, cy = rSite.y - ay, d = 2 * (bx * cy - by * cx), hb = bx * bx + by * by, hc = cx * cx + cy * cy, vertex = { - x: (cy * hb - by * hc) / d + ax, - y: (bx * hc - cx * hb) / d + ay - }; - d3_geom_voronoiSetEdgeEnd(rArc.edge, lSite, rSite, vertex); - newArc.edge = d3_geom_voronoiCreateEdge(lSite, site, null, vertex); - rArc.edge = d3_geom_voronoiCreateEdge(site, rSite, null, vertex); - d3_geom_voronoiAttachCircle(lArc); - d3_geom_voronoiAttachCircle(rArc); - } - function d3_geom_voronoiLeftBreakPoint(arc, directrix) { - var site = arc.site, rfocx = site.x, rfocy = site.y, pby2 = rfocy - directrix; - if (!pby2) return rfocx; - var lArc = arc.P; - if (!lArc) return -Infinity; - site = lArc.site; - var lfocx = site.x, lfocy = site.y, plby2 = lfocy - directrix; - if (!plby2) return lfocx; - var hl = lfocx - rfocx, aby2 = 1 / pby2 - 1 / plby2, b = hl / plby2; - if (aby2) return (-b + Math.sqrt(b * b - 2 * aby2 * (hl * hl / (-2 * plby2) - lfocy + plby2 / 2 + rfocy - pby2 / 2))) / aby2 + rfocx; - return (rfocx + lfocx) / 2; - } - function d3_geom_voronoiRightBreakPoint(arc, directrix) { - var rArc = arc.N; - if (rArc) return d3_geom_voronoiLeftBreakPoint(rArc, directrix); - var site = arc.site; - return site.y === directrix ? site.x : Infinity; - } - function d3_geom_voronoiCell(site) { - this.site = site; - this.edges = []; - } - d3_geom_voronoiCell.prototype.prepare = function() { - var halfEdges = this.edges, iHalfEdge = halfEdges.length, edge; - while (iHalfEdge--) { - edge = halfEdges[iHalfEdge].edge; - if (!edge.b || !edge.a) halfEdges.splice(iHalfEdge, 1); - } - halfEdges.sort(d3_geom_voronoiHalfEdgeOrder); - return halfEdges.length; - }; - function d3_geom_voronoiCloseCells(extent) { - var x0 = extent[0][0], x1 = extent[1][0], y0 = extent[0][1], y1 = extent[1][1], x2, y2, x3, y3, cells = d3_geom_voronoiCells, iCell = cells.length, cell, iHalfEdge, halfEdges, nHalfEdges, start, end; - while (iCell--) { - cell = cells[iCell]; - if (!cell || !cell.prepare()) continue; - halfEdges = cell.edges; - nHalfEdges = halfEdges.length; - iHalfEdge = 0; - while (iHalfEdge < nHalfEdges) { - end = halfEdges[iHalfEdge].end(), x3 = end.x, y3 = end.y; - start = halfEdges[++iHalfEdge % nHalfEdges].start(), x2 = start.x, y2 = start.y; - if (abs(x3 - x2) > ε || abs(y3 - y2) > ε) { - halfEdges.splice(iHalfEdge, 0, new d3_geom_voronoiHalfEdge(d3_geom_voronoiCreateBorderEdge(cell.site, end, abs(x3 - x0) < ε && y1 - y3 > ε ? { - x: x0, - y: abs(x2 - x0) < ε ? y2 : y1 - } : abs(y3 - y1) < ε && x1 - x3 > ε ? { - x: abs(y2 - y1) < ε ? x2 : x1, - y: y1 - } : abs(x3 - x1) < ε && y3 - y0 > ε ? { - x: x1, - y: abs(x2 - x1) < ε ? y2 : y0 - } : abs(y3 - y0) < ε && x3 - x0 > ε ? { - x: abs(y2 - y0) < ε ? x2 : x0, - y: y0 - } : null), cell.site, null)); - ++nHalfEdges; - } - } - } - } - function d3_geom_voronoiHalfEdgeOrder(a, b) { - return b.angle - a.angle; - } - function d3_geom_voronoiCircle() { - d3_geom_voronoiRedBlackNode(this); - this.x = this.y = this.arc = this.site = this.cy = null; - } - function d3_geom_voronoiAttachCircle(arc) { - var lArc = arc.P, rArc = arc.N; - if (!lArc || !rArc) return; - var lSite = lArc.site, cSite = arc.site, rSite = rArc.site; - if (lSite === rSite) return; - var bx = cSite.x, by = cSite.y, ax = lSite.x - bx, ay = lSite.y - by, cx = rSite.x - bx, cy = rSite.y - by; - var d = 2 * (ax * cy - ay * cx); - if (d >= -ε2) return; - var ha = ax * ax + ay * ay, hc = cx * cx + cy * cy, x = (cy * ha - ay * hc) / d, y = (ax * hc - cx * ha) / d, cy = y + by; - var circle = d3_geom_voronoiCirclePool.pop() || new d3_geom_voronoiCircle(); - circle.arc = arc; - circle.site = cSite; - circle.x = x + bx; - circle.y = cy + Math.sqrt(x * x + y * y); - circle.cy = cy; - arc.circle = circle; - var before = null, node = d3_geom_voronoiCircles._; - while (node) { - if (circle.y < node.y || circle.y === node.y && circle.x <= node.x) { - if (node.L) node = node.L; else { - before = node.P; - break; - } - } else { - if (node.R) node = node.R; else { - before = node; - break; - } - } - } - d3_geom_voronoiCircles.insert(before, circle); - if (!before) d3_geom_voronoiFirstCircle = circle; - } - function d3_geom_voronoiDetachCircle(arc) { - var circle = arc.circle; - if (circle) { - if (!circle.P) d3_geom_voronoiFirstCircle = circle.N; - d3_geom_voronoiCircles.remove(circle); - d3_geom_voronoiCirclePool.push(circle); - d3_geom_voronoiRedBlackNode(circle); - arc.circle = null; - } - } - function d3_geom_voronoiClipEdges(extent) { - var edges = d3_geom_voronoiEdges, clip = d3_geom_clipLine(extent[0][0], extent[0][1], extent[1][0], extent[1][1]), i = edges.length, e; - while (i--) { - e = edges[i]; - if (!d3_geom_voronoiConnectEdge(e, extent) || !clip(e) || abs(e.a.x - e.b.x) < ε && abs(e.a.y - e.b.y) < ε) { - e.a = e.b = null; - edges.splice(i, 1); - } - } - } - function d3_geom_voronoiConnectEdge(edge, extent) { - var vb = edge.b; - if (vb) return true; - var va = edge.a, x0 = extent[0][0], x1 = extent[1][0], y0 = extent[0][1], y1 = extent[1][1], lSite = edge.l, rSite = edge.r, lx = lSite.x, ly = lSite.y, rx = rSite.x, ry = rSite.y, fx = (lx + rx) / 2, fy = (ly + ry) / 2, fm, fb; - if (ry === ly) { - if (fx < x0 || fx >= x1) return; - if (lx > rx) { - if (!va) va = { - x: fx, - y: y0 - }; else if (va.y >= y1) return; - vb = { - x: fx, - y: y1 - }; - } else { - if (!va) va = { - x: fx, - y: y1 - }; else if (va.y < y0) return; - vb = { - x: fx, - y: y0 - }; - } - } else { - fm = (lx - rx) / (ry - ly); - fb = fy - fm * fx; - if (fm < -1 || fm > 1) { - if (lx > rx) { - if (!va) va = { - x: (y0 - fb) / fm, - y: y0 - }; else if (va.y >= y1) return; - vb = { - x: (y1 - fb) / fm, - y: y1 - }; - } else { - if (!va) va = { - x: (y1 - fb) / fm, - y: y1 - }; else if (va.y < y0) return; - vb = { - x: (y0 - fb) / fm, - y: y0 - }; - } - } else { - if (ly < ry) { - if (!va) va = { - x: x0, - y: fm * x0 + fb - }; else if (va.x >= x1) return; - vb = { - x: x1, - y: fm * x1 + fb - }; - } else { - if (!va) va = { - x: x1, - y: fm * x1 + fb - }; else if (va.x < x0) return; - vb = { - x: x0, - y: fm * x0 + fb - }; - } - } - } - edge.a = va; - edge.b = vb; - return true; - } - function d3_geom_voronoiEdge(lSite, rSite) { - this.l = lSite; - this.r = rSite; - this.a = this.b = null; - } - function d3_geom_voronoiCreateEdge(lSite, rSite, va, vb) { - var edge = new d3_geom_voronoiEdge(lSite, rSite); - d3_geom_voronoiEdges.push(edge); - if (va) d3_geom_voronoiSetEdgeEnd(edge, lSite, rSite, va); - if (vb) d3_geom_voronoiSetEdgeEnd(edge, rSite, lSite, vb); - d3_geom_voronoiCells[lSite.i].edges.push(new d3_geom_voronoiHalfEdge(edge, lSite, rSite)); - d3_geom_voronoiCells[rSite.i].edges.push(new d3_geom_voronoiHalfEdge(edge, rSite, lSite)); - return edge; - } - function d3_geom_voronoiCreateBorderEdge(lSite, va, vb) { - var edge = new d3_geom_voronoiEdge(lSite, null); - edge.a = va; - edge.b = vb; - d3_geom_voronoiEdges.push(edge); - return edge; - } - function d3_geom_voronoiSetEdgeEnd(edge, lSite, rSite, vertex) { - if (!edge.a && !edge.b) { - edge.a = vertex; - edge.l = lSite; - edge.r = rSite; - } else if (edge.l === rSite) { - edge.b = vertex; - } else { - edge.a = vertex; - } - } - function d3_geom_voronoiHalfEdge(edge, lSite, rSite) { - var va = edge.a, vb = edge.b; - this.edge = edge; - this.site = lSite; - this.angle = rSite ? Math.atan2(rSite.y - lSite.y, rSite.x - lSite.x) : edge.l === lSite ? Math.atan2(vb.x - va.x, va.y - vb.y) : Math.atan2(va.x - vb.x, vb.y - va.y); - } - d3_geom_voronoiHalfEdge.prototype = { - start: function() { - return this.edge.l === this.site ? this.edge.a : this.edge.b; - }, - end: function() { - return this.edge.l === this.site ? this.edge.b : this.edge.a; - } - }; - function d3_geom_voronoiRedBlackTree() { - this._ = null; - } - function d3_geom_voronoiRedBlackNode(node) { - node.U = node.C = node.L = node.R = node.P = node.N = null; - } - d3_geom_voronoiRedBlackTree.prototype = { - insert: function(after, node) { - var parent, grandpa, uncle; - if (after) { - node.P = after; - node.N = after.N; - if (after.N) after.N.P = node; - after.N = node; - if (after.R) { - after = after.R; - while (after.L) after = after.L; - after.L = node; - } else { - after.R = node; - } - parent = after; - } else if (this._) { - after = d3_geom_voronoiRedBlackFirst(this._); - node.P = null; - node.N = after; - after.P = after.L = node; - parent = after; - } else { - node.P = node.N = null; - this._ = node; - parent = null; - } - node.L = node.R = null; - node.U = parent; - node.C = true; - after = node; - while (parent && parent.C) { - grandpa = parent.U; - if (parent === grandpa.L) { - uncle = grandpa.R; - if (uncle && uncle.C) { - parent.C = uncle.C = false; - grandpa.C = true; - after = grandpa; - } else { - if (after === parent.R) { - d3_geom_voronoiRedBlackRotateLeft(this, parent); - after = parent; - parent = after.U; - } - parent.C = false; - grandpa.C = true; - d3_geom_voronoiRedBlackRotateRight(this, grandpa); - } - } else { - uncle = grandpa.L; - if (uncle && uncle.C) { - parent.C = uncle.C = false; - grandpa.C = true; - after = grandpa; - } else { - if (after === parent.L) { - d3_geom_voronoiRedBlackRotateRight(this, parent); - after = parent; - parent = after.U; - } - parent.C = false; - grandpa.C = true; - d3_geom_voronoiRedBlackRotateLeft(this, grandpa); - } - } - parent = after.U; - } - this._.C = false; - }, - remove: function(node) { - if (node.N) node.N.P = node.P; - if (node.P) node.P.N = node.N; - node.N = node.P = null; - var parent = node.U, sibling, left = node.L, right = node.R, next, red; - if (!left) next = right; else if (!right) next = left; else next = d3_geom_voronoiRedBlackFirst(right); - if (parent) { - if (parent.L === node) parent.L = next; else parent.R = next; - } else { - this._ = next; - } - if (left && right) { - red = next.C; - next.C = node.C; - next.L = left; - left.U = next; - if (next !== right) { - parent = next.U; - next.U = node.U; - node = next.R; - parent.L = node; - next.R = right; - right.U = next; - } else { - next.U = parent; - parent = next; - node = next.R; - } - } else { - red = node.C; - node = next; - } - if (node) node.U = parent; - if (red) return; - if (node && node.C) { - node.C = false; - return; - } - do { - if (node === this._) break; - if (node === parent.L) { - sibling = parent.R; - if (sibling.C) { - sibling.C = false; - parent.C = true; - d3_geom_voronoiRedBlackRotateLeft(this, parent); - sibling = parent.R; - } - if (sibling.L && sibling.L.C || sibling.R && sibling.R.C) { - if (!sibling.R || !sibling.R.C) { - sibling.L.C = false; - sibling.C = true; - d3_geom_voronoiRedBlackRotateRight(this, sibling); - sibling = parent.R; - } - sibling.C = parent.C; - parent.C = sibling.R.C = false; - d3_geom_voronoiRedBlackRotateLeft(this, parent); - node = this._; - break; - } - } else { - sibling = parent.L; - if (sibling.C) { - sibling.C = false; - parent.C = true; - d3_geom_voronoiRedBlackRotateRight(this, parent); - sibling = parent.L; - } - if (sibling.L && sibling.L.C || sibling.R && sibling.R.C) { - if (!sibling.L || !sibling.L.C) { - sibling.R.C = false; - sibling.C = true; - d3_geom_voronoiRedBlackRotateLeft(this, sibling); - sibling = parent.L; - } - sibling.C = parent.C; - parent.C = sibling.L.C = false; - d3_geom_voronoiRedBlackRotateRight(this, parent); - node = this._; - break; - } - } - sibling.C = true; - node = parent; - parent = parent.U; - } while (!node.C); - if (node) node.C = false; - } - }; - function d3_geom_voronoiRedBlackRotateLeft(tree, node) { - var p = node, q = node.R, parent = p.U; - if (parent) { - if (parent.L === p) parent.L = q; else parent.R = q; - } else { - tree._ = q; - } - q.U = parent; - p.U = q; - p.R = q.L; - if (p.R) p.R.U = p; - q.L = p; - } - function d3_geom_voronoiRedBlackRotateRight(tree, node) { - var p = node, q = node.L, parent = p.U; - if (parent) { - if (parent.L === p) parent.L = q; else parent.R = q; - } else { - tree._ = q; - } - q.U = parent; - p.U = q; - p.L = q.R; - if (p.L) p.L.U = p; - q.R = p; - } - function d3_geom_voronoiRedBlackFirst(node) { - while (node.L) node = node.L; - return node; - } - function d3_geom_voronoi(sites, bbox) { - var site = sites.sort(d3_geom_voronoiVertexOrder).pop(), x0, y0, circle; - d3_geom_voronoiEdges = []; - d3_geom_voronoiCells = new Array(sites.length); - d3_geom_voronoiBeaches = new d3_geom_voronoiRedBlackTree(); - d3_geom_voronoiCircles = new d3_geom_voronoiRedBlackTree(); - while (true) { - circle = d3_geom_voronoiFirstCircle; - if (site && (!circle || site.y < circle.y || site.y === circle.y && site.x < circle.x)) { - if (site.x !== x0 || site.y !== y0) { - d3_geom_voronoiCells[site.i] = new d3_geom_voronoiCell(site); - d3_geom_voronoiAddBeach(site); - x0 = site.x, y0 = site.y; - } - site = sites.pop(); - } else if (circle) { - d3_geom_voronoiRemoveBeach(circle.arc); - } else { - break; - } - } - if (bbox) d3_geom_voronoiClipEdges(bbox), d3_geom_voronoiCloseCells(bbox); - var diagram = { - cells: d3_geom_voronoiCells, - edges: d3_geom_voronoiEdges - }; - d3_geom_voronoiBeaches = d3_geom_voronoiCircles = d3_geom_voronoiEdges = d3_geom_voronoiCells = null; - return diagram; - } - function d3_geom_voronoiVertexOrder(a, b) { - return b.y - a.y || b.x - a.x; - } - d3.geom.voronoi = function(points) { - var x = d3_geom_pointX, y = d3_geom_pointY, fx = x, fy = y, clipExtent = d3_geom_voronoiClipExtent; - if (points) return voronoi(points); - function voronoi(data) { - var polygons = new Array(data.length), x0 = clipExtent[0][0], y0 = clipExtent[0][1], x1 = clipExtent[1][0], y1 = clipExtent[1][1]; - d3_geom_voronoi(sites(data), clipExtent).cells.forEach(function(cell, i) { - var edges = cell.edges, site = cell.site, polygon = polygons[i] = edges.length ? edges.map(function(e) { - var s = e.start(); - return [ s.x, s.y ]; - }) : site.x >= x0 && site.x <= x1 && site.y >= y0 && site.y <= y1 ? [ [ x0, y1 ], [ x1, y1 ], [ x1, y0 ], [ x0, y0 ] ] : []; - polygon.point = data[i]; - }); - return polygons; - } - function sites(data) { - return data.map(function(d, i) { - return { - x: Math.round(fx(d, i) / ε) * ε, - y: Math.round(fy(d, i) / ε) * ε, - i: i - }; - }); - } - voronoi.links = function(data) { - return d3_geom_voronoi(sites(data)).edges.filter(function(edge) { - return edge.l && edge.r; - }).map(function(edge) { - return { - source: data[edge.l.i], - target: data[edge.r.i] - }; - }); - }; - voronoi.triangles = function(data) { - var triangles = []; - d3_geom_voronoi(sites(data)).cells.forEach(function(cell, i) { - var site = cell.site, edges = cell.edges.sort(d3_geom_voronoiHalfEdgeOrder), j = -1, m = edges.length, e0, s0, e1 = edges[m - 1].edge, s1 = e1.l === site ? e1.r : e1.l; - while (++j < m) { - e0 = e1; - s0 = s1; - e1 = edges[j].edge; - s1 = e1.l === site ? e1.r : e1.l; - if (i < s0.i && i < s1.i && d3_geom_voronoiTriangleArea(site, s0, s1) < 0) { - triangles.push([ data[i], data[s0.i], data[s1.i] ]); - } - } - }); - return triangles; - }; - voronoi.x = function(_) { - return arguments.length ? (fx = d3_functor(x = _), voronoi) : x; - }; - voronoi.y = function(_) { - return arguments.length ? (fy = d3_functor(y = _), voronoi) : y; - }; - voronoi.clipExtent = function(_) { - if (!arguments.length) return clipExtent === d3_geom_voronoiClipExtent ? null : clipExtent; - clipExtent = _ == null ? d3_geom_voronoiClipExtent : _; - return voronoi; - }; - voronoi.size = function(_) { - if (!arguments.length) return clipExtent === d3_geom_voronoiClipExtent ? null : clipExtent && clipExtent[1]; - return voronoi.clipExtent(_ && [ [ 0, 0 ], _ ]); - }; - return voronoi; - }; - var d3_geom_voronoiClipExtent = [ [ -1e6, -1e6 ], [ 1e6, 1e6 ] ]; - function d3_geom_voronoiTriangleArea(a, b, c) { - return (a.x - c.x) * (b.y - a.y) - (a.x - b.x) * (c.y - a.y); - } - d3.geom.delaunay = function(vertices) { - return d3.geom.voronoi().triangles(vertices); - }; - d3.geom.quadtree = function(points, x1, y1, x2, y2) { - var x = d3_geom_pointX, y = d3_geom_pointY, compat; - if (compat = arguments.length) { - x = d3_geom_quadtreeCompatX; - y = d3_geom_quadtreeCompatY; - if (compat === 3) { - y2 = y1; - x2 = x1; - y1 = x1 = 0; - } - return quadtree(points); - } - function quadtree(data) { - var d, fx = d3_functor(x), fy = d3_functor(y), xs, ys, i, n, x1_, y1_, x2_, y2_; - if (x1 != null) { - x1_ = x1, y1_ = y1, x2_ = x2, y2_ = y2; - } else { - x2_ = y2_ = -(x1_ = y1_ = Infinity); - xs = [], ys = []; - n = data.length; - if (compat) for (i = 0; i < n; ++i) { - d = data[i]; - if (d.x < x1_) x1_ = d.x; - if (d.y < y1_) y1_ = d.y; - if (d.x > x2_) x2_ = d.x; - if (d.y > y2_) y2_ = d.y; - xs.push(d.x); - ys.push(d.y); - } else for (i = 0; i < n; ++i) { - var x_ = +fx(d = data[i], i), y_ = +fy(d, i); - if (x_ < x1_) x1_ = x_; - if (y_ < y1_) y1_ = y_; - if (x_ > x2_) x2_ = x_; - if (y_ > y2_) y2_ = y_; - xs.push(x_); - ys.push(y_); - } - } - var dx = x2_ - x1_, dy = y2_ - y1_; - if (dx > dy) y2_ = y1_ + dx; else x2_ = x1_ + dy; - function insert(n, d, x, y, x1, y1, x2, y2) { - if (isNaN(x) || isNaN(y)) return; - if (n.leaf) { - var nx = n.x, ny = n.y; - if (nx != null) { - if (abs(nx - x) + abs(ny - y) < .01) { - insertChild(n, d, x, y, x1, y1, x2, y2); - } else { - var nPoint = n.point; - n.x = n.y = n.point = null; - insertChild(n, nPoint, nx, ny, x1, y1, x2, y2); - insertChild(n, d, x, y, x1, y1, x2, y2); - } - } else { - n.x = x, n.y = y, n.point = d; - } - } else { - insertChild(n, d, x, y, x1, y1, x2, y2); - } - } - function insertChild(n, d, x, y, x1, y1, x2, y2) { - var xm = (x1 + x2) * .5, ym = (y1 + y2) * .5, right = x >= xm, below = y >= ym, i = below << 1 | right; - n.leaf = false; - n = n.nodes[i] || (n.nodes[i] = d3_geom_quadtreeNode()); - if (right) x1 = xm; else x2 = xm; - if (below) y1 = ym; else y2 = ym; - insert(n, d, x, y, x1, y1, x2, y2); - } - var root = d3_geom_quadtreeNode(); - root.add = function(d) { - insert(root, d, +fx(d, ++i), +fy(d, i), x1_, y1_, x2_, y2_); - }; - root.visit = function(f) { - d3_geom_quadtreeVisit(f, root, x1_, y1_, x2_, y2_); - }; - root.find = function(point) { - return d3_geom_quadtreeFind(root, point[0], point[1], x1_, y1_, x2_, y2_); - }; - i = -1; - if (x1 == null) { - while (++i < n) { - insert(root, data[i], xs[i], ys[i], x1_, y1_, x2_, y2_); - } - --i; - } else data.forEach(root.add); - xs = ys = data = d = null; - return root; - } - quadtree.x = function(_) { - return arguments.length ? (x = _, quadtree) : x; - }; - quadtree.y = function(_) { - return arguments.length ? (y = _, quadtree) : y; - }; - quadtree.extent = function(_) { - if (!arguments.length) return x1 == null ? null : [ [ x1, y1 ], [ x2, y2 ] ]; - if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = +_[0][0], y1 = +_[0][1], x2 = +_[1][0], - y2 = +_[1][1]; - return quadtree; - }; - quadtree.size = function(_) { - if (!arguments.length) return x1 == null ? null : [ x2 - x1, y2 - y1 ]; - if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = y1 = 0, x2 = +_[0], y2 = +_[1]; - return quadtree; - }; - return quadtree; - }; - function d3_geom_quadtreeCompatX(d) { - return d.x; - } - function d3_geom_quadtreeCompatY(d) { - return d.y; - } - function d3_geom_quadtreeNode() { - return { - leaf: true, - nodes: [], - point: null, - x: null, - y: null - }; - } - function d3_geom_quadtreeVisit(f, node, x1, y1, x2, y2) { - if (!f(node, x1, y1, x2, y2)) { - var sx = (x1 + x2) * .5, sy = (y1 + y2) * .5, children = node.nodes; - if (children[0]) d3_geom_quadtreeVisit(f, children[0], x1, y1, sx, sy); - if (children[1]) d3_geom_quadtreeVisit(f, children[1], sx, y1, x2, sy); - if (children[2]) d3_geom_quadtreeVisit(f, children[2], x1, sy, sx, y2); - if (children[3]) d3_geom_quadtreeVisit(f, children[3], sx, sy, x2, y2); - } - } - function d3_geom_quadtreeFind(root, x, y, x0, y0, x3, y3) { - var minDistance2 = Infinity, closestPoint; - (function find(node, x1, y1, x2, y2) { - if (x1 > x3 || y1 > y3 || x2 < x0 || y2 < y0) return; - if (point = node.point) { - var point, dx = x - node.x, dy = y - node.y, distance2 = dx * dx + dy * dy; - if (distance2 < minDistance2) { - var distance = Math.sqrt(minDistance2 = distance2); - x0 = x - distance, y0 = y - distance; - x3 = x + distance, y3 = y + distance; - closestPoint = point; - } - } - var children = node.nodes, xm = (x1 + x2) * .5, ym = (y1 + y2) * .5, right = x >= xm, below = y >= ym; - for (var i = below << 1 | right, j = i + 4; i < j; ++i) { - if (node = children[i & 3]) switch (i & 3) { - case 0: - find(node, x1, y1, xm, ym); - break; - - case 1: - find(node, xm, y1, x2, ym); - break; - - case 2: - find(node, x1, ym, xm, y2); - break; - - case 3: - find(node, xm, ym, x2, y2); - break; - } - } - })(root, x0, y0, x3, y3); - return closestPoint; - } - d3.interpolateRgb = d3_interpolateRgb; - function d3_interpolateRgb(a, b) { - a = d3.rgb(a); - b = d3.rgb(b); - var ar = a.r, ag = a.g, ab = a.b, br = b.r - ar, bg = b.g - ag, bb = b.b - ab; - return function(t) { - return "#" + d3_rgb_hex(Math.round(ar + br * t)) + d3_rgb_hex(Math.round(ag + bg * t)) + d3_rgb_hex(Math.round(ab + bb * t)); - }; - } - d3.interpolateObject = d3_interpolateObject; - function d3_interpolateObject(a, b) { - var i = {}, c = {}, k; - for (k in a) { - if (k in b) { - i[k] = d3_interpolate(a[k], b[k]); - } else { - c[k] = a[k]; - } - } - for (k in b) { - if (!(k in a)) { - c[k] = b[k]; - } - } - return function(t) { - for (k in i) c[k] = i[k](t); - return c; - }; - } - d3.interpolateNumber = d3_interpolateNumber; - function d3_interpolateNumber(a, b) { - a = +a, b = +b; - return function(t) { - return a * (1 - t) + b * t; - }; - } - d3.interpolateString = d3_interpolateString; - function d3_interpolateString(a, b) { - var bi = d3_interpolate_numberA.lastIndex = d3_interpolate_numberB.lastIndex = 0, am, bm, bs, i = -1, s = [], q = []; - a = a + "", b = b + ""; - while ((am = d3_interpolate_numberA.exec(a)) && (bm = d3_interpolate_numberB.exec(b))) { - if ((bs = bm.index) > bi) { - bs = b.slice(bi, bs); - if (s[i]) s[i] += bs; else s[++i] = bs; - } - if ((am = am[0]) === (bm = bm[0])) { - if (s[i]) s[i] += bm; else s[++i] = bm; - } else { - s[++i] = null; - q.push({ - i: i, - x: d3_interpolateNumber(am, bm) - }); - } - bi = d3_interpolate_numberB.lastIndex; - } - if (bi < b.length) { - bs = b.slice(bi); - if (s[i]) s[i] += bs; else s[++i] = bs; - } - return s.length < 2 ? q[0] ? (b = q[0].x, function(t) { - return b(t) + ""; - }) : function() { - return b; - } : (b = q.length, function(t) { - for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t); - return s.join(""); - }); - } - var d3_interpolate_numberA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, d3_interpolate_numberB = new RegExp(d3_interpolate_numberA.source, "g"); - d3.interpolate = d3_interpolate; - function d3_interpolate(a, b) { - var i = d3.interpolators.length, f; - while (--i >= 0 && !(f = d3.interpolators[i](a, b))) ; - return f; - } - d3.interpolators = [ function(a, b) { - var t = typeof b; - return (t === "string" ? d3_rgb_names.has(b.toLowerCase()) || /^(#|rgb\(|hsl\()/i.test(b) ? d3_interpolateRgb : d3_interpolateString : b instanceof d3_color ? d3_interpolateRgb : Array.isArray(b) ? d3_interpolateArray : t === "object" && isNaN(b) ? d3_interpolateObject : d3_interpolateNumber)(a, b); - } ]; - d3.interpolateArray = d3_interpolateArray; - function d3_interpolateArray(a, b) { - var x = [], c = [], na = a.length, nb = b.length, n0 = Math.min(a.length, b.length), i; - for (i = 0; i < n0; ++i) x.push(d3_interpolate(a[i], b[i])); - for (;i < na; ++i) c[i] = a[i]; - for (;i < nb; ++i) c[i] = b[i]; - return function(t) { - for (i = 0; i < n0; ++i) c[i] = x[i](t); - return c; - }; - } - var d3_ease_default = function() { - return d3_identity; - }; - var d3_ease = d3.map({ - linear: d3_ease_default, - poly: d3_ease_poly, - quad: function() { - return d3_ease_quad; - }, - cubic: function() { - return d3_ease_cubic; - }, - sin: function() { - return d3_ease_sin; - }, - exp: function() { - return d3_ease_exp; - }, - circle: function() { - return d3_ease_circle; - }, - elastic: d3_ease_elastic, - back: d3_ease_back, - bounce: function() { - return d3_ease_bounce; - } - }); - var d3_ease_mode = d3.map({ - "in": d3_identity, - out: d3_ease_reverse, - "in-out": d3_ease_reflect, - "out-in": function(f) { - return d3_ease_reflect(d3_ease_reverse(f)); - } - }); - d3.ease = function(name) { - var i = name.indexOf("-"), t = i >= 0 ? name.slice(0, i) : name, m = i >= 0 ? name.slice(i + 1) : "in"; - t = d3_ease.get(t) || d3_ease_default; - m = d3_ease_mode.get(m) || d3_identity; - return d3_ease_clamp(m(t.apply(null, d3_arraySlice.call(arguments, 1)))); - }; - function d3_ease_clamp(f) { - return function(t) { - return t <= 0 ? 0 : t >= 1 ? 1 : f(t); - }; - } - function d3_ease_reverse(f) { - return function(t) { - return 1 - f(1 - t); - }; - } - function d3_ease_reflect(f) { - return function(t) { - return .5 * (t < .5 ? f(2 * t) : 2 - f(2 - 2 * t)); - }; - } - function d3_ease_quad(t) { - return t * t; - } - function d3_ease_cubic(t) { - return t * t * t; - } - function d3_ease_cubicInOut(t) { - if (t <= 0) return 0; - if (t >= 1) return 1; - var t2 = t * t, t3 = t2 * t; - return 4 * (t < .5 ? t3 : 3 * (t - t2) + t3 - .75); - } - function d3_ease_poly(e) { - return function(t) { - return Math.pow(t, e); - }; - } - function d3_ease_sin(t) { - return 1 - Math.cos(t * halfπ); - } - function d3_ease_exp(t) { - return Math.pow(2, 10 * (t - 1)); - } - function d3_ease_circle(t) { - return 1 - Math.sqrt(1 - t * t); - } - function d3_ease_elastic(a, p) { - var s; - if (arguments.length < 2) p = .45; - if (arguments.length) s = p / τ * Math.asin(1 / a); else a = 1, s = p / 4; - return function(t) { - return 1 + a * Math.pow(2, -10 * t) * Math.sin((t - s) * τ / p); - }; - } - function d3_ease_back(s) { - if (!s) s = 1.70158; - return function(t) { - return t * t * ((s + 1) * t - s); - }; - } - function d3_ease_bounce(t) { - return t < 1 / 2.75 ? 7.5625 * t * t : t < 2 / 2.75 ? 7.5625 * (t -= 1.5 / 2.75) * t + .75 : t < 2.5 / 2.75 ? 7.5625 * (t -= 2.25 / 2.75) * t + .9375 : 7.5625 * (t -= 2.625 / 2.75) * t + .984375; - } - d3.interpolateHcl = d3_interpolateHcl; - function d3_interpolateHcl(a, b) { - a = d3.hcl(a); - b = d3.hcl(b); - var ah = a.h, ac = a.c, al = a.l, bh = b.h - ah, bc = b.c - ac, bl = b.l - al; - if (isNaN(bc)) bc = 0, ac = isNaN(ac) ? b.c : ac; - if (isNaN(bh)) bh = 0, ah = isNaN(ah) ? b.h : ah; else if (bh > 180) bh -= 360; else if (bh < -180) bh += 360; - return function(t) { - return d3_hcl_lab(ah + bh * t, ac + bc * t, al + bl * t) + ""; - }; - } - d3.interpolateHsl = d3_interpolateHsl; - function d3_interpolateHsl(a, b) { - a = d3.hsl(a); - b = d3.hsl(b); - var ah = a.h, as = a.s, al = a.l, bh = b.h - ah, bs = b.s - as, bl = b.l - al; - if (isNaN(bs)) bs = 0, as = isNaN(as) ? b.s : as; - if (isNaN(bh)) bh = 0, ah = isNaN(ah) ? b.h : ah; else if (bh > 180) bh -= 360; else if (bh < -180) bh += 360; - return function(t) { - return d3_hsl_rgb(ah + bh * t, as + bs * t, al + bl * t) + ""; - }; - } - d3.interpolateLab = d3_interpolateLab; - function d3_interpolateLab(a, b) { - a = d3.lab(a); - b = d3.lab(b); - var al = a.l, aa = a.a, ab = a.b, bl = b.l - al, ba = b.a - aa, bb = b.b - ab; - return function(t) { - return d3_lab_rgb(al + bl * t, aa + ba * t, ab + bb * t) + ""; - }; - } - d3.interpolateRound = d3_interpolateRound; - function d3_interpolateRound(a, b) { - b -= a; - return function(t) { - return Math.round(a + b * t); - }; - } - d3.transform = function(string) { - var g = d3_document.createElementNS(d3.ns.prefix.svg, "g"); - return (d3.transform = function(string) { - if (string != null) { - g.setAttribute("transform", string); - var t = g.transform.baseVal.consolidate(); - } - return new d3_transform(t ? t.matrix : d3_transformIdentity); - })(string); - }; - function d3_transform(m) { - var r0 = [ m.a, m.b ], r1 = [ m.c, m.d ], kx = d3_transformNormalize(r0), kz = d3_transformDot(r0, r1), ky = d3_transformNormalize(d3_transformCombine(r1, r0, -kz)) || 0; - if (r0[0] * r1[1] < r1[0] * r0[1]) { - r0[0] *= -1; - r0[1] *= -1; - kx *= -1; - kz *= -1; - } - this.rotate = (kx ? Math.atan2(r0[1], r0[0]) : Math.atan2(-r1[0], r1[1])) * d3_degrees; - this.translate = [ m.e, m.f ]; - this.scale = [ kx, ky ]; - this.skew = ky ? Math.atan2(kz, ky) * d3_degrees : 0; - } - d3_transform.prototype.toString = function() { - return "translate(" + this.translate + ")rotate(" + this.rotate + ")skewX(" + this.skew + ")scale(" + this.scale + ")"; - }; - function d3_transformDot(a, b) { - return a[0] * b[0] + a[1] * b[1]; - } - function d3_transformNormalize(a) { - var k = Math.sqrt(d3_transformDot(a, a)); - if (k) { - a[0] /= k; - a[1] /= k; - } - return k; - } - function d3_transformCombine(a, b, k) { - a[0] += k * b[0]; - a[1] += k * b[1]; - return a; - } - var d3_transformIdentity = { - a: 1, - b: 0, - c: 0, - d: 1, - e: 0, - f: 0 - }; - d3.interpolateTransform = d3_interpolateTransform; - function d3_interpolateTransformPop(s) { - return s.length ? s.pop() + "," : ""; - } - function d3_interpolateTranslate(ta, tb, s, q) { - if (ta[0] !== tb[0] || ta[1] !== tb[1]) { - var i = s.push("translate(", null, ",", null, ")"); - q.push({ - i: i - 4, - x: d3_interpolateNumber(ta[0], tb[0]) - }, { - i: i - 2, - x: d3_interpolateNumber(ta[1], tb[1]) - }); - } else if (tb[0] || tb[1]) { - s.push("translate(" + tb + ")"); - } - } - function d3_interpolateRotate(ra, rb, s, q) { - if (ra !== rb) { - if (ra - rb > 180) rb += 360; else if (rb - ra > 180) ra += 360; - q.push({ - i: s.push(d3_interpolateTransformPop(s) + "rotate(", null, ")") - 2, - x: d3_interpolateNumber(ra, rb) - }); - } else if (rb) { - s.push(d3_interpolateTransformPop(s) + "rotate(" + rb + ")"); - } - } - function d3_interpolateSkew(wa, wb, s, q) { - if (wa !== wb) { - q.push({ - i: s.push(d3_interpolateTransformPop(s) + "skewX(", null, ")") - 2, - x: d3_interpolateNumber(wa, wb) - }); - } else if (wb) { - s.push(d3_interpolateTransformPop(s) + "skewX(" + wb + ")"); - } - } - function d3_interpolateScale(ka, kb, s, q) { - if (ka[0] !== kb[0] || ka[1] !== kb[1]) { - var i = s.push(d3_interpolateTransformPop(s) + "scale(", null, ",", null, ")"); - q.push({ - i: i - 4, - x: d3_interpolateNumber(ka[0], kb[0]) - }, { - i: i - 2, - x: d3_interpolateNumber(ka[1], kb[1]) - }); - } else if (kb[0] !== 1 || kb[1] !== 1) { - s.push(d3_interpolateTransformPop(s) + "scale(" + kb + ")"); - } - } - function d3_interpolateTransform(a, b) { - var s = [], q = []; - a = d3.transform(a), b = d3.transform(b); - d3_interpolateTranslate(a.translate, b.translate, s, q); - d3_interpolateRotate(a.rotate, b.rotate, s, q); - d3_interpolateSkew(a.skew, b.skew, s, q); - d3_interpolateScale(a.scale, b.scale, s, q); - a = b = null; - return function(t) { - var i = -1, n = q.length, o; - while (++i < n) s[(o = q[i]).i] = o.x(t); - return s.join(""); - }; - } - function d3_uninterpolateNumber(a, b) { - b = (b -= a = +a) || 1 / b; - return function(x) { - return (x - a) / b; - }; - } - function d3_uninterpolateClamp(a, b) { - b = (b -= a = +a) || 1 / b; - return function(x) { - return Math.max(0, Math.min(1, (x - a) / b)); - }; - } - d3.layout = {}; - d3.layout.bundle = function() { - return function(links) { - var paths = [], i = -1, n = links.length; - while (++i < n) paths.push(d3_layout_bundlePath(links[i])); - return paths; - }; - }; - function d3_layout_bundlePath(link) { - var start = link.source, end = link.target, lca = d3_layout_bundleLeastCommonAncestor(start, end), points = [ start ]; - while (start !== lca) { - start = start.parent; - points.push(start); - } - var k = points.length; - while (end !== lca) { - points.splice(k, 0, end); - end = end.parent; - } - return points; - } - function d3_layout_bundleAncestors(node) { - var ancestors = [], parent = node.parent; - while (parent != null) { - ancestors.push(node); - node = parent; - parent = parent.parent; - } - ancestors.push(node); - return ancestors; - } - function d3_layout_bundleLeastCommonAncestor(a, b) { - if (a === b) return a; - var aNodes = d3_layout_bundleAncestors(a), bNodes = d3_layout_bundleAncestors(b), aNode = aNodes.pop(), bNode = bNodes.pop(), sharedNode = null; - while (aNode === bNode) { - sharedNode = aNode; - aNode = aNodes.pop(); - bNode = bNodes.pop(); - } - return sharedNode; - } - d3.layout.chord = function() { - var chord = {}, chords, groups, matrix, n, padding = 0, sortGroups, sortSubgroups, sortChords; - function relayout() { - var subgroups = {}, groupSums = [], groupIndex = d3.range(n), subgroupIndex = [], k, x, x0, i, j; - chords = []; - groups = []; - k = 0, i = -1; - while (++i < n) { - x = 0, j = -1; - while (++j < n) { - x += matrix[i][j]; - } - groupSums.push(x); - subgroupIndex.push(d3.range(n)); - k += x; - } - if (sortGroups) { - groupIndex.sort(function(a, b) { - return sortGroups(groupSums[a], groupSums[b]); - }); - } - if (sortSubgroups) { - subgroupIndex.forEach(function(d, i) { - d.sort(function(a, b) { - return sortSubgroups(matrix[i][a], matrix[i][b]); - }); - }); - } - k = (τ - padding * n) / k; - x = 0, i = -1; - while (++i < n) { - x0 = x, j = -1; - while (++j < n) { - var di = groupIndex[i], dj = subgroupIndex[di][j], v = matrix[di][dj], a0 = x, a1 = x += v * k; - subgroups[di + "-" + dj] = { - index: di, - subindex: dj, - startAngle: a0, - endAngle: a1, - value: v - }; - } - groups[di] = { - index: di, - startAngle: x0, - endAngle: x, - value: groupSums[di] - }; - x += padding; - } - i = -1; - while (++i < n) { - j = i - 1; - while (++j < n) { - var source = subgroups[i + "-" + j], target = subgroups[j + "-" + i]; - if (source.value || target.value) { - chords.push(source.value < target.value ? { - source: target, - target: source - } : { - source: source, - target: target - }); - } - } - } - if (sortChords) resort(); - } - function resort() { - chords.sort(function(a, b) { - return sortChords((a.source.value + a.target.value) / 2, (b.source.value + b.target.value) / 2); - }); - } - chord.matrix = function(x) { - if (!arguments.length) return matrix; - n = (matrix = x) && matrix.length; - chords = groups = null; - return chord; - }; - chord.padding = function(x) { - if (!arguments.length) return padding; - padding = x; - chords = groups = null; - return chord; - }; - chord.sortGroups = function(x) { - if (!arguments.length) return sortGroups; - sortGroups = x; - chords = groups = null; - return chord; - }; - chord.sortSubgroups = function(x) { - if (!arguments.length) return sortSubgroups; - sortSubgroups = x; - chords = null; - return chord; - }; - chord.sortChords = function(x) { - if (!arguments.length) return sortChords; - sortChords = x; - if (chords) resort(); - return chord; - }; - chord.chords = function() { - if (!chords) relayout(); - return chords; - }; - chord.groups = function() { - if (!groups) relayout(); - return groups; - }; - return chord; - }; - d3.layout.force = function() { - var force = {}, event = d3.dispatch("start", "tick", "end"), timer, size = [ 1, 1 ], drag, alpha, friction = .9, linkDistance = d3_layout_forceLinkDistance, linkStrength = d3_layout_forceLinkStrength, charge = -30, chargeDistance2 = d3_layout_forceChargeDistance2, gravity = .1, theta2 = .64, nodes = [], links = [], distances, strengths, charges; - function repulse(node) { - return function(quad, x1, _, x2) { - if (quad.point !== node) { - var dx = quad.cx - node.x, dy = quad.cy - node.y, dw = x2 - x1, dn = dx * dx + dy * dy; - if (dw * dw / theta2 < dn) { - if (dn < chargeDistance2) { - var k = quad.charge / dn; - node.px -= dx * k; - node.py -= dy * k; - } - return true; - } - if (quad.point && dn && dn < chargeDistance2) { - var k = quad.pointCharge / dn; - node.px -= dx * k; - node.py -= dy * k; - } - } - return !quad.charge; - }; - } - force.tick = function() { - if ((alpha *= .99) < .005) { - timer = null; - event.end({ - type: "end", - alpha: alpha = 0 - }); - return true; - } - var n = nodes.length, m = links.length, q, i, o, s, t, l, k, x, y; - for (i = 0; i < m; ++i) { - o = links[i]; - s = o.source; - t = o.target; - x = t.x - s.x; - y = t.y - s.y; - if (l = x * x + y * y) { - l = alpha * strengths[i] * ((l = Math.sqrt(l)) - distances[i]) / l; - x *= l; - y *= l; - t.x -= x * (k = s.weight + t.weight ? s.weight / (s.weight + t.weight) : .5); - t.y -= y * k; - s.x += x * (k = 1 - k); - s.y += y * k; - } - } - if (k = alpha * gravity) { - x = size[0] / 2; - y = size[1] / 2; - i = -1; - if (k) while (++i < n) { - o = nodes[i]; - o.x += (x - o.x) * k; - o.y += (y - o.y) * k; - } - } - if (charge) { - d3_layout_forceAccumulate(q = d3.geom.quadtree(nodes), alpha, charges); - i = -1; - while (++i < n) { - if (!(o = nodes[i]).fixed) { - q.visit(repulse(o)); - } - } - } - i = -1; - while (++i < n) { - o = nodes[i]; - if (o.fixed) { - o.x = o.px; - o.y = o.py; - } else { - o.x -= (o.px - (o.px = o.x)) * friction; - o.y -= (o.py - (o.py = o.y)) * friction; - } - } - event.tick({ - type: "tick", - alpha: alpha - }); - }; - force.nodes = function(x) { - if (!arguments.length) return nodes; - nodes = x; - return force; - }; - force.links = function(x) { - if (!arguments.length) return links; - links = x; - return force; - }; - force.size = function(x) { - if (!arguments.length) return size; - size = x; - return force; - }; - force.linkDistance = function(x) { - if (!arguments.length) return linkDistance; - linkDistance = typeof x === "function" ? x : +x; - return force; - }; - force.distance = force.linkDistance; - force.linkStrength = function(x) { - if (!arguments.length) return linkStrength; - linkStrength = typeof x === "function" ? x : +x; - return force; - }; - force.friction = function(x) { - if (!arguments.length) return friction; - friction = +x; - return force; - }; - force.charge = function(x) { - if (!arguments.length) return charge; - charge = typeof x === "function" ? x : +x; - return force; - }; - force.chargeDistance = function(x) { - if (!arguments.length) return Math.sqrt(chargeDistance2); - chargeDistance2 = x * x; - return force; - }; - force.gravity = function(x) { - if (!arguments.length) return gravity; - gravity = +x; - return force; - }; - force.theta = function(x) { - if (!arguments.length) return Math.sqrt(theta2); - theta2 = x * x; - return force; - }; - force.alpha = function(x) { - if (!arguments.length) return alpha; - x = +x; - if (alpha) { - if (x > 0) { - alpha = x; - } else { - timer.c = null, timer.t = NaN, timer = null; - event.end({ - type: "end", - alpha: alpha = 0 - }); - } - } else if (x > 0) { - event.start({ - type: "start", - alpha: alpha = x - }); - timer = d3_timer(force.tick); - } - return force; - }; - force.start = function() { - var i, n = nodes.length, m = links.length, w = size[0], h = size[1], neighbors, o; - for (i = 0; i < n; ++i) { - (o = nodes[i]).index = i; - o.weight = 0; - } - for (i = 0; i < m; ++i) { - o = links[i]; - if (typeof o.source == "number") o.source = nodes[o.source]; - if (typeof o.target == "number") o.target = nodes[o.target]; - ++o.source.weight; - ++o.target.weight; - } - for (i = 0; i < n; ++i) { - o = nodes[i]; - if (isNaN(o.x)) o.x = position("x", w); - if (isNaN(o.y)) o.y = position("y", h); - if (isNaN(o.px)) o.px = o.x; - if (isNaN(o.py)) o.py = o.y; - } - distances = []; - if (typeof linkDistance === "function") for (i = 0; i < m; ++i) distances[i] = +linkDistance.call(this, links[i], i); else for (i = 0; i < m; ++i) distances[i] = linkDistance; - strengths = []; - if (typeof linkStrength === "function") for (i = 0; i < m; ++i) strengths[i] = +linkStrength.call(this, links[i], i); else for (i = 0; i < m; ++i) strengths[i] = linkStrength; - charges = []; - if (typeof charge === "function") for (i = 0; i < n; ++i) charges[i] = +charge.call(this, nodes[i], i); else for (i = 0; i < n; ++i) charges[i] = charge; - function position(dimension, size) { - if (!neighbors) { - neighbors = new Array(n); - for (j = 0; j < n; ++j) { - neighbors[j] = []; - } - for (j = 0; j < m; ++j) { - var o = links[j]; - neighbors[o.source.index].push(o.target); - neighbors[o.target.index].push(o.source); - } - } - var candidates = neighbors[i], j = -1, l = candidates.length, x; - while (++j < l) if (!isNaN(x = candidates[j][dimension])) return x; - return Math.random() * size; - } - return force.resume(); - }; - force.resume = function() { - return force.alpha(.1); - }; - force.stop = function() { - return force.alpha(0); - }; - force.drag = function() { - if (!drag) drag = d3.behavior.drag().origin(d3_identity).on("dragstart.force", d3_layout_forceDragstart).on("drag.force", dragmove).on("dragend.force", d3_layout_forceDragend); - if (!arguments.length) return drag; - this.on("mouseover.force", d3_layout_forceMouseover).on("mouseout.force", d3_layout_forceMouseout).call(drag); - }; - function dragmove(d) { - d.px = d3.event.x, d.py = d3.event.y; - force.resume(); - } - return d3.rebind(force, event, "on"); - }; - function d3_layout_forceDragstart(d) { - d.fixed |= 2; - } - function d3_layout_forceDragend(d) { - d.fixed &= ~6; - } - function d3_layout_forceMouseover(d) { - d.fixed |= 4; - d.px = d.x, d.py = d.y; - } - function d3_layout_forceMouseout(d) { - d.fixed &= ~4; - } - function d3_layout_forceAccumulate(quad, alpha, charges) { - var cx = 0, cy = 0; - quad.charge = 0; - if (!quad.leaf) { - var nodes = quad.nodes, n = nodes.length, i = -1, c; - while (++i < n) { - c = nodes[i]; - if (c == null) continue; - d3_layout_forceAccumulate(c, alpha, charges); - quad.charge += c.charge; - cx += c.charge * c.cx; - cy += c.charge * c.cy; - } - } - if (quad.point) { - if (!quad.leaf) { - quad.point.x += Math.random() - .5; - quad.point.y += Math.random() - .5; - } - var k = alpha * charges[quad.point.index]; - quad.charge += quad.pointCharge = k; - cx += k * quad.point.x; - cy += k * quad.point.y; - } - quad.cx = cx / quad.charge; - quad.cy = cy / quad.charge; - } - var d3_layout_forceLinkDistance = 20, d3_layout_forceLinkStrength = 1, d3_layout_forceChargeDistance2 = Infinity; - d3.layout.hierarchy = function() { - var sort = d3_layout_hierarchySort, children = d3_layout_hierarchyChildren, value = d3_layout_hierarchyValue; - function hierarchy(root) { - var stack = [ root ], nodes = [], node; - root.depth = 0; - while ((node = stack.pop()) != null) { - nodes.push(node); - if ((childs = children.call(hierarchy, node, node.depth)) && (n = childs.length)) { - var n, childs, child; - while (--n >= 0) { - stack.push(child = childs[n]); - child.parent = node; - child.depth = node.depth + 1; - } - if (value) node.value = 0; - node.children = childs; - } else { - if (value) node.value = +value.call(hierarchy, node, node.depth) || 0; - delete node.children; - } - } - d3_layout_hierarchyVisitAfter(root, function(node) { - var childs, parent; - if (sort && (childs = node.children)) childs.sort(sort); - if (value && (parent = node.parent)) parent.value += node.value; - }); - return nodes; - } - hierarchy.sort = function(x) { - if (!arguments.length) return sort; - sort = x; - return hierarchy; - }; - hierarchy.children = function(x) { - if (!arguments.length) return children; - children = x; - return hierarchy; - }; - hierarchy.value = function(x) { - if (!arguments.length) return value; - value = x; - return hierarchy; - }; - hierarchy.revalue = function(root) { - if (value) { - d3_layout_hierarchyVisitBefore(root, function(node) { - if (node.children) node.value = 0; - }); - d3_layout_hierarchyVisitAfter(root, function(node) { - var parent; - if (!node.children) node.value = +value.call(hierarchy, node, node.depth) || 0; - if (parent = node.parent) parent.value += node.value; - }); - } - return root; - }; - return hierarchy; - }; - function d3_layout_hierarchyRebind(object, hierarchy) { - d3.rebind(object, hierarchy, "sort", "children", "value"); - object.nodes = object; - object.links = d3_layout_hierarchyLinks; - return object; - } - function d3_layout_hierarchyVisitBefore(node, callback) { - var nodes = [ node ]; - while ((node = nodes.pop()) != null) { - callback(node); - if ((children = node.children) && (n = children.length)) { - var n, children; - while (--n >= 0) nodes.push(children[n]); - } - } - } - function d3_layout_hierarchyVisitAfter(node, callback) { - var nodes = [ node ], nodes2 = []; - while ((node = nodes.pop()) != null) { - nodes2.push(node); - if ((children = node.children) && (n = children.length)) { - var i = -1, n, children; - while (++i < n) nodes.push(children[i]); - } - } - while ((node = nodes2.pop()) != null) { - callback(node); - } - } - function d3_layout_hierarchyChildren(d) { - return d.children; - } - function d3_layout_hierarchyValue(d) { - return d.value; - } - function d3_layout_hierarchySort(a, b) { - return b.value - a.value; - } - function d3_layout_hierarchyLinks(nodes) { - return d3.merge(nodes.map(function(parent) { - return (parent.children || []).map(function(child) { - return { - source: parent, - target: child - }; - }); - })); - } - d3.layout.partition = function() { - var hierarchy = d3.layout.hierarchy(), size = [ 1, 1 ]; - function position(node, x, dx, dy) { - var children = node.children; - node.x = x; - node.y = node.depth * dy; - node.dx = dx; - node.dy = dy; - if (children && (n = children.length)) { - var i = -1, n, c, d; - dx = node.value ? dx / node.value : 0; - while (++i < n) { - position(c = children[i], x, d = c.value * dx, dy); - x += d; - } - } - } - function depth(node) { - var children = node.children, d = 0; - if (children && (n = children.length)) { - var i = -1, n; - while (++i < n) d = Math.max(d, depth(children[i])); - } - return 1 + d; - } - function partition(d, i) { - var nodes = hierarchy.call(this, d, i); - position(nodes[0], 0, size[0], size[1] / depth(nodes[0])); - return nodes; - } - partition.size = function(x) { - if (!arguments.length) return size; - size = x; - return partition; - }; - return d3_layout_hierarchyRebind(partition, hierarchy); - }; - d3.layout.pie = function() { - var value = Number, sort = d3_layout_pieSortByValue, startAngle = 0, endAngle = τ, padAngle = 0; - function pie(data) { - var n = data.length, values = data.map(function(d, i) { - return +value.call(pie, d, i); - }), a = +(typeof startAngle === "function" ? startAngle.apply(this, arguments) : startAngle), da = (typeof endAngle === "function" ? endAngle.apply(this, arguments) : endAngle) - a, p = Math.min(Math.abs(da) / n, +(typeof padAngle === "function" ? padAngle.apply(this, arguments) : padAngle)), pa = p * (da < 0 ? -1 : 1), sum = d3.sum(values), k = sum ? (da - n * pa) / sum : 0, index = d3.range(n), arcs = [], v; - if (sort != null) index.sort(sort === d3_layout_pieSortByValue ? function(i, j) { - return values[j] - values[i]; - } : function(i, j) { - return sort(data[i], data[j]); - }); - index.forEach(function(i) { - arcs[i] = { - data: data[i], - value: v = values[i], - startAngle: a, - endAngle: a += v * k + pa, - padAngle: p - }; - }); - return arcs; - } - pie.value = function(_) { - if (!arguments.length) return value; - value = _; - return pie; - }; - pie.sort = function(_) { - if (!arguments.length) return sort; - sort = _; - return pie; - }; - pie.startAngle = function(_) { - if (!arguments.length) return startAngle; - startAngle = _; - return pie; - }; - pie.endAngle = function(_) { - if (!arguments.length) return endAngle; - endAngle = _; - return pie; - }; - pie.padAngle = function(_) { - if (!arguments.length) return padAngle; - padAngle = _; - return pie; - }; - return pie; - }; - var d3_layout_pieSortByValue = {}; - d3.layout.stack = function() { - var values = d3_identity, order = d3_layout_stackOrderDefault, offset = d3_layout_stackOffsetZero, out = d3_layout_stackOut, x = d3_layout_stackX, y = d3_layout_stackY; - function stack(data, index) { - if (!(n = data.length)) return data; - var series = data.map(function(d, i) { - return values.call(stack, d, i); - }); - var points = series.map(function(d) { - return d.map(function(v, i) { - return [ x.call(stack, v, i), y.call(stack, v, i) ]; - }); - }); - var orders = order.call(stack, points, index); - series = d3.permute(series, orders); - points = d3.permute(points, orders); - var offsets = offset.call(stack, points, index); - var m = series[0].length, n, i, j, o; - for (j = 0; j < m; ++j) { - out.call(stack, series[0][j], o = offsets[j], points[0][j][1]); - for (i = 1; i < n; ++i) { - out.call(stack, series[i][j], o += points[i - 1][j][1], points[i][j][1]); - } - } - return data; - } - stack.values = function(x) { - if (!arguments.length) return values; - values = x; - return stack; - }; - stack.order = function(x) { - if (!arguments.length) return order; - order = typeof x === "function" ? x : d3_layout_stackOrders.get(x) || d3_layout_stackOrderDefault; - return stack; - }; - stack.offset = function(x) { - if (!arguments.length) return offset; - offset = typeof x === "function" ? x : d3_layout_stackOffsets.get(x) || d3_layout_stackOffsetZero; - return stack; - }; - stack.x = function(z) { - if (!arguments.length) return x; - x = z; - return stack; - }; - stack.y = function(z) { - if (!arguments.length) return y; - y = z; - return stack; - }; - stack.out = function(z) { - if (!arguments.length) return out; - out = z; - return stack; - }; - return stack; - }; - function d3_layout_stackX(d) { - return d.x; - } - function d3_layout_stackY(d) { - return d.y; - } - function d3_layout_stackOut(d, y0, y) { - d.y0 = y0; - d.y = y; - } - var d3_layout_stackOrders = d3.map({ - "inside-out": function(data) { - var n = data.length, i, j, max = data.map(d3_layout_stackMaxIndex), sums = data.map(d3_layout_stackReduceSum), index = d3.range(n).sort(function(a, b) { - return max[a] - max[b]; - }), top = 0, bottom = 0, tops = [], bottoms = []; - for (i = 0; i < n; ++i) { - j = index[i]; - if (top < bottom) { - top += sums[j]; - tops.push(j); - } else { - bottom += sums[j]; - bottoms.push(j); - } - } - return bottoms.reverse().concat(tops); - }, - reverse: function(data) { - return d3.range(data.length).reverse(); - }, - "default": d3_layout_stackOrderDefault - }); - var d3_layout_stackOffsets = d3.map({ - silhouette: function(data) { - var n = data.length, m = data[0].length, sums = [], max = 0, i, j, o, y0 = []; - for (j = 0; j < m; ++j) { - for (i = 0, o = 0; i < n; i++) o += data[i][j][1]; - if (o > max) max = o; - sums.push(o); - } - for (j = 0; j < m; ++j) { - y0[j] = (max - sums[j]) / 2; - } - return y0; - }, - wiggle: function(data) { - var n = data.length, x = data[0], m = x.length, i, j, k, s1, s2, s3, dx, o, o0, y0 = []; - y0[0] = o = o0 = 0; - for (j = 1; j < m; ++j) { - for (i = 0, s1 = 0; i < n; ++i) s1 += data[i][j][1]; - for (i = 0, s2 = 0, dx = x[j][0] - x[j - 1][0]; i < n; ++i) { - for (k = 0, s3 = (data[i][j][1] - data[i][j - 1][1]) / (2 * dx); k < i; ++k) { - s3 += (data[k][j][1] - data[k][j - 1][1]) / dx; - } - s2 += s3 * data[i][j][1]; - } - y0[j] = o -= s1 ? s2 / s1 * dx : 0; - if (o < o0) o0 = o; - } - for (j = 0; j < m; ++j) y0[j] -= o0; - return y0; - }, - expand: function(data) { - var n = data.length, m = data[0].length, k = 1 / n, i, j, o, y0 = []; - for (j = 0; j < m; ++j) { - for (i = 0, o = 0; i < n; i++) o += data[i][j][1]; - if (o) for (i = 0; i < n; i++) data[i][j][1] /= o; else for (i = 0; i < n; i++) data[i][j][1] = k; - } - for (j = 0; j < m; ++j) y0[j] = 0; - return y0; - }, - zero: d3_layout_stackOffsetZero - }); - function d3_layout_stackOrderDefault(data) { - return d3.range(data.length); - } - function d3_layout_stackOffsetZero(data) { - var j = -1, m = data[0].length, y0 = []; - while (++j < m) y0[j] = 0; - return y0; - } - function d3_layout_stackMaxIndex(array) { - var i = 1, j = 0, v = array[0][1], k, n = array.length; - for (;i < n; ++i) { - if ((k = array[i][1]) > v) { - j = i; - v = k; - } - } - return j; - } - function d3_layout_stackReduceSum(d) { - return d.reduce(d3_layout_stackSum, 0); - } - function d3_layout_stackSum(p, d) { - return p + d[1]; - } - d3.layout.histogram = function() { - var frequency = true, valuer = Number, ranger = d3_layout_histogramRange, binner = d3_layout_histogramBinSturges; - function histogram(data, i) { - var bins = [], values = data.map(valuer, this), range = ranger.call(this, values, i), thresholds = binner.call(this, range, values, i), bin, i = -1, n = values.length, m = thresholds.length - 1, k = frequency ? 1 : 1 / n, x; - while (++i < m) { - bin = bins[i] = []; - bin.dx = thresholds[i + 1] - (bin.x = thresholds[i]); - bin.y = 0; - } - if (m > 0) { - i = -1; - while (++i < n) { - x = values[i]; - if (x >= range[0] && x <= range[1]) { - bin = bins[d3.bisect(thresholds, x, 1, m) - 1]; - bin.y += k; - bin.push(data[i]); - } - } - } - return bins; - } - histogram.value = function(x) { - if (!arguments.length) return valuer; - valuer = x; - return histogram; - }; - histogram.range = function(x) { - if (!arguments.length) return ranger; - ranger = d3_functor(x); - return histogram; - }; - histogram.bins = function(x) { - if (!arguments.length) return binner; - binner = typeof x === "number" ? function(range) { - return d3_layout_histogramBinFixed(range, x); - } : d3_functor(x); - return histogram; - }; - histogram.frequency = function(x) { - if (!arguments.length) return frequency; - frequency = !!x; - return histogram; - }; - return histogram; - }; - function d3_layout_histogramBinSturges(range, values) { - return d3_layout_histogramBinFixed(range, Math.ceil(Math.log(values.length) / Math.LN2 + 1)); - } - function d3_layout_histogramBinFixed(range, n) { - var x = -1, b = +range[0], m = (range[1] - b) / n, f = []; - while (++x <= n) f[x] = m * x + b; - return f; - } - function d3_layout_histogramRange(values) { - return [ d3.min(values), d3.max(values) ]; - } - d3.layout.pack = function() { - var hierarchy = d3.layout.hierarchy().sort(d3_layout_packSort), padding = 0, size = [ 1, 1 ], radius; - function pack(d, i) { - var nodes = hierarchy.call(this, d, i), root = nodes[0], w = size[0], h = size[1], r = radius == null ? Math.sqrt : typeof radius === "function" ? radius : function() { - return radius; - }; - root.x = root.y = 0; - d3_layout_hierarchyVisitAfter(root, function(d) { - d.r = +r(d.value); - }); - d3_layout_hierarchyVisitAfter(root, d3_layout_packSiblings); - if (padding) { - var dr = padding * (radius ? 1 : Math.max(2 * root.r / w, 2 * root.r / h)) / 2; - d3_layout_hierarchyVisitAfter(root, function(d) { - d.r += dr; - }); - d3_layout_hierarchyVisitAfter(root, d3_layout_packSiblings); - d3_layout_hierarchyVisitAfter(root, function(d) { - d.r -= dr; - }); - } - d3_layout_packTransform(root, w / 2, h / 2, radius ? 1 : 1 / Math.max(2 * root.r / w, 2 * root.r / h)); - return nodes; - } - pack.size = function(_) { - if (!arguments.length) return size; - size = _; - return pack; - }; - pack.radius = function(_) { - if (!arguments.length) return radius; - radius = _ == null || typeof _ === "function" ? _ : +_; - return pack; - }; - pack.padding = function(_) { - if (!arguments.length) return padding; - padding = +_; - return pack; - }; - return d3_layout_hierarchyRebind(pack, hierarchy); - }; - function d3_layout_packSort(a, b) { - return a.value - b.value; - } - function d3_layout_packInsert(a, b) { - var c = a._pack_next; - a._pack_next = b; - b._pack_prev = a; - b._pack_next = c; - c._pack_prev = b; - } - function d3_layout_packSplice(a, b) { - a._pack_next = b; - b._pack_prev = a; - } - function d3_layout_packIntersects(a, b) { - var dx = b.x - a.x, dy = b.y - a.y, dr = a.r + b.r; - return .999 * dr * dr > dx * dx + dy * dy; - } - function d3_layout_packSiblings(node) { - if (!(nodes = node.children) || !(n = nodes.length)) return; - var nodes, xMin = Infinity, xMax = -Infinity, yMin = Infinity, yMax = -Infinity, a, b, c, i, j, k, n; - function bound(node) { - xMin = Math.min(node.x - node.r, xMin); - xMax = Math.max(node.x + node.r, xMax); - yMin = Math.min(node.y - node.r, yMin); - yMax = Math.max(node.y + node.r, yMax); - } - nodes.forEach(d3_layout_packLink); - a = nodes[0]; - a.x = -a.r; - a.y = 0; - bound(a); - if (n > 1) { - b = nodes[1]; - b.x = b.r; - b.y = 0; - bound(b); - if (n > 2) { - c = nodes[2]; - d3_layout_packPlace(a, b, c); - bound(c); - d3_layout_packInsert(a, c); - a._pack_prev = c; - d3_layout_packInsert(c, b); - b = a._pack_next; - for (i = 3; i < n; i++) { - d3_layout_packPlace(a, b, c = nodes[i]); - var isect = 0, s1 = 1, s2 = 1; - for (j = b._pack_next; j !== b; j = j._pack_next, s1++) { - if (d3_layout_packIntersects(j, c)) { - isect = 1; - break; - } - } - if (isect == 1) { - for (k = a._pack_prev; k !== j._pack_prev; k = k._pack_prev, s2++) { - if (d3_layout_packIntersects(k, c)) { - break; - } - } - } - if (isect) { - if (s1 < s2 || s1 == s2 && b.r < a.r) d3_layout_packSplice(a, b = j); else d3_layout_packSplice(a = k, b); - i--; - } else { - d3_layout_packInsert(a, c); - b = c; - bound(c); - } - } - } - } - var cx = (xMin + xMax) / 2, cy = (yMin + yMax) / 2, cr = 0; - for (i = 0; i < n; i++) { - c = nodes[i]; - c.x -= cx; - c.y -= cy; - cr = Math.max(cr, c.r + Math.sqrt(c.x * c.x + c.y * c.y)); - } - node.r = cr; - nodes.forEach(d3_layout_packUnlink); - } - function d3_layout_packLink(node) { - node._pack_next = node._pack_prev = node; - } - function d3_layout_packUnlink(node) { - delete node._pack_next; - delete node._pack_prev; - } - function d3_layout_packTransform(node, x, y, k) { - var children = node.children; - node.x = x += k * node.x; - node.y = y += k * node.y; - node.r *= k; - if (children) { - var i = -1, n = children.length; - while (++i < n) d3_layout_packTransform(children[i], x, y, k); - } - } - function d3_layout_packPlace(a, b, c) { - var db = a.r + c.r, dx = b.x - a.x, dy = b.y - a.y; - if (db && (dx || dy)) { - var da = b.r + c.r, dc = dx * dx + dy * dy; - da *= da; - db *= db; - var x = .5 + (db - da) / (2 * dc), y = Math.sqrt(Math.max(0, 2 * da * (db + dc) - (db -= dc) * db - da * da)) / (2 * dc); - c.x = a.x + x * dx + y * dy; - c.y = a.y + x * dy - y * dx; - } else { - c.x = a.x + db; - c.y = a.y; - } - } - d3.layout.tree = function() { - var hierarchy = d3.layout.hierarchy().sort(null).value(null), separation = d3_layout_treeSeparation, size = [ 1, 1 ], nodeSize = null; - function tree(d, i) { - var nodes = hierarchy.call(this, d, i), root0 = nodes[0], root1 = wrapTree(root0); - d3_layout_hierarchyVisitAfter(root1, firstWalk), root1.parent.m = -root1.z; - d3_layout_hierarchyVisitBefore(root1, secondWalk); - if (nodeSize) d3_layout_hierarchyVisitBefore(root0, sizeNode); else { - var left = root0, right = root0, bottom = root0; - d3_layout_hierarchyVisitBefore(root0, function(node) { - if (node.x < left.x) left = node; - if (node.x > right.x) right = node; - if (node.depth > bottom.depth) bottom = node; - }); - var tx = separation(left, right) / 2 - left.x, kx = size[0] / (right.x + separation(right, left) / 2 + tx), ky = size[1] / (bottom.depth || 1); - d3_layout_hierarchyVisitBefore(root0, function(node) { - node.x = (node.x + tx) * kx; - node.y = node.depth * ky; - }); - } - return nodes; - } - function wrapTree(root0) { - var root1 = { - A: null, - children: [ root0 ] - }, queue = [ root1 ], node1; - while ((node1 = queue.pop()) != null) { - for (var children = node1.children, child, i = 0, n = children.length; i < n; ++i) { - queue.push((children[i] = child = { - _: children[i], - parent: node1, - children: (child = children[i].children) && child.slice() || [], - A: null, - a: null, - z: 0, - m: 0, - c: 0, - s: 0, - t: null, - i: i - }).a = child); - } - } - return root1.children[0]; - } - function firstWalk(v) { - var children = v.children, siblings = v.parent.children, w = v.i ? siblings[v.i - 1] : null; - if (children.length) { - d3_layout_treeShift(v); - var midpoint = (children[0].z + children[children.length - 1].z) / 2; - if (w) { - v.z = w.z + separation(v._, w._); - v.m = v.z - midpoint; - } else { - v.z = midpoint; - } - } else if (w) { - v.z = w.z + separation(v._, w._); - } - v.parent.A = apportion(v, w, v.parent.A || siblings[0]); - } - function secondWalk(v) { - v._.x = v.z + v.parent.m; - v.m += v.parent.m; - } - function apportion(v, w, ancestor) { - if (w) { - var vip = v, vop = v, vim = w, vom = vip.parent.children[0], sip = vip.m, sop = vop.m, sim = vim.m, som = vom.m, shift; - while (vim = d3_layout_treeRight(vim), vip = d3_layout_treeLeft(vip), vim && vip) { - vom = d3_layout_treeLeft(vom); - vop = d3_layout_treeRight(vop); - vop.a = v; - shift = vim.z + sim - vip.z - sip + separation(vim._, vip._); - if (shift > 0) { - d3_layout_treeMove(d3_layout_treeAncestor(vim, v, ancestor), v, shift); - sip += shift; - sop += shift; - } - sim += vim.m; - sip += vip.m; - som += vom.m; - sop += vop.m; - } - if (vim && !d3_layout_treeRight(vop)) { - vop.t = vim; - vop.m += sim - sop; - } - if (vip && !d3_layout_treeLeft(vom)) { - vom.t = vip; - vom.m += sip - som; - ancestor = v; - } - } - return ancestor; - } - function sizeNode(node) { - node.x *= size[0]; - node.y = node.depth * size[1]; - } - tree.separation = function(x) { - if (!arguments.length) return separation; - separation = x; - return tree; - }; - tree.size = function(x) { - if (!arguments.length) return nodeSize ? null : size; - nodeSize = (size = x) == null ? sizeNode : null; - return tree; - }; - tree.nodeSize = function(x) { - if (!arguments.length) return nodeSize ? size : null; - nodeSize = (size = x) == null ? null : sizeNode; - return tree; - }; - return d3_layout_hierarchyRebind(tree, hierarchy); - }; - function d3_layout_treeSeparation(a, b) { - return a.parent == b.parent ? 1 : 2; - } - function d3_layout_treeLeft(v) { - var children = v.children; - return children.length ? children[0] : v.t; - } - function d3_layout_treeRight(v) { - var children = v.children, n; - return (n = children.length) ? children[n - 1] : v.t; - } - function d3_layout_treeMove(wm, wp, shift) { - var change = shift / (wp.i - wm.i); - wp.c -= change; - wp.s += shift; - wm.c += change; - wp.z += shift; - wp.m += shift; - } - function d3_layout_treeShift(v) { - var shift = 0, change = 0, children = v.children, i = children.length, w; - while (--i >= 0) { - w = children[i]; - w.z += shift; - w.m += shift; - shift += w.s + (change += w.c); - } - } - function d3_layout_treeAncestor(vim, v, ancestor) { - return vim.a.parent === v.parent ? vim.a : ancestor; - } - d3.layout.cluster = function() { - var hierarchy = d3.layout.hierarchy().sort(null).value(null), separation = d3_layout_treeSeparation, size = [ 1, 1 ], nodeSize = false; - function cluster(d, i) { - var nodes = hierarchy.call(this, d, i), root = nodes[0], previousNode, x = 0; - d3_layout_hierarchyVisitAfter(root, function(node) { - var children = node.children; - if (children && children.length) { - node.x = d3_layout_clusterX(children); - node.y = d3_layout_clusterY(children); - } else { - node.x = previousNode ? x += separation(node, previousNode) : 0; - node.y = 0; - previousNode = node; - } - }); - var left = d3_layout_clusterLeft(root), right = d3_layout_clusterRight(root), x0 = left.x - separation(left, right) / 2, x1 = right.x + separation(right, left) / 2; - d3_layout_hierarchyVisitAfter(root, nodeSize ? function(node) { - node.x = (node.x - root.x) * size[0]; - node.y = (root.y - node.y) * size[1]; - } : function(node) { - node.x = (node.x - x0) / (x1 - x0) * size[0]; - node.y = (1 - (root.y ? node.y / root.y : 1)) * size[1]; - }); - return nodes; - } - cluster.separation = function(x) { - if (!arguments.length) return separation; - separation = x; - return cluster; - }; - cluster.size = function(x) { - if (!arguments.length) return nodeSize ? null : size; - nodeSize = (size = x) == null; - return cluster; - }; - cluster.nodeSize = function(x) { - if (!arguments.length) return nodeSize ? size : null; - nodeSize = (size = x) != null; - return cluster; - }; - return d3_layout_hierarchyRebind(cluster, hierarchy); - }; - function d3_layout_clusterY(children) { - return 1 + d3.max(children, function(child) { - return child.y; - }); - } - function d3_layout_clusterX(children) { - return children.reduce(function(x, child) { - return x + child.x; - }, 0) / children.length; - } - function d3_layout_clusterLeft(node) { - var children = node.children; - return children && children.length ? d3_layout_clusterLeft(children[0]) : node; - } - function d3_layout_clusterRight(node) { - var children = node.children, n; - return children && (n = children.length) ? d3_layout_clusterRight(children[n - 1]) : node; - } - d3.layout.treemap = function() { - var hierarchy = d3.layout.hierarchy(), round = Math.round, size = [ 1, 1 ], padding = null, pad = d3_layout_treemapPadNull, sticky = false, stickies, mode = "squarify", ratio = .5 * (1 + Math.sqrt(5)); - function scale(children, k) { - var i = -1, n = children.length, child, area; - while (++i < n) { - area = (child = children[i]).value * (k < 0 ? 0 : k); - child.area = isNaN(area) || area <= 0 ? 0 : area; - } - } - function squarify(node) { - var children = node.children; - if (children && children.length) { - var rect = pad(node), row = [], remaining = children.slice(), child, best = Infinity, score, u = mode === "slice" ? rect.dx : mode === "dice" ? rect.dy : mode === "slice-dice" ? node.depth & 1 ? rect.dy : rect.dx : Math.min(rect.dx, rect.dy), n; - scale(remaining, rect.dx * rect.dy / node.value); - row.area = 0; - while ((n = remaining.length) > 0) { - row.push(child = remaining[n - 1]); - row.area += child.area; - if (mode !== "squarify" || (score = worst(row, u)) <= best) { - remaining.pop(); - best = score; - } else { - row.area -= row.pop().area; - position(row, u, rect, false); - u = Math.min(rect.dx, rect.dy); - row.length = row.area = 0; - best = Infinity; - } - } - if (row.length) { - position(row, u, rect, true); - row.length = row.area = 0; - } - children.forEach(squarify); - } - } - function stickify(node) { - var children = node.children; - if (children && children.length) { - var rect = pad(node), remaining = children.slice(), child, row = []; - scale(remaining, rect.dx * rect.dy / node.value); - row.area = 0; - while (child = remaining.pop()) { - row.push(child); - row.area += child.area; - if (child.z != null) { - position(row, child.z ? rect.dx : rect.dy, rect, !remaining.length); - row.length = row.area = 0; - } - } - children.forEach(stickify); - } - } - function worst(row, u) { - var s = row.area, r, rmax = 0, rmin = Infinity, i = -1, n = row.length; - while (++i < n) { - if (!(r = row[i].area)) continue; - if (r < rmin) rmin = r; - if (r > rmax) rmax = r; - } - s *= s; - u *= u; - return s ? Math.max(u * rmax * ratio / s, s / (u * rmin * ratio)) : Infinity; - } - function position(row, u, rect, flush) { - var i = -1, n = row.length, x = rect.x, y = rect.y, v = u ? round(row.area / u) : 0, o; - if (u == rect.dx) { - if (flush || v > rect.dy) v = rect.dy; - while (++i < n) { - o = row[i]; - o.x = x; - o.y = y; - o.dy = v; - x += o.dx = Math.min(rect.x + rect.dx - x, v ? round(o.area / v) : 0); - } - o.z = true; - o.dx += rect.x + rect.dx - x; - rect.y += v; - rect.dy -= v; - } else { - if (flush || v > rect.dx) v = rect.dx; - while (++i < n) { - o = row[i]; - o.x = x; - o.y = y; - o.dx = v; - y += o.dy = Math.min(rect.y + rect.dy - y, v ? round(o.area / v) : 0); - } - o.z = false; - o.dy += rect.y + rect.dy - y; - rect.x += v; - rect.dx -= v; - } - } - function treemap(d) { - var nodes = stickies || hierarchy(d), root = nodes[0]; - root.x = root.y = 0; - if (root.value) root.dx = size[0], root.dy = size[1]; else root.dx = root.dy = 0; - if (stickies) hierarchy.revalue(root); - scale([ root ], root.dx * root.dy / root.value); - (stickies ? stickify : squarify)(root); - if (sticky) stickies = nodes; - return nodes; - } - treemap.size = function(x) { - if (!arguments.length) return size; - size = x; - return treemap; - }; - treemap.padding = function(x) { - if (!arguments.length) return padding; - function padFunction(node) { - var p = x.call(treemap, node, node.depth); - return p == null ? d3_layout_treemapPadNull(node) : d3_layout_treemapPad(node, typeof p === "number" ? [ p, p, p, p ] : p); - } - function padConstant(node) { - return d3_layout_treemapPad(node, x); - } - var type; - pad = (padding = x) == null ? d3_layout_treemapPadNull : (type = typeof x) === "function" ? padFunction : type === "number" ? (x = [ x, x, x, x ], - padConstant) : padConstant; - return treemap; - }; - treemap.round = function(x) { - if (!arguments.length) return round != Number; - round = x ? Math.round : Number; - return treemap; - }; - treemap.sticky = function(x) { - if (!arguments.length) return sticky; - sticky = x; - stickies = null; - return treemap; - }; - treemap.ratio = function(x) { - if (!arguments.length) return ratio; - ratio = x; - return treemap; - }; - treemap.mode = function(x) { - if (!arguments.length) return mode; - mode = x + ""; - return treemap; - }; - return d3_layout_hierarchyRebind(treemap, hierarchy); - }; - function d3_layout_treemapPadNull(node) { - return { - x: node.x, - y: node.y, - dx: node.dx, - dy: node.dy - }; - } - function d3_layout_treemapPad(node, padding) { - var x = node.x + padding[3], y = node.y + padding[0], dx = node.dx - padding[1] - padding[3], dy = node.dy - padding[0] - padding[2]; - if (dx < 0) { - x += dx / 2; - dx = 0; - } - if (dy < 0) { - y += dy / 2; - dy = 0; - } - return { - x: x, - y: y, - dx: dx, - dy: dy - }; - } - d3.random = { - normal: function(µ, σ) { - var n = arguments.length; - if (n < 2) σ = 1; - if (n < 1) µ = 0; - return function() { - var x, y, r; - do { - x = Math.random() * 2 - 1; - y = Math.random() * 2 - 1; - r = x * x + y * y; - } while (!r || r > 1); - return µ + σ * x * Math.sqrt(-2 * Math.log(r) / r); - }; - }, - logNormal: function() { - var random = d3.random.normal.apply(d3, arguments); - return function() { - return Math.exp(random()); - }; - }, - bates: function(m) { - var random = d3.random.irwinHall(m); - return function() { - return random() / m; - }; - }, - irwinHall: function(m) { - return function() { - for (var s = 0, j = 0; j < m; j++) s += Math.random(); - return s; - }; - } - }; - d3.scale = {}; - function d3_scaleExtent(domain) { - var start = domain[0], stop = domain[domain.length - 1]; - return start < stop ? [ start, stop ] : [ stop, start ]; - } - function d3_scaleRange(scale) { - return scale.rangeExtent ? scale.rangeExtent() : d3_scaleExtent(scale.range()); - } - function d3_scale_bilinear(domain, range, uninterpolate, interpolate) { - var u = uninterpolate(domain[0], domain[1]), i = interpolate(range[0], range[1]); - return function(x) { - return i(u(x)); - }; - } - function d3_scale_nice(domain, nice) { - var i0 = 0, i1 = domain.length - 1, x0 = domain[i0], x1 = domain[i1], dx; - if (x1 < x0) { - dx = i0, i0 = i1, i1 = dx; - dx = x0, x0 = x1, x1 = dx; - } - domain[i0] = nice.floor(x0); - domain[i1] = nice.ceil(x1); - return domain; - } - function d3_scale_niceStep(step) { - return step ? { - floor: function(x) { - return Math.floor(x / step) * step; - }, - ceil: function(x) { - return Math.ceil(x / step) * step; - } - } : d3_scale_niceIdentity; - } - var d3_scale_niceIdentity = { - floor: d3_identity, - ceil: d3_identity - }; - function d3_scale_polylinear(domain, range, uninterpolate, interpolate) { - var u = [], i = [], j = 0, k = Math.min(domain.length, range.length) - 1; - if (domain[k] < domain[0]) { - domain = domain.slice().reverse(); - range = range.slice().reverse(); - } - while (++j <= k) { - u.push(uninterpolate(domain[j - 1], domain[j])); - i.push(interpolate(range[j - 1], range[j])); - } - return function(x) { - var j = d3.bisect(domain, x, 1, k) - 1; - return i[j](u[j](x)); - }; - } - d3.scale.linear = function() { - return d3_scale_linear([ 0, 1 ], [ 0, 1 ], d3_interpolate, false); - }; - function d3_scale_linear(domain, range, interpolate, clamp) { - var output, input; - function rescale() { - var linear = Math.min(domain.length, range.length) > 2 ? d3_scale_polylinear : d3_scale_bilinear, uninterpolate = clamp ? d3_uninterpolateClamp : d3_uninterpolateNumber; - output = linear(domain, range, uninterpolate, interpolate); - input = linear(range, domain, uninterpolate, d3_interpolate); - return scale; - } - function scale(x) { - return output(x); - } - scale.invert = function(y) { - return input(y); - }; - scale.domain = function(x) { - if (!arguments.length) return domain; - domain = x.map(Number); - return rescale(); - }; - scale.range = function(x) { - if (!arguments.length) return range; - range = x; - return rescale(); - }; - scale.rangeRound = function(x) { - return scale.range(x).interpolate(d3_interpolateRound); - }; - scale.clamp = function(x) { - if (!arguments.length) return clamp; - clamp = x; - return rescale(); - }; - scale.interpolate = function(x) { - if (!arguments.length) return interpolate; - interpolate = x; - return rescale(); - }; - scale.ticks = function(m) { - return d3_scale_linearTicks(domain, m); - }; - scale.tickFormat = function(m, format) { - return d3_scale_linearTickFormat(domain, m, format); - }; - scale.nice = function(m) { - d3_scale_linearNice(domain, m); - return rescale(); - }; - scale.copy = function() { - return d3_scale_linear(domain, range, interpolate, clamp); - }; - return rescale(); - } - function d3_scale_linearRebind(scale, linear) { - return d3.rebind(scale, linear, "range", "rangeRound", "interpolate", "clamp"); - } - function d3_scale_linearNice(domain, m) { - d3_scale_nice(domain, d3_scale_niceStep(d3_scale_linearTickRange(domain, m)[2])); - d3_scale_nice(domain, d3_scale_niceStep(d3_scale_linearTickRange(domain, m)[2])); - return domain; - } - function d3_scale_linearTickRange(domain, m) { - if (m == null) m = 10; - var extent = d3_scaleExtent(domain), span = extent[1] - extent[0], step = Math.pow(10, Math.floor(Math.log(span / m) / Math.LN10)), err = m / span * step; - if (err <= .15) step *= 10; else if (err <= .35) step *= 5; else if (err <= .75) step *= 2; - extent[0] = Math.ceil(extent[0] / step) * step; - extent[1] = Math.floor(extent[1] / step) * step + step * .5; - extent[2] = step; - return extent; - } - function d3_scale_linearTicks(domain, m) { - return d3.range.apply(d3, d3_scale_linearTickRange(domain, m)); - } - function d3_scale_linearTickFormat(domain, m, format) { - var range = d3_scale_linearTickRange(domain, m); - if (format) { - var match = d3_format_re.exec(format); - match.shift(); - if (match[8] === "s") { - var prefix = d3.formatPrefix(Math.max(abs(range[0]), abs(range[1]))); - if (!match[7]) match[7] = "." + d3_scale_linearPrecision(prefix.scale(range[2])); - match[8] = "f"; - format = d3.format(match.join("")); - return function(d) { - return format(prefix.scale(d)) + prefix.symbol; - }; - } - if (!match[7]) match[7] = "." + d3_scale_linearFormatPrecision(match[8], range); - format = match.join(""); - } else { - format = ",." + d3_scale_linearPrecision(range[2]) + "f"; - } - return d3.format(format); - } - var d3_scale_linearFormatSignificant = { - s: 1, - g: 1, - p: 1, - r: 1, - e: 1 - }; - function d3_scale_linearPrecision(value) { - return -Math.floor(Math.log(value) / Math.LN10 + .01); - } - function d3_scale_linearFormatPrecision(type, range) { - var p = d3_scale_linearPrecision(range[2]); - return type in d3_scale_linearFormatSignificant ? Math.abs(p - d3_scale_linearPrecision(Math.max(abs(range[0]), abs(range[1])))) + +(type !== "e") : p - (type === "%") * 2; - } - d3.scale.log = function() { - return d3_scale_log(d3.scale.linear().domain([ 0, 1 ]), 10, true, [ 1, 10 ]); - }; - function d3_scale_log(linear, base, positive, domain) { - function log(x) { - return (positive ? Math.log(x < 0 ? 0 : x) : -Math.log(x > 0 ? 0 : -x)) / Math.log(base); - } - function pow(x) { - return positive ? Math.pow(base, x) : -Math.pow(base, -x); - } - function scale(x) { - return linear(log(x)); - } - scale.invert = function(x) { - return pow(linear.invert(x)); - }; - scale.domain = function(x) { - if (!arguments.length) return domain; - positive = x[0] >= 0; - linear.domain((domain = x.map(Number)).map(log)); - return scale; - }; - scale.base = function(_) { - if (!arguments.length) return base; - base = +_; - linear.domain(domain.map(log)); - return scale; - }; - scale.nice = function() { - var niced = d3_scale_nice(domain.map(log), positive ? Math : d3_scale_logNiceNegative); - linear.domain(niced); - domain = niced.map(pow); - return scale; - }; - scale.ticks = function() { - var extent = d3_scaleExtent(domain), ticks = [], u = extent[0], v = extent[1], i = Math.floor(log(u)), j = Math.ceil(log(v)), n = base % 1 ? 2 : base; - if (isFinite(j - i)) { - if (positive) { - for (;i < j; i++) for (var k = 1; k < n; k++) ticks.push(pow(i) * k); - ticks.push(pow(i)); - } else { - ticks.push(pow(i)); - for (;i++ < j; ) for (var k = n - 1; k > 0; k--) ticks.push(pow(i) * k); - } - for (i = 0; ticks[i] < u; i++) {} - for (j = ticks.length; ticks[j - 1] > v; j--) {} - ticks = ticks.slice(i, j); - } - return ticks; - }; - scale.tickFormat = function(n, format) { - if (!arguments.length) return d3_scale_logFormat; - if (arguments.length < 2) format = d3_scale_logFormat; else if (typeof format !== "function") format = d3.format(format); - var k = Math.max(1, base * n / scale.ticks().length); - return function(d) { - var i = d / pow(Math.round(log(d))); - if (i * base < base - .5) i *= base; - return i <= k ? format(d) : ""; - }; - }; - scale.copy = function() { - return d3_scale_log(linear.copy(), base, positive, domain); - }; - return d3_scale_linearRebind(scale, linear); - } - var d3_scale_logFormat = d3.format(".0e"), d3_scale_logNiceNegative = { - floor: function(x) { - return -Math.ceil(-x); - }, - ceil: function(x) { - return -Math.floor(-x); - } - }; - d3.scale.pow = function() { - return d3_scale_pow(d3.scale.linear(), 1, [ 0, 1 ]); - }; - function d3_scale_pow(linear, exponent, domain) { - var powp = d3_scale_powPow(exponent), powb = d3_scale_powPow(1 / exponent); - function scale(x) { - return linear(powp(x)); - } - scale.invert = function(x) { - return powb(linear.invert(x)); - }; - scale.domain = function(x) { - if (!arguments.length) return domain; - linear.domain((domain = x.map(Number)).map(powp)); - return scale; - }; - scale.ticks = function(m) { - return d3_scale_linearTicks(domain, m); - }; - scale.tickFormat = function(m, format) { - return d3_scale_linearTickFormat(domain, m, format); - }; - scale.nice = function(m) { - return scale.domain(d3_scale_linearNice(domain, m)); - }; - scale.exponent = function(x) { - if (!arguments.length) return exponent; - powp = d3_scale_powPow(exponent = x); - powb = d3_scale_powPow(1 / exponent); - linear.domain(domain.map(powp)); - return scale; - }; - scale.copy = function() { - return d3_scale_pow(linear.copy(), exponent, domain); - }; - return d3_scale_linearRebind(scale, linear); - } - function d3_scale_powPow(e) { - return function(x) { - return x < 0 ? -Math.pow(-x, e) : Math.pow(x, e); - }; - } - d3.scale.sqrt = function() { - return d3.scale.pow().exponent(.5); - }; - d3.scale.ordinal = function() { - return d3_scale_ordinal([], { - t: "range", - a: [ [] ] - }); - }; - function d3_scale_ordinal(domain, ranger) { - var index, range, rangeBand; - function scale(x) { - return range[((index.get(x) || (ranger.t === "range" ? index.set(x, domain.push(x)) : NaN)) - 1) % range.length]; - } - function steps(start, step) { - return d3.range(domain.length).map(function(i) { - return start + step * i; - }); - } - scale.domain = function(x) { - if (!arguments.length) return domain; - domain = []; - index = new d3_Map(); - var i = -1, n = x.length, xi; - while (++i < n) if (!index.has(xi = x[i])) index.set(xi, domain.push(xi)); - return scale[ranger.t].apply(scale, ranger.a); - }; - scale.range = function(x) { - if (!arguments.length) return range; - range = x; - rangeBand = 0; - ranger = { - t: "range", - a: arguments - }; - return scale; - }; - scale.rangePoints = function(x, padding) { - if (arguments.length < 2) padding = 0; - var start = x[0], stop = x[1], step = domain.length < 2 ? (start = (start + stop) / 2, - 0) : (stop - start) / (domain.length - 1 + padding); - range = steps(start + step * padding / 2, step); - rangeBand = 0; - ranger = { - t: "rangePoints", - a: arguments - }; - return scale; - }; - scale.rangeRoundPoints = function(x, padding) { - if (arguments.length < 2) padding = 0; - var start = x[0], stop = x[1], step = domain.length < 2 ? (start = stop = Math.round((start + stop) / 2), - 0) : (stop - start) / (domain.length - 1 + padding) | 0; - range = steps(start + Math.round(step * padding / 2 + (stop - start - (domain.length - 1 + padding) * step) / 2), step); - rangeBand = 0; - ranger = { - t: "rangeRoundPoints", - a: arguments - }; - return scale; - }; - scale.rangeBands = function(x, padding, outerPadding) { - if (arguments.length < 2) padding = 0; - if (arguments.length < 3) outerPadding = padding; - var reverse = x[1] < x[0], start = x[reverse - 0], stop = x[1 - reverse], step = (stop - start) / (domain.length - padding + 2 * outerPadding); - range = steps(start + step * outerPadding, step); - if (reverse) range.reverse(); - rangeBand = step * (1 - padding); - ranger = { - t: "rangeBands", - a: arguments - }; - return scale; - }; - scale.rangeRoundBands = function(x, padding, outerPadding) { - if (arguments.length < 2) padding = 0; - if (arguments.length < 3) outerPadding = padding; - var reverse = x[1] < x[0], start = x[reverse - 0], stop = x[1 - reverse], step = Math.floor((stop - start) / (domain.length - padding + 2 * outerPadding)); - range = steps(start + Math.round((stop - start - (domain.length - padding) * step) / 2), step); - if (reverse) range.reverse(); - rangeBand = Math.round(step * (1 - padding)); - ranger = { - t: "rangeRoundBands", - a: arguments - }; - return scale; - }; - scale.rangeBand = function() { - return rangeBand; - }; - scale.rangeExtent = function() { - return d3_scaleExtent(ranger.a[0]); - }; - scale.copy = function() { - return d3_scale_ordinal(domain, ranger); - }; - return scale.domain(domain); - } - d3.scale.category10 = function() { - return d3.scale.ordinal().range(d3_category10); - }; - d3.scale.category20 = function() { - return d3.scale.ordinal().range(d3_category20); - }; - d3.scale.category20b = function() { - return d3.scale.ordinal().range(d3_category20b); - }; - d3.scale.category20c = function() { - return d3.scale.ordinal().range(d3_category20c); - }; - var d3_category10 = [ 2062260, 16744206, 2924588, 14034728, 9725885, 9197131, 14907330, 8355711, 12369186, 1556175 ].map(d3_rgbString); - var d3_category20 = [ 2062260, 11454440, 16744206, 16759672, 2924588, 10018698, 14034728, 16750742, 9725885, 12955861, 9197131, 12885140, 14907330, 16234194, 8355711, 13092807, 12369186, 14408589, 1556175, 10410725 ].map(d3_rgbString); - var d3_category20b = [ 3750777, 5395619, 7040719, 10264286, 6519097, 9216594, 11915115, 13556636, 9202993, 12426809, 15186514, 15190932, 8666169, 11356490, 14049643, 15177372, 8077683, 10834324, 13528509, 14589654 ].map(d3_rgbString); - var d3_category20c = [ 3244733, 7057110, 10406625, 13032431, 15095053, 16616764, 16625259, 16634018, 3253076, 7652470, 10607003, 13101504, 7695281, 10394312, 12369372, 14342891, 6513507, 9868950, 12434877, 14277081 ].map(d3_rgbString); - d3.scale.quantile = function() { - return d3_scale_quantile([], []); - }; - function d3_scale_quantile(domain, range) { - var thresholds; - function rescale() { - var k = 0, q = range.length; - thresholds = []; - while (++k < q) thresholds[k - 1] = d3.quantile(domain, k / q); - return scale; - } - function scale(x) { - if (!isNaN(x = +x)) return range[d3.bisect(thresholds, x)]; - } - scale.domain = function(x) { - if (!arguments.length) return domain; - domain = x.map(d3_number).filter(d3_numeric).sort(d3_ascending); - return rescale(); - }; - scale.range = function(x) { - if (!arguments.length) return range; - range = x; - return rescale(); - }; - scale.quantiles = function() { - return thresholds; - }; - scale.invertExtent = function(y) { - y = range.indexOf(y); - return y < 0 ? [ NaN, NaN ] : [ y > 0 ? thresholds[y - 1] : domain[0], y < thresholds.length ? thresholds[y] : domain[domain.length - 1] ]; - }; - scale.copy = function() { - return d3_scale_quantile(domain, range); - }; - return rescale(); - } - d3.scale.quantize = function() { - return d3_scale_quantize(0, 1, [ 0, 1 ]); - }; - function d3_scale_quantize(x0, x1, range) { - var kx, i; - function scale(x) { - return range[Math.max(0, Math.min(i, Math.floor(kx * (x - x0))))]; - } - function rescale() { - kx = range.length / (x1 - x0); - i = range.length - 1; - return scale; - } - scale.domain = function(x) { - if (!arguments.length) return [ x0, x1 ]; - x0 = +x[0]; - x1 = +x[x.length - 1]; - return rescale(); - }; - scale.range = function(x) { - if (!arguments.length) return range; - range = x; - return rescale(); - }; - scale.invertExtent = function(y) { - y = range.indexOf(y); - y = y < 0 ? NaN : y / kx + x0; - return [ y, y + 1 / kx ]; - }; - scale.copy = function() { - return d3_scale_quantize(x0, x1, range); - }; - return rescale(); - } - d3.scale.threshold = function() { - return d3_scale_threshold([ .5 ], [ 0, 1 ]); - }; - function d3_scale_threshold(domain, range) { - function scale(x) { - if (x <= x) return range[d3.bisect(domain, x)]; - } - scale.domain = function(_) { - if (!arguments.length) return domain; - domain = _; - return scale; - }; - scale.range = function(_) { - if (!arguments.length) return range; - range = _; - return scale; - }; - scale.invertExtent = function(y) { - y = range.indexOf(y); - return [ domain[y - 1], domain[y] ]; - }; - scale.copy = function() { - return d3_scale_threshold(domain, range); - }; - return scale; - } - d3.scale.identity = function() { - return d3_scale_identity([ 0, 1 ]); - }; - function d3_scale_identity(domain) { - function identity(x) { - return +x; - } - identity.invert = identity; - identity.domain = identity.range = function(x) { - if (!arguments.length) return domain; - domain = x.map(identity); - return identity; - }; - identity.ticks = function(m) { - return d3_scale_linearTicks(domain, m); - }; - identity.tickFormat = function(m, format) { - return d3_scale_linearTickFormat(domain, m, format); - }; - identity.copy = function() { - return d3_scale_identity(domain); - }; - return identity; - } - d3.svg = {}; - function d3_zero() { - return 0; - } - d3.svg.arc = function() { - var innerRadius = d3_svg_arcInnerRadius, outerRadius = d3_svg_arcOuterRadius, cornerRadius = d3_zero, padRadius = d3_svg_arcAuto, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle, padAngle = d3_svg_arcPadAngle; - function arc() { - var r0 = Math.max(0, +innerRadius.apply(this, arguments)), r1 = Math.max(0, +outerRadius.apply(this, arguments)), a0 = startAngle.apply(this, arguments) - halfπ, a1 = endAngle.apply(this, arguments) - halfπ, da = Math.abs(a1 - a0), cw = a0 > a1 ? 0 : 1; - if (r1 < r0) rc = r1, r1 = r0, r0 = rc; - if (da >= τε) return circleSegment(r1, cw) + (r0 ? circleSegment(r0, 1 - cw) : "") + "Z"; - var rc, cr, rp, ap, p0 = 0, p1 = 0, x0, y0, x1, y1, x2, y2, x3, y3, path = []; - if (ap = (+padAngle.apply(this, arguments) || 0) / 2) { - rp = padRadius === d3_svg_arcAuto ? Math.sqrt(r0 * r0 + r1 * r1) : +padRadius.apply(this, arguments); - if (!cw) p1 *= -1; - if (r1) p1 = d3_asin(rp / r1 * Math.sin(ap)); - if (r0) p0 = d3_asin(rp / r0 * Math.sin(ap)); - } - if (r1) { - x0 = r1 * Math.cos(a0 + p1); - y0 = r1 * Math.sin(a0 + p1); - x1 = r1 * Math.cos(a1 - p1); - y1 = r1 * Math.sin(a1 - p1); - var l1 = Math.abs(a1 - a0 - 2 * p1) <= π ? 0 : 1; - if (p1 && d3_svg_arcSweep(x0, y0, x1, y1) === cw ^ l1) { - var h1 = (a0 + a1) / 2; - x0 = r1 * Math.cos(h1); - y0 = r1 * Math.sin(h1); - x1 = y1 = null; - } - } else { - x0 = y0 = 0; - } - if (r0) { - x2 = r0 * Math.cos(a1 - p0); - y2 = r0 * Math.sin(a1 - p0); - x3 = r0 * Math.cos(a0 + p0); - y3 = r0 * Math.sin(a0 + p0); - var l0 = Math.abs(a0 - a1 + 2 * p0) <= π ? 0 : 1; - if (p0 && d3_svg_arcSweep(x2, y2, x3, y3) === 1 - cw ^ l0) { - var h0 = (a0 + a1) / 2; - x2 = r0 * Math.cos(h0); - y2 = r0 * Math.sin(h0); - x3 = y3 = null; - } - } else { - x2 = y2 = 0; - } - if (da > ε && (rc = Math.min(Math.abs(r1 - r0) / 2, +cornerRadius.apply(this, arguments))) > .001) { - cr = r0 < r1 ^ cw ? 0 : 1; - var rc1 = rc, rc0 = rc; - if (da < π) { - var oc = x3 == null ? [ x2, y2 ] : x1 == null ? [ x0, y0 ] : d3_geom_polygonIntersect([ x0, y0 ], [ x3, y3 ], [ x1, y1 ], [ x2, y2 ]), ax = x0 - oc[0], ay = y0 - oc[1], bx = x1 - oc[0], by = y1 - oc[1], kc = 1 / Math.sin(Math.acos((ax * bx + ay * by) / (Math.sqrt(ax * ax + ay * ay) * Math.sqrt(bx * bx + by * by))) / 2), lc = Math.sqrt(oc[0] * oc[0] + oc[1] * oc[1]); - rc0 = Math.min(rc, (r0 - lc) / (kc - 1)); - rc1 = Math.min(rc, (r1 - lc) / (kc + 1)); - } - if (x1 != null) { - var t30 = d3_svg_arcCornerTangents(x3 == null ? [ x2, y2 ] : [ x3, y3 ], [ x0, y0 ], r1, rc1, cw), t12 = d3_svg_arcCornerTangents([ x1, y1 ], [ x2, y2 ], r1, rc1, cw); - if (rc === rc1) { - path.push("M", t30[0], "A", rc1, ",", rc1, " 0 0,", cr, " ", t30[1], "A", r1, ",", r1, " 0 ", 1 - cw ^ d3_svg_arcSweep(t30[1][0], t30[1][1], t12[1][0], t12[1][1]), ",", cw, " ", t12[1], "A", rc1, ",", rc1, " 0 0,", cr, " ", t12[0]); - } else { - path.push("M", t30[0], "A", rc1, ",", rc1, " 0 1,", cr, " ", t12[0]); - } - } else { - path.push("M", x0, ",", y0); - } - if (x3 != null) { - var t03 = d3_svg_arcCornerTangents([ x0, y0 ], [ x3, y3 ], r0, -rc0, cw), t21 = d3_svg_arcCornerTangents([ x2, y2 ], x1 == null ? [ x0, y0 ] : [ x1, y1 ], r0, -rc0, cw); - if (rc === rc0) { - path.push("L", t21[0], "A", rc0, ",", rc0, " 0 0,", cr, " ", t21[1], "A", r0, ",", r0, " 0 ", cw ^ d3_svg_arcSweep(t21[1][0], t21[1][1], t03[1][0], t03[1][1]), ",", 1 - cw, " ", t03[1], "A", rc0, ",", rc0, " 0 0,", cr, " ", t03[0]); - } else { - path.push("L", t21[0], "A", rc0, ",", rc0, " 0 0,", cr, " ", t03[0]); - } - } else { - path.push("L", x2, ",", y2); - } - } else { - path.push("M", x0, ",", y0); - if (x1 != null) path.push("A", r1, ",", r1, " 0 ", l1, ",", cw, " ", x1, ",", y1); - path.push("L", x2, ",", y2); - if (x3 != null) path.push("A", r0, ",", r0, " 0 ", l0, ",", 1 - cw, " ", x3, ",", y3); - } - path.push("Z"); - return path.join(""); - } - function circleSegment(r1, cw) { - return "M0," + r1 + "A" + r1 + "," + r1 + " 0 1," + cw + " 0," + -r1 + "A" + r1 + "," + r1 + " 0 1," + cw + " 0," + r1; - } - arc.innerRadius = function(v) { - if (!arguments.length) return innerRadius; - innerRadius = d3_functor(v); - return arc; - }; - arc.outerRadius = function(v) { - if (!arguments.length) return outerRadius; - outerRadius = d3_functor(v); - return arc; - }; - arc.cornerRadius = function(v) { - if (!arguments.length) return cornerRadius; - cornerRadius = d3_functor(v); - return arc; - }; - arc.padRadius = function(v) { - if (!arguments.length) return padRadius; - padRadius = v == d3_svg_arcAuto ? d3_svg_arcAuto : d3_functor(v); - return arc; - }; - arc.startAngle = function(v) { - if (!arguments.length) return startAngle; - startAngle = d3_functor(v); - return arc; - }; - arc.endAngle = function(v) { - if (!arguments.length) return endAngle; - endAngle = d3_functor(v); - return arc; - }; - arc.padAngle = function(v) { - if (!arguments.length) return padAngle; - padAngle = d3_functor(v); - return arc; - }; - arc.centroid = function() { - var r = (+innerRadius.apply(this, arguments) + +outerRadius.apply(this, arguments)) / 2, a = (+startAngle.apply(this, arguments) + +endAngle.apply(this, arguments)) / 2 - halfπ; - return [ Math.cos(a) * r, Math.sin(a) * r ]; - }; - return arc; - }; - var d3_svg_arcAuto = "auto"; - function d3_svg_arcInnerRadius(d) { - return d.innerRadius; - } - function d3_svg_arcOuterRadius(d) { - return d.outerRadius; - } - function d3_svg_arcStartAngle(d) { - return d.startAngle; - } - function d3_svg_arcEndAngle(d) { - return d.endAngle; - } - function d3_svg_arcPadAngle(d) { - return d && d.padAngle; - } - function d3_svg_arcSweep(x0, y0, x1, y1) { - return (x0 - x1) * y0 - (y0 - y1) * x0 > 0 ? 0 : 1; - } - function d3_svg_arcCornerTangents(p0, p1, r1, rc, cw) { - var x01 = p0[0] - p1[0], y01 = p0[1] - p1[1], lo = (cw ? rc : -rc) / Math.sqrt(x01 * x01 + y01 * y01), ox = lo * y01, oy = -lo * x01, x1 = p0[0] + ox, y1 = p0[1] + oy, x2 = p1[0] + ox, y2 = p1[1] + oy, x3 = (x1 + x2) / 2, y3 = (y1 + y2) / 2, dx = x2 - x1, dy = y2 - y1, d2 = dx * dx + dy * dy, r = r1 - rc, D = x1 * y2 - x2 * y1, d = (dy < 0 ? -1 : 1) * Math.sqrt(Math.max(0, r * r * d2 - D * D)), cx0 = (D * dy - dx * d) / d2, cy0 = (-D * dx - dy * d) / d2, cx1 = (D * dy + dx * d) / d2, cy1 = (-D * dx + dy * d) / d2, dx0 = cx0 - x3, dy0 = cy0 - y3, dx1 = cx1 - x3, dy1 = cy1 - y3; - if (dx0 * dx0 + dy0 * dy0 > dx1 * dx1 + dy1 * dy1) cx0 = cx1, cy0 = cy1; - return [ [ cx0 - ox, cy0 - oy ], [ cx0 * r1 / r, cy0 * r1 / r ] ]; - } - function d3_svg_line(projection) { - var x = d3_geom_pointX, y = d3_geom_pointY, defined = d3_true, interpolate = d3_svg_lineLinear, interpolateKey = interpolate.key, tension = .7; - function line(data) { - var segments = [], points = [], i = -1, n = data.length, d, fx = d3_functor(x), fy = d3_functor(y); - function segment() { - segments.push("M", interpolate(projection(points), tension)); - } - while (++i < n) { - if (defined.call(this, d = data[i], i)) { - points.push([ +fx.call(this, d, i), +fy.call(this, d, i) ]); - } else if (points.length) { - segment(); - points = []; - } - } - if (points.length) segment(); - return segments.length ? segments.join("") : null; - } - line.x = function(_) { - if (!arguments.length) return x; - x = _; - return line; - }; - line.y = function(_) { - if (!arguments.length) return y; - y = _; - return line; - }; - line.defined = function(_) { - if (!arguments.length) return defined; - defined = _; - return line; - }; - line.interpolate = function(_) { - if (!arguments.length) return interpolateKey; - if (typeof _ === "function") interpolateKey = interpolate = _; else interpolateKey = (interpolate = d3_svg_lineInterpolators.get(_) || d3_svg_lineLinear).key; - return line; - }; - line.tension = function(_) { - if (!arguments.length) return tension; - tension = _; - return line; - }; - return line; - } - d3.svg.line = function() { - return d3_svg_line(d3_identity); - }; - var d3_svg_lineInterpolators = d3.map({ - linear: d3_svg_lineLinear, - "linear-closed": d3_svg_lineLinearClosed, - step: d3_svg_lineStep, - "step-before": d3_svg_lineStepBefore, - "step-after": d3_svg_lineStepAfter, - basis: d3_svg_lineBasis, - "basis-open": d3_svg_lineBasisOpen, - "basis-closed": d3_svg_lineBasisClosed, - bundle: d3_svg_lineBundle, - cardinal: d3_svg_lineCardinal, - "cardinal-open": d3_svg_lineCardinalOpen, - "cardinal-closed": d3_svg_lineCardinalClosed, - monotone: d3_svg_lineMonotone - }); - d3_svg_lineInterpolators.forEach(function(key, value) { - value.key = key; - value.closed = /-closed$/.test(key); - }); - function d3_svg_lineLinear(points) { - return points.length > 1 ? points.join("L") : points + "Z"; - } - function d3_svg_lineLinearClosed(points) { - return points.join("L") + "Z"; - } - function d3_svg_lineStep(points) { - var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; - while (++i < n) path.push("H", (p[0] + (p = points[i])[0]) / 2, "V", p[1]); - if (n > 1) path.push("H", p[0]); - return path.join(""); - } - function d3_svg_lineStepBefore(points) { - var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; - while (++i < n) path.push("V", (p = points[i])[1], "H", p[0]); - return path.join(""); - } - function d3_svg_lineStepAfter(points) { - var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; - while (++i < n) path.push("H", (p = points[i])[0], "V", p[1]); - return path.join(""); - } - function d3_svg_lineCardinalOpen(points, tension) { - return points.length < 4 ? d3_svg_lineLinear(points) : points[1] + d3_svg_lineHermite(points.slice(1, -1), d3_svg_lineCardinalTangents(points, tension)); - } - function d3_svg_lineCardinalClosed(points, tension) { - return points.length < 3 ? d3_svg_lineLinearClosed(points) : points[0] + d3_svg_lineHermite((points.push(points[0]), - points), d3_svg_lineCardinalTangents([ points[points.length - 2] ].concat(points, [ points[1] ]), tension)); - } - function d3_svg_lineCardinal(points, tension) { - return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite(points, d3_svg_lineCardinalTangents(points, tension)); - } - function d3_svg_lineHermite(points, tangents) { - if (tangents.length < 1 || points.length != tangents.length && points.length != tangents.length + 2) { - return d3_svg_lineLinear(points); - } - var quad = points.length != tangents.length, path = "", p0 = points[0], p = points[1], t0 = tangents[0], t = t0, pi = 1; - if (quad) { - path += "Q" + (p[0] - t0[0] * 2 / 3) + "," + (p[1] - t0[1] * 2 / 3) + "," + p[0] + "," + p[1]; - p0 = points[1]; - pi = 2; - } - if (tangents.length > 1) { - t = tangents[1]; - p = points[pi]; - pi++; - path += "C" + (p0[0] + t0[0]) + "," + (p0[1] + t0[1]) + "," + (p[0] - t[0]) + "," + (p[1] - t[1]) + "," + p[0] + "," + p[1]; - for (var i = 2; i < tangents.length; i++, pi++) { - p = points[pi]; - t = tangents[i]; - path += "S" + (p[0] - t[0]) + "," + (p[1] - t[1]) + "," + p[0] + "," + p[1]; - } - } - if (quad) { - var lp = points[pi]; - path += "Q" + (p[0] + t[0] * 2 / 3) + "," + (p[1] + t[1] * 2 / 3) + "," + lp[0] + "," + lp[1]; - } - return path; - } - function d3_svg_lineCardinalTangents(points, tension) { - var tangents = [], a = (1 - tension) / 2, p0, p1 = points[0], p2 = points[1], i = 1, n = points.length; - while (++i < n) { - p0 = p1; - p1 = p2; - p2 = points[i]; - tangents.push([ a * (p2[0] - p0[0]), a * (p2[1] - p0[1]) ]); - } - return tangents; - } - function d3_svg_lineBasis(points) { - if (points.length < 3) return d3_svg_lineLinear(points); - var i = 1, n = points.length, pi = points[0], x0 = pi[0], y0 = pi[1], px = [ x0, x0, x0, (pi = points[1])[0] ], py = [ y0, y0, y0, pi[1] ], path = [ x0, ",", y0, "L", d3_svg_lineDot4(d3_svg_lineBasisBezier3, px), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, py) ]; - points.push(points[n - 1]); - while (++i <= n) { - pi = points[i]; - px.shift(); - px.push(pi[0]); - py.shift(); - py.push(pi[1]); - d3_svg_lineBasisBezier(path, px, py); - } - points.pop(); - path.push("L", pi); - return path.join(""); - } - function d3_svg_lineBasisOpen(points) { - if (points.length < 4) return d3_svg_lineLinear(points); - var path = [], i = -1, n = points.length, pi, px = [ 0 ], py = [ 0 ]; - while (++i < 3) { - pi = points[i]; - px.push(pi[0]); - py.push(pi[1]); - } - path.push(d3_svg_lineDot4(d3_svg_lineBasisBezier3, px) + "," + d3_svg_lineDot4(d3_svg_lineBasisBezier3, py)); - --i; - while (++i < n) { - pi = points[i]; - px.shift(); - px.push(pi[0]); - py.shift(); - py.push(pi[1]); - d3_svg_lineBasisBezier(path, px, py); - } - return path.join(""); - } - function d3_svg_lineBasisClosed(points) { - var path, i = -1, n = points.length, m = n + 4, pi, px = [], py = []; - while (++i < 4) { - pi = points[i % n]; - px.push(pi[0]); - py.push(pi[1]); - } - path = [ d3_svg_lineDot4(d3_svg_lineBasisBezier3, px), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, py) ]; - --i; - while (++i < m) { - pi = points[i % n]; - px.shift(); - px.push(pi[0]); - py.shift(); - py.push(pi[1]); - d3_svg_lineBasisBezier(path, px, py); - } - return path.join(""); - } - function d3_svg_lineBundle(points, tension) { - var n = points.length - 1; - if (n) { - var x0 = points[0][0], y0 = points[0][1], dx = points[n][0] - x0, dy = points[n][1] - y0, i = -1, p, t; - while (++i <= n) { - p = points[i]; - t = i / n; - p[0] = tension * p[0] + (1 - tension) * (x0 + t * dx); - p[1] = tension * p[1] + (1 - tension) * (y0 + t * dy); - } - } - return d3_svg_lineBasis(points); - } - function d3_svg_lineDot4(a, b) { - return a[0] * b[0] + a[1] * b[1] + a[2] * b[2] + a[3] * b[3]; - } - var d3_svg_lineBasisBezier1 = [ 0, 2 / 3, 1 / 3, 0 ], d3_svg_lineBasisBezier2 = [ 0, 1 / 3, 2 / 3, 0 ], d3_svg_lineBasisBezier3 = [ 0, 1 / 6, 2 / 3, 1 / 6 ]; - function d3_svg_lineBasisBezier(path, x, y) { - path.push("C", d3_svg_lineDot4(d3_svg_lineBasisBezier1, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier1, y), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier2, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier2, y), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, y)); - } - function d3_svg_lineSlope(p0, p1) { - return (p1[1] - p0[1]) / (p1[0] - p0[0]); - } - function d3_svg_lineFiniteDifferences(points) { - var i = 0, j = points.length - 1, m = [], p0 = points[0], p1 = points[1], d = m[0] = d3_svg_lineSlope(p0, p1); - while (++i < j) { - m[i] = (d + (d = d3_svg_lineSlope(p0 = p1, p1 = points[i + 1]))) / 2; - } - m[i] = d; - return m; - } - function d3_svg_lineMonotoneTangents(points) { - var tangents = [], d, a, b, s, m = d3_svg_lineFiniteDifferences(points), i = -1, j = points.length - 1; - while (++i < j) { - d = d3_svg_lineSlope(points[i], points[i + 1]); - if (abs(d) < ε) { - m[i] = m[i + 1] = 0; - } else { - a = m[i] / d; - b = m[i + 1] / d; - s = a * a + b * b; - if (s > 9) { - s = d * 3 / Math.sqrt(s); - m[i] = s * a; - m[i + 1] = s * b; - } - } - } - i = -1; - while (++i <= j) { - s = (points[Math.min(j, i + 1)][0] - points[Math.max(0, i - 1)][0]) / (6 * (1 + m[i] * m[i])); - tangents.push([ s || 0, m[i] * s || 0 ]); - } - return tangents; - } - function d3_svg_lineMonotone(points) { - return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite(points, d3_svg_lineMonotoneTangents(points)); - } - d3.svg.line.radial = function() { - var line = d3_svg_line(d3_svg_lineRadial); - line.radius = line.x, delete line.x; - line.angle = line.y, delete line.y; - return line; - }; - function d3_svg_lineRadial(points) { - var point, i = -1, n = points.length, r, a; - while (++i < n) { - point = points[i]; - r = point[0]; - a = point[1] - halfπ; - point[0] = r * Math.cos(a); - point[1] = r * Math.sin(a); - } - return points; - } - function d3_svg_area(projection) { - var x0 = d3_geom_pointX, x1 = d3_geom_pointX, y0 = 0, y1 = d3_geom_pointY, defined = d3_true, interpolate = d3_svg_lineLinear, interpolateKey = interpolate.key, interpolateReverse = interpolate, L = "L", tension = .7; - function area(data) { - var segments = [], points0 = [], points1 = [], i = -1, n = data.length, d, fx0 = d3_functor(x0), fy0 = d3_functor(y0), fx1 = x0 === x1 ? function() { - return x; - } : d3_functor(x1), fy1 = y0 === y1 ? function() { - return y; - } : d3_functor(y1), x, y; - function segment() { - segments.push("M", interpolate(projection(points1), tension), L, interpolateReverse(projection(points0.reverse()), tension), "Z"); - } - while (++i < n) { - if (defined.call(this, d = data[i], i)) { - points0.push([ x = +fx0.call(this, d, i), y = +fy0.call(this, d, i) ]); - points1.push([ +fx1.call(this, d, i), +fy1.call(this, d, i) ]); - } else if (points0.length) { - segment(); - points0 = []; - points1 = []; - } - } - if (points0.length) segment(); - return segments.length ? segments.join("") : null; - } - area.x = function(_) { - if (!arguments.length) return x1; - x0 = x1 = _; - return area; - }; - area.x0 = function(_) { - if (!arguments.length) return x0; - x0 = _; - return area; - }; - area.x1 = function(_) { - if (!arguments.length) return x1; - x1 = _; - return area; - }; - area.y = function(_) { - if (!arguments.length) return y1; - y0 = y1 = _; - return area; - }; - area.y0 = function(_) { - if (!arguments.length) return y0; - y0 = _; - return area; - }; - area.y1 = function(_) { - if (!arguments.length) return y1; - y1 = _; - return area; - }; - area.defined = function(_) { - if (!arguments.length) return defined; - defined = _; - return area; - }; - area.interpolate = function(_) { - if (!arguments.length) return interpolateKey; - if (typeof _ === "function") interpolateKey = interpolate = _; else interpolateKey = (interpolate = d3_svg_lineInterpolators.get(_) || d3_svg_lineLinear).key; - interpolateReverse = interpolate.reverse || interpolate; - L = interpolate.closed ? "M" : "L"; - return area; - }; - area.tension = function(_) { - if (!arguments.length) return tension; - tension = _; - return area; - }; - return area; - } - d3_svg_lineStepBefore.reverse = d3_svg_lineStepAfter; - d3_svg_lineStepAfter.reverse = d3_svg_lineStepBefore; - d3.svg.area = function() { - return d3_svg_area(d3_identity); - }; - d3.svg.area.radial = function() { - var area = d3_svg_area(d3_svg_lineRadial); - area.radius = area.x, delete area.x; - area.innerRadius = area.x0, delete area.x0; - area.outerRadius = area.x1, delete area.x1; - area.angle = area.y, delete area.y; - area.startAngle = area.y0, delete area.y0; - area.endAngle = area.y1, delete area.y1; - return area; - }; - d3.svg.chord = function() { - var source = d3_source, target = d3_target, radius = d3_svg_chordRadius, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle; - function chord(d, i) { - var s = subgroup(this, source, d, i), t = subgroup(this, target, d, i); - return "M" + s.p0 + arc(s.r, s.p1, s.a1 - s.a0) + (equals(s, t) ? curve(s.r, s.p1, s.r, s.p0) : curve(s.r, s.p1, t.r, t.p0) + arc(t.r, t.p1, t.a1 - t.a0) + curve(t.r, t.p1, s.r, s.p0)) + "Z"; - } - function subgroup(self, f, d, i) { - var subgroup = f.call(self, d, i), r = radius.call(self, subgroup, i), a0 = startAngle.call(self, subgroup, i) - halfπ, a1 = endAngle.call(self, subgroup, i) - halfπ; - return { - r: r, - a0: a0, - a1: a1, - p0: [ r * Math.cos(a0), r * Math.sin(a0) ], - p1: [ r * Math.cos(a1), r * Math.sin(a1) ] - }; - } - function equals(a, b) { - return a.a0 == b.a0 && a.a1 == b.a1; - } - function arc(r, p, a) { - return "A" + r + "," + r + " 0 " + +(a > π) + ",1 " + p; - } - function curve(r0, p0, r1, p1) { - return "Q 0,0 " + p1; - } - chord.radius = function(v) { - if (!arguments.length) return radius; - radius = d3_functor(v); - return chord; - }; - chord.source = function(v) { - if (!arguments.length) return source; - source = d3_functor(v); - return chord; - }; - chord.target = function(v) { - if (!arguments.length) return target; - target = d3_functor(v); - return chord; - }; - chord.startAngle = function(v) { - if (!arguments.length) return startAngle; - startAngle = d3_functor(v); - return chord; - }; - chord.endAngle = function(v) { - if (!arguments.length) return endAngle; - endAngle = d3_functor(v); - return chord; - }; - return chord; - }; - function d3_svg_chordRadius(d) { - return d.radius; - } - d3.svg.diagonal = function() { - var source = d3_source, target = d3_target, projection = d3_svg_diagonalProjection; - function diagonal(d, i) { - var p0 = source.call(this, d, i), p3 = target.call(this, d, i), m = (p0.y + p3.y) / 2, p = [ p0, { - x: p0.x, - y: m - }, { - x: p3.x, - y: m - }, p3 ]; - p = p.map(projection); - return "M" + p[0] + "C" + p[1] + " " + p[2] + " " + p[3]; - } - diagonal.source = function(x) { - if (!arguments.length) return source; - source = d3_functor(x); - return diagonal; - }; - diagonal.target = function(x) { - if (!arguments.length) return target; - target = d3_functor(x); - return diagonal; - }; - diagonal.projection = function(x) { - if (!arguments.length) return projection; - projection = x; - return diagonal; - }; - return diagonal; - }; - function d3_svg_diagonalProjection(d) { - return [ d.x, d.y ]; - } - d3.svg.diagonal.radial = function() { - var diagonal = d3.svg.diagonal(), projection = d3_svg_diagonalProjection, projection_ = diagonal.projection; - diagonal.projection = function(x) { - return arguments.length ? projection_(d3_svg_diagonalRadialProjection(projection = x)) : projection; - }; - return diagonal; - }; - function d3_svg_diagonalRadialProjection(projection) { - return function() { - var d = projection.apply(this, arguments), r = d[0], a = d[1] - halfπ; - return [ r * Math.cos(a), r * Math.sin(a) ]; - }; - } - d3.svg.symbol = function() { - var type = d3_svg_symbolType, size = d3_svg_symbolSize; - function symbol(d, i) { - return (d3_svg_symbols.get(type.call(this, d, i)) || d3_svg_symbolCircle)(size.call(this, d, i)); - } - symbol.type = function(x) { - if (!arguments.length) return type; - type = d3_functor(x); - return symbol; - }; - symbol.size = function(x) { - if (!arguments.length) return size; - size = d3_functor(x); - return symbol; - }; - return symbol; - }; - function d3_svg_symbolSize() { - return 64; - } - function d3_svg_symbolType() { - return "circle"; - } - function d3_svg_symbolCircle(size) { - var r = Math.sqrt(size / π); - return "M0," + r + "A" + r + "," + r + " 0 1,1 0," + -r + "A" + r + "," + r + " 0 1,1 0," + r + "Z"; - } - var d3_svg_symbols = d3.map({ - circle: d3_svg_symbolCircle, - cross: function(size) { - var r = Math.sqrt(size / 5) / 2; - return "M" + -3 * r + "," + -r + "H" + -r + "V" + -3 * r + "H" + r + "V" + -r + "H" + 3 * r + "V" + r + "H" + r + "V" + 3 * r + "H" + -r + "V" + r + "H" + -3 * r + "Z"; - }, - diamond: function(size) { - var ry = Math.sqrt(size / (2 * d3_svg_symbolTan30)), rx = ry * d3_svg_symbolTan30; - return "M0," + -ry + "L" + rx + ",0" + " 0," + ry + " " + -rx + ",0" + "Z"; - }, - square: function(size) { - var r = Math.sqrt(size) / 2; - return "M" + -r + "," + -r + "L" + r + "," + -r + " " + r + "," + r + " " + -r + "," + r + "Z"; - }, - "triangle-down": function(size) { - var rx = Math.sqrt(size / d3_svg_symbolSqrt3), ry = rx * d3_svg_symbolSqrt3 / 2; - return "M0," + ry + "L" + rx + "," + -ry + " " + -rx + "," + -ry + "Z"; - }, - "triangle-up": function(size) { - var rx = Math.sqrt(size / d3_svg_symbolSqrt3), ry = rx * d3_svg_symbolSqrt3 / 2; - return "M0," + -ry + "L" + rx + "," + ry + " " + -rx + "," + ry + "Z"; - } - }); - d3.svg.symbolTypes = d3_svg_symbols.keys(); - var d3_svg_symbolSqrt3 = Math.sqrt(3), d3_svg_symbolTan30 = Math.tan(30 * d3_radians); - d3_selectionPrototype.transition = function(name) { - var id = d3_transitionInheritId || ++d3_transitionId, ns = d3_transitionNamespace(name), subgroups = [], subgroup, node, transition = d3_transitionInherit || { - time: Date.now(), - ease: d3_ease_cubicInOut, - delay: 0, - duration: 250 - }; - for (var j = -1, m = this.length; ++j < m; ) { - subgroups.push(subgroup = []); - for (var group = this[j], i = -1, n = group.length; ++i < n; ) { - if (node = group[i]) d3_transitionNode(node, i, ns, id, transition); - subgroup.push(node); - } - } - return d3_transition(subgroups, ns, id); - }; - d3_selectionPrototype.interrupt = function(name) { - return this.each(name == null ? d3_selection_interrupt : d3_selection_interruptNS(d3_transitionNamespace(name))); - }; - var d3_selection_interrupt = d3_selection_interruptNS(d3_transitionNamespace()); - function d3_selection_interruptNS(ns) { - return function() { - var lock, activeId, active; - if ((lock = this[ns]) && (active = lock[activeId = lock.active])) { - active.timer.c = null; - active.timer.t = NaN; - if (--lock.count) delete lock[activeId]; else delete this[ns]; - lock.active += .5; - active.event && active.event.interrupt.call(this, this.__data__, active.index); - } - }; - } - function d3_transition(groups, ns, id) { - d3_subclass(groups, d3_transitionPrototype); - groups.namespace = ns; - groups.id = id; - return groups; - } - var d3_transitionPrototype = [], d3_transitionId = 0, d3_transitionInheritId, d3_transitionInherit; - d3_transitionPrototype.call = d3_selectionPrototype.call; - d3_transitionPrototype.empty = d3_selectionPrototype.empty; - d3_transitionPrototype.node = d3_selectionPrototype.node; - d3_transitionPrototype.size = d3_selectionPrototype.size; - d3.transition = function(selection, name) { - return selection && selection.transition ? d3_transitionInheritId ? selection.transition(name) : selection : d3.selection().transition(selection); - }; - d3.transition.prototype = d3_transitionPrototype; - d3_transitionPrototype.select = function(selector) { - var id = this.id, ns = this.namespace, subgroups = [], subgroup, subnode, node; - selector = d3_selection_selector(selector); - for (var j = -1, m = this.length; ++j < m; ) { - subgroups.push(subgroup = []); - for (var group = this[j], i = -1, n = group.length; ++i < n; ) { - if ((node = group[i]) && (subnode = selector.call(node, node.__data__, i, j))) { - if ("__data__" in node) subnode.__data__ = node.__data__; - d3_transitionNode(subnode, i, ns, id, node[ns][id]); - subgroup.push(subnode); - } else { - subgroup.push(null); - } - } - } - return d3_transition(subgroups, ns, id); - }; - d3_transitionPrototype.selectAll = function(selector) { - var id = this.id, ns = this.namespace, subgroups = [], subgroup, subnodes, node, subnode, transition; - selector = d3_selection_selectorAll(selector); - for (var j = -1, m = this.length; ++j < m; ) { - for (var group = this[j], i = -1, n = group.length; ++i < n; ) { - if (node = group[i]) { - transition = node[ns][id]; - subnodes = selector.call(node, node.__data__, i, j); - subgroups.push(subgroup = []); - for (var k = -1, o = subnodes.length; ++k < o; ) { - if (subnode = subnodes[k]) d3_transitionNode(subnode, k, ns, id, transition); - subgroup.push(subnode); - } - } - } - } - return d3_transition(subgroups, ns, id); - }; - d3_transitionPrototype.filter = function(filter) { - var subgroups = [], subgroup, group, node; - if (typeof filter !== "function") filter = d3_selection_filter(filter); - for (var j = 0, m = this.length; j < m; j++) { - subgroups.push(subgroup = []); - for (var group = this[j], i = 0, n = group.length; i < n; i++) { - if ((node = group[i]) && filter.call(node, node.__data__, i, j)) { - subgroup.push(node); - } - } - } - return d3_transition(subgroups, this.namespace, this.id); - }; - d3_transitionPrototype.tween = function(name, tween) { - var id = this.id, ns = this.namespace; - if (arguments.length < 2) return this.node()[ns][id].tween.get(name); - return d3_selection_each(this, tween == null ? function(node) { - node[ns][id].tween.remove(name); - } : function(node) { - node[ns][id].tween.set(name, tween); - }); - }; - function d3_transition_tween(groups, name, value, tween) { - var id = groups.id, ns = groups.namespace; - return d3_selection_each(groups, typeof value === "function" ? function(node, i, j) { - node[ns][id].tween.set(name, tween(value.call(node, node.__data__, i, j))); - } : (value = tween(value), function(node) { - node[ns][id].tween.set(name, value); - })); - } - d3_transitionPrototype.attr = function(nameNS, value) { - if (arguments.length < 2) { - for (value in nameNS) this.attr(value, nameNS[value]); - return this; - } - var interpolate = nameNS == "transform" ? d3_interpolateTransform : d3_interpolate, name = d3.ns.qualify(nameNS); - function attrNull() { - this.removeAttribute(name); - } - function attrNullNS() { - this.removeAttributeNS(name.space, name.local); - } - function attrTween(b) { - return b == null ? attrNull : (b += "", function() { - var a = this.getAttribute(name), i; - return a !== b && (i = interpolate(a, b), function(t) { - this.setAttribute(name, i(t)); - }); - }); - } - function attrTweenNS(b) { - return b == null ? attrNullNS : (b += "", function() { - var a = this.getAttributeNS(name.space, name.local), i; - return a !== b && (i = interpolate(a, b), function(t) { - this.setAttributeNS(name.space, name.local, i(t)); - }); - }); - } - return d3_transition_tween(this, "attr." + nameNS, value, name.local ? attrTweenNS : attrTween); - }; - d3_transitionPrototype.attrTween = function(nameNS, tween) { - var name = d3.ns.qualify(nameNS); - function attrTween(d, i) { - var f = tween.call(this, d, i, this.getAttribute(name)); - return f && function(t) { - this.setAttribute(name, f(t)); - }; - } - function attrTweenNS(d, i) { - var f = tween.call(this, d, i, this.getAttributeNS(name.space, name.local)); - return f && function(t) { - this.setAttributeNS(name.space, name.local, f(t)); - }; - } - return this.tween("attr." + nameNS, name.local ? attrTweenNS : attrTween); - }; - d3_transitionPrototype.style = function(name, value, priority) { - var n = arguments.length; - if (n < 3) { - if (typeof name !== "string") { - if (n < 2) value = ""; - for (priority in name) this.style(priority, name[priority], value); - return this; - } - priority = ""; - } - function styleNull() { - this.style.removeProperty(name); - } - function styleString(b) { - return b == null ? styleNull : (b += "", function() { - var a = d3_window(this).getComputedStyle(this, null).getPropertyValue(name), i; - return a !== b && (i = d3_interpolate(a, b), function(t) { - this.style.setProperty(name, i(t), priority); - }); - }); - } - return d3_transition_tween(this, "style." + name, value, styleString); - }; - d3_transitionPrototype.styleTween = function(name, tween, priority) { - if (arguments.length < 3) priority = ""; - function styleTween(d, i) { - var f = tween.call(this, d, i, d3_window(this).getComputedStyle(this, null).getPropertyValue(name)); - return f && function(t) { - this.style.setProperty(name, f(t), priority); - }; - } - return this.tween("style." + name, styleTween); - }; - d3_transitionPrototype.text = function(value) { - return d3_transition_tween(this, "text", value, d3_transition_text); - }; - function d3_transition_text(b) { - if (b == null) b = ""; - return function() { - this.textContent = b; - }; - } - d3_transitionPrototype.remove = function() { - var ns = this.namespace; - return this.each("end.transition", function() { - var p; - if (this[ns].count < 2 && (p = this.parentNode)) p.removeChild(this); - }); - }; - d3_transitionPrototype.ease = function(value) { - var id = this.id, ns = this.namespace; - if (arguments.length < 1) return this.node()[ns][id].ease; - if (typeof value !== "function") value = d3.ease.apply(d3, arguments); - return d3_selection_each(this, function(node) { - node[ns][id].ease = value; - }); - }; - d3_transitionPrototype.delay = function(value) { - var id = this.id, ns = this.namespace; - if (arguments.length < 1) return this.node()[ns][id].delay; - return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { - node[ns][id].delay = +value.call(node, node.__data__, i, j); - } : (value = +value, function(node) { - node[ns][id].delay = value; - })); - }; - d3_transitionPrototype.duration = function(value) { - var id = this.id, ns = this.namespace; - if (arguments.length < 1) return this.node()[ns][id].duration; - return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { - node[ns][id].duration = Math.max(1, value.call(node, node.__data__, i, j)); - } : (value = Math.max(1, value), function(node) { - node[ns][id].duration = value; - })); - }; - d3_transitionPrototype.each = function(type, listener) { - var id = this.id, ns = this.namespace; - if (arguments.length < 2) { - var inherit = d3_transitionInherit, inheritId = d3_transitionInheritId; - try { - d3_transitionInheritId = id; - d3_selection_each(this, function(node, i, j) { - d3_transitionInherit = node[ns][id]; - type.call(node, node.__data__, i, j); - }); - } finally { - d3_transitionInherit = inherit; - d3_transitionInheritId = inheritId; - } - } else { - d3_selection_each(this, function(node) { - var transition = node[ns][id]; - (transition.event || (transition.event = d3.dispatch("start", "end", "interrupt"))).on(type, listener); - }); - } - return this; - }; - d3_transitionPrototype.transition = function() { - var id0 = this.id, id1 = ++d3_transitionId, ns = this.namespace, subgroups = [], subgroup, group, node, transition; - for (var j = 0, m = this.length; j < m; j++) { - subgroups.push(subgroup = []); - for (var group = this[j], i = 0, n = group.length; i < n; i++) { - if (node = group[i]) { - transition = node[ns][id0]; - d3_transitionNode(node, i, ns, id1, { - time: transition.time, - ease: transition.ease, - delay: transition.delay + transition.duration, - duration: transition.duration - }); - } - subgroup.push(node); - } - } - return d3_transition(subgroups, ns, id1); - }; - function d3_transitionNamespace(name) { - return name == null ? "__transition__" : "__transition_" + name + "__"; - } - function d3_transitionNode(node, i, ns, id, inherit) { - var lock = node[ns] || (node[ns] = { - active: 0, - count: 0 - }), transition = lock[id], time, timer, duration, ease, tweens; - function schedule(elapsed) { - var delay = transition.delay; - timer.t = delay + time; - if (delay <= elapsed) return start(elapsed - delay); - timer.c = start; - } - function start(elapsed) { - var activeId = lock.active, active = lock[activeId]; - if (active) { - active.timer.c = null; - active.timer.t = NaN; - --lock.count; - delete lock[activeId]; - active.event && active.event.interrupt.call(node, node.__data__, active.index); - } - for (var cancelId in lock) { - if (+cancelId < id) { - var cancel = lock[cancelId]; - cancel.timer.c = null; - cancel.timer.t = NaN; - --lock.count; - delete lock[cancelId]; - } - } - timer.c = tick; - d3_timer(function() { - if (timer.c && tick(elapsed || 1)) { - timer.c = null; - timer.t = NaN; - } - return 1; - }, 0, time); - lock.active = id; - transition.event && transition.event.start.call(node, node.__data__, i); - tweens = []; - transition.tween.forEach(function(key, value) { - if (value = value.call(node, node.__data__, i)) { - tweens.push(value); - } - }); - ease = transition.ease; - duration = transition.duration; - } - function tick(elapsed) { - var t = elapsed / duration, e = ease(t), n = tweens.length; - while (n > 0) { - tweens[--n].call(node, e); - } - if (t >= 1) { - transition.event && transition.event.end.call(node, node.__data__, i); - if (--lock.count) delete lock[id]; else delete node[ns]; - return 1; - } - } - if (!transition) { - time = inherit.time; - timer = d3_timer(schedule, 0, time); - transition = lock[id] = { - tween: new d3_Map(), - time: time, - timer: timer, - delay: inherit.delay, - duration: inherit.duration, - ease: inherit.ease, - index: i - }; - inherit = null; - ++lock.count; - } - } - d3.svg.axis = function() { - var scale = d3.scale.linear(), orient = d3_svg_axisDefaultOrient, innerTickSize = 6, outerTickSize = 6, tickPadding = 3, tickArguments_ = [ 10 ], tickValues = null, tickFormat_; - function axis(g) { - g.each(function() { - var g = d3.select(this); - var scale0 = this.__chart__ || scale, scale1 = this.__chart__ = scale.copy(); - var ticks = tickValues == null ? scale1.ticks ? scale1.ticks.apply(scale1, tickArguments_) : scale1.domain() : tickValues, tickFormat = tickFormat_ == null ? scale1.tickFormat ? scale1.tickFormat.apply(scale1, tickArguments_) : d3_identity : tickFormat_, tick = g.selectAll(".tick").data(ticks, scale1), tickEnter = tick.enter().insert("g", ".domain").attr("class", "tick").style("opacity", ε), tickExit = d3.transition(tick.exit()).style("opacity", ε).remove(), tickUpdate = d3.transition(tick.order()).style("opacity", 1), tickSpacing = Math.max(innerTickSize, 0) + tickPadding, tickTransform; - var range = d3_scaleRange(scale1), path = g.selectAll(".domain").data([ 0 ]), pathUpdate = (path.enter().append("path").attr("class", "domain"), - d3.transition(path)); - tickEnter.append("line"); - tickEnter.append("text"); - var lineEnter = tickEnter.select("line"), lineUpdate = tickUpdate.select("line"), text = tick.select("text").text(tickFormat), textEnter = tickEnter.select("text"), textUpdate = tickUpdate.select("text"), sign = orient === "top" || orient === "left" ? -1 : 1, x1, x2, y1, y2; - if (orient === "bottom" || orient === "top") { - tickTransform = d3_svg_axisX, x1 = "x", y1 = "y", x2 = "x2", y2 = "y2"; - text.attr("dy", sign < 0 ? "0em" : ".71em").style("text-anchor", "middle"); - pathUpdate.attr("d", "M" + range[0] + "," + sign * outerTickSize + "V0H" + range[1] + "V" + sign * outerTickSize); - } else { - tickTransform = d3_svg_axisY, x1 = "y", y1 = "x", x2 = "y2", y2 = "x2"; - text.attr("dy", ".32em").style("text-anchor", sign < 0 ? "end" : "start"); - pathUpdate.attr("d", "M" + sign * outerTickSize + "," + range[0] + "H0V" + range[1] + "H" + sign * outerTickSize); - } - lineEnter.attr(y2, sign * innerTickSize); - textEnter.attr(y1, sign * tickSpacing); - lineUpdate.attr(x2, 0).attr(y2, sign * innerTickSize); - textUpdate.attr(x1, 0).attr(y1, sign * tickSpacing); - if (scale1.rangeBand) { - var x = scale1, dx = x.rangeBand() / 2; - scale0 = scale1 = function(d) { - return x(d) + dx; - }; - } else if (scale0.rangeBand) { - scale0 = scale1; - } else { - tickExit.call(tickTransform, scale1, scale0); - } - tickEnter.call(tickTransform, scale0, scale1); - tickUpdate.call(tickTransform, scale1, scale1); - }); - } - axis.scale = function(x) { - if (!arguments.length) return scale; - scale = x; - return axis; - }; - axis.orient = function(x) { - if (!arguments.length) return orient; - orient = x in d3_svg_axisOrients ? x + "" : d3_svg_axisDefaultOrient; - return axis; - }; - axis.ticks = function() { - if (!arguments.length) return tickArguments_; - tickArguments_ = d3_array(arguments); - return axis; - }; - axis.tickValues = function(x) { - if (!arguments.length) return tickValues; - tickValues = x; - return axis; - }; - axis.tickFormat = function(x) { - if (!arguments.length) return tickFormat_; - tickFormat_ = x; - return axis; - }; - axis.tickSize = function(x) { - var n = arguments.length; - if (!n) return innerTickSize; - innerTickSize = +x; - outerTickSize = +arguments[n - 1]; - return axis; - }; - axis.innerTickSize = function(x) { - if (!arguments.length) return innerTickSize; - innerTickSize = +x; - return axis; - }; - axis.outerTickSize = function(x) { - if (!arguments.length) return outerTickSize; - outerTickSize = +x; - return axis; - }; - axis.tickPadding = function(x) { - if (!arguments.length) return tickPadding; - tickPadding = +x; - return axis; - }; - axis.tickSubdivide = function() { - return arguments.length && axis; - }; - return axis; - }; - var d3_svg_axisDefaultOrient = "bottom", d3_svg_axisOrients = { - top: 1, - right: 1, - bottom: 1, - left: 1 - }; - function d3_svg_axisX(selection, x0, x1) { - selection.attr("transform", function(d) { - var v0 = x0(d); - return "translate(" + (isFinite(v0) ? v0 : x1(d)) + ",0)"; - }); - } - function d3_svg_axisY(selection, y0, y1) { - selection.attr("transform", function(d) { - var v0 = y0(d); - return "translate(0," + (isFinite(v0) ? v0 : y1(d)) + ")"; - }); - } - d3.svg.brush = function() { - var event = d3_eventDispatch(brush, "brushstart", "brush", "brushend"), x = null, y = null, xExtent = [ 0, 0 ], yExtent = [ 0, 0 ], xExtentDomain, yExtentDomain, xClamp = true, yClamp = true, resizes = d3_svg_brushResizes[0]; - function brush(g) { - g.each(function() { - var g = d3.select(this).style("pointer-events", "all").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)").on("mousedown.brush", brushstart).on("touchstart.brush", brushstart); - var background = g.selectAll(".background").data([ 0 ]); - background.enter().append("rect").attr("class", "background").style("visibility", "hidden").style("cursor", "crosshair"); - g.selectAll(".extent").data([ 0 ]).enter().append("rect").attr("class", "extent").style("cursor", "move"); - var resize = g.selectAll(".resize").data(resizes, d3_identity); - resize.exit().remove(); - resize.enter().append("g").attr("class", function(d) { - return "resize " + d; - }).style("cursor", function(d) { - return d3_svg_brushCursor[d]; - }).append("rect").attr("x", function(d) { - return /[ew]$/.test(d) ? -3 : null; - }).attr("y", function(d) { - return /^[ns]/.test(d) ? -3 : null; - }).attr("width", 6).attr("height", 6).style("visibility", "hidden"); - resize.style("display", brush.empty() ? "none" : null); - var gUpdate = d3.transition(g), backgroundUpdate = d3.transition(background), range; - if (x) { - range = d3_scaleRange(x); - backgroundUpdate.attr("x", range[0]).attr("width", range[1] - range[0]); - redrawX(gUpdate); - } - if (y) { - range = d3_scaleRange(y); - backgroundUpdate.attr("y", range[0]).attr("height", range[1] - range[0]); - redrawY(gUpdate); - } - redraw(gUpdate); - }); - } - brush.event = function(g) { - g.each(function() { - var event_ = event.of(this, arguments), extent1 = { - x: xExtent, - y: yExtent, - i: xExtentDomain, - j: yExtentDomain - }, extent0 = this.__chart__ || extent1; - this.__chart__ = extent1; - if (d3_transitionInheritId) { - d3.select(this).transition().each("start.brush", function() { - xExtentDomain = extent0.i; - yExtentDomain = extent0.j; - xExtent = extent0.x; - yExtent = extent0.y; - event_({ - type: "brushstart" - }); - }).tween("brush:brush", function() { - var xi = d3_interpolateArray(xExtent, extent1.x), yi = d3_interpolateArray(yExtent, extent1.y); - xExtentDomain = yExtentDomain = null; - return function(t) { - xExtent = extent1.x = xi(t); - yExtent = extent1.y = yi(t); - event_({ - type: "brush", - mode: "resize" - }); - }; - }).each("end.brush", function() { - xExtentDomain = extent1.i; - yExtentDomain = extent1.j; - event_({ - type: "brush", - mode: "resize" - }); - event_({ - type: "brushend" - }); - }); - } else { - event_({ - type: "brushstart" - }); - event_({ - type: "brush", - mode: "resize" - }); - event_({ - type: "brushend" - }); - } - }); - }; - function redraw(g) { - g.selectAll(".resize").attr("transform", function(d) { - return "translate(" + xExtent[+/e$/.test(d)] + "," + yExtent[+/^s/.test(d)] + ")"; - }); - } - function redrawX(g) { - g.select(".extent").attr("x", xExtent[0]); - g.selectAll(".extent,.n>rect,.s>rect").attr("width", xExtent[1] - xExtent[0]); - } - function redrawY(g) { - g.select(".extent").attr("y", yExtent[0]); - g.selectAll(".extent,.e>rect,.w>rect").attr("height", yExtent[1] - yExtent[0]); - } - function brushstart() { - var target = this, eventTarget = d3.select(d3.event.target), event_ = event.of(target, arguments), g = d3.select(target), resizing = eventTarget.datum(), resizingX = !/^(n|s)$/.test(resizing) && x, resizingY = !/^(e|w)$/.test(resizing) && y, dragging = eventTarget.classed("extent"), dragRestore = d3_event_dragSuppress(target), center, origin = d3.mouse(target), offset; - var w = d3.select(d3_window(target)).on("keydown.brush", keydown).on("keyup.brush", keyup); - if (d3.event.changedTouches) { - w.on("touchmove.brush", brushmove).on("touchend.brush", brushend); - } else { - w.on("mousemove.brush", brushmove).on("mouseup.brush", brushend); - } - g.interrupt().selectAll("*").interrupt(); - if (dragging) { - origin[0] = xExtent[0] - origin[0]; - origin[1] = yExtent[0] - origin[1]; - } else if (resizing) { - var ex = +/w$/.test(resizing), ey = +/^n/.test(resizing); - offset = [ xExtent[1 - ex] - origin[0], yExtent[1 - ey] - origin[1] ]; - origin[0] = xExtent[ex]; - origin[1] = yExtent[ey]; - } else if (d3.event.altKey) center = origin.slice(); - g.style("pointer-events", "none").selectAll(".resize").style("display", null); - d3.select("body").style("cursor", eventTarget.style("cursor")); - event_({ - type: "brushstart" - }); - brushmove(); - function keydown() { - if (d3.event.keyCode == 32) { - if (!dragging) { - center = null; - origin[0] -= xExtent[1]; - origin[1] -= yExtent[1]; - dragging = 2; - } - d3_eventPreventDefault(); - } - } - function keyup() { - if (d3.event.keyCode == 32 && dragging == 2) { - origin[0] += xExtent[1]; - origin[1] += yExtent[1]; - dragging = 0; - d3_eventPreventDefault(); - } - } - function brushmove() { - var point = d3.mouse(target), moved = false; - if (offset) { - point[0] += offset[0]; - point[1] += offset[1]; - } - if (!dragging) { - if (d3.event.altKey) { - if (!center) center = [ (xExtent[0] + xExtent[1]) / 2, (yExtent[0] + yExtent[1]) / 2 ]; - origin[0] = xExtent[+(point[0] < center[0])]; - origin[1] = yExtent[+(point[1] < center[1])]; - } else center = null; - } - if (resizingX && move1(point, x, 0)) { - redrawX(g); - moved = true; - } - if (resizingY && move1(point, y, 1)) { - redrawY(g); - moved = true; - } - if (moved) { - redraw(g); - event_({ - type: "brush", - mode: dragging ? "move" : "resize" - }); - } - } - function move1(point, scale, i) { - var range = d3_scaleRange(scale), r0 = range[0], r1 = range[1], position = origin[i], extent = i ? yExtent : xExtent, size = extent[1] - extent[0], min, max; - if (dragging) { - r0 -= position; - r1 -= size + position; - } - min = (i ? yClamp : xClamp) ? Math.max(r0, Math.min(r1, point[i])) : point[i]; - if (dragging) { - max = (min += position) + size; - } else { - if (center) position = Math.max(r0, Math.min(r1, 2 * center[i] - min)); - if (position < min) { - max = min; - min = position; - } else { - max = position; - } - } - if (extent[0] != min || extent[1] != max) { - if (i) yExtentDomain = null; else xExtentDomain = null; - extent[0] = min; - extent[1] = max; - return true; - } - } - function brushend() { - brushmove(); - g.style("pointer-events", "all").selectAll(".resize").style("display", brush.empty() ? "none" : null); - d3.select("body").style("cursor", null); - w.on("mousemove.brush", null).on("mouseup.brush", null).on("touchmove.brush", null).on("touchend.brush", null).on("keydown.brush", null).on("keyup.brush", null); - dragRestore(); - event_({ - type: "brushend" - }); - } - } - brush.x = function(z) { - if (!arguments.length) return x; - x = z; - resizes = d3_svg_brushResizes[!x << 1 | !y]; - return brush; - }; - brush.y = function(z) { - if (!arguments.length) return y; - y = z; - resizes = d3_svg_brushResizes[!x << 1 | !y]; - return brush; - }; - brush.clamp = function(z) { - if (!arguments.length) return x && y ? [ xClamp, yClamp ] : x ? xClamp : y ? yClamp : null; - if (x && y) xClamp = !!z[0], yClamp = !!z[1]; else if (x) xClamp = !!z; else if (y) yClamp = !!z; - return brush; - }; - brush.extent = function(z) { - var x0, x1, y0, y1, t; - if (!arguments.length) { - if (x) { - if (xExtentDomain) { - x0 = xExtentDomain[0], x1 = xExtentDomain[1]; - } else { - x0 = xExtent[0], x1 = xExtent[1]; - if (x.invert) x0 = x.invert(x0), x1 = x.invert(x1); - if (x1 < x0) t = x0, x0 = x1, x1 = t; - } - } - if (y) { - if (yExtentDomain) { - y0 = yExtentDomain[0], y1 = yExtentDomain[1]; - } else { - y0 = yExtent[0], y1 = yExtent[1]; - if (y.invert) y0 = y.invert(y0), y1 = y.invert(y1); - if (y1 < y0) t = y0, y0 = y1, y1 = t; - } - } - return x && y ? [ [ x0, y0 ], [ x1, y1 ] ] : x ? [ x0, x1 ] : y && [ y0, y1 ]; - } - if (x) { - x0 = z[0], x1 = z[1]; - if (y) x0 = x0[0], x1 = x1[0]; - xExtentDomain = [ x0, x1 ]; - if (x.invert) x0 = x(x0), x1 = x(x1); - if (x1 < x0) t = x0, x0 = x1, x1 = t; - if (x0 != xExtent[0] || x1 != xExtent[1]) xExtent = [ x0, x1 ]; - } - if (y) { - y0 = z[0], y1 = z[1]; - if (x) y0 = y0[1], y1 = y1[1]; - yExtentDomain = [ y0, y1 ]; - if (y.invert) y0 = y(y0), y1 = y(y1); - if (y1 < y0) t = y0, y0 = y1, y1 = t; - if (y0 != yExtent[0] || y1 != yExtent[1]) yExtent = [ y0, y1 ]; - } - return brush; - }; - brush.clear = function() { - if (!brush.empty()) { - xExtent = [ 0, 0 ], yExtent = [ 0, 0 ]; - xExtentDomain = yExtentDomain = null; - } - return brush; - }; - brush.empty = function() { - return !!x && xExtent[0] == xExtent[1] || !!y && yExtent[0] == yExtent[1]; - }; - return d3.rebind(brush, event, "on"); - }; - var d3_svg_brushCursor = { - n: "ns-resize", - e: "ew-resize", - s: "ns-resize", - w: "ew-resize", - nw: "nwse-resize", - ne: "nesw-resize", - se: "nwse-resize", - sw: "nesw-resize" - }; - var d3_svg_brushResizes = [ [ "n", "e", "s", "w", "nw", "ne", "se", "sw" ], [ "e", "w" ], [ "n", "s" ], [] ]; - var d3_time_format = d3_time.format = d3_locale_enUS.timeFormat; - var d3_time_formatUtc = d3_time_format.utc; - var d3_time_formatIso = d3_time_formatUtc("%Y-%m-%dT%H:%M:%S.%LZ"); - d3_time_format.iso = Date.prototype.toISOString && +new Date("2000-01-01T00:00:00.000Z") ? d3_time_formatIsoNative : d3_time_formatIso; - function d3_time_formatIsoNative(date) { - return date.toISOString(); - } - d3_time_formatIsoNative.parse = function(string) { - var date = new Date(string); - return isNaN(date) ? null : date; - }; - d3_time_formatIsoNative.toString = d3_time_formatIso.toString; - d3_time.second = d3_time_interval(function(date) { - return new d3_date(Math.floor(date / 1e3) * 1e3); - }, function(date, offset) { - date.setTime(date.getTime() + Math.floor(offset) * 1e3); - }, function(date) { - return date.getSeconds(); - }); - d3_time.seconds = d3_time.second.range; - d3_time.seconds.utc = d3_time.second.utc.range; - d3_time.minute = d3_time_interval(function(date) { - return new d3_date(Math.floor(date / 6e4) * 6e4); - }, function(date, offset) { - date.setTime(date.getTime() + Math.floor(offset) * 6e4); - }, function(date) { - return date.getMinutes(); - }); - d3_time.minutes = d3_time.minute.range; - d3_time.minutes.utc = d3_time.minute.utc.range; - d3_time.hour = d3_time_interval(function(date) { - var timezone = date.getTimezoneOffset() / 60; - return new d3_date((Math.floor(date / 36e5 - timezone) + timezone) * 36e5); - }, function(date, offset) { - date.setTime(date.getTime() + Math.floor(offset) * 36e5); - }, function(date) { - return date.getHours(); - }); - d3_time.hours = d3_time.hour.range; - d3_time.hours.utc = d3_time.hour.utc.range; - d3_time.month = d3_time_interval(function(date) { - date = d3_time.day(date); - date.setDate(1); - return date; - }, function(date, offset) { - date.setMonth(date.getMonth() + offset); - }, function(date) { - return date.getMonth(); - }); - d3_time.months = d3_time.month.range; - d3_time.months.utc = d3_time.month.utc.range; - function d3_time_scale(linear, methods, format) { - function scale(x) { - return linear(x); - } - scale.invert = function(x) { - return d3_time_scaleDate(linear.invert(x)); - }; - scale.domain = function(x) { - if (!arguments.length) return linear.domain().map(d3_time_scaleDate); - linear.domain(x); - return scale; - }; - function tickMethod(extent, count) { - var span = extent[1] - extent[0], target = span / count, i = d3.bisect(d3_time_scaleSteps, target); - return i == d3_time_scaleSteps.length ? [ methods.year, d3_scale_linearTickRange(extent.map(function(d) { - return d / 31536e6; - }), count)[2] ] : !i ? [ d3_time_scaleMilliseconds, d3_scale_linearTickRange(extent, count)[2] ] : methods[target / d3_time_scaleSteps[i - 1] < d3_time_scaleSteps[i] / target ? i - 1 : i]; - } - scale.nice = function(interval, skip) { - var domain = scale.domain(), extent = d3_scaleExtent(domain), method = interval == null ? tickMethod(extent, 10) : typeof interval === "number" && tickMethod(extent, interval); - if (method) interval = method[0], skip = method[1]; - function skipped(date) { - return !isNaN(date) && !interval.range(date, d3_time_scaleDate(+date + 1), skip).length; - } - return scale.domain(d3_scale_nice(domain, skip > 1 ? { - floor: function(date) { - while (skipped(date = interval.floor(date))) date = d3_time_scaleDate(date - 1); - return date; - }, - ceil: function(date) { - while (skipped(date = interval.ceil(date))) date = d3_time_scaleDate(+date + 1); - return date; - } - } : interval)); - }; - scale.ticks = function(interval, skip) { - var extent = d3_scaleExtent(scale.domain()), method = interval == null ? tickMethod(extent, 10) : typeof interval === "number" ? tickMethod(extent, interval) : !interval.range && [ { - range: interval - }, skip ]; - if (method) interval = method[0], skip = method[1]; - return interval.range(extent[0], d3_time_scaleDate(+extent[1] + 1), skip < 1 ? 1 : skip); - }; - scale.tickFormat = function() { - return format; - }; - scale.copy = function() { - return d3_time_scale(linear.copy(), methods, format); - }; - return d3_scale_linearRebind(scale, linear); - } - function d3_time_scaleDate(t) { - return new Date(t); - } - var d3_time_scaleSteps = [ 1e3, 5e3, 15e3, 3e4, 6e4, 3e5, 9e5, 18e5, 36e5, 108e5, 216e5, 432e5, 864e5, 1728e5, 6048e5, 2592e6, 7776e6, 31536e6 ]; - var d3_time_scaleLocalMethods = [ [ d3_time.second, 1 ], [ d3_time.second, 5 ], [ d3_time.second, 15 ], [ d3_time.second, 30 ], [ d3_time.minute, 1 ], [ d3_time.minute, 5 ], [ d3_time.minute, 15 ], [ d3_time.minute, 30 ], [ d3_time.hour, 1 ], [ d3_time.hour, 3 ], [ d3_time.hour, 6 ], [ d3_time.hour, 12 ], [ d3_time.day, 1 ], [ d3_time.day, 2 ], [ d3_time.week, 1 ], [ d3_time.month, 1 ], [ d3_time.month, 3 ], [ d3_time.year, 1 ] ]; - var d3_time_scaleLocalFormat = d3_time_format.multi([ [ ".%L", function(d) { - return d.getMilliseconds(); - } ], [ ":%S", function(d) { - return d.getSeconds(); - } ], [ "%I:%M", function(d) { - return d.getMinutes(); - } ], [ "%I %p", function(d) { - return d.getHours(); - } ], [ "%a %d", function(d) { - return d.getDay() && d.getDate() != 1; - } ], [ "%b %d", function(d) { - return d.getDate() != 1; - } ], [ "%B", function(d) { - return d.getMonth(); - } ], [ "%Y", d3_true ] ]); - var d3_time_scaleMilliseconds = { - range: function(start, stop, step) { - return d3.range(Math.ceil(start / step) * step, +stop, step).map(d3_time_scaleDate); - }, - floor: d3_identity, - ceil: d3_identity - }; - d3_time_scaleLocalMethods.year = d3_time.year; - d3_time.scale = function() { - return d3_time_scale(d3.scale.linear(), d3_time_scaleLocalMethods, d3_time_scaleLocalFormat); - }; - var d3_time_scaleUtcMethods = d3_time_scaleLocalMethods.map(function(m) { - return [ m[0].utc, m[1] ]; - }); - var d3_time_scaleUtcFormat = d3_time_formatUtc.multi([ [ ".%L", function(d) { - return d.getUTCMilliseconds(); - } ], [ ":%S", function(d) { - return d.getUTCSeconds(); - } ], [ "%I:%M", function(d) { - return d.getUTCMinutes(); - } ], [ "%I %p", function(d) { - return d.getUTCHours(); - } ], [ "%a %d", function(d) { - return d.getUTCDay() && d.getUTCDate() != 1; - } ], [ "%b %d", function(d) { - return d.getUTCDate() != 1; - } ], [ "%B", function(d) { - return d.getUTCMonth(); - } ], [ "%Y", d3_true ] ]); - d3_time_scaleUtcMethods.year = d3_time.year.utc; - d3_time.scale.utc = function() { - return d3_time_scale(d3.scale.linear(), d3_time_scaleUtcMethods, d3_time_scaleUtcFormat); - }; - d3.text = d3_xhrType(function(request) { - return request.responseText; - }); - d3.json = function(url, callback) { - return d3_xhr(url, "application/json", d3_json, callback); - }; - function d3_json(request) { - return JSON.parse(request.responseText); - } - d3.html = function(url, callback) { - return d3_xhr(url, "text/html", d3_html, callback); - }; - function d3_html(request) { - var range = d3_document.createRange(); - range.selectNode(d3_document.body); - return range.createContextualFragment(request.responseText); - } - d3.xml = d3_xhrType(function(request) { - return request.responseXML; - }); - if (typeof define === "function" && define.amd) this.d3 = d3, define(d3); else if (typeof module === "object" && module.exports) module.exports = d3; else this.d3 = d3; -}(); diff --git a/graph.js b/graph.js deleted file mode 100644 index ad8279395d..0000000000 --- a/graph.js +++ /dev/null @@ -1,129 +0,0 @@ -// GNU Guix --- Functional package management for GNU -// Copyright © 2016 Ricardo Wurmus -// -// This file is part of GNU Guix. -// -// GNU Guix is free software; you can redistribute it and/or modify it -// under the terms of the GNU General Public License as published by -// the Free Software Foundation; either version 3 of the License, or (at -// your option) any later version. -// -// GNU Guix is distributed in the hope that it will be useful, but -// WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with GNU Guix. If not, see . - -var outerRadius = Math.max(nodeArray.length * 15, 500) / 2, - innerRadius = outerRadius - Math.min(nodeArray.length * 5, 200), - width = outerRadius * 2, - height = outerRadius * 2, - colors = d3.scale.category20c(), - matrix = []; - -function neighborsOf (node) { - return links.filter(function (e) { - return e.source === node; - }).map(function (e) { - return e.target; - }); -} - -function zoomed () { - zoomer.attr("transform", - "translate(" + d3.event.translate + ")" + - "scale(" + d3.event.scale + ")"); -} - -function fade (opacity, root) { - return function (g, i) { - root.selectAll("g path.chord") - .filter(function (d) { - return d.source.index != i && d.target.index != i; - }) - .transition() - .style("opacity", opacity); - }; -} - -// Now that we have all nodes in an object we can replace each reference -// with the actual node object. -links.forEach(function (link) { - link.target = nodes[link.target]; - link.source = nodes[link.source]; -}); - -// Construct a square matrix for package dependencies -nodeArray.forEach(function (d, index, arr) { - var source = index, - row = matrix[source]; - if (!row) { - row = matrix[source] = []; - for (var i = -1; ++i < arr.length;) row[i] = 0; - } - neighborsOf(d).forEach(function (d) { row[d.index]++; }); -}); - -// chord layout -var chord = d3.layout.chord() - .padding(0.01) - .sortSubgroups(d3.descending) - .sortChords(d3.descending) - .matrix(matrix); - -var arc = d3.svg.arc() - .innerRadius(innerRadius) - .outerRadius(innerRadius + 20); - -var zoom = d3.behavior.zoom() - .scaleExtent([0.1, 10]) - .on("zoom", zoomed); - -var svg = d3.select("body").append("svg") - .attr("width", "100%") - .attr("height", "100%") - .attr('viewBox', '0 0 ' + Math.min(width, height) + ' ' + Math.min(width, height)) - .attr('preserveAspectRatio', 'xMinYMin') - .call(zoom); - -var zoomer = svg.append("g"); - -var container = zoomer.append("g") - .attr("transform", "translate(" + outerRadius + "," + outerRadius + ")"); - -// Group for arcs and labels -var g = container.selectAll(".group") - .data(chord.groups) - .enter().append("g") - .attr("class", "group") - .on("mouseout", fade(1, container)) - .on("mouseover", fade(0.1, container)); - -// Draw one segment per package -g.append("path") - .style("fill", function (d) { return colors(d.index); }) - .style("stroke", function (d) { return colors(d.index); }) - .attr("d", arc); - -// Add circular labels -g.append("text") - .each(function (d) { d.angle = (d.startAngle + d.endAngle) / 2; }) - .attr("dy", ".35em") - .attr("transform", function (d) { - return "rotate(" + (d.angle * 180 / Math.PI - 90) + ")" - + "translate(" + (innerRadius + 26) + ")" - + (d.angle > Math.PI ? "rotate(180)" : ""); - }) - .style("text-anchor", function (d) { return d.angle > Math.PI ? "end" : null; }) - .text(function (d) { return nodeArray[d.index].label; }); - -// Draw chords from source to target; color by source. -container.selectAll(".chord") - .data(chord.chords) - .enter().append("path") - .attr("class", "chord") - .style("stroke", function (d) { return d3.rgb(colors(d.source.index)).darker(); }) - .style("fill", function (d) { return colors(d.source.index); }) - .attr("d", d3.svg.chord().radius(innerRadius)); diff --git a/guix/d3.v3.js b/guix/d3.v3.js new file mode 100644 index 0000000000..d234c4ec86 --- /dev/null +++ b/guix/d3.v3.js @@ -0,0 +1,9584 @@ +// Downloaded from http://d3js.org/d3.v3.js +// +// Copyright 2010-2016 Mike Bostock +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without modification, +// are permitted provided that the following conditions are met: +// +// * Redistributions of source code must retain the above copyright notice, this +// list of conditions and the following disclaimer. +// +// * Redistributions in binary form must reproduce the above copyright notice, +// this list of conditions and the following disclaimer in the documentation +// and/or other materials provided with the distribution. +// +// * Neither the name of the author nor the names of contributors may be used to +// endorse or promote products derived from this software without specific prior +// written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +!function() { + var d3 = { + version: "3.5.17" + }; + var d3_arraySlice = [].slice, d3_array = function(list) { + return d3_arraySlice.call(list); + }; + var d3_document = this.document; + function d3_documentElement(node) { + return node && (node.ownerDocument || node.document || node).documentElement; + } + function d3_window(node) { + return node && (node.ownerDocument && node.ownerDocument.defaultView || node.document && node || node.defaultView); + } + if (d3_document) { + try { + d3_array(d3_document.documentElement.childNodes)[0].nodeType; + } catch (e) { + d3_array = function(list) { + var i = list.length, array = new Array(i); + while (i--) array[i] = list[i]; + return array; + }; + } + } + if (!Date.now) Date.now = function() { + return +new Date(); + }; + if (d3_document) { + try { + d3_document.createElement("DIV").style.setProperty("opacity", 0, ""); + } catch (error) { + var d3_element_prototype = this.Element.prototype, d3_element_setAttribute = d3_element_prototype.setAttribute, d3_element_setAttributeNS = d3_element_prototype.setAttributeNS, d3_style_prototype = this.CSSStyleDeclaration.prototype, d3_style_setProperty = d3_style_prototype.setProperty; + d3_element_prototype.setAttribute = function(name, value) { + d3_element_setAttribute.call(this, name, value + ""); + }; + d3_element_prototype.setAttributeNS = function(space, local, value) { + d3_element_setAttributeNS.call(this, space, local, value + ""); + }; + d3_style_prototype.setProperty = function(name, value, priority) { + d3_style_setProperty.call(this, name, value + "", priority); + }; + } + } + d3.ascending = d3_ascending; + function d3_ascending(a, b) { + return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN; + } + d3.descending = function(a, b) { + return b < a ? -1 : b > a ? 1 : b >= a ? 0 : NaN; + }; + d3.min = function(array, f) { + var i = -1, n = array.length, a, b; + if (arguments.length === 1) { + while (++i < n) if ((b = array[i]) != null && b >= b) { + a = b; + break; + } + while (++i < n) if ((b = array[i]) != null && a > b) a = b; + } else { + while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { + a = b; + break; + } + while (++i < n) if ((b = f.call(array, array[i], i)) != null && a > b) a = b; + } + return a; + }; + d3.max = function(array, f) { + var i = -1, n = array.length, a, b; + if (arguments.length === 1) { + while (++i < n) if ((b = array[i]) != null && b >= b) { + a = b; + break; + } + while (++i < n) if ((b = array[i]) != null && b > a) a = b; + } else { + while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { + a = b; + break; + } + while (++i < n) if ((b = f.call(array, array[i], i)) != null && b > a) a = b; + } + return a; + }; + d3.extent = function(array, f) { + var i = -1, n = array.length, a, b, c; + if (arguments.length === 1) { + while (++i < n) if ((b = array[i]) != null && b >= b) { + a = c = b; + break; + } + while (++i < n) if ((b = array[i]) != null) { + if (a > b) a = b; + if (c < b) c = b; + } + } else { + while (++i < n) if ((b = f.call(array, array[i], i)) != null && b >= b) { + a = c = b; + break; + } + while (++i < n) if ((b = f.call(array, array[i], i)) != null) { + if (a > b) a = b; + if (c < b) c = b; + } + } + return [ a, c ]; + }; + function d3_number(x) { + return x === null ? NaN : +x; + } + function d3_numeric(x) { + return !isNaN(x); + } + d3.sum = function(array, f) { + var s = 0, n = array.length, a, i = -1; + if (arguments.length === 1) { + while (++i < n) if (d3_numeric(a = +array[i])) s += a; + } else { + while (++i < n) if (d3_numeric(a = +f.call(array, array[i], i))) s += a; + } + return s; + }; + d3.mean = function(array, f) { + var s = 0, n = array.length, a, i = -1, j = n; + if (arguments.length === 1) { + while (++i < n) if (d3_numeric(a = d3_number(array[i]))) s += a; else --j; + } else { + while (++i < n) if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) s += a; else --j; + } + if (j) return s / j; + }; + d3.quantile = function(values, p) { + var H = (values.length - 1) * p + 1, h = Math.floor(H), v = +values[h - 1], e = H - h; + return e ? v + e * (values[h] - v) : v; + }; + d3.median = function(array, f) { + var numbers = [], n = array.length, a, i = -1; + if (arguments.length === 1) { + while (++i < n) if (d3_numeric(a = d3_number(array[i]))) numbers.push(a); + } else { + while (++i < n) if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) numbers.push(a); + } + if (numbers.length) return d3.quantile(numbers.sort(d3_ascending), .5); + }; + d3.variance = function(array, f) { + var n = array.length, m = 0, a, d, s = 0, i = -1, j = 0; + if (arguments.length === 1) { + while (++i < n) { + if (d3_numeric(a = d3_number(array[i]))) { + d = a - m; + m += d / ++j; + s += d * (a - m); + } + } + } else { + while (++i < n) { + if (d3_numeric(a = d3_number(f.call(array, array[i], i)))) { + d = a - m; + m += d / ++j; + s += d * (a - m); + } + } + } + if (j > 1) return s / (j - 1); + }; + d3.deviation = function() { + var v = d3.variance.apply(this, arguments); + return v ? Math.sqrt(v) : v; + }; + function d3_bisector(compare) { + return { + left: function(a, x, lo, hi) { + if (arguments.length < 3) lo = 0; + if (arguments.length < 4) hi = a.length; + while (lo < hi) { + var mid = lo + hi >>> 1; + if (compare(a[mid], x) < 0) lo = mid + 1; else hi = mid; + } + return lo; + }, + right: function(a, x, lo, hi) { + if (arguments.length < 3) lo = 0; + if (arguments.length < 4) hi = a.length; + while (lo < hi) { + var mid = lo + hi >>> 1; + if (compare(a[mid], x) > 0) hi = mid; else lo = mid + 1; + } + return lo; + } + }; + } + var d3_bisect = d3_bisector(d3_ascending); + d3.bisectLeft = d3_bisect.left; + d3.bisect = d3.bisectRight = d3_bisect.right; + d3.bisector = function(f) { + return d3_bisector(f.length === 1 ? function(d, x) { + return d3_ascending(f(d), x); + } : f); + }; + d3.shuffle = function(array, i0, i1) { + if ((m = arguments.length) < 3) { + i1 = array.length; + if (m < 2) i0 = 0; + } + var m = i1 - i0, t, i; + while (m) { + i = Math.random() * m-- | 0; + t = array[m + i0], array[m + i0] = array[i + i0], array[i + i0] = t; + } + return array; + }; + d3.permute = function(array, indexes) { + var i = indexes.length, permutes = new Array(i); + while (i--) permutes[i] = array[indexes[i]]; + return permutes; + }; + d3.pairs = function(array) { + var i = 0, n = array.length - 1, p0, p1 = array[0], pairs = new Array(n < 0 ? 0 : n); + while (i < n) pairs[i] = [ p0 = p1, p1 = array[++i] ]; + return pairs; + }; + d3.transpose = function(matrix) { + if (!(n = matrix.length)) return []; + for (var i = -1, m = d3.min(matrix, d3_transposeLength), transpose = new Array(m); ++i < m; ) { + for (var j = -1, n, row = transpose[i] = new Array(n); ++j < n; ) { + row[j] = matrix[j][i]; + } + } + return transpose; + }; + function d3_transposeLength(d) { + return d.length; + } + d3.zip = function() { + return d3.transpose(arguments); + }; + d3.keys = function(map) { + var keys = []; + for (var key in map) keys.push(key); + return keys; + }; + d3.values = function(map) { + var values = []; + for (var key in map) values.push(map[key]); + return values; + }; + d3.entries = function(map) { + var entries = []; + for (var key in map) entries.push({ + key: key, + value: map[key] + }); + return entries; + }; + d3.merge = function(arrays) { + var n = arrays.length, m, i = -1, j = 0, merged, array; + while (++i < n) j += arrays[i].length; + merged = new Array(j); + while (--n >= 0) { + array = arrays[n]; + m = array.length; + while (--m >= 0) { + merged[--j] = array[m]; + } + } + return merged; + }; + var abs = Math.abs; + d3.range = function(start, stop, step) { + if (arguments.length < 3) { + step = 1; + if (arguments.length < 2) { + stop = start; + start = 0; + } + } + if ((stop - start) / step === Infinity) throw new Error("infinite range"); + var range = [], k = d3_range_integerScale(abs(step)), i = -1, j; + start *= k, stop *= k, step *= k; + if (step < 0) while ((j = start + step * ++i) > stop) range.push(j / k); else while ((j = start + step * ++i) < stop) range.push(j / k); + return range; + }; + function d3_range_integerScale(x) { + var k = 1; + while (x * k % 1) k *= 10; + return k; + } + function d3_class(ctor, properties) { + for (var key in properties) { + Object.defineProperty(ctor.prototype, key, { + value: properties[key], + enumerable: false + }); + } + } + d3.map = function(object, f) { + var map = new d3_Map(); + if (object instanceof d3_Map) { + object.forEach(function(key, value) { + map.set(key, value); + }); + } else if (Array.isArray(object)) { + var i = -1, n = object.length, o; + if (arguments.length === 1) while (++i < n) map.set(i, object[i]); else while (++i < n) map.set(f.call(object, o = object[i], i), o); + } else { + for (var key in object) map.set(key, object[key]); + } + return map; + }; + function d3_Map() { + this._ = Object.create(null); + } + var d3_map_proto = "__proto__", d3_map_zero = "\x00"; + d3_class(d3_Map, { + has: d3_map_has, + get: function(key) { + return this._[d3_map_escape(key)]; + }, + set: function(key, value) { + return this._[d3_map_escape(key)] = value; + }, + remove: d3_map_remove, + keys: d3_map_keys, + values: function() { + var values = []; + for (var key in this._) values.push(this._[key]); + return values; + }, + entries: function() { + var entries = []; + for (var key in this._) entries.push({ + key: d3_map_unescape(key), + value: this._[key] + }); + return entries; + }, + size: d3_map_size, + empty: d3_map_empty, + forEach: function(f) { + for (var key in this._) f.call(this, d3_map_unescape(key), this._[key]); + } + }); + function d3_map_escape(key) { + return (key += "") === d3_map_proto || key[0] === d3_map_zero ? d3_map_zero + key : key; + } + function d3_map_unescape(key) { + return (key += "")[0] === d3_map_zero ? key.slice(1) : key; + } + function d3_map_has(key) { + return d3_map_escape(key) in this._; + } + function d3_map_remove(key) { + return (key = d3_map_escape(key)) in this._ && delete this._[key]; + } + function d3_map_keys() { + var keys = []; + for (var key in this._) keys.push(d3_map_unescape(key)); + return keys; + } + function d3_map_size() { + var size = 0; + for (var key in this._) ++size; + return size; + } + function d3_map_empty() { + for (var key in this._) return false; + return true; + } + d3.nest = function() { + var nest = {}, keys = [], sortKeys = [], sortValues, rollup; + function map(mapType, array, depth) { + if (depth >= keys.length) return rollup ? rollup.call(nest, array) : sortValues ? array.sort(sortValues) : array; + var i = -1, n = array.length, key = keys[depth++], keyValue, object, setter, valuesByKey = new d3_Map(), values; + while (++i < n) { + if (values = valuesByKey.get(keyValue = key(object = array[i]))) { + values.push(object); + } else { + valuesByKey.set(keyValue, [ object ]); + } + } + if (mapType) { + object = mapType(); + setter = function(keyValue, values) { + object.set(keyValue, map(mapType, values, depth)); + }; + } else { + object = {}; + setter = function(keyValue, values) { + object[keyValue] = map(mapType, values, depth); + }; + } + valuesByKey.forEach(setter); + return object; + } + function entries(map, depth) { + if (depth >= keys.length) return map; + var array = [], sortKey = sortKeys[depth++]; + map.forEach(function(key, keyMap) { + array.push({ + key: key, + values: entries(keyMap, depth) + }); + }); + return sortKey ? array.sort(function(a, b) { + return sortKey(a.key, b.key); + }) : array; + } + nest.map = function(array, mapType) { + return map(mapType, array, 0); + }; + nest.entries = function(array) { + return entries(map(d3.map, array, 0), 0); + }; + nest.key = function(d) { + keys.push(d); + return nest; + }; + nest.sortKeys = function(order) { + sortKeys[keys.length - 1] = order; + return nest; + }; + nest.sortValues = function(order) { + sortValues = order; + return nest; + }; + nest.rollup = function(f) { + rollup = f; + return nest; + }; + return nest; + }; + d3.set = function(array) { + var set = new d3_Set(); + if (array) for (var i = 0, n = array.length; i < n; ++i) set.add(array[i]); + return set; + }; + function d3_Set() { + this._ = Object.create(null); + } + d3_class(d3_Set, { + has: d3_map_has, + add: function(key) { + this._[d3_map_escape(key += "")] = true; + return key; + }, + remove: d3_map_remove, + values: d3_map_keys, + size: d3_map_size, + empty: d3_map_empty, + forEach: function(f) { + for (var key in this._) f.call(this, d3_map_unescape(key)); + } + }); + d3.behavior = {}; + function d3_identity(d) { + return d; + } + d3.rebind = function(target, source) { + var i = 1, n = arguments.length, method; + while (++i < n) target[method = arguments[i]] = d3_rebind(target, source, source[method]); + return target; + }; + function d3_rebind(target, source, method) { + return function() { + var value = method.apply(source, arguments); + return value === source ? target : value; + }; + } + function d3_vendorSymbol(object, name) { + if (name in object) return name; + name = name.charAt(0).toUpperCase() + name.slice(1); + for (var i = 0, n = d3_vendorPrefixes.length; i < n; ++i) { + var prefixName = d3_vendorPrefixes[i] + name; + if (prefixName in object) return prefixName; + } + } + var d3_vendorPrefixes = [ "webkit", "ms", "moz", "Moz", "o", "O" ]; + function d3_noop() {} + d3.dispatch = function() { + var dispatch = new d3_dispatch(), i = -1, n = arguments.length; + while (++i < n) dispatch[arguments[i]] = d3_dispatch_event(dispatch); + return dispatch; + }; + function d3_dispatch() {} + d3_dispatch.prototype.on = function(type, listener) { + var i = type.indexOf("."), name = ""; + if (i >= 0) { + name = type.slice(i + 1); + type = type.slice(0, i); + } + if (type) return arguments.length < 2 ? this[type].on(name) : this[type].on(name, listener); + if (arguments.length === 2) { + if (listener == null) for (type in this) { + if (this.hasOwnProperty(type)) this[type].on(name, null); + } + return this; + } + }; + function d3_dispatch_event(dispatch) { + var listeners = [], listenerByName = new d3_Map(); + function event() { + var z = listeners, i = -1, n = z.length, l; + while (++i < n) if (l = z[i].on) l.apply(this, arguments); + return dispatch; + } + event.on = function(name, listener) { + var l = listenerByName.get(name), i; + if (arguments.length < 2) return l && l.on; + if (l) { + l.on = null; + listeners = listeners.slice(0, i = listeners.indexOf(l)).concat(listeners.slice(i + 1)); + listenerByName.remove(name); + } + if (listener) listeners.push(listenerByName.set(name, { + on: listener + })); + return dispatch; + }; + return event; + } + d3.event = null; + function d3_eventPreventDefault() { + d3.event.preventDefault(); + } + function d3_eventSource() { + var e = d3.event, s; + while (s = e.sourceEvent) e = s; + return e; + } + function d3_eventDispatch(target) { + var dispatch = new d3_dispatch(), i = 0, n = arguments.length; + while (++i < n) dispatch[arguments[i]] = d3_dispatch_event(dispatch); + dispatch.of = function(thiz, argumentz) { + return function(e1) { + try { + var e0 = e1.sourceEvent = d3.event; + e1.target = target; + d3.event = e1; + dispatch[e1.type].apply(thiz, argumentz); + } finally { + d3.event = e0; + } + }; + }; + return dispatch; + } + d3.requote = function(s) { + return s.replace(d3_requote_re, "\\$&"); + }; + var d3_requote_re = /[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g; + var d3_subclass = {}.__proto__ ? function(object, prototype) { + object.__proto__ = prototype; + } : function(object, prototype) { + for (var property in prototype) object[property] = prototype[property]; + }; + function d3_selection(groups) { + d3_subclass(groups, d3_selectionPrototype); + return groups; + } + var d3_select = function(s, n) { + return n.querySelector(s); + }, d3_selectAll = function(s, n) { + return n.querySelectorAll(s); + }, d3_selectMatches = function(n, s) { + var d3_selectMatcher = n.matches || n[d3_vendorSymbol(n, "matchesSelector")]; + d3_selectMatches = function(n, s) { + return d3_selectMatcher.call(n, s); + }; + return d3_selectMatches(n, s); + }; + if (typeof Sizzle === "function") { + d3_select = function(s, n) { + return Sizzle(s, n)[0] || null; + }; + d3_selectAll = Sizzle; + d3_selectMatches = Sizzle.matchesSelector; + } + d3.selection = function() { + return d3.select(d3_document.documentElement); + }; + var d3_selectionPrototype = d3.selection.prototype = []; + d3_selectionPrototype.select = function(selector) { + var subgroups = [], subgroup, subnode, group, node; + selector = d3_selection_selector(selector); + for (var j = -1, m = this.length; ++j < m; ) { + subgroups.push(subgroup = []); + subgroup.parentNode = (group = this[j]).parentNode; + for (var i = -1, n = group.length; ++i < n; ) { + if (node = group[i]) { + subgroup.push(subnode = selector.call(node, node.__data__, i, j)); + if (subnode && "__data__" in node) subnode.__data__ = node.__data__; + } else { + subgroup.push(null); + } + } + } + return d3_selection(subgroups); + }; + function d3_selection_selector(selector) { + return typeof selector === "function" ? selector : function() { + return d3_select(selector, this); + }; + } + d3_selectionPrototype.selectAll = function(selector) { + var subgroups = [], subgroup, node; + selector = d3_selection_selectorAll(selector); + for (var j = -1, m = this.length; ++j < m; ) { + for (var group = this[j], i = -1, n = group.length; ++i < n; ) { + if (node = group[i]) { + subgroups.push(subgroup = d3_array(selector.call(node, node.__data__, i, j))); + subgroup.parentNode = node; + } + } + } + return d3_selection(subgroups); + }; + function d3_selection_selectorAll(selector) { + return typeof selector === "function" ? selector : function() { + return d3_selectAll(selector, this); + }; + } + var d3_nsXhtml = "http://www.w3.org/1999/xhtml"; + var d3_nsPrefix = { + svg: "http://www.w3.org/2000/svg", + xhtml: d3_nsXhtml, + xlink: "http://www.w3.org/1999/xlink", + xml: "http://www.w3.org/XML/1998/namespace", + xmlns: "http://www.w3.org/2000/xmlns/" + }; + d3.ns = { + prefix: d3_nsPrefix, + qualify: function(name) { + var i = name.indexOf(":"), prefix = name; + if (i >= 0 && (prefix = name.slice(0, i)) !== "xmlns") name = name.slice(i + 1); + return d3_nsPrefix.hasOwnProperty(prefix) ? { + space: d3_nsPrefix[prefix], + local: name + } : name; + } + }; + d3_selectionPrototype.attr = function(name, value) { + if (arguments.length < 2) { + if (typeof name === "string") { + var node = this.node(); + name = d3.ns.qualify(name); + return name.local ? node.getAttributeNS(name.space, name.local) : node.getAttribute(name); + } + for (value in name) this.each(d3_selection_attr(value, name[value])); + return this; + } + return this.each(d3_selection_attr(name, value)); + }; + function d3_selection_attr(name, value) { + name = d3.ns.qualify(name); + function attrNull() { + this.removeAttribute(name); + } + function attrNullNS() { + this.removeAttributeNS(name.space, name.local); + } + function attrConstant() { + this.setAttribute(name, value); + } + function attrConstantNS() { + this.setAttributeNS(name.space, name.local, value); + } + function attrFunction() { + var x = value.apply(this, arguments); + if (x == null) this.removeAttribute(name); else this.setAttribute(name, x); + } + function attrFunctionNS() { + var x = value.apply(this, arguments); + if (x == null) this.removeAttributeNS(name.space, name.local); else this.setAttributeNS(name.space, name.local, x); + } + return value == null ? name.local ? attrNullNS : attrNull : typeof value === "function" ? name.local ? attrFunctionNS : attrFunction : name.local ? attrConstantNS : attrConstant; + } + function d3_collapse(s) { + return s.trim().replace(/\s+/g, " "); + } + d3_selectionPrototype.classed = function(name, value) { + if (arguments.length < 2) { + if (typeof name === "string") { + var node = this.node(), n = (name = d3_selection_classes(name)).length, i = -1; + if (value = node.classList) { + while (++i < n) if (!value.contains(name[i])) return false; + } else { + value = node.getAttribute("class"); + while (++i < n) if (!d3_selection_classedRe(name[i]).test(value)) return false; + } + return true; + } + for (value in name) this.each(d3_selection_classed(value, name[value])); + return this; + } + return this.each(d3_selection_classed(name, value)); + }; + function d3_selection_classedRe(name) { + return new RegExp("(?:^|\\s+)" + d3.requote(name) + "(?:\\s+|$)", "g"); + } + function d3_selection_classes(name) { + return (name + "").trim().split(/^|\s+/); + } + function d3_selection_classed(name, value) { + name = d3_selection_classes(name).map(d3_selection_classedName); + var n = name.length; + function classedConstant() { + var i = -1; + while (++i < n) name[i](this, value); + } + function classedFunction() { + var i = -1, x = value.apply(this, arguments); + while (++i < n) name[i](this, x); + } + return typeof value === "function" ? classedFunction : classedConstant; + } + function d3_selection_classedName(name) { + var re = d3_selection_classedRe(name); + return function(node, value) { + if (c = node.classList) return value ? c.add(name) : c.remove(name); + var c = node.getAttribute("class") || ""; + if (value) { + re.lastIndex = 0; + if (!re.test(c)) node.setAttribute("class", d3_collapse(c + " " + name)); + } else { + node.setAttribute("class", d3_collapse(c.replace(re, " "))); + } + }; + } + d3_selectionPrototype.style = function(name, value, priority) { + var n = arguments.length; + if (n < 3) { + if (typeof name !== "string") { + if (n < 2) value = ""; + for (priority in name) this.each(d3_selection_style(priority, name[priority], value)); + return this; + } + if (n < 2) { + var node = this.node(); + return d3_window(node).getComputedStyle(node, null).getPropertyValue(name); + } + priority = ""; + } + return this.each(d3_selection_style(name, value, priority)); + }; + function d3_selection_style(name, value, priority) { + function styleNull() { + this.style.removeProperty(name); + } + function styleConstant() { + this.style.setProperty(name, value, priority); + } + function styleFunction() { + var x = value.apply(this, arguments); + if (x == null) this.style.removeProperty(name); else this.style.setProperty(name, x, priority); + } + return value == null ? styleNull : typeof value === "function" ? styleFunction : styleConstant; + } + d3_selectionPrototype.property = function(name, value) { + if (arguments.length < 2) { + if (typeof name === "string") return this.node()[name]; + for (value in name) this.each(d3_selection_property(value, name[value])); + return this; + } + return this.each(d3_selection_property(name, value)); + }; + function d3_selection_property(name, value) { + function propertyNull() { + delete this[name]; + } + function propertyConstant() { + this[name] = value; + } + function propertyFunction() { + var x = value.apply(this, arguments); + if (x == null) delete this[name]; else this[name] = x; + } + return value == null ? propertyNull : typeof value === "function" ? propertyFunction : propertyConstant; + } + d3_selectionPrototype.text = function(value) { + return arguments.length ? this.each(typeof value === "function" ? function() { + var v = value.apply(this, arguments); + this.textContent = v == null ? "" : v; + } : value == null ? function() { + this.textContent = ""; + } : function() { + this.textContent = value; + }) : this.node().textContent; + }; + d3_selectionPrototype.html = function(value) { + return arguments.length ? this.each(typeof value === "function" ? function() { + var v = value.apply(this, arguments); + this.innerHTML = v == null ? "" : v; + } : value == null ? function() { + this.innerHTML = ""; + } : function() { + this.innerHTML = value; + }) : this.node().innerHTML; + }; + d3_selectionPrototype.append = function(name) { + name = d3_selection_creator(name); + return this.select(function() { + return this.appendChild(name.apply(this, arguments)); + }); + }; + function d3_selection_creator(name) { + function create() { + var document = this.ownerDocument, namespace = this.namespaceURI; + return namespace === d3_nsXhtml && document.documentElement.namespaceURI === d3_nsXhtml ? document.createElement(name) : document.createElementNS(namespace, name); + } + function createNS() { + return this.ownerDocument.createElementNS(name.space, name.local); + } + return typeof name === "function" ? name : (name = d3.ns.qualify(name)).local ? createNS : create; + } + d3_selectionPrototype.insert = function(name, before) { + name = d3_selection_creator(name); + before = d3_selection_selector(before); + return this.select(function() { + return this.insertBefore(name.apply(this, arguments), before.apply(this, arguments) || null); + }); + }; + d3_selectionPrototype.remove = function() { + return this.each(d3_selectionRemove); + }; + function d3_selectionRemove() { + var parent = this.parentNode; + if (parent) parent.removeChild(this); + } + d3_selectionPrototype.data = function(value, key) { + var i = -1, n = this.length, group, node; + if (!arguments.length) { + value = new Array(n = (group = this[0]).length); + while (++i < n) { + if (node = group[i]) { + value[i] = node.__data__; + } + } + return value; + } + function bind(group, groupData) { + var i, n = group.length, m = groupData.length, n0 = Math.min(n, m), updateNodes = new Array(m), enterNodes = new Array(m), exitNodes = new Array(n), node, nodeData; + if (key) { + var nodeByKeyValue = new d3_Map(), keyValues = new Array(n), keyValue; + for (i = -1; ++i < n; ) { + if (node = group[i]) { + if (nodeByKeyValue.has(keyValue = key.call(node, node.__data__, i))) { + exitNodes[i] = node; + } else { + nodeByKeyValue.set(keyValue, node); + } + keyValues[i] = keyValue; + } + } + for (i = -1; ++i < m; ) { + if (!(node = nodeByKeyValue.get(keyValue = key.call(groupData, nodeData = groupData[i], i)))) { + enterNodes[i] = d3_selection_dataNode(nodeData); + } else if (node !== true) { + updateNodes[i] = node; + node.__data__ = nodeData; + } + nodeByKeyValue.set(keyValue, true); + } + for (i = -1; ++i < n; ) { + if (i in keyValues && nodeByKeyValue.get(keyValues[i]) !== true) { + exitNodes[i] = group[i]; + } + } + } else { + for (i = -1; ++i < n0; ) { + node = group[i]; + nodeData = groupData[i]; + if (node) { + node.__data__ = nodeData; + updateNodes[i] = node; + } else { + enterNodes[i] = d3_selection_dataNode(nodeData); + } + } + for (;i < m; ++i) { + enterNodes[i] = d3_selection_dataNode(groupData[i]); + } + for (;i < n; ++i) { + exitNodes[i] = group[i]; + } + } + enterNodes.update = updateNodes; + enterNodes.parentNode = updateNodes.parentNode = exitNodes.parentNode = group.parentNode; + enter.push(enterNodes); + update.push(updateNodes); + exit.push(exitNodes); + } + var enter = d3_selection_enter([]), update = d3_selection([]), exit = d3_selection([]); + if (typeof value === "function") { + while (++i < n) { + bind(group = this[i], value.call(group, group.parentNode.__data__, i)); + } + } else { + while (++i < n) { + bind(group = this[i], value); + } + } + update.enter = function() { + return enter; + }; + update.exit = function() { + return exit; + }; + return update; + }; + function d3_selection_dataNode(data) { + return { + __data__: data + }; + } + d3_selectionPrototype.datum = function(value) { + return arguments.length ? this.property("__data__", value) : this.property("__data__"); + }; + d3_selectionPrototype.filter = function(filter) { + var subgroups = [], subgroup, group, node; + if (typeof filter !== "function") filter = d3_selection_filter(filter); + for (var j = 0, m = this.length; j < m; j++) { + subgroups.push(subgroup = []); + subgroup.parentNode = (group = this[j]).parentNode; + for (var i = 0, n = group.length; i < n; i++) { + if ((node = group[i]) && filter.call(node, node.__data__, i, j)) { + subgroup.push(node); + } + } + } + return d3_selection(subgroups); + }; + function d3_selection_filter(selector) { + return function() { + return d3_selectMatches(this, selector); + }; + } + d3_selectionPrototype.order = function() { + for (var j = -1, m = this.length; ++j < m; ) { + for (var group = this[j], i = group.length - 1, next = group[i], node; --i >= 0; ) { + if (node = group[i]) { + if (next && next !== node.nextSibling) next.parentNode.insertBefore(node, next); + next = node; + } + } + } + return this; + }; + d3_selectionPrototype.sort = function(comparator) { + comparator = d3_selection_sortComparator.apply(this, arguments); + for (var j = -1, m = this.length; ++j < m; ) this[j].sort(comparator); + return this.order(); + }; + function d3_selection_sortComparator(comparator) { + if (!arguments.length) comparator = d3_ascending; + return function(a, b) { + return a && b ? comparator(a.__data__, b.__data__) : !a - !b; + }; + } + d3_selectionPrototype.each = function(callback) { + return d3_selection_each(this, function(node, i, j) { + callback.call(node, node.__data__, i, j); + }); + }; + function d3_selection_each(groups, callback) { + for (var j = 0, m = groups.length; j < m; j++) { + for (var group = groups[j], i = 0, n = group.length, node; i < n; i++) { + if (node = group[i]) callback(node, i, j); + } + } + return groups; + } + d3_selectionPrototype.call = function(callback) { + var args = d3_array(arguments); + callback.apply(args[0] = this, args); + return this; + }; + d3_selectionPrototype.empty = function() { + return !this.node(); + }; + d3_selectionPrototype.node = function() { + for (var j = 0, m = this.length; j < m; j++) { + for (var group = this[j], i = 0, n = group.length; i < n; i++) { + var node = group[i]; + if (node) return node; + } + } + return null; + }; + d3_selectionPrototype.size = function() { + var n = 0; + d3_selection_each(this, function() { + ++n; + }); + return n; + }; + function d3_selection_enter(selection) { + d3_subclass(selection, d3_selection_enterPrototype); + return selection; + } + var d3_selection_enterPrototype = []; + d3.selection.enter = d3_selection_enter; + d3.selection.enter.prototype = d3_selection_enterPrototype; + d3_selection_enterPrototype.append = d3_selectionPrototype.append; + d3_selection_enterPrototype.empty = d3_selectionPrototype.empty; + d3_selection_enterPrototype.node = d3_selectionPrototype.node; + d3_selection_enterPrototype.call = d3_selectionPrototype.call; + d3_selection_enterPrototype.size = d3_selectionPrototype.size; + d3_selection_enterPrototype.select = function(selector) { + var subgroups = [], subgroup, subnode, upgroup, group, node; + for (var j = -1, m = this.length; ++j < m; ) { + upgroup = (group = this[j]).update; + subgroups.push(subgroup = []); + subgroup.parentNode = group.parentNode; + for (var i = -1, n = group.length; ++i < n; ) { + if (node = group[i]) { + subgroup.push(upgroup[i] = subnode = selector.call(group.parentNode, node.__data__, i, j)); + subnode.__data__ = node.__data__; + } else { + subgroup.push(null); + } + } + } + return d3_selection(subgroups); + }; + d3_selection_enterPrototype.insert = function(name, before) { + if (arguments.length < 2) before = d3_selection_enterInsertBefore(this); + return d3_selectionPrototype.insert.call(this, name, before); + }; + function d3_selection_enterInsertBefore(enter) { + var i0, j0; + return function(d, i, j) { + var group = enter[j].update, n = group.length, node; + if (j != j0) j0 = j, i0 = 0; + if (i >= i0) i0 = i + 1; + while (!(node = group[i0]) && ++i0 < n) ; + return node; + }; + } + d3.select = function(node) { + var group; + if (typeof node === "string") { + group = [ d3_select(node, d3_document) ]; + group.parentNode = d3_document.documentElement; + } else { + group = [ node ]; + group.parentNode = d3_documentElement(node); + } + return d3_selection([ group ]); + }; + d3.selectAll = function(nodes) { + var group; + if (typeof nodes === "string") { + group = d3_array(d3_selectAll(nodes, d3_document)); + group.parentNode = d3_document.documentElement; + } else { + group = d3_array(nodes); + group.parentNode = null; + } + return d3_selection([ group ]); + }; + d3_selectionPrototype.on = function(type, listener, capture) { + var n = arguments.length; + if (n < 3) { + if (typeof type !== "string") { + if (n < 2) listener = false; + for (capture in type) this.each(d3_selection_on(capture, type[capture], listener)); + return this; + } + if (n < 2) return (n = this.node()["__on" + type]) && n._; + capture = false; + } + return this.each(d3_selection_on(type, listener, capture)); + }; + function d3_selection_on(type, listener, capture) { + var name = "__on" + type, i = type.indexOf("."), wrap = d3_selection_onListener; + if (i > 0) type = type.slice(0, i); + var filter = d3_selection_onFilters.get(type); + if (filter) type = filter, wrap = d3_selection_onFilter; + function onRemove() { + var l = this[name]; + if (l) { + this.removeEventListener(type, l, l.$); + delete this[name]; + } + } + function onAdd() { + var l = wrap(listener, d3_array(arguments)); + onRemove.call(this); + this.addEventListener(type, this[name] = l, l.$ = capture); + l._ = listener; + } + function removeAll() { + var re = new RegExp("^__on([^.]+)" + d3.requote(type) + "$"), match; + for (var name in this) { + if (match = name.match(re)) { + var l = this[name]; + this.removeEventListener(match[1], l, l.$); + delete this[name]; + } + } + } + return i ? listener ? onAdd : onRemove : listener ? d3_noop : removeAll; + } + var d3_selection_onFilters = d3.map({ + mouseenter: "mouseover", + mouseleave: "mouseout" + }); + if (d3_document) { + d3_selection_onFilters.forEach(function(k) { + if ("on" + k in d3_document) d3_selection_onFilters.remove(k); + }); + } + function d3_selection_onListener(listener, argumentz) { + return function(e) { + var o = d3.event; + d3.event = e; + argumentz[0] = this.__data__; + try { + listener.apply(this, argumentz); + } finally { + d3.event = o; + } + }; + } + function d3_selection_onFilter(listener, argumentz) { + var l = d3_selection_onListener(listener, argumentz); + return function(e) { + var target = this, related = e.relatedTarget; + if (!related || related !== target && !(related.compareDocumentPosition(target) & 8)) { + l.call(target, e); + } + }; + } + var d3_event_dragSelect, d3_event_dragId = 0; + function d3_event_dragSuppress(node) { + var name = ".dragsuppress-" + ++d3_event_dragId, click = "click" + name, w = d3.select(d3_window(node)).on("touchmove" + name, d3_eventPreventDefault).on("dragstart" + name, d3_eventPreventDefault).on("selectstart" + name, d3_eventPreventDefault); + if (d3_event_dragSelect == null) { + d3_event_dragSelect = "onselectstart" in node ? false : d3_vendorSymbol(node.style, "userSelect"); + } + if (d3_event_dragSelect) { + var style = d3_documentElement(node).style, select = style[d3_event_dragSelect]; + style[d3_event_dragSelect] = "none"; + } + return function(suppressClick) { + w.on(name, null); + if (d3_event_dragSelect) style[d3_event_dragSelect] = select; + if (suppressClick) { + var off = function() { + w.on(click, null); + }; + w.on(click, function() { + d3_eventPreventDefault(); + off(); + }, true); + setTimeout(off, 0); + } + }; + } + d3.mouse = function(container) { + return d3_mousePoint(container, d3_eventSource()); + }; + var d3_mouse_bug44083 = this.navigator && /WebKit/.test(this.navigator.userAgent) ? -1 : 0; + function d3_mousePoint(container, e) { + if (e.changedTouches) e = e.changedTouches[0]; + var svg = container.ownerSVGElement || container; + if (svg.createSVGPoint) { + var point = svg.createSVGPoint(); + if (d3_mouse_bug44083 < 0) { + var window = d3_window(container); + if (window.scrollX || window.scrollY) { + svg = d3.select("body").append("svg").style({ + position: "absolute", + top: 0, + left: 0, + margin: 0, + padding: 0, + border: "none" + }, "important"); + var ctm = svg[0][0].getScreenCTM(); + d3_mouse_bug44083 = !(ctm.f || ctm.e); + svg.remove(); + } + } + if (d3_mouse_bug44083) point.x = e.pageX, point.y = e.pageY; else point.x = e.clientX, + point.y = e.clientY; + point = point.matrixTransform(container.getScreenCTM().inverse()); + return [ point.x, point.y ]; + } + var rect = container.getBoundingClientRect(); + return [ e.clientX - rect.left - container.clientLeft, e.clientY - rect.top - container.clientTop ]; + } + d3.touch = function(container, touches, identifier) { + if (arguments.length < 3) identifier = touches, touches = d3_eventSource().changedTouches; + if (touches) for (var i = 0, n = touches.length, touch; i < n; ++i) { + if ((touch = touches[i]).identifier === identifier) { + return d3_mousePoint(container, touch); + } + } + }; + d3.behavior.drag = function() { + var event = d3_eventDispatch(drag, "drag", "dragstart", "dragend"), origin = null, mousedown = dragstart(d3_noop, d3.mouse, d3_window, "mousemove", "mouseup"), touchstart = dragstart(d3_behavior_dragTouchId, d3.touch, d3_identity, "touchmove", "touchend"); + function drag() { + this.on("mousedown.drag", mousedown).on("touchstart.drag", touchstart); + } + function dragstart(id, position, subject, move, end) { + return function() { + var that = this, target = d3.event.target.correspondingElement || d3.event.target, parent = that.parentNode, dispatch = event.of(that, arguments), dragged = 0, dragId = id(), dragName = ".drag" + (dragId == null ? "" : "-" + dragId), dragOffset, dragSubject = d3.select(subject(target)).on(move + dragName, moved).on(end + dragName, ended), dragRestore = d3_event_dragSuppress(target), position0 = position(parent, dragId); + if (origin) { + dragOffset = origin.apply(that, arguments); + dragOffset = [ dragOffset.x - position0[0], dragOffset.y - position0[1] ]; + } else { + dragOffset = [ 0, 0 ]; + } + dispatch({ + type: "dragstart" + }); + function moved() { + var position1 = position(parent, dragId), dx, dy; + if (!position1) return; + dx = position1[0] - position0[0]; + dy = position1[1] - position0[1]; + dragged |= dx | dy; + position0 = position1; + dispatch({ + type: "drag", + x: position1[0] + dragOffset[0], + y: position1[1] + dragOffset[1], + dx: dx, + dy: dy + }); + } + function ended() { + if (!position(parent, dragId)) return; + dragSubject.on(move + dragName, null).on(end + dragName, null); + dragRestore(dragged); + dispatch({ + type: "dragend" + }); + } + }; + } + drag.origin = function(x) { + if (!arguments.length) return origin; + origin = x; + return drag; + }; + return d3.rebind(drag, event, "on"); + }; + function d3_behavior_dragTouchId() { + return d3.event.changedTouches[0].identifier; + } + d3.touches = function(container, touches) { + if (arguments.length < 2) touches = d3_eventSource().touches; + return touches ? d3_array(touches).map(function(touch) { + var point = d3_mousePoint(container, touch); + point.identifier = touch.identifier; + return point; + }) : []; + }; + var ε = 1e-6, ε2 = ε * ε, π = Math.PI, τ = 2 * π, τε = τ - ε, halfπ = π / 2, d3_radians = π / 180, d3_degrees = 180 / π; + function d3_sgn(x) { + return x > 0 ? 1 : x < 0 ? -1 : 0; + } + function d3_cross2d(a, b, c) { + return (b[0] - a[0]) * (c[1] - a[1]) - (b[1] - a[1]) * (c[0] - a[0]); + } + function d3_acos(x) { + return x > 1 ? 0 : x < -1 ? π : Math.acos(x); + } + function d3_asin(x) { + return x > 1 ? halfπ : x < -1 ? -halfπ : Math.asin(x); + } + function d3_sinh(x) { + return ((x = Math.exp(x)) - 1 / x) / 2; + } + function d3_cosh(x) { + return ((x = Math.exp(x)) + 1 / x) / 2; + } + function d3_tanh(x) { + return ((x = Math.exp(2 * x)) - 1) / (x + 1); + } + function d3_haversin(x) { + return (x = Math.sin(x / 2)) * x; + } + var ρ = Math.SQRT2, ρ2 = 2, ρ4 = 4; + d3.interpolateZoom = function(p0, p1) { + var ux0 = p0[0], uy0 = p0[1], w0 = p0[2], ux1 = p1[0], uy1 = p1[1], w1 = p1[2], dx = ux1 - ux0, dy = uy1 - uy0, d2 = dx * dx + dy * dy, i, S; + if (d2 < ε2) { + S = Math.log(w1 / w0) / ρ; + i = function(t) { + return [ ux0 + t * dx, uy0 + t * dy, w0 * Math.exp(ρ * t * S) ]; + }; + } else { + var d1 = Math.sqrt(d2), b0 = (w1 * w1 - w0 * w0 + ρ4 * d2) / (2 * w0 * ρ2 * d1), b1 = (w1 * w1 - w0 * w0 - ρ4 * d2) / (2 * w1 * ρ2 * d1), r0 = Math.log(Math.sqrt(b0 * b0 + 1) - b0), r1 = Math.log(Math.sqrt(b1 * b1 + 1) - b1); + S = (r1 - r0) / ρ; + i = function(t) { + var s = t * S, coshr0 = d3_cosh(r0), u = w0 / (ρ2 * d1) * (coshr0 * d3_tanh(ρ * s + r0) - d3_sinh(r0)); + return [ ux0 + u * dx, uy0 + u * dy, w0 * coshr0 / d3_cosh(ρ * s + r0) ]; + }; + } + i.duration = S * 1e3; + return i; + }; + d3.behavior.zoom = function() { + var view = { + x: 0, + y: 0, + k: 1 + }, translate0, center0, center, size = [ 960, 500 ], scaleExtent = d3_behavior_zoomInfinity, duration = 250, zooming = 0, mousedown = "mousedown.zoom", mousemove = "mousemove.zoom", mouseup = "mouseup.zoom", mousewheelTimer, touchstart = "touchstart.zoom", touchtime, event = d3_eventDispatch(zoom, "zoomstart", "zoom", "zoomend"), x0, x1, y0, y1; + if (!d3_behavior_zoomWheel) { + d3_behavior_zoomWheel = "onwheel" in d3_document ? (d3_behavior_zoomDelta = function() { + return -d3.event.deltaY * (d3.event.deltaMode ? 120 : 1); + }, "wheel") : "onmousewheel" in d3_document ? (d3_behavior_zoomDelta = function() { + return d3.event.wheelDelta; + }, "mousewheel") : (d3_behavior_zoomDelta = function() { + return -d3.event.detail; + }, "MozMousePixelScroll"); + } + function zoom(g) { + g.on(mousedown, mousedowned).on(d3_behavior_zoomWheel + ".zoom", mousewheeled).on("dblclick.zoom", dblclicked).on(touchstart, touchstarted); + } + zoom.event = function(g) { + g.each(function() { + var dispatch = event.of(this, arguments), view1 = view; + if (d3_transitionInheritId) { + d3.select(this).transition().each("start.zoom", function() { + view = this.__chart__ || { + x: 0, + y: 0, + k: 1 + }; + zoomstarted(dispatch); + }).tween("zoom:zoom", function() { + var dx = size[0], dy = size[1], cx = center0 ? center0[0] : dx / 2, cy = center0 ? center0[1] : dy / 2, i = d3.interpolateZoom([ (cx - view.x) / view.k, (cy - view.y) / view.k, dx / view.k ], [ (cx - view1.x) / view1.k, (cy - view1.y) / view1.k, dx / view1.k ]); + return function(t) { + var l = i(t), k = dx / l[2]; + this.__chart__ = view = { + x: cx - l[0] * k, + y: cy - l[1] * k, + k: k + }; + zoomed(dispatch); + }; + }).each("interrupt.zoom", function() { + zoomended(dispatch); + }).each("end.zoom", function() { + zoomended(dispatch); + }); + } else { + this.__chart__ = view; + zoomstarted(dispatch); + zoomed(dispatch); + zoomended(dispatch); + } + }); + }; + zoom.translate = function(_) { + if (!arguments.length) return [ view.x, view.y ]; + view = { + x: +_[0], + y: +_[1], + k: view.k + }; + rescale(); + return zoom; + }; + zoom.scale = function(_) { + if (!arguments.length) return view.k; + view = { + x: view.x, + y: view.y, + k: null + }; + scaleTo(+_); + rescale(); + return zoom; + }; + zoom.scaleExtent = function(_) { + if (!arguments.length) return scaleExtent; + scaleExtent = _ == null ? d3_behavior_zoomInfinity : [ +_[0], +_[1] ]; + return zoom; + }; + zoom.center = function(_) { + if (!arguments.length) return center; + center = _ && [ +_[0], +_[1] ]; + return zoom; + }; + zoom.size = function(_) { + if (!arguments.length) return size; + size = _ && [ +_[0], +_[1] ]; + return zoom; + }; + zoom.duration = function(_) { + if (!arguments.length) return duration; + duration = +_; + return zoom; + }; + zoom.x = function(z) { + if (!arguments.length) return x1; + x1 = z; + x0 = z.copy(); + view = { + x: 0, + y: 0, + k: 1 + }; + return zoom; + }; + zoom.y = function(z) { + if (!arguments.length) return y1; + y1 = z; + y0 = z.copy(); + view = { + x: 0, + y: 0, + k: 1 + }; + return zoom; + }; + function location(p) { + return [ (p[0] - view.x) / view.k, (p[1] - view.y) / view.k ]; + } + function point(l) { + return [ l[0] * view.k + view.x, l[1] * view.k + view.y ]; + } + function scaleTo(s) { + view.k = Math.max(scaleExtent[0], Math.min(scaleExtent[1], s)); + } + function translateTo(p, l) { + l = point(l); + view.x += p[0] - l[0]; + view.y += p[1] - l[1]; + } + function zoomTo(that, p, l, k) { + that.__chart__ = { + x: view.x, + y: view.y, + k: view.k + }; + scaleTo(Math.pow(2, k)); + translateTo(center0 = p, l); + that = d3.select(that); + if (duration > 0) that = that.transition().duration(duration); + that.call(zoom.event); + } + function rescale() { + if (x1) x1.domain(x0.range().map(function(x) { + return (x - view.x) / view.k; + }).map(x0.invert)); + if (y1) y1.domain(y0.range().map(function(y) { + return (y - view.y) / view.k; + }).map(y0.invert)); + } + function zoomstarted(dispatch) { + if (!zooming++) dispatch({ + type: "zoomstart" + }); + } + function zoomed(dispatch) { + rescale(); + dispatch({ + type: "zoom", + scale: view.k, + translate: [ view.x, view.y ] + }); + } + function zoomended(dispatch) { + if (!--zooming) dispatch({ + type: "zoomend" + }), center0 = null; + } + function mousedowned() { + var that = this, dispatch = event.of(that, arguments), dragged = 0, subject = d3.select(d3_window(that)).on(mousemove, moved).on(mouseup, ended), location0 = location(d3.mouse(that)), dragRestore = d3_event_dragSuppress(that); + d3_selection_interrupt.call(that); + zoomstarted(dispatch); + function moved() { + dragged = 1; + translateTo(d3.mouse(that), location0); + zoomed(dispatch); + } + function ended() { + subject.on(mousemove, null).on(mouseup, null); + dragRestore(dragged); + zoomended(dispatch); + } + } + function touchstarted() { + var that = this, dispatch = event.of(that, arguments), locations0 = {}, distance0 = 0, scale0, zoomName = ".zoom-" + d3.event.changedTouches[0].identifier, touchmove = "touchmove" + zoomName, touchend = "touchend" + zoomName, targets = [], subject = d3.select(that), dragRestore = d3_event_dragSuppress(that); + started(); + zoomstarted(dispatch); + subject.on(mousedown, null).on(touchstart, started); + function relocate() { + var touches = d3.touches(that); + scale0 = view.k; + touches.forEach(function(t) { + if (t.identifier in locations0) locations0[t.identifier] = location(t); + }); + return touches; + } + function started() { + var target = d3.event.target; + d3.select(target).on(touchmove, moved).on(touchend, ended); + targets.push(target); + var changed = d3.event.changedTouches; + for (var i = 0, n = changed.length; i < n; ++i) { + locations0[changed[i].identifier] = null; + } + var touches = relocate(), now = Date.now(); + if (touches.length === 1) { + if (now - touchtime < 500) { + var p = touches[0]; + zoomTo(that, p, locations0[p.identifier], Math.floor(Math.log(view.k) / Math.LN2) + 1); + d3_eventPreventDefault(); + } + touchtime = now; + } else if (touches.length > 1) { + var p = touches[0], q = touches[1], dx = p[0] - q[0], dy = p[1] - q[1]; + distance0 = dx * dx + dy * dy; + } + } + function moved() { + var touches = d3.touches(that), p0, l0, p1, l1; + d3_selection_interrupt.call(that); + for (var i = 0, n = touches.length; i < n; ++i, l1 = null) { + p1 = touches[i]; + if (l1 = locations0[p1.identifier]) { + if (l0) break; + p0 = p1, l0 = l1; + } + } + if (l1) { + var distance1 = (distance1 = p1[0] - p0[0]) * distance1 + (distance1 = p1[1] - p0[1]) * distance1, scale1 = distance0 && Math.sqrt(distance1 / distance0); + p0 = [ (p0[0] + p1[0]) / 2, (p0[1] + p1[1]) / 2 ]; + l0 = [ (l0[0] + l1[0]) / 2, (l0[1] + l1[1]) / 2 ]; + scaleTo(scale1 * scale0); + } + touchtime = null; + translateTo(p0, l0); + zoomed(dispatch); + } + function ended() { + if (d3.event.touches.length) { + var changed = d3.event.changedTouches; + for (var i = 0, n = changed.length; i < n; ++i) { + delete locations0[changed[i].identifier]; + } + for (var identifier in locations0) { + return void relocate(); + } + } + d3.selectAll(targets).on(zoomName, null); + subject.on(mousedown, mousedowned).on(touchstart, touchstarted); + dragRestore(); + zoomended(dispatch); + } + } + function mousewheeled() { + var dispatch = event.of(this, arguments); + if (mousewheelTimer) clearTimeout(mousewheelTimer); else d3_selection_interrupt.call(this), + translate0 = location(center0 = center || d3.mouse(this)), zoomstarted(dispatch); + mousewheelTimer = setTimeout(function() { + mousewheelTimer = null; + zoomended(dispatch); + }, 50); + d3_eventPreventDefault(); + scaleTo(Math.pow(2, d3_behavior_zoomDelta() * .002) * view.k); + translateTo(center0, translate0); + zoomed(dispatch); + } + function dblclicked() { + var p = d3.mouse(this), k = Math.log(view.k) / Math.LN2; + zoomTo(this, p, location(p), d3.event.shiftKey ? Math.ceil(k) - 1 : Math.floor(k) + 1); + } + return d3.rebind(zoom, event, "on"); + }; + var d3_behavior_zoomInfinity = [ 0, Infinity ], d3_behavior_zoomDelta, d3_behavior_zoomWheel; + d3.color = d3_color; + function d3_color() {} + d3_color.prototype.toString = function() { + return this.rgb() + ""; + }; + d3.hsl = d3_hsl; + function d3_hsl(h, s, l) { + return this instanceof d3_hsl ? void (this.h = +h, this.s = +s, this.l = +l) : arguments.length < 2 ? h instanceof d3_hsl ? new d3_hsl(h.h, h.s, h.l) : d3_rgb_parse("" + h, d3_rgb_hsl, d3_hsl) : new d3_hsl(h, s, l); + } + var d3_hslPrototype = d3_hsl.prototype = new d3_color(); + d3_hslPrototype.brighter = function(k) { + k = Math.pow(.7, arguments.length ? k : 1); + return new d3_hsl(this.h, this.s, this.l / k); + }; + d3_hslPrototype.darker = function(k) { + k = Math.pow(.7, arguments.length ? k : 1); + return new d3_hsl(this.h, this.s, k * this.l); + }; + d3_hslPrototype.rgb = function() { + return d3_hsl_rgb(this.h, this.s, this.l); + }; + function d3_hsl_rgb(h, s, l) { + var m1, m2; + h = isNaN(h) ? 0 : (h %= 360) < 0 ? h + 360 : h; + s = isNaN(s) ? 0 : s < 0 ? 0 : s > 1 ? 1 : s; + l = l < 0 ? 0 : l > 1 ? 1 : l; + m2 = l <= .5 ? l * (1 + s) : l + s - l * s; + m1 = 2 * l - m2; + function v(h) { + if (h > 360) h -= 360; else if (h < 0) h += 360; + if (h < 60) return m1 + (m2 - m1) * h / 60; + if (h < 180) return m2; + if (h < 240) return m1 + (m2 - m1) * (240 - h) / 60; + return m1; + } + function vv(h) { + return Math.round(v(h) * 255); + } + return new d3_rgb(vv(h + 120), vv(h), vv(h - 120)); + } + d3.hcl = d3_hcl; + function d3_hcl(h, c, l) { + return this instanceof d3_hcl ? void (this.h = +h, this.c = +c, this.l = +l) : arguments.length < 2 ? h instanceof d3_hcl ? new d3_hcl(h.h, h.c, h.l) : h instanceof d3_lab ? d3_lab_hcl(h.l, h.a, h.b) : d3_lab_hcl((h = d3_rgb_lab((h = d3.rgb(h)).r, h.g, h.b)).l, h.a, h.b) : new d3_hcl(h, c, l); + } + var d3_hclPrototype = d3_hcl.prototype = new d3_color(); + d3_hclPrototype.brighter = function(k) { + return new d3_hcl(this.h, this.c, Math.min(100, this.l + d3_lab_K * (arguments.length ? k : 1))); + }; + d3_hclPrototype.darker = function(k) { + return new d3_hcl(this.h, this.c, Math.max(0, this.l - d3_lab_K * (arguments.length ? k : 1))); + }; + d3_hclPrototype.rgb = function() { + return d3_hcl_lab(this.h, this.c, this.l).rgb(); + }; + function d3_hcl_lab(h, c, l) { + if (isNaN(h)) h = 0; + if (isNaN(c)) c = 0; + return new d3_lab(l, Math.cos(h *= d3_radians) * c, Math.sin(h) * c); + } + d3.lab = d3_lab; + function d3_lab(l, a, b) { + return this instanceof d3_lab ? void (this.l = +l, this.a = +a, this.b = +b) : arguments.length < 2 ? l instanceof d3_lab ? new d3_lab(l.l, l.a, l.b) : l instanceof d3_hcl ? d3_hcl_lab(l.h, l.c, l.l) : d3_rgb_lab((l = d3_rgb(l)).r, l.g, l.b) : new d3_lab(l, a, b); + } + var d3_lab_K = 18; + var d3_lab_X = .95047, d3_lab_Y = 1, d3_lab_Z = 1.08883; + var d3_labPrototype = d3_lab.prototype = new d3_color(); + d3_labPrototype.brighter = function(k) { + return new d3_lab(Math.min(100, this.l + d3_lab_K * (arguments.length ? k : 1)), this.a, this.b); + }; + d3_labPrototype.darker = function(k) { + return new d3_lab(Math.max(0, this.l - d3_lab_K * (arguments.length ? k : 1)), this.a, this.b); + }; + d3_labPrototype.rgb = function() { + return d3_lab_rgb(this.l, this.a, this.b); + }; + function d3_lab_rgb(l, a, b) { + var y = (l + 16) / 116, x = y + a / 500, z = y - b / 200; + x = d3_lab_xyz(x) * d3_lab_X; + y = d3_lab_xyz(y) * d3_lab_Y; + z = d3_lab_xyz(z) * d3_lab_Z; + return new d3_rgb(d3_xyz_rgb(3.2404542 * x - 1.5371385 * y - .4985314 * z), d3_xyz_rgb(-.969266 * x + 1.8760108 * y + .041556 * z), d3_xyz_rgb(.0556434 * x - .2040259 * y + 1.0572252 * z)); + } + function d3_lab_hcl(l, a, b) { + return l > 0 ? new d3_hcl(Math.atan2(b, a) * d3_degrees, Math.sqrt(a * a + b * b), l) : new d3_hcl(NaN, NaN, l); + } + function d3_lab_xyz(x) { + return x > .206893034 ? x * x * x : (x - 4 / 29) / 7.787037; + } + function d3_xyz_lab(x) { + return x > .008856 ? Math.pow(x, 1 / 3) : 7.787037 * x + 4 / 29; + } + function d3_xyz_rgb(r) { + return Math.round(255 * (r <= .00304 ? 12.92 * r : 1.055 * Math.pow(r, 1 / 2.4) - .055)); + } + d3.rgb = d3_rgb; + function d3_rgb(r, g, b) { + return this instanceof d3_rgb ? void (this.r = ~~r, this.g = ~~g, this.b = ~~b) : arguments.length < 2 ? r instanceof d3_rgb ? new d3_rgb(r.r, r.g, r.b) : d3_rgb_parse("" + r, d3_rgb, d3_hsl_rgb) : new d3_rgb(r, g, b); + } + function d3_rgbNumber(value) { + return new d3_rgb(value >> 16, value >> 8 & 255, value & 255); + } + function d3_rgbString(value) { + return d3_rgbNumber(value) + ""; + } + var d3_rgbPrototype = d3_rgb.prototype = new d3_color(); + d3_rgbPrototype.brighter = function(k) { + k = Math.pow(.7, arguments.length ? k : 1); + var r = this.r, g = this.g, b = this.b, i = 30; + if (!r && !g && !b) return new d3_rgb(i, i, i); + if (r && r < i) r = i; + if (g && g < i) g = i; + if (b && b < i) b = i; + return new d3_rgb(Math.min(255, r / k), Math.min(255, g / k), Math.min(255, b / k)); + }; + d3_rgbPrototype.darker = function(k) { + k = Math.pow(.7, arguments.length ? k : 1); + return new d3_rgb(k * this.r, k * this.g, k * this.b); + }; + d3_rgbPrototype.hsl = function() { + return d3_rgb_hsl(this.r, this.g, this.b); + }; + d3_rgbPrototype.toString = function() { + return "#" + d3_rgb_hex(this.r) + d3_rgb_hex(this.g) + d3_rgb_hex(this.b); + }; + function d3_rgb_hex(v) { + return v < 16 ? "0" + Math.max(0, v).toString(16) : Math.min(255, v).toString(16); + } + function d3_rgb_parse(format, rgb, hsl) { + var r = 0, g = 0, b = 0, m1, m2, color; + m1 = /([a-z]+)\((.*)\)/.exec(format = format.toLowerCase()); + if (m1) { + m2 = m1[2].split(","); + switch (m1[1]) { + case "hsl": + { + return hsl(parseFloat(m2[0]), parseFloat(m2[1]) / 100, parseFloat(m2[2]) / 100); + } + + case "rgb": + { + return rgb(d3_rgb_parseNumber(m2[0]), d3_rgb_parseNumber(m2[1]), d3_rgb_parseNumber(m2[2])); + } + } + } + if (color = d3_rgb_names.get(format)) { + return rgb(color.r, color.g, color.b); + } + if (format != null && format.charAt(0) === "#" && !isNaN(color = parseInt(format.slice(1), 16))) { + if (format.length === 4) { + r = (color & 3840) >> 4; + r = r >> 4 | r; + g = color & 240; + g = g >> 4 | g; + b = color & 15; + b = b << 4 | b; + } else if (format.length === 7) { + r = (color & 16711680) >> 16; + g = (color & 65280) >> 8; + b = color & 255; + } + } + return rgb(r, g, b); + } + function d3_rgb_hsl(r, g, b) { + var min = Math.min(r /= 255, g /= 255, b /= 255), max = Math.max(r, g, b), d = max - min, h, s, l = (max + min) / 2; + if (d) { + s = l < .5 ? d / (max + min) : d / (2 - max - min); + if (r == max) h = (g - b) / d + (g < b ? 6 : 0); else if (g == max) h = (b - r) / d + 2; else h = (r - g) / d + 4; + h *= 60; + } else { + h = NaN; + s = l > 0 && l < 1 ? 0 : h; + } + return new d3_hsl(h, s, l); + } + function d3_rgb_lab(r, g, b) { + r = d3_rgb_xyz(r); + g = d3_rgb_xyz(g); + b = d3_rgb_xyz(b); + var x = d3_xyz_lab((.4124564 * r + .3575761 * g + .1804375 * b) / d3_lab_X), y = d3_xyz_lab((.2126729 * r + .7151522 * g + .072175 * b) / d3_lab_Y), z = d3_xyz_lab((.0193339 * r + .119192 * g + .9503041 * b) / d3_lab_Z); + return d3_lab(116 * y - 16, 500 * (x - y), 200 * (y - z)); + } + function d3_rgb_xyz(r) { + return (r /= 255) <= .04045 ? r / 12.92 : Math.pow((r + .055) / 1.055, 2.4); + } + function d3_rgb_parseNumber(c) { + var f = parseFloat(c); + return c.charAt(c.length - 1) === "%" ? Math.round(f * 2.55) : f; + } + var d3_rgb_names = d3.map({ + aliceblue: 15792383, + antiquewhite: 16444375, + aqua: 65535, + aquamarine: 8388564, + azure: 15794175, + beige: 16119260, + bisque: 16770244, + black: 0, + blanchedalmond: 16772045, + blue: 255, + blueviolet: 9055202, + brown: 10824234, + burlywood: 14596231, + cadetblue: 6266528, + chartreuse: 8388352, + chocolate: 13789470, + coral: 16744272, + cornflowerblue: 6591981, + cornsilk: 16775388, + crimson: 14423100, + cyan: 65535, + darkblue: 139, + darkcyan: 35723, + darkgoldenrod: 12092939, + darkgray: 11119017, + darkgreen: 25600, + darkgrey: 11119017, + darkkhaki: 12433259, + darkmagenta: 9109643, + darkolivegreen: 5597999, + darkorange: 16747520, + darkorchid: 10040012, + darkred: 9109504, + darksalmon: 15308410, + darkseagreen: 9419919, + darkslateblue: 4734347, + darkslategray: 3100495, + darkslategrey: 3100495, + darkturquoise: 52945, + darkviolet: 9699539, + deeppink: 16716947, + deepskyblue: 49151, + dimgray: 6908265, + dimgrey: 6908265, + dodgerblue: 2003199, + firebrick: 11674146, + floralwhite: 16775920, + forestgreen: 2263842, + fuchsia: 16711935, + gainsboro: 14474460, + ghostwhite: 16316671, + gold: 16766720, + goldenrod: 14329120, + gray: 8421504, + green: 32768, + greenyellow: 11403055, + grey: 8421504, + honeydew: 15794160, + hotpink: 16738740, + indianred: 13458524, + indigo: 4915330, + ivory: 16777200, + khaki: 15787660, + lavender: 15132410, + lavenderblush: 16773365, + lawngreen: 8190976, + lemonchiffon: 16775885, + lightblue: 11393254, + lightcoral: 15761536, + lightcyan: 14745599, + lightgoldenrodyellow: 16448210, + lightgray: 13882323, + lightgreen: 9498256, + lightgrey: 13882323, + lightpink: 16758465, + lightsalmon: 16752762, + lightseagreen: 2142890, + lightskyblue: 8900346, + lightslategray: 7833753, + lightslategrey: 7833753, + lightsteelblue: 11584734, + lightyellow: 16777184, + lime: 65280, + limegreen: 3329330, + linen: 16445670, + magenta: 16711935, + maroon: 8388608, + mediumaquamarine: 6737322, + mediumblue: 205, + mediumorchid: 12211667, + mediumpurple: 9662683, + mediumseagreen: 3978097, + mediumslateblue: 8087790, + mediumspringgreen: 64154, + mediumturquoise: 4772300, + mediumvioletred: 13047173, + midnightblue: 1644912, + mintcream: 16121850, + mistyrose: 16770273, + moccasin: 16770229, + navajowhite: 16768685, + navy: 128, + oldlace: 16643558, + olive: 8421376, + olivedrab: 7048739, + orange: 16753920, + orangered: 16729344, + orchid: 14315734, + palegoldenrod: 15657130, + palegreen: 10025880, + paleturquoise: 11529966, + palevioletred: 14381203, + papayawhip: 16773077, + peachpuff: 16767673, + peru: 13468991, + pink: 16761035, + plum: 14524637, + powderblue: 11591910, + purple: 8388736, + rebeccapurple: 6697881, + red: 16711680, + rosybrown: 12357519, + royalblue: 4286945, + saddlebrown: 9127187, + salmon: 16416882, + sandybrown: 16032864, + seagreen: 3050327, + seashell: 16774638, + sienna: 10506797, + silver: 12632256, + skyblue: 8900331, + slateblue: 6970061, + slategray: 7372944, + slategrey: 7372944, + snow: 16775930, + springgreen: 65407, + steelblue: 4620980, + tan: 13808780, + teal: 32896, + thistle: 14204888, + tomato: 16737095, + turquoise: 4251856, + violet: 15631086, + wheat: 16113331, + white: 16777215, + whitesmoke: 16119285, + yellow: 16776960, + yellowgreen: 10145074 + }); + d3_rgb_names.forEach(function(key, value) { + d3_rgb_names.set(key, d3_rgbNumber(value)); + }); + function d3_functor(v) { + return typeof v === "function" ? v : function() { + return v; + }; + } + d3.functor = d3_functor; + d3.xhr = d3_xhrType(d3_identity); + function d3_xhrType(response) { + return function(url, mimeType, callback) { + if (arguments.length === 2 && typeof mimeType === "function") callback = mimeType, + mimeType = null; + return d3_xhr(url, mimeType, response, callback); + }; + } + function d3_xhr(url, mimeType, response, callback) { + var xhr = {}, dispatch = d3.dispatch("beforesend", "progress", "load", "error"), headers = {}, request = new XMLHttpRequest(), responseType = null; + if (this.XDomainRequest && !("withCredentials" in request) && /^(http(s)?:)?\/\//.test(url)) request = new XDomainRequest(); + "onload" in request ? request.onload = request.onerror = respond : request.onreadystatechange = function() { + request.readyState > 3 && respond(); + }; + function respond() { + var status = request.status, result; + if (!status && d3_xhrHasResponse(request) || status >= 200 && status < 300 || status === 304) { + try { + result = response.call(xhr, request); + } catch (e) { + dispatch.error.call(xhr, e); + return; + } + dispatch.load.call(xhr, result); + } else { + dispatch.error.call(xhr, request); + } + } + request.onprogress = function(event) { + var o = d3.event; + d3.event = event; + try { + dispatch.progress.call(xhr, request); + } finally { + d3.event = o; + } + }; + xhr.header = function(name, value) { + name = (name + "").toLowerCase(); + if (arguments.length < 2) return headers[name]; + if (value == null) delete headers[name]; else headers[name] = value + ""; + return xhr; + }; + xhr.mimeType = function(value) { + if (!arguments.length) return mimeType; + mimeType = value == null ? null : value + ""; + return xhr; + }; + xhr.responseType = function(value) { + if (!arguments.length) return responseType; + responseType = value; + return xhr; + }; + xhr.response = function(value) { + response = value; + return xhr; + }; + [ "get", "post" ].forEach(function(method) { + xhr[method] = function() { + return xhr.send.apply(xhr, [ method ].concat(d3_array(arguments))); + }; + }); + xhr.send = function(method, data, callback) { + if (arguments.length === 2 && typeof data === "function") callback = data, data = null; + request.open(method, url, true); + if (mimeType != null && !("accept" in headers)) headers["accept"] = mimeType + ",*/*"; + if (request.setRequestHeader) for (var name in headers) request.setRequestHeader(name, headers[name]); + if (mimeType != null && request.overrideMimeType) request.overrideMimeType(mimeType); + if (responseType != null) request.responseType = responseType; + if (callback != null) xhr.on("error", callback).on("load", function(request) { + callback(null, request); + }); + dispatch.beforesend.call(xhr, request); + request.send(data == null ? null : data); + return xhr; + }; + xhr.abort = function() { + request.abort(); + return xhr; + }; + d3.rebind(xhr, dispatch, "on"); + return callback == null ? xhr : xhr.get(d3_xhr_fixCallback(callback)); + } + function d3_xhr_fixCallback(callback) { + return callback.length === 1 ? function(error, request) { + callback(error == null ? request : null); + } : callback; + } + function d3_xhrHasResponse(request) { + var type = request.responseType; + return type && type !== "text" ? request.response : request.responseText; + } + d3.dsv = function(delimiter, mimeType) { + var reFormat = new RegExp('["' + delimiter + "\n]"), delimiterCode = delimiter.charCodeAt(0); + function dsv(url, row, callback) { + if (arguments.length < 3) callback = row, row = null; + var xhr = d3_xhr(url, mimeType, row == null ? response : typedResponse(row), callback); + xhr.row = function(_) { + return arguments.length ? xhr.response((row = _) == null ? response : typedResponse(_)) : row; + }; + return xhr; + } + function response(request) { + return dsv.parse(request.responseText); + } + function typedResponse(f) { + return function(request) { + return dsv.parse(request.responseText, f); + }; + } + dsv.parse = function(text, f) { + var o; + return dsv.parseRows(text, function(row, i) { + if (o) return o(row, i - 1); + var a = new Function("d", "return {" + row.map(function(name, i) { + return JSON.stringify(name) + ": d[" + i + "]"; + }).join(",") + "}"); + o = f ? function(row, i) { + return f(a(row), i); + } : a; + }); + }; + dsv.parseRows = function(text, f) { + var EOL = {}, EOF = {}, rows = [], N = text.length, I = 0, n = 0, t, eol; + function token() { + if (I >= N) return EOF; + if (eol) return eol = false, EOL; + var j = I; + if (text.charCodeAt(j) === 34) { + var i = j; + while (i++ < N) { + if (text.charCodeAt(i) === 34) { + if (text.charCodeAt(i + 1) !== 34) break; + ++i; + } + } + I = i + 2; + var c = text.charCodeAt(i + 1); + if (c === 13) { + eol = true; + if (text.charCodeAt(i + 2) === 10) ++I; + } else if (c === 10) { + eol = true; + } + return text.slice(j + 1, i).replace(/""/g, '"'); + } + while (I < N) { + var c = text.charCodeAt(I++), k = 1; + if (c === 10) eol = true; else if (c === 13) { + eol = true; + if (text.charCodeAt(I) === 10) ++I, ++k; + } else if (c !== delimiterCode) continue; + return text.slice(j, I - k); + } + return text.slice(j); + } + while ((t = token()) !== EOF) { + var a = []; + while (t !== EOL && t !== EOF) { + a.push(t); + t = token(); + } + if (f && (a = f(a, n++)) == null) continue; + rows.push(a); + } + return rows; + }; + dsv.format = function(rows) { + if (Array.isArray(rows[0])) return dsv.formatRows(rows); + var fieldSet = new d3_Set(), fields = []; + rows.forEach(function(row) { + for (var field in row) { + if (!fieldSet.has(field)) { + fields.push(fieldSet.add(field)); + } + } + }); + return [ fields.map(formatValue).join(delimiter) ].concat(rows.map(function(row) { + return fields.map(function(field) { + return formatValue(row[field]); + }).join(delimiter); + })).join("\n"); + }; + dsv.formatRows = function(rows) { + return rows.map(formatRow).join("\n"); + }; + function formatRow(row) { + return row.map(formatValue).join(delimiter); + } + function formatValue(text) { + return reFormat.test(text) ? '"' + text.replace(/\"/g, '""') + '"' : text; + } + return dsv; + }; + d3.csv = d3.dsv(",", "text/csv"); + d3.tsv = d3.dsv(" ", "text/tab-separated-values"); + var d3_timer_queueHead, d3_timer_queueTail, d3_timer_interval, d3_timer_timeout, d3_timer_frame = this[d3_vendorSymbol(this, "requestAnimationFrame")] || function(callback) { + setTimeout(callback, 17); + }; + d3.timer = function() { + d3_timer.apply(this, arguments); + }; + function d3_timer(callback, delay, then) { + var n = arguments.length; + if (n < 2) delay = 0; + if (n < 3) then = Date.now(); + var time = then + delay, timer = { + c: callback, + t: time, + n: null + }; + if (d3_timer_queueTail) d3_timer_queueTail.n = timer; else d3_timer_queueHead = timer; + d3_timer_queueTail = timer; + if (!d3_timer_interval) { + d3_timer_timeout = clearTimeout(d3_timer_timeout); + d3_timer_interval = 1; + d3_timer_frame(d3_timer_step); + } + return timer; + } + function d3_timer_step() { + var now = d3_timer_mark(), delay = d3_timer_sweep() - now; + if (delay > 24) { + if (isFinite(delay)) { + clearTimeout(d3_timer_timeout); + d3_timer_timeout = setTimeout(d3_timer_step, delay); + } + d3_timer_interval = 0; + } else { + d3_timer_interval = 1; + d3_timer_frame(d3_timer_step); + } + } + d3.timer.flush = function() { + d3_timer_mark(); + d3_timer_sweep(); + }; + function d3_timer_mark() { + var now = Date.now(), timer = d3_timer_queueHead; + while (timer) { + if (now >= timer.t && timer.c(now - timer.t)) timer.c = null; + timer = timer.n; + } + return now; + } + function d3_timer_sweep() { + var t0, t1 = d3_timer_queueHead, time = Infinity; + while (t1) { + if (t1.c) { + if (t1.t < time) time = t1.t; + t1 = (t0 = t1).n; + } else { + t1 = t0 ? t0.n = t1.n : d3_timer_queueHead = t1.n; + } + } + d3_timer_queueTail = t0; + return time; + } + function d3_format_precision(x, p) { + return p - (x ? Math.ceil(Math.log(x) / Math.LN10) : 1); + } + d3.round = function(x, n) { + return n ? Math.round(x * (n = Math.pow(10, n))) / n : Math.round(x); + }; + var d3_formatPrefixes = [ "y", "z", "a", "f", "p", "n", "µ", "m", "", "k", "M", "G", "T", "P", "E", "Z", "Y" ].map(d3_formatPrefix); + d3.formatPrefix = function(value, precision) { + var i = 0; + if (value = +value) { + if (value < 0) value *= -1; + if (precision) value = d3.round(value, d3_format_precision(value, precision)); + i = 1 + Math.floor(1e-12 + Math.log(value) / Math.LN10); + i = Math.max(-24, Math.min(24, Math.floor((i - 1) / 3) * 3)); + } + return d3_formatPrefixes[8 + i / 3]; + }; + function d3_formatPrefix(d, i) { + var k = Math.pow(10, abs(8 - i) * 3); + return { + scale: i > 8 ? function(d) { + return d / k; + } : function(d) { + return d * k; + }, + symbol: d + }; + } + function d3_locale_numberFormat(locale) { + var locale_decimal = locale.decimal, locale_thousands = locale.thousands, locale_grouping = locale.grouping, locale_currency = locale.currency, formatGroup = locale_grouping && locale_thousands ? function(value, width) { + var i = value.length, t = [], j = 0, g = locale_grouping[0], length = 0; + while (i > 0 && g > 0) { + if (length + g + 1 > width) g = Math.max(1, width - length); + t.push(value.substring(i -= g, i + g)); + if ((length += g + 1) > width) break; + g = locale_grouping[j = (j + 1) % locale_grouping.length]; + } + return t.reverse().join(locale_thousands); + } : d3_identity; + return function(specifier) { + var match = d3_format_re.exec(specifier), fill = match[1] || " ", align = match[2] || ">", sign = match[3] || "-", symbol = match[4] || "", zfill = match[5], width = +match[6], comma = match[7], precision = match[8], type = match[9], scale = 1, prefix = "", suffix = "", integer = false, exponent = true; + if (precision) precision = +precision.substring(1); + if (zfill || fill === "0" && align === "=") { + zfill = fill = "0"; + align = "="; + } + switch (type) { + case "n": + comma = true; + type = "g"; + break; + + case "%": + scale = 100; + suffix = "%"; + type = "f"; + break; + + case "p": + scale = 100; + suffix = "%"; + type = "r"; + break; + + case "b": + case "o": + case "x": + case "X": + if (symbol === "#") prefix = "0" + type.toLowerCase(); + + case "c": + exponent = false; + + case "d": + integer = true; + precision = 0; + break; + + case "s": + scale = -1; + type = "r"; + break; + } + if (symbol === "$") prefix = locale_currency[0], suffix = locale_currency[1]; + if (type == "r" && !precision) type = "g"; + if (precision != null) { + if (type == "g") precision = Math.max(1, Math.min(21, precision)); else if (type == "e" || type == "f") precision = Math.max(0, Math.min(20, precision)); + } + type = d3_format_types.get(type) || d3_format_typeDefault; + var zcomma = zfill && comma; + return function(value) { + var fullSuffix = suffix; + if (integer && value % 1) return ""; + var negative = value < 0 || value === 0 && 1 / value < 0 ? (value = -value, "-") : sign === "-" ? "" : sign; + if (scale < 0) { + var unit = d3.formatPrefix(value, precision); + value = unit.scale(value); + fullSuffix = unit.symbol + suffix; + } else { + value *= scale; + } + value = type(value, precision); + var i = value.lastIndexOf("."), before, after; + if (i < 0) { + var j = exponent ? value.lastIndexOf("e") : -1; + if (j < 0) before = value, after = ""; else before = value.substring(0, j), after = value.substring(j); + } else { + before = value.substring(0, i); + after = locale_decimal + value.substring(i + 1); + } + if (!zfill && comma) before = formatGroup(before, Infinity); + var length = prefix.length + before.length + after.length + (zcomma ? 0 : negative.length), padding = length < width ? new Array(length = width - length + 1).join(fill) : ""; + if (zcomma) before = formatGroup(padding + before, padding.length ? width - after.length : Infinity); + negative += prefix; + value = before + after; + return (align === "<" ? negative + value + padding : align === ">" ? padding + negative + value : align === "^" ? padding.substring(0, length >>= 1) + negative + value + padding.substring(length) : negative + (zcomma ? value : padding + value)) + fullSuffix; + }; + }; + } + var d3_format_re = /(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i; + var d3_format_types = d3.map({ + b: function(x) { + return x.toString(2); + }, + c: function(x) { + return String.fromCharCode(x); + }, + o: function(x) { + return x.toString(8); + }, + x: function(x) { + return x.toString(16); + }, + X: function(x) { + return x.toString(16).toUpperCase(); + }, + g: function(x, p) { + return x.toPrecision(p); + }, + e: function(x, p) { + return x.toExponential(p); + }, + f: function(x, p) { + return x.toFixed(p); + }, + r: function(x, p) { + return (x = d3.round(x, d3_format_precision(x, p))).toFixed(Math.max(0, Math.min(20, d3_format_precision(x * (1 + 1e-15), p)))); + } + }); + function d3_format_typeDefault(x) { + return x + ""; + } + var d3_time = d3.time = {}, d3_date = Date; + function d3_date_utc() { + this._ = new Date(arguments.length > 1 ? Date.UTC.apply(this, arguments) : arguments[0]); + } + d3_date_utc.prototype = { + getDate: function() { + return this._.getUTCDate(); + }, + getDay: function() { + return this._.getUTCDay(); + }, + getFullYear: function() { + return this._.getUTCFullYear(); + }, + getHours: function() { + return this._.getUTCHours(); + }, + getMilliseconds: function() { + return this._.getUTCMilliseconds(); + }, + getMinutes: function() { + return this._.getUTCMinutes(); + }, + getMonth: function() { + return this._.getUTCMonth(); + }, + getSeconds: function() { + return this._.getUTCSeconds(); + }, + getTime: function() { + return this._.getTime(); + }, + getTimezoneOffset: function() { + return 0; + }, + valueOf: function() { + return this._.valueOf(); + }, + setDate: function() { + d3_time_prototype.setUTCDate.apply(this._, arguments); + }, + setDay: function() { + d3_time_prototype.setUTCDay.apply(this._, arguments); + }, + setFullYear: function() { + d3_time_prototype.setUTCFullYear.apply(this._, arguments); + }, + setHours: function() { + d3_time_prototype.setUTCHours.apply(this._, arguments); + }, + setMilliseconds: function() { + d3_time_prototype.setUTCMilliseconds.apply(this._, arguments); + }, + setMinutes: function() { + d3_time_prototype.setUTCMinutes.apply(this._, arguments); + }, + setMonth: function() { + d3_time_prototype.setUTCMonth.apply(this._, arguments); + }, + setSeconds: function() { + d3_time_prototype.setUTCSeconds.apply(this._, arguments); + }, + setTime: function() { + d3_time_prototype.setTime.apply(this._, arguments); + } + }; + var d3_time_prototype = Date.prototype; + function d3_time_interval(local, step, number) { + function round(date) { + var d0 = local(date), d1 = offset(d0, 1); + return date - d0 < d1 - date ? d0 : d1; + } + function ceil(date) { + step(date = local(new d3_date(date - 1)), 1); + return date; + } + function offset(date, k) { + step(date = new d3_date(+date), k); + return date; + } + function range(t0, t1, dt) { + var time = ceil(t0), times = []; + if (dt > 1) { + while (time < t1) { + if (!(number(time) % dt)) times.push(new Date(+time)); + step(time, 1); + } + } else { + while (time < t1) times.push(new Date(+time)), step(time, 1); + } + return times; + } + function range_utc(t0, t1, dt) { + try { + d3_date = d3_date_utc; + var utc = new d3_date_utc(); + utc._ = t0; + return range(utc, t1, dt); + } finally { + d3_date = Date; + } + } + local.floor = local; + local.round = round; + local.ceil = ceil; + local.offset = offset; + local.range = range; + var utc = local.utc = d3_time_interval_utc(local); + utc.floor = utc; + utc.round = d3_time_interval_utc(round); + utc.ceil = d3_time_interval_utc(ceil); + utc.offset = d3_time_interval_utc(offset); + utc.range = range_utc; + return local; + } + function d3_time_interval_utc(method) { + return function(date, k) { + try { + d3_date = d3_date_utc; + var utc = new d3_date_utc(); + utc._ = date; + return method(utc, k)._; + } finally { + d3_date = Date; + } + }; + } + d3_time.year = d3_time_interval(function(date) { + date = d3_time.day(date); + date.setMonth(0, 1); + return date; + }, function(date, offset) { + date.setFullYear(date.getFullYear() + offset); + }, function(date) { + return date.getFullYear(); + }); + d3_time.years = d3_time.year.range; + d3_time.years.utc = d3_time.year.utc.range; + d3_time.day = d3_time_interval(function(date) { + var day = new d3_date(2e3, 0); + day.setFullYear(date.getFullYear(), date.getMonth(), date.getDate()); + return day; + }, function(date, offset) { + date.setDate(date.getDate() + offset); + }, function(date) { + return date.getDate() - 1; + }); + d3_time.days = d3_time.day.range; + d3_time.days.utc = d3_time.day.utc.range; + d3_time.dayOfYear = function(date) { + var year = d3_time.year(date); + return Math.floor((date - year - (date.getTimezoneOffset() - year.getTimezoneOffset()) * 6e4) / 864e5); + }; + [ "sunday", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday" ].forEach(function(day, i) { + i = 7 - i; + var interval = d3_time[day] = d3_time_interval(function(date) { + (date = d3_time.day(date)).setDate(date.getDate() - (date.getDay() + i) % 7); + return date; + }, function(date, offset) { + date.setDate(date.getDate() + Math.floor(offset) * 7); + }, function(date) { + var day = d3_time.year(date).getDay(); + return Math.floor((d3_time.dayOfYear(date) + (day + i) % 7) / 7) - (day !== i); + }); + d3_time[day + "s"] = interval.range; + d3_time[day + "s"].utc = interval.utc.range; + d3_time[day + "OfYear"] = function(date) { + var day = d3_time.year(date).getDay(); + return Math.floor((d3_time.dayOfYear(date) + (day + i) % 7) / 7); + }; + }); + d3_time.week = d3_time.sunday; + d3_time.weeks = d3_time.sunday.range; + d3_time.weeks.utc = d3_time.sunday.utc.range; + d3_time.weekOfYear = d3_time.sundayOfYear; + function d3_locale_timeFormat(locale) { + var locale_dateTime = locale.dateTime, locale_date = locale.date, locale_time = locale.time, locale_periods = locale.periods, locale_days = locale.days, locale_shortDays = locale.shortDays, locale_months = locale.months, locale_shortMonths = locale.shortMonths; + function d3_time_format(template) { + var n = template.length; + function format(date) { + var string = [], i = -1, j = 0, c, p, f; + while (++i < n) { + if (template.charCodeAt(i) === 37) { + string.push(template.slice(j, i)); + if ((p = d3_time_formatPads[c = template.charAt(++i)]) != null) c = template.charAt(++i); + if (f = d3_time_formats[c]) c = f(date, p == null ? c === "e" ? " " : "0" : p); + string.push(c); + j = i + 1; + } + } + string.push(template.slice(j, i)); + return string.join(""); + } + format.parse = function(string) { + var d = { + y: 1900, + m: 0, + d: 1, + H: 0, + M: 0, + S: 0, + L: 0, + Z: null + }, i = d3_time_parse(d, template, string, 0); + if (i != string.length) return null; + if ("p" in d) d.H = d.H % 12 + d.p * 12; + var localZ = d.Z != null && d3_date !== d3_date_utc, date = new (localZ ? d3_date_utc : d3_date)(); + if ("j" in d) date.setFullYear(d.y, 0, d.j); else if ("W" in d || "U" in d) { + if (!("w" in d)) d.w = "W" in d ? 1 : 0; + date.setFullYear(d.y, 0, 1); + date.setFullYear(d.y, 0, "W" in d ? (d.w + 6) % 7 + d.W * 7 - (date.getDay() + 5) % 7 : d.w + d.U * 7 - (date.getDay() + 6) % 7); + } else date.setFullYear(d.y, d.m, d.d); + date.setHours(d.H + (d.Z / 100 | 0), d.M + d.Z % 100, d.S, d.L); + return localZ ? date._ : date; + }; + format.toString = function() { + return template; + }; + return format; + } + function d3_time_parse(date, template, string, j) { + var c, p, t, i = 0, n = template.length, m = string.length; + while (i < n) { + if (j >= m) return -1; + c = template.charCodeAt(i++); + if (c === 37) { + t = template.charAt(i++); + p = d3_time_parsers[t in d3_time_formatPads ? template.charAt(i++) : t]; + if (!p || (j = p(date, string, j)) < 0) return -1; + } else if (c != string.charCodeAt(j++)) { + return -1; + } + } + return j; + } + d3_time_format.utc = function(template) { + var local = d3_time_format(template); + function format(date) { + try { + d3_date = d3_date_utc; + var utc = new d3_date(); + utc._ = date; + return local(utc); + } finally { + d3_date = Date; + } + } + format.parse = function(string) { + try { + d3_date = d3_date_utc; + var date = local.parse(string); + return date && date._; + } finally { + d3_date = Date; + } + }; + format.toString = local.toString; + return format; + }; + d3_time_format.multi = d3_time_format.utc.multi = d3_time_formatMulti; + var d3_time_periodLookup = d3.map(), d3_time_dayRe = d3_time_formatRe(locale_days), d3_time_dayLookup = d3_time_formatLookup(locale_days), d3_time_dayAbbrevRe = d3_time_formatRe(locale_shortDays), d3_time_dayAbbrevLookup = d3_time_formatLookup(locale_shortDays), d3_time_monthRe = d3_time_formatRe(locale_months), d3_time_monthLookup = d3_time_formatLookup(locale_months), d3_time_monthAbbrevRe = d3_time_formatRe(locale_shortMonths), d3_time_monthAbbrevLookup = d3_time_formatLookup(locale_shortMonths); + locale_periods.forEach(function(p, i) { + d3_time_periodLookup.set(p.toLowerCase(), i); + }); + var d3_time_formats = { + a: function(d) { + return locale_shortDays[d.getDay()]; + }, + A: function(d) { + return locale_days[d.getDay()]; + }, + b: function(d) { + return locale_shortMonths[d.getMonth()]; + }, + B: function(d) { + return locale_months[d.getMonth()]; + }, + c: d3_time_format(locale_dateTime), + d: function(d, p) { + return d3_time_formatPad(d.getDate(), p, 2); + }, + e: function(d, p) { + return d3_time_formatPad(d.getDate(), p, 2); + }, + H: function(d, p) { + return d3_time_formatPad(d.getHours(), p, 2); + }, + I: function(d, p) { + return d3_time_formatPad(d.getHours() % 12 || 12, p, 2); + }, + j: function(d, p) { + return d3_time_formatPad(1 + d3_time.dayOfYear(d), p, 3); + }, + L: function(d, p) { + return d3_time_formatPad(d.getMilliseconds(), p, 3); + }, + m: function(d, p) { + return d3_time_formatPad(d.getMonth() + 1, p, 2); + }, + M: function(d, p) { + return d3_time_formatPad(d.getMinutes(), p, 2); + }, + p: function(d) { + return locale_periods[+(d.getHours() >= 12)]; + }, + S: function(d, p) { + return d3_time_formatPad(d.getSeconds(), p, 2); + }, + U: function(d, p) { + return d3_time_formatPad(d3_time.sundayOfYear(d), p, 2); + }, + w: function(d) { + return d.getDay(); + }, + W: function(d, p) { + return d3_time_formatPad(d3_time.mondayOfYear(d), p, 2); + }, + x: d3_time_format(locale_date), + X: d3_time_format(locale_time), + y: function(d, p) { + return d3_time_formatPad(d.getFullYear() % 100, p, 2); + }, + Y: function(d, p) { + return d3_time_formatPad(d.getFullYear() % 1e4, p, 4); + }, + Z: d3_time_zone, + "%": function() { + return "%"; + } + }; + var d3_time_parsers = { + a: d3_time_parseWeekdayAbbrev, + A: d3_time_parseWeekday, + b: d3_time_parseMonthAbbrev, + B: d3_time_parseMonth, + c: d3_time_parseLocaleFull, + d: d3_time_parseDay, + e: d3_time_parseDay, + H: d3_time_parseHour24, + I: d3_time_parseHour24, + j: d3_time_parseDayOfYear, + L: d3_time_parseMilliseconds, + m: d3_time_parseMonthNumber, + M: d3_time_parseMinutes, + p: d3_time_parseAmPm, + S: d3_time_parseSeconds, + U: d3_time_parseWeekNumberSunday, + w: d3_time_parseWeekdayNumber, + W: d3_time_parseWeekNumberMonday, + x: d3_time_parseLocaleDate, + X: d3_time_parseLocaleTime, + y: d3_time_parseYear, + Y: d3_time_parseFullYear, + Z: d3_time_parseZone, + "%": d3_time_parseLiteralPercent + }; + function d3_time_parseWeekdayAbbrev(date, string, i) { + d3_time_dayAbbrevRe.lastIndex = 0; + var n = d3_time_dayAbbrevRe.exec(string.slice(i)); + return n ? (date.w = d3_time_dayAbbrevLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; + } + function d3_time_parseWeekday(date, string, i) { + d3_time_dayRe.lastIndex = 0; + var n = d3_time_dayRe.exec(string.slice(i)); + return n ? (date.w = d3_time_dayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; + } + function d3_time_parseMonthAbbrev(date, string, i) { + d3_time_monthAbbrevRe.lastIndex = 0; + var n = d3_time_monthAbbrevRe.exec(string.slice(i)); + return n ? (date.m = d3_time_monthAbbrevLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; + } + function d3_time_parseMonth(date, string, i) { + d3_time_monthRe.lastIndex = 0; + var n = d3_time_monthRe.exec(string.slice(i)); + return n ? (date.m = d3_time_monthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1; + } + function d3_time_parseLocaleFull(date, string, i) { + return d3_time_parse(date, d3_time_formats.c.toString(), string, i); + } + function d3_time_parseLocaleDate(date, string, i) { + return d3_time_parse(date, d3_time_formats.x.toString(), string, i); + } + function d3_time_parseLocaleTime(date, string, i) { + return d3_time_parse(date, d3_time_formats.X.toString(), string, i); + } + function d3_time_parseAmPm(date, string, i) { + var n = d3_time_periodLookup.get(string.slice(i, i += 2).toLowerCase()); + return n == null ? -1 : (date.p = n, i); + } + return d3_time_format; + } + var d3_time_formatPads = { + "-": "", + _: " ", + "0": "0" + }, d3_time_numberRe = /^\s*\d+/, d3_time_percentRe = /^%/; + function d3_time_formatPad(value, fill, width) { + var sign = value < 0 ? "-" : "", string = (sign ? -value : value) + "", length = string.length; + return sign + (length < width ? new Array(width - length + 1).join(fill) + string : string); + } + function d3_time_formatRe(names) { + return new RegExp("^(?:" + names.map(d3.requote).join("|") + ")", "i"); + } + function d3_time_formatLookup(names) { + var map = new d3_Map(), i = -1, n = names.length; + while (++i < n) map.set(names[i].toLowerCase(), i); + return map; + } + function d3_time_parseWeekdayNumber(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 1)); + return n ? (date.w = +n[0], i + n[0].length) : -1; + } + function d3_time_parseWeekNumberSunday(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i)); + return n ? (date.U = +n[0], i + n[0].length) : -1; + } + function d3_time_parseWeekNumberMonday(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i)); + return n ? (date.W = +n[0], i + n[0].length) : -1; + } + function d3_time_parseFullYear(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 4)); + return n ? (date.y = +n[0], i + n[0].length) : -1; + } + function d3_time_parseYear(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.y = d3_time_expandYear(+n[0]), i + n[0].length) : -1; + } + function d3_time_parseZone(date, string, i) { + return /^[+-]\d{4}$/.test(string = string.slice(i, i + 5)) ? (date.Z = -string, + i + 5) : -1; + } + function d3_time_expandYear(d) { + return d + (d > 68 ? 1900 : 2e3); + } + function d3_time_parseMonthNumber(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.m = n[0] - 1, i + n[0].length) : -1; + } + function d3_time_parseDay(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.d = +n[0], i + n[0].length) : -1; + } + function d3_time_parseDayOfYear(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 3)); + return n ? (date.j = +n[0], i + n[0].length) : -1; + } + function d3_time_parseHour24(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.H = +n[0], i + n[0].length) : -1; + } + function d3_time_parseMinutes(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.M = +n[0], i + n[0].length) : -1; + } + function d3_time_parseSeconds(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 2)); + return n ? (date.S = +n[0], i + n[0].length) : -1; + } + function d3_time_parseMilliseconds(date, string, i) { + d3_time_numberRe.lastIndex = 0; + var n = d3_time_numberRe.exec(string.slice(i, i + 3)); + return n ? (date.L = +n[0], i + n[0].length) : -1; + } + function d3_time_zone(d) { + var z = d.getTimezoneOffset(), zs = z > 0 ? "-" : "+", zh = abs(z) / 60 | 0, zm = abs(z) % 60; + return zs + d3_time_formatPad(zh, "0", 2) + d3_time_formatPad(zm, "0", 2); + } + function d3_time_parseLiteralPercent(date, string, i) { + d3_time_percentRe.lastIndex = 0; + var n = d3_time_percentRe.exec(string.slice(i, i + 1)); + return n ? i + n[0].length : -1; + } + function d3_time_formatMulti(formats) { + var n = formats.length, i = -1; + while (++i < n) formats[i][0] = this(formats[i][0]); + return function(date) { + var i = 0, f = formats[i]; + while (!f[1](date)) f = formats[++i]; + return f[0](date); + }; + } + d3.locale = function(locale) { + return { + numberFormat: d3_locale_numberFormat(locale), + timeFormat: d3_locale_timeFormat(locale) + }; + }; + var d3_locale_enUS = d3.locale({ + decimal: ".", + thousands: ",", + grouping: [ 3 ], + currency: [ "$", "" ], + dateTime: "%a %b %e %X %Y", + date: "%m/%d/%Y", + time: "%H:%M:%S", + periods: [ "AM", "PM" ], + days: [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], + shortDays: [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], + months: [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ], + shortMonths: [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ] + }); + d3.format = d3_locale_enUS.numberFormat; + d3.geo = {}; + function d3_adder() {} + d3_adder.prototype = { + s: 0, + t: 0, + add: function(y) { + d3_adderSum(y, this.t, d3_adderTemp); + d3_adderSum(d3_adderTemp.s, this.s, this); + if (this.s) this.t += d3_adderTemp.t; else this.s = d3_adderTemp.t; + }, + reset: function() { + this.s = this.t = 0; + }, + valueOf: function() { + return this.s; + } + }; + var d3_adderTemp = new d3_adder(); + function d3_adderSum(a, b, o) { + var x = o.s = a + b, bv = x - a, av = x - bv; + o.t = a - av + (b - bv); + } + d3.geo.stream = function(object, listener) { + if (object && d3_geo_streamObjectType.hasOwnProperty(object.type)) { + d3_geo_streamObjectType[object.type](object, listener); + } else { + d3_geo_streamGeometry(object, listener); + } + }; + function d3_geo_streamGeometry(geometry, listener) { + if (geometry && d3_geo_streamGeometryType.hasOwnProperty(geometry.type)) { + d3_geo_streamGeometryType[geometry.type](geometry, listener); + } + } + var d3_geo_streamObjectType = { + Feature: function(feature, listener) { + d3_geo_streamGeometry(feature.geometry, listener); + }, + FeatureCollection: function(object, listener) { + var features = object.features, i = -1, n = features.length; + while (++i < n) d3_geo_streamGeometry(features[i].geometry, listener); + } + }; + var d3_geo_streamGeometryType = { + Sphere: function(object, listener) { + listener.sphere(); + }, + Point: function(object, listener) { + object = object.coordinates; + listener.point(object[0], object[1], object[2]); + }, + MultiPoint: function(object, listener) { + var coordinates = object.coordinates, i = -1, n = coordinates.length; + while (++i < n) object = coordinates[i], listener.point(object[0], object[1], object[2]); + }, + LineString: function(object, listener) { + d3_geo_streamLine(object.coordinates, listener, 0); + }, + MultiLineString: function(object, listener) { + var coordinates = object.coordinates, i = -1, n = coordinates.length; + while (++i < n) d3_geo_streamLine(coordinates[i], listener, 0); + }, + Polygon: function(object, listener) { + d3_geo_streamPolygon(object.coordinates, listener); + }, + MultiPolygon: function(object, listener) { + var coordinates = object.coordinates, i = -1, n = coordinates.length; + while (++i < n) d3_geo_streamPolygon(coordinates[i], listener); + }, + GeometryCollection: function(object, listener) { + var geometries = object.geometries, i = -1, n = geometries.length; + while (++i < n) d3_geo_streamGeometry(geometries[i], listener); + } + }; + function d3_geo_streamLine(coordinates, listener, closed) { + var i = -1, n = coordinates.length - closed, coordinate; + listener.lineStart(); + while (++i < n) coordinate = coordinates[i], listener.point(coordinate[0], coordinate[1], coordinate[2]); + listener.lineEnd(); + } + function d3_geo_streamPolygon(coordinates, listener) { + var i = -1, n = coordinates.length; + listener.polygonStart(); + while (++i < n) d3_geo_streamLine(coordinates[i], listener, 1); + listener.polygonEnd(); + } + d3.geo.area = function(object) { + d3_geo_areaSum = 0; + d3.geo.stream(object, d3_geo_area); + return d3_geo_areaSum; + }; + var d3_geo_areaSum, d3_geo_areaRingSum = new d3_adder(); + var d3_geo_area = { + sphere: function() { + d3_geo_areaSum += 4 * π; + }, + point: d3_noop, + lineStart: d3_noop, + lineEnd: d3_noop, + polygonStart: function() { + d3_geo_areaRingSum.reset(); + d3_geo_area.lineStart = d3_geo_areaRingStart; + }, + polygonEnd: function() { + var area = 2 * d3_geo_areaRingSum; + d3_geo_areaSum += area < 0 ? 4 * π + area : area; + d3_geo_area.lineStart = d3_geo_area.lineEnd = d3_geo_area.point = d3_noop; + } + }; + function d3_geo_areaRingStart() { + var λ00, φ00, λ0, cosφ0, sinφ0; + d3_geo_area.point = function(λ, φ) { + d3_geo_area.point = nextPoint; + λ0 = (λ00 = λ) * d3_radians, cosφ0 = Math.cos(φ = (φ00 = φ) * d3_radians / 2 + π / 4), + sinφ0 = Math.sin(φ); + }; + function nextPoint(λ, φ) { + λ *= d3_radians; + φ = φ * d3_radians / 2 + π / 4; + var dλ = λ - λ0, sdλ = dλ >= 0 ? 1 : -1, adλ = sdλ * dλ, cosφ = Math.cos(φ), sinφ = Math.sin(φ), k = sinφ0 * sinφ, u = cosφ0 * cosφ + k * Math.cos(adλ), v = k * sdλ * Math.sin(adλ); + d3_geo_areaRingSum.add(Math.atan2(v, u)); + λ0 = λ, cosφ0 = cosφ, sinφ0 = sinφ; + } + d3_geo_area.lineEnd = function() { + nextPoint(λ00, φ00); + }; + } + function d3_geo_cartesian(spherical) { + var λ = spherical[0], φ = spherical[1], cosφ = Math.cos(φ); + return [ cosφ * Math.cos(λ), cosφ * Math.sin(λ), Math.sin(φ) ]; + } + function d3_geo_cartesianDot(a, b) { + return a[0] * b[0] + a[1] * b[1] + a[2] * b[2]; + } + function d3_geo_cartesianCross(a, b) { + return [ a[1] * b[2] - a[2] * b[1], a[2] * b[0] - a[0] * b[2], a[0] * b[1] - a[1] * b[0] ]; + } + function d3_geo_cartesianAdd(a, b) { + a[0] += b[0]; + a[1] += b[1]; + a[2] += b[2]; + } + function d3_geo_cartesianScale(vector, k) { + return [ vector[0] * k, vector[1] * k, vector[2] * k ]; + } + function d3_geo_cartesianNormalize(d) { + var l = Math.sqrt(d[0] * d[0] + d[1] * d[1] + d[2] * d[2]); + d[0] /= l; + d[1] /= l; + d[2] /= l; + } + function d3_geo_spherical(cartesian) { + return [ Math.atan2(cartesian[1], cartesian[0]), d3_asin(cartesian[2]) ]; + } + function d3_geo_sphericalEqual(a, b) { + return abs(a[0] - b[0]) < ε && abs(a[1] - b[1]) < ε; + } + d3.geo.bounds = function() { + var λ0, φ0, λ1, φ1, λ_, λ__, φ__, p0, dλSum, ranges, range; + var bound = { + point: point, + lineStart: lineStart, + lineEnd: lineEnd, + polygonStart: function() { + bound.point = ringPoint; + bound.lineStart = ringStart; + bound.lineEnd = ringEnd; + dλSum = 0; + d3_geo_area.polygonStart(); + }, + polygonEnd: function() { + d3_geo_area.polygonEnd(); + bound.point = point; + bound.lineStart = lineStart; + bound.lineEnd = lineEnd; + if (d3_geo_areaRingSum < 0) λ0 = -(λ1 = 180), φ0 = -(φ1 = 90); else if (dλSum > ε) φ1 = 90; else if (dλSum < -ε) φ0 = -90; + range[0] = λ0, range[1] = λ1; + } + }; + function point(λ, φ) { + ranges.push(range = [ λ0 = λ, λ1 = λ ]); + if (φ < φ0) φ0 = φ; + if (φ > φ1) φ1 = φ; + } + function linePoint(λ, φ) { + var p = d3_geo_cartesian([ λ * d3_radians, φ * d3_radians ]); + if (p0) { + var normal = d3_geo_cartesianCross(p0, p), equatorial = [ normal[1], -normal[0], 0 ], inflection = d3_geo_cartesianCross(equatorial, normal); + d3_geo_cartesianNormalize(inflection); + inflection = d3_geo_spherical(inflection); + var dλ = λ - λ_, s = dλ > 0 ? 1 : -1, λi = inflection[0] * d3_degrees * s, antimeridian = abs(dλ) > 180; + if (antimeridian ^ (s * λ_ < λi && λi < s * λ)) { + var φi = inflection[1] * d3_degrees; + if (φi > φ1) φ1 = φi; + } else if (λi = (λi + 360) % 360 - 180, antimeridian ^ (s * λ_ < λi && λi < s * λ)) { + var φi = -inflection[1] * d3_degrees; + if (φi < φ0) φ0 = φi; + } else { + if (φ < φ0) φ0 = φ; + if (φ > φ1) φ1 = φ; + } + if (antimeridian) { + if (λ < λ_) { + if (angle(λ0, λ) > angle(λ0, λ1)) λ1 = λ; + } else { + if (angle(λ, λ1) > angle(λ0, λ1)) λ0 = λ; + } + } else { + if (λ1 >= λ0) { + if (λ < λ0) λ0 = λ; + if (λ > λ1) λ1 = λ; + } else { + if (λ > λ_) { + if (angle(λ0, λ) > angle(λ0, λ1)) λ1 = λ; + } else { + if (angle(λ, λ1) > angle(λ0, λ1)) λ0 = λ; + } + } + } + } else { + point(λ, φ); + } + p0 = p, λ_ = λ; + } + function lineStart() { + bound.point = linePoint; + } + function lineEnd() { + range[0] = λ0, range[1] = λ1; + bound.point = point; + p0 = null; + } + function ringPoint(λ, φ) { + if (p0) { + var dλ = λ - λ_; + dλSum += abs(dλ) > 180 ? dλ + (dλ > 0 ? 360 : -360) : dλ; + } else λ__ = λ, φ__ = φ; + d3_geo_area.point(λ, φ); + linePoint(λ, φ); + } + function ringStart() { + d3_geo_area.lineStart(); + } + function ringEnd() { + ringPoint(λ__, φ__); + d3_geo_area.lineEnd(); + if (abs(dλSum) > ε) λ0 = -(λ1 = 180); + range[0] = λ0, range[1] = λ1; + p0 = null; + } + function angle(λ0, λ1) { + return (λ1 -= λ0) < 0 ? λ1 + 360 : λ1; + } + function compareRanges(a, b) { + return a[0] - b[0]; + } + function withinRange(x, range) { + return range[0] <= range[1] ? range[0] <= x && x <= range[1] : x < range[0] || range[1] < x; + } + return function(feature) { + φ1 = λ1 = -(λ0 = φ0 = Infinity); + ranges = []; + d3.geo.stream(feature, bound); + var n = ranges.length; + if (n) { + ranges.sort(compareRanges); + for (var i = 1, a = ranges[0], b, merged = [ a ]; i < n; ++i) { + b = ranges[i]; + if (withinRange(b[0], a) || withinRange(b[1], a)) { + if (angle(a[0], b[1]) > angle(a[0], a[1])) a[1] = b[1]; + if (angle(b[0], a[1]) > angle(a[0], a[1])) a[0] = b[0]; + } else { + merged.push(a = b); + } + } + var best = -Infinity, dλ; + for (var n = merged.length - 1, i = 0, a = merged[n], b; i <= n; a = b, ++i) { + b = merged[i]; + if ((dλ = angle(a[1], b[0])) > best) best = dλ, λ0 = b[0], λ1 = a[1]; + } + } + ranges = range = null; + return λ0 === Infinity || φ0 === Infinity ? [ [ NaN, NaN ], [ NaN, NaN ] ] : [ [ λ0, φ0 ], [ λ1, φ1 ] ]; + }; + }(); + d3.geo.centroid = function(object) { + d3_geo_centroidW0 = d3_geo_centroidW1 = d3_geo_centroidX0 = d3_geo_centroidY0 = d3_geo_centroidZ0 = d3_geo_centroidX1 = d3_geo_centroidY1 = d3_geo_centroidZ1 = d3_geo_centroidX2 = d3_geo_centroidY2 = d3_geo_centroidZ2 = 0; + d3.geo.stream(object, d3_geo_centroid); + var x = d3_geo_centroidX2, y = d3_geo_centroidY2, z = d3_geo_centroidZ2, m = x * x + y * y + z * z; + if (m < ε2) { + x = d3_geo_centroidX1, y = d3_geo_centroidY1, z = d3_geo_centroidZ1; + if (d3_geo_centroidW1 < ε) x = d3_geo_centroidX0, y = d3_geo_centroidY0, z = d3_geo_centroidZ0; + m = x * x + y * y + z * z; + if (m < ε2) return [ NaN, NaN ]; + } + return [ Math.atan2(y, x) * d3_degrees, d3_asin(z / Math.sqrt(m)) * d3_degrees ]; + }; + var d3_geo_centroidW0, d3_geo_centroidW1, d3_geo_centroidX0, d3_geo_centroidY0, d3_geo_centroidZ0, d3_geo_centroidX1, d3_geo_centroidY1, d3_geo_centroidZ1, d3_geo_centroidX2, d3_geo_centroidY2, d3_geo_centroidZ2; + var d3_geo_centroid = { + sphere: d3_noop, + point: d3_geo_centroidPoint, + lineStart: d3_geo_centroidLineStart, + lineEnd: d3_geo_centroidLineEnd, + polygonStart: function() { + d3_geo_centroid.lineStart = d3_geo_centroidRingStart; + }, + polygonEnd: function() { + d3_geo_centroid.lineStart = d3_geo_centroidLineStart; + } + }; + function d3_geo_centroidPoint(λ, φ) { + λ *= d3_radians; + var cosφ = Math.cos(φ *= d3_radians); + d3_geo_centroidPointXYZ(cosφ * Math.cos(λ), cosφ * Math.sin(λ), Math.sin(φ)); + } + function d3_geo_centroidPointXYZ(x, y, z) { + ++d3_geo_centroidW0; + d3_geo_centroidX0 += (x - d3_geo_centroidX0) / d3_geo_centroidW0; + d3_geo_centroidY0 += (y - d3_geo_centroidY0) / d3_geo_centroidW0; + d3_geo_centroidZ0 += (z - d3_geo_centroidZ0) / d3_geo_centroidW0; + } + function d3_geo_centroidLineStart() { + var x0, y0, z0; + d3_geo_centroid.point = function(λ, φ) { + λ *= d3_radians; + var cosφ = Math.cos(φ *= d3_radians); + x0 = cosφ * Math.cos(λ); + y0 = cosφ * Math.sin(λ); + z0 = Math.sin(φ); + d3_geo_centroid.point = nextPoint; + d3_geo_centroidPointXYZ(x0, y0, z0); + }; + function nextPoint(λ, φ) { + λ *= d3_radians; + var cosφ = Math.cos(φ *= d3_radians), x = cosφ * Math.cos(λ), y = cosφ * Math.sin(λ), z = Math.sin(φ), w = Math.atan2(Math.sqrt((w = y0 * z - z0 * y) * w + (w = z0 * x - x0 * z) * w + (w = x0 * y - y0 * x) * w), x0 * x + y0 * y + z0 * z); + d3_geo_centroidW1 += w; + d3_geo_centroidX1 += w * (x0 + (x0 = x)); + d3_geo_centroidY1 += w * (y0 + (y0 = y)); + d3_geo_centroidZ1 += w * (z0 + (z0 = z)); + d3_geo_centroidPointXYZ(x0, y0, z0); + } + } + function d3_geo_centroidLineEnd() { + d3_geo_centroid.point = d3_geo_centroidPoint; + } + function d3_geo_centroidRingStart() { + var λ00, φ00, x0, y0, z0; + d3_geo_centroid.point = function(λ, φ) { + λ00 = λ, φ00 = φ; + d3_geo_centroid.point = nextPoint; + λ *= d3_radians; + var cosφ = Math.cos(φ *= d3_radians); + x0 = cosφ * Math.cos(λ); + y0 = cosφ * Math.sin(λ); + z0 = Math.sin(φ); + d3_geo_centroidPointXYZ(x0, y0, z0); + }; + d3_geo_centroid.lineEnd = function() { + nextPoint(λ00, φ00); + d3_geo_centroid.lineEnd = d3_geo_centroidLineEnd; + d3_geo_centroid.point = d3_geo_centroidPoint; + }; + function nextPoint(λ, φ) { + λ *= d3_radians; + var cosφ = Math.cos(φ *= d3_radians), x = cosφ * Math.cos(λ), y = cosφ * Math.sin(λ), z = Math.sin(φ), cx = y0 * z - z0 * y, cy = z0 * x - x0 * z, cz = x0 * y - y0 * x, m = Math.sqrt(cx * cx + cy * cy + cz * cz), u = x0 * x + y0 * y + z0 * z, v = m && -d3_acos(u) / m, w = Math.atan2(m, u); + d3_geo_centroidX2 += v * cx; + d3_geo_centroidY2 += v * cy; + d3_geo_centroidZ2 += v * cz; + d3_geo_centroidW1 += w; + d3_geo_centroidX1 += w * (x0 + (x0 = x)); + d3_geo_centroidY1 += w * (y0 + (y0 = y)); + d3_geo_centroidZ1 += w * (z0 + (z0 = z)); + d3_geo_centroidPointXYZ(x0, y0, z0); + } + } + function d3_geo_compose(a, b) { + function compose(x, y) { + return x = a(x, y), b(x[0], x[1]); + } + if (a.invert && b.invert) compose.invert = function(x, y) { + return x = b.invert(x, y), x && a.invert(x[0], x[1]); + }; + return compose; + } + function d3_true() { + return true; + } + function d3_geo_clipPolygon(segments, compare, clipStartInside, interpolate, listener) { + var subject = [], clip = []; + segments.forEach(function(segment) { + if ((n = segment.length - 1) <= 0) return; + var n, p0 = segment[0], p1 = segment[n]; + if (d3_geo_sphericalEqual(p0, p1)) { + listener.lineStart(); + for (var i = 0; i < n; ++i) listener.point((p0 = segment[i])[0], p0[1]); + listener.lineEnd(); + return; + } + var a = new d3_geo_clipPolygonIntersection(p0, segment, null, true), b = new d3_geo_clipPolygonIntersection(p0, null, a, false); + a.o = b; + subject.push(a); + clip.push(b); + a = new d3_geo_clipPolygonIntersection(p1, segment, null, false); + b = new d3_geo_clipPolygonIntersection(p1, null, a, true); + a.o = b; + subject.push(a); + clip.push(b); + }); + clip.sort(compare); + d3_geo_clipPolygonLinkCircular(subject); + d3_geo_clipPolygonLinkCircular(clip); + if (!subject.length) return; + for (var i = 0, entry = clipStartInside, n = clip.length; i < n; ++i) { + clip[i].e = entry = !entry; + } + var start = subject[0], points, point; + while (1) { + var current = start, isSubject = true; + while (current.v) if ((current = current.n) === start) return; + points = current.z; + listener.lineStart(); + do { + current.v = current.o.v = true; + if (current.e) { + if (isSubject) { + for (var i = 0, n = points.length; i < n; ++i) listener.point((point = points[i])[0], point[1]); + } else { + interpolate(current.x, current.n.x, 1, listener); + } + current = current.n; + } else { + if (isSubject) { + points = current.p.z; + for (var i = points.length - 1; i >= 0; --i) listener.point((point = points[i])[0], point[1]); + } else { + interpolate(current.x, current.p.x, -1, listener); + } + current = current.p; + } + current = current.o; + points = current.z; + isSubject = !isSubject; + } while (!current.v); + listener.lineEnd(); + } + } + function d3_geo_clipPolygonLinkCircular(array) { + if (!(n = array.length)) return; + var n, i = 0, a = array[0], b; + while (++i < n) { + a.n = b = array[i]; + b.p = a; + a = b; + } + a.n = b = array[0]; + b.p = a; + } + function d3_geo_clipPolygonIntersection(point, points, other, entry) { + this.x = point; + this.z = points; + this.o = other; + this.e = entry; + this.v = false; + this.n = this.p = null; + } + function d3_geo_clip(pointVisible, clipLine, interpolate, clipStart) { + return function(rotate, listener) { + var line = clipLine(listener), rotatedClipStart = rotate.invert(clipStart[0], clipStart[1]); + var clip = { + point: point, + lineStart: lineStart, + lineEnd: lineEnd, + polygonStart: function() { + clip.point = pointRing; + clip.lineStart = ringStart; + clip.lineEnd = ringEnd; + segments = []; + polygon = []; + }, + polygonEnd: function() { + clip.point = point; + clip.lineStart = lineStart; + clip.lineEnd = lineEnd; + segments = d3.merge(segments); + var clipStartInside = d3_geo_pointInPolygon(rotatedClipStart, polygon); + if (segments.length) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; + d3_geo_clipPolygon(segments, d3_geo_clipSort, clipStartInside, interpolate, listener); + } else if (clipStartInside) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; + listener.lineStart(); + interpolate(null, null, 1, listener); + listener.lineEnd(); + } + if (polygonStarted) listener.polygonEnd(), polygonStarted = false; + segments = polygon = null; + }, + sphere: function() { + listener.polygonStart(); + listener.lineStart(); + interpolate(null, null, 1, listener); + listener.lineEnd(); + listener.polygonEnd(); + } + }; + function point(λ, φ) { + var point = rotate(λ, φ); + if (pointVisible(λ = point[0], φ = point[1])) listener.point(λ, φ); + } + function pointLine(λ, φ) { + var point = rotate(λ, φ); + line.point(point[0], point[1]); + } + function lineStart() { + clip.point = pointLine; + line.lineStart(); + } + function lineEnd() { + clip.point = point; + line.lineEnd(); + } + var segments; + var buffer = d3_geo_clipBufferListener(), ringListener = clipLine(buffer), polygonStarted = false, polygon, ring; + function pointRing(λ, φ) { + ring.push([ λ, φ ]); + var point = rotate(λ, φ); + ringListener.point(point[0], point[1]); + } + function ringStart() { + ringListener.lineStart(); + ring = []; + } + function ringEnd() { + pointRing(ring[0][0], ring[0][1]); + ringListener.lineEnd(); + var clean = ringListener.clean(), ringSegments = buffer.buffer(), segment, n = ringSegments.length; + ring.pop(); + polygon.push(ring); + ring = null; + if (!n) return; + if (clean & 1) { + segment = ringSegments[0]; + var n = segment.length - 1, i = -1, point; + if (n > 0) { + if (!polygonStarted) listener.polygonStart(), polygonStarted = true; + listener.lineStart(); + while (++i < n) listener.point((point = segment[i])[0], point[1]); + listener.lineEnd(); + } + return; + } + if (n > 1 && clean & 2) ringSegments.push(ringSegments.pop().concat(ringSegments.shift())); + segments.push(ringSegments.filter(d3_geo_clipSegmentLength1)); + } + return clip; + }; + } + function d3_geo_clipSegmentLength1(segment) { + return segment.length > 1; + } + function d3_geo_clipBufferListener() { + var lines = [], line; + return { + lineStart: function() { + lines.push(line = []); + }, + point: function(λ, φ) { + line.push([ λ, φ ]); + }, + lineEnd: d3_noop, + buffer: function() { + var buffer = lines; + lines = []; + line = null; + return buffer; + }, + rejoin: function() { + if (lines.length > 1) lines.push(lines.pop().concat(lines.shift())); + } + }; + } + function d3_geo_clipSort(a, b) { + return ((a = a.x)[0] < 0 ? a[1] - halfπ - ε : halfπ - a[1]) - ((b = b.x)[0] < 0 ? b[1] - halfπ - ε : halfπ - b[1]); + } + var d3_geo_clipAntimeridian = d3_geo_clip(d3_true, d3_geo_clipAntimeridianLine, d3_geo_clipAntimeridianInterpolate, [ -π, -π / 2 ]); + function d3_geo_clipAntimeridianLine(listener) { + var λ0 = NaN, φ0 = NaN, sλ0 = NaN, clean; + return { + lineStart: function() { + listener.lineStart(); + clean = 1; + }, + point: function(λ1, φ1) { + var sλ1 = λ1 > 0 ? π : -π, dλ = abs(λ1 - λ0); + if (abs(dλ - π) < ε) { + listener.point(λ0, φ0 = (φ0 + φ1) / 2 > 0 ? halfπ : -halfπ); + listener.point(sλ0, φ0); + listener.lineEnd(); + listener.lineStart(); + listener.point(sλ1, φ0); + listener.point(λ1, φ0); + clean = 0; + } else if (sλ0 !== sλ1 && dλ >= π) { + if (abs(λ0 - sλ0) < ε) λ0 -= sλ0 * ε; + if (abs(λ1 - sλ1) < ε) λ1 -= sλ1 * ε; + φ0 = d3_geo_clipAntimeridianIntersect(λ0, φ0, λ1, φ1); + listener.point(sλ0, φ0); + listener.lineEnd(); + listener.lineStart(); + listener.point(sλ1, φ0); + clean = 0; + } + listener.point(λ0 = λ1, φ0 = φ1); + sλ0 = sλ1; + }, + lineEnd: function() { + listener.lineEnd(); + λ0 = φ0 = NaN; + }, + clean: function() { + return 2 - clean; + } + }; + } + function d3_geo_clipAntimeridianIntersect(λ0, φ0, λ1, φ1) { + var cosφ0, cosφ1, sinλ0_λ1 = Math.sin(λ0 - λ1); + return abs(sinλ0_λ1) > ε ? Math.atan((Math.sin(φ0) * (cosφ1 = Math.cos(φ1)) * Math.sin(λ1) - Math.sin(φ1) * (cosφ0 = Math.cos(φ0)) * Math.sin(λ0)) / (cosφ0 * cosφ1 * sinλ0_λ1)) : (φ0 + φ1) / 2; + } + function d3_geo_clipAntimeridianInterpolate(from, to, direction, listener) { + var φ; + if (from == null) { + φ = direction * halfπ; + listener.point(-π, φ); + listener.point(0, φ); + listener.point(π, φ); + listener.point(π, 0); + listener.point(π, -φ); + listener.point(0, -φ); + listener.point(-π, -φ); + listener.point(-π, 0); + listener.point(-π, φ); + } else if (abs(from[0] - to[0]) > ε) { + var s = from[0] < to[0] ? π : -π; + φ = direction * s / 2; + listener.point(-s, φ); + listener.point(0, φ); + listener.point(s, φ); + } else { + listener.point(to[0], to[1]); + } + } + function d3_geo_pointInPolygon(point, polygon) { + var meridian = point[0], parallel = point[1], meridianNormal = [ Math.sin(meridian), -Math.cos(meridian), 0 ], polarAngle = 0, winding = 0; + d3_geo_areaRingSum.reset(); + for (var i = 0, n = polygon.length; i < n; ++i) { + var ring = polygon[i], m = ring.length; + if (!m) continue; + var point0 = ring[0], λ0 = point0[0], φ0 = point0[1] / 2 + π / 4, sinφ0 = Math.sin(φ0), cosφ0 = Math.cos(φ0), j = 1; + while (true) { + if (j === m) j = 0; + point = ring[j]; + var λ = point[0], φ = point[1] / 2 + π / 4, sinφ = Math.sin(φ), cosφ = Math.cos(φ), dλ = λ - λ0, sdλ = dλ >= 0 ? 1 : -1, adλ = sdλ * dλ, antimeridian = adλ > π, k = sinφ0 * sinφ; + d3_geo_areaRingSum.add(Math.atan2(k * sdλ * Math.sin(adλ), cosφ0 * cosφ + k * Math.cos(adλ))); + polarAngle += antimeridian ? dλ + sdλ * τ : dλ; + if (antimeridian ^ λ0 >= meridian ^ λ >= meridian) { + var arc = d3_geo_cartesianCross(d3_geo_cartesian(point0), d3_geo_cartesian(point)); + d3_geo_cartesianNormalize(arc); + var intersection = d3_geo_cartesianCross(meridianNormal, arc); + d3_geo_cartesianNormalize(intersection); + var φarc = (antimeridian ^ dλ >= 0 ? -1 : 1) * d3_asin(intersection[2]); + if (parallel > φarc || parallel === φarc && (arc[0] || arc[1])) { + winding += antimeridian ^ dλ >= 0 ? 1 : -1; + } + } + if (!j++) break; + λ0 = λ, sinφ0 = sinφ, cosφ0 = cosφ, point0 = point; + } + } + return (polarAngle < -ε || polarAngle < ε && d3_geo_areaRingSum < -ε) ^ winding & 1; + } + function d3_geo_clipCircle(radius) { + var cr = Math.cos(radius), smallRadius = cr > 0, notHemisphere = abs(cr) > ε, interpolate = d3_geo_circleInterpolate(radius, 6 * d3_radians); + return d3_geo_clip(visible, clipLine, interpolate, smallRadius ? [ 0, -radius ] : [ -π, radius - π ]); + function visible(λ, φ) { + return Math.cos(λ) * Math.cos(φ) > cr; + } + function clipLine(listener) { + var point0, c0, v0, v00, clean; + return { + lineStart: function() { + v00 = v0 = false; + clean = 1; + }, + point: function(λ, φ) { + var point1 = [ λ, φ ], point2, v = visible(λ, φ), c = smallRadius ? v ? 0 : code(λ, φ) : v ? code(λ + (λ < 0 ? π : -π), φ) : 0; + if (!point0 && (v00 = v0 = v)) listener.lineStart(); + if (v !== v0) { + point2 = intersect(point0, point1); + if (d3_geo_sphericalEqual(point0, point2) || d3_geo_sphericalEqual(point1, point2)) { + point1[0] += ε; + point1[1] += ε; + v = visible(point1[0], point1[1]); + } + } + if (v !== v0) { + clean = 0; + if (v) { + listener.lineStart(); + point2 = intersect(point1, point0); + listener.point(point2[0], point2[1]); + } else { + point2 = intersect(point0, point1); + listener.point(point2[0], point2[1]); + listener.lineEnd(); + } + point0 = point2; + } else if (notHemisphere && point0 && smallRadius ^ v) { + var t; + if (!(c & c0) && (t = intersect(point1, point0, true))) { + clean = 0; + if (smallRadius) { + listener.lineStart(); + listener.point(t[0][0], t[0][1]); + listener.point(t[1][0], t[1][1]); + listener.lineEnd(); + } else { + listener.point(t[1][0], t[1][1]); + listener.lineEnd(); + listener.lineStart(); + listener.point(t[0][0], t[0][1]); + } + } + } + if (v && (!point0 || !d3_geo_sphericalEqual(point0, point1))) { + listener.point(point1[0], point1[1]); + } + point0 = point1, v0 = v, c0 = c; + }, + lineEnd: function() { + if (v0) listener.lineEnd(); + point0 = null; + }, + clean: function() { + return clean | (v00 && v0) << 1; + } + }; + } + function intersect(a, b, two) { + var pa = d3_geo_cartesian(a), pb = d3_geo_cartesian(b); + var n1 = [ 1, 0, 0 ], n2 = d3_geo_cartesianCross(pa, pb), n2n2 = d3_geo_cartesianDot(n2, n2), n1n2 = n2[0], determinant = n2n2 - n1n2 * n1n2; + if (!determinant) return !two && a; + var c1 = cr * n2n2 / determinant, c2 = -cr * n1n2 / determinant, n1xn2 = d3_geo_cartesianCross(n1, n2), A = d3_geo_cartesianScale(n1, c1), B = d3_geo_cartesianScale(n2, c2); + d3_geo_cartesianAdd(A, B); + var u = n1xn2, w = d3_geo_cartesianDot(A, u), uu = d3_geo_cartesianDot(u, u), t2 = w * w - uu * (d3_geo_cartesianDot(A, A) - 1); + if (t2 < 0) return; + var t = Math.sqrt(t2), q = d3_geo_cartesianScale(u, (-w - t) / uu); + d3_geo_cartesianAdd(q, A); + q = d3_geo_spherical(q); + if (!two) return q; + var λ0 = a[0], λ1 = b[0], φ0 = a[1], φ1 = b[1], z; + if (λ1 < λ0) z = λ0, λ0 = λ1, λ1 = z; + var δλ = λ1 - λ0, polar = abs(δλ - π) < ε, meridian = polar || δλ < ε; + if (!polar && φ1 < φ0) z = φ0, φ0 = φ1, φ1 = z; + if (meridian ? polar ? φ0 + φ1 > 0 ^ q[1] < (abs(q[0] - λ0) < ε ? φ0 : φ1) : φ0 <= q[1] && q[1] <= φ1 : δλ > π ^ (λ0 <= q[0] && q[0] <= λ1)) { + var q1 = d3_geo_cartesianScale(u, (-w + t) / uu); + d3_geo_cartesianAdd(q1, A); + return [ q, d3_geo_spherical(q1) ]; + } + } + function code(λ, φ) { + var r = smallRadius ? radius : π - radius, code = 0; + if (λ < -r) code |= 1; else if (λ > r) code |= 2; + if (φ < -r) code |= 4; else if (φ > r) code |= 8; + return code; + } + } + function d3_geom_clipLine(x0, y0, x1, y1) { + return function(line) { + var a = line.a, b = line.b, ax = a.x, ay = a.y, bx = b.x, by = b.y, t0 = 0, t1 = 1, dx = bx - ax, dy = by - ay, r; + r = x0 - ax; + if (!dx && r > 0) return; + r /= dx; + if (dx < 0) { + if (r < t0) return; + if (r < t1) t1 = r; + } else if (dx > 0) { + if (r > t1) return; + if (r > t0) t0 = r; + } + r = x1 - ax; + if (!dx && r < 0) return; + r /= dx; + if (dx < 0) { + if (r > t1) return; + if (r > t0) t0 = r; + } else if (dx > 0) { + if (r < t0) return; + if (r < t1) t1 = r; + } + r = y0 - ay; + if (!dy && r > 0) return; + r /= dy; + if (dy < 0) { + if (r < t0) return; + if (r < t1) t1 = r; + } else if (dy > 0) { + if (r > t1) return; + if (r > t0) t0 = r; + } + r = y1 - ay; + if (!dy && r < 0) return; + r /= dy; + if (dy < 0) { + if (r > t1) return; + if (r > t0) t0 = r; + } else if (dy > 0) { + if (r < t0) return; + if (r < t1) t1 = r; + } + if (t0 > 0) line.a = { + x: ax + t0 * dx, + y: ay + t0 * dy + }; + if (t1 < 1) line.b = { + x: ax + t1 * dx, + y: ay + t1 * dy + }; + return line; + }; + } + var d3_geo_clipExtentMAX = 1e9; + d3.geo.clipExtent = function() { + var x0, y0, x1, y1, stream, clip, clipExtent = { + stream: function(output) { + if (stream) stream.valid = false; + stream = clip(output); + stream.valid = true; + return stream; + }, + extent: function(_) { + if (!arguments.length) return [ [ x0, y0 ], [ x1, y1 ] ]; + clip = d3_geo_clipExtent(x0 = +_[0][0], y0 = +_[0][1], x1 = +_[1][0], y1 = +_[1][1]); + if (stream) stream.valid = false, stream = null; + return clipExtent; + } + }; + return clipExtent.extent([ [ 0, 0 ], [ 960, 500 ] ]); + }; + function d3_geo_clipExtent(x0, y0, x1, y1) { + return function(listener) { + var listener_ = listener, bufferListener = d3_geo_clipBufferListener(), clipLine = d3_geom_clipLine(x0, y0, x1, y1), segments, polygon, ring; + var clip = { + point: point, + lineStart: lineStart, + lineEnd: lineEnd, + polygonStart: function() { + listener = bufferListener; + segments = []; + polygon = []; + clean = true; + }, + polygonEnd: function() { + listener = listener_; + segments = d3.merge(segments); + var clipStartInside = insidePolygon([ x0, y1 ]), inside = clean && clipStartInside, visible = segments.length; + if (inside || visible) { + listener.polygonStart(); + if (inside) { + listener.lineStart(); + interpolate(null, null, 1, listener); + listener.lineEnd(); + } + if (visible) { + d3_geo_clipPolygon(segments, compare, clipStartInside, interpolate, listener); + } + listener.polygonEnd(); + } + segments = polygon = ring = null; + } + }; + function insidePolygon(p) { + var wn = 0, n = polygon.length, y = p[1]; + for (var i = 0; i < n; ++i) { + for (var j = 1, v = polygon[i], m = v.length, a = v[0], b; j < m; ++j) { + b = v[j]; + if (a[1] <= y) { + if (b[1] > y && d3_cross2d(a, b, p) > 0) ++wn; + } else { + if (b[1] <= y && d3_cross2d(a, b, p) < 0) --wn; + } + a = b; + } + } + return wn !== 0; + } + function interpolate(from, to, direction, listener) { + var a = 0, a1 = 0; + if (from == null || (a = corner(from, direction)) !== (a1 = corner(to, direction)) || comparePoints(from, to) < 0 ^ direction > 0) { + do { + listener.point(a === 0 || a === 3 ? x0 : x1, a > 1 ? y1 : y0); + } while ((a = (a + direction + 4) % 4) !== a1); + } else { + listener.point(to[0], to[1]); + } + } + function pointVisible(x, y) { + return x0 <= x && x <= x1 && y0 <= y && y <= y1; + } + function point(x, y) { + if (pointVisible(x, y)) listener.point(x, y); + } + var x__, y__, v__, x_, y_, v_, first, clean; + function lineStart() { + clip.point = linePoint; + if (polygon) polygon.push(ring = []); + first = true; + v_ = false; + x_ = y_ = NaN; + } + function lineEnd() { + if (segments) { + linePoint(x__, y__); + if (v__ && v_) bufferListener.rejoin(); + segments.push(bufferListener.buffer()); + } + clip.point = point; + if (v_) listener.lineEnd(); + } + function linePoint(x, y) { + x = Math.max(-d3_geo_clipExtentMAX, Math.min(d3_geo_clipExtentMAX, x)); + y = Math.max(-d3_geo_clipExtentMAX, Math.min(d3_geo_clipExtentMAX, y)); + var v = pointVisible(x, y); + if (polygon) ring.push([ x, y ]); + if (first) { + x__ = x, y__ = y, v__ = v; + first = false; + if (v) { + listener.lineStart(); + listener.point(x, y); + } + } else { + if (v && v_) listener.point(x, y); else { + var l = { + a: { + x: x_, + y: y_ + }, + b: { + x: x, + y: y + } + }; + if (clipLine(l)) { + if (!v_) { + listener.lineStart(); + listener.point(l.a.x, l.a.y); + } + listener.point(l.b.x, l.b.y); + if (!v) listener.lineEnd(); + clean = false; + } else if (v) { + listener.lineStart(); + listener.point(x, y); + clean = false; + } + } + } + x_ = x, y_ = y, v_ = v; + } + return clip; + }; + function corner(p, direction) { + return abs(p[0] - x0) < ε ? direction > 0 ? 0 : 3 : abs(p[0] - x1) < ε ? direction > 0 ? 2 : 1 : abs(p[1] - y0) < ε ? direction > 0 ? 1 : 0 : direction > 0 ? 3 : 2; + } + function compare(a, b) { + return comparePoints(a.x, b.x); + } + function comparePoints(a, b) { + var ca = corner(a, 1), cb = corner(b, 1); + return ca !== cb ? ca - cb : ca === 0 ? b[1] - a[1] : ca === 1 ? a[0] - b[0] : ca === 2 ? a[1] - b[1] : b[0] - a[0]; + } + } + function d3_geo_conic(projectAt) { + var φ0 = 0, φ1 = π / 3, m = d3_geo_projectionMutator(projectAt), p = m(φ0, φ1); + p.parallels = function(_) { + if (!arguments.length) return [ φ0 / π * 180, φ1 / π * 180 ]; + return m(φ0 = _[0] * π / 180, φ1 = _[1] * π / 180); + }; + return p; + } + function d3_geo_conicEqualArea(φ0, φ1) { + var sinφ0 = Math.sin(φ0), n = (sinφ0 + Math.sin(φ1)) / 2, C = 1 + sinφ0 * (2 * n - sinφ0), ρ0 = Math.sqrt(C) / n; + function forward(λ, φ) { + var ρ = Math.sqrt(C - 2 * n * Math.sin(φ)) / n; + return [ ρ * Math.sin(λ *= n), ρ0 - ρ * Math.cos(λ) ]; + } + forward.invert = function(x, y) { + var ρ0_y = ρ0 - y; + return [ Math.atan2(x, ρ0_y) / n, d3_asin((C - (x * x + ρ0_y * ρ0_y) * n * n) / (2 * n)) ]; + }; + return forward; + } + (d3.geo.conicEqualArea = function() { + return d3_geo_conic(d3_geo_conicEqualArea); + }).raw = d3_geo_conicEqualArea; + d3.geo.albers = function() { + return d3.geo.conicEqualArea().rotate([ 96, 0 ]).center([ -.6, 38.7 ]).parallels([ 29.5, 45.5 ]).scale(1070); + }; + d3.geo.albersUsa = function() { + var lower48 = d3.geo.albers(); + var alaska = d3.geo.conicEqualArea().rotate([ 154, 0 ]).center([ -2, 58.5 ]).parallels([ 55, 65 ]); + var hawaii = d3.geo.conicEqualArea().rotate([ 157, 0 ]).center([ -3, 19.9 ]).parallels([ 8, 18 ]); + var point, pointStream = { + point: function(x, y) { + point = [ x, y ]; + } + }, lower48Point, alaskaPoint, hawaiiPoint; + function albersUsa(coordinates) { + var x = coordinates[0], y = coordinates[1]; + point = null; + (lower48Point(x, y), point) || (alaskaPoint(x, y), point) || hawaiiPoint(x, y); + return point; + } + albersUsa.invert = function(coordinates) { + var k = lower48.scale(), t = lower48.translate(), x = (coordinates[0] - t[0]) / k, y = (coordinates[1] - t[1]) / k; + return (y >= .12 && y < .234 && x >= -.425 && x < -.214 ? alaska : y >= .166 && y < .234 && x >= -.214 && x < -.115 ? hawaii : lower48).invert(coordinates); + }; + albersUsa.stream = function(stream) { + var lower48Stream = lower48.stream(stream), alaskaStream = alaska.stream(stream), hawaiiStream = hawaii.stream(stream); + return { + point: function(x, y) { + lower48Stream.point(x, y); + alaskaStream.point(x, y); + hawaiiStream.point(x, y); + }, + sphere: function() { + lower48Stream.sphere(); + alaskaStream.sphere(); + hawaiiStream.sphere(); + }, + lineStart: function() { + lower48Stream.lineStart(); + alaskaStream.lineStart(); + hawaiiStream.lineStart(); + }, + lineEnd: function() { + lower48Stream.lineEnd(); + alaskaStream.lineEnd(); + hawaiiStream.lineEnd(); + }, + polygonStart: function() { + lower48Stream.polygonStart(); + alaskaStream.polygonStart(); + hawaiiStream.polygonStart(); + }, + polygonEnd: function() { + lower48Stream.polygonEnd(); + alaskaStream.polygonEnd(); + hawaiiStream.polygonEnd(); + } + }; + }; + albersUsa.precision = function(_) { + if (!arguments.length) return lower48.precision(); + lower48.precision(_); + alaska.precision(_); + hawaii.precision(_); + return albersUsa; + }; + albersUsa.scale = function(_) { + if (!arguments.length) return lower48.scale(); + lower48.scale(_); + alaska.scale(_ * .35); + hawaii.scale(_); + return albersUsa.translate(lower48.translate()); + }; + albersUsa.translate = function(_) { + if (!arguments.length) return lower48.translate(); + var k = lower48.scale(), x = +_[0], y = +_[1]; + lower48Point = lower48.translate(_).clipExtent([ [ x - .455 * k, y - .238 * k ], [ x + .455 * k, y + .238 * k ] ]).stream(pointStream).point; + alaskaPoint = alaska.translate([ x - .307 * k, y + .201 * k ]).clipExtent([ [ x - .425 * k + ε, y + .12 * k + ε ], [ x - .214 * k - ε, y + .234 * k - ε ] ]).stream(pointStream).point; + hawaiiPoint = hawaii.translate([ x - .205 * k, y + .212 * k ]).clipExtent([ [ x - .214 * k + ε, y + .166 * k + ε ], [ x - .115 * k - ε, y + .234 * k - ε ] ]).stream(pointStream).point; + return albersUsa; + }; + return albersUsa.scale(1070); + }; + var d3_geo_pathAreaSum, d3_geo_pathAreaPolygon, d3_geo_pathArea = { + point: d3_noop, + lineStart: d3_noop, + lineEnd: d3_noop, + polygonStart: function() { + d3_geo_pathAreaPolygon = 0; + d3_geo_pathArea.lineStart = d3_geo_pathAreaRingStart; + }, + polygonEnd: function() { + d3_geo_pathArea.lineStart = d3_geo_pathArea.lineEnd = d3_geo_pathArea.point = d3_noop; + d3_geo_pathAreaSum += abs(d3_geo_pathAreaPolygon / 2); + } + }; + function d3_geo_pathAreaRingStart() { + var x00, y00, x0, y0; + d3_geo_pathArea.point = function(x, y) { + d3_geo_pathArea.point = nextPoint; + x00 = x0 = x, y00 = y0 = y; + }; + function nextPoint(x, y) { + d3_geo_pathAreaPolygon += y0 * x - x0 * y; + x0 = x, y0 = y; + } + d3_geo_pathArea.lineEnd = function() { + nextPoint(x00, y00); + }; + } + var d3_geo_pathBoundsX0, d3_geo_pathBoundsY0, d3_geo_pathBoundsX1, d3_geo_pathBoundsY1; + var d3_geo_pathBounds = { + point: d3_geo_pathBoundsPoint, + lineStart: d3_noop, + lineEnd: d3_noop, + polygonStart: d3_noop, + polygonEnd: d3_noop + }; + function d3_geo_pathBoundsPoint(x, y) { + if (x < d3_geo_pathBoundsX0) d3_geo_pathBoundsX0 = x; + if (x > d3_geo_pathBoundsX1) d3_geo_pathBoundsX1 = x; + if (y < d3_geo_pathBoundsY0) d3_geo_pathBoundsY0 = y; + if (y > d3_geo_pathBoundsY1) d3_geo_pathBoundsY1 = y; + } + function d3_geo_pathBuffer() { + var pointCircle = d3_geo_pathBufferCircle(4.5), buffer = []; + var stream = { + point: point, + lineStart: function() { + stream.point = pointLineStart; + }, + lineEnd: lineEnd, + polygonStart: function() { + stream.lineEnd = lineEndPolygon; + }, + polygonEnd: function() { + stream.lineEnd = lineEnd; + stream.point = point; + }, + pointRadius: function(_) { + pointCircle = d3_geo_pathBufferCircle(_); + return stream; + }, + result: function() { + if (buffer.length) { + var result = buffer.join(""); + buffer = []; + return result; + } + } + }; + function point(x, y) { + buffer.push("M", x, ",", y, pointCircle); + } + function pointLineStart(x, y) { + buffer.push("M", x, ",", y); + stream.point = pointLine; + } + function pointLine(x, y) { + buffer.push("L", x, ",", y); + } + function lineEnd() { + stream.point = point; + } + function lineEndPolygon() { + buffer.push("Z"); + } + return stream; + } + function d3_geo_pathBufferCircle(radius) { + return "m0," + radius + "a" + radius + "," + radius + " 0 1,1 0," + -2 * radius + "a" + radius + "," + radius + " 0 1,1 0," + 2 * radius + "z"; + } + var d3_geo_pathCentroid = { + point: d3_geo_pathCentroidPoint, + lineStart: d3_geo_pathCentroidLineStart, + lineEnd: d3_geo_pathCentroidLineEnd, + polygonStart: function() { + d3_geo_pathCentroid.lineStart = d3_geo_pathCentroidRingStart; + }, + polygonEnd: function() { + d3_geo_pathCentroid.point = d3_geo_pathCentroidPoint; + d3_geo_pathCentroid.lineStart = d3_geo_pathCentroidLineStart; + d3_geo_pathCentroid.lineEnd = d3_geo_pathCentroidLineEnd; + } + }; + function d3_geo_pathCentroidPoint(x, y) { + d3_geo_centroidX0 += x; + d3_geo_centroidY0 += y; + ++d3_geo_centroidZ0; + } + function d3_geo_pathCentroidLineStart() { + var x0, y0; + d3_geo_pathCentroid.point = function(x, y) { + d3_geo_pathCentroid.point = nextPoint; + d3_geo_pathCentroidPoint(x0 = x, y0 = y); + }; + function nextPoint(x, y) { + var dx = x - x0, dy = y - y0, z = Math.sqrt(dx * dx + dy * dy); + d3_geo_centroidX1 += z * (x0 + x) / 2; + d3_geo_centroidY1 += z * (y0 + y) / 2; + d3_geo_centroidZ1 += z; + d3_geo_pathCentroidPoint(x0 = x, y0 = y); + } + } + function d3_geo_pathCentroidLineEnd() { + d3_geo_pathCentroid.point = d3_geo_pathCentroidPoint; + } + function d3_geo_pathCentroidRingStart() { + var x00, y00, x0, y0; + d3_geo_pathCentroid.point = function(x, y) { + d3_geo_pathCentroid.point = nextPoint; + d3_geo_pathCentroidPoint(x00 = x0 = x, y00 = y0 = y); + }; + function nextPoint(x, y) { + var dx = x - x0, dy = y - y0, z = Math.sqrt(dx * dx + dy * dy); + d3_geo_centroidX1 += z * (x0 + x) / 2; + d3_geo_centroidY1 += z * (y0 + y) / 2; + d3_geo_centroidZ1 += z; + z = y0 * x - x0 * y; + d3_geo_centroidX2 += z * (x0 + x); + d3_geo_centroidY2 += z * (y0 + y); + d3_geo_centroidZ2 += z * 3; + d3_geo_pathCentroidPoint(x0 = x, y0 = y); + } + d3_geo_pathCentroid.lineEnd = function() { + nextPoint(x00, y00); + }; + } + function d3_geo_pathContext(context) { + var pointRadius = 4.5; + var stream = { + point: point, + lineStart: function() { + stream.point = pointLineStart; + }, + lineEnd: lineEnd, + polygonStart: function() { + stream.lineEnd = lineEndPolygon; + }, + polygonEnd: function() { + stream.lineEnd = lineEnd; + stream.point = point; + }, + pointRadius: function(_) { + pointRadius = _; + return stream; + }, + result: d3_noop + }; + function point(x, y) { + context.moveTo(x + pointRadius, y); + context.arc(x, y, pointRadius, 0, τ); + } + function pointLineStart(x, y) { + context.moveTo(x, y); + stream.point = pointLine; + } + function pointLine(x, y) { + context.lineTo(x, y); + } + function lineEnd() { + stream.point = point; + } + function lineEndPolygon() { + context.closePath(); + } + return stream; + } + function d3_geo_resample(project) { + var δ2 = .5, cosMinDistance = Math.cos(30 * d3_radians), maxDepth = 16; + function resample(stream) { + return (maxDepth ? resampleRecursive : resampleNone)(stream); + } + function resampleNone(stream) { + return d3_geo_transformPoint(stream, function(x, y) { + x = project(x, y); + stream.point(x[0], x[1]); + }); + } + function resampleRecursive(stream) { + var λ00, φ00, x00, y00, a00, b00, c00, λ0, x0, y0, a0, b0, c0; + var resample = { + point: point, + lineStart: lineStart, + lineEnd: lineEnd, + polygonStart: function() { + stream.polygonStart(); + resample.lineStart = ringStart; + }, + polygonEnd: function() { + stream.polygonEnd(); + resample.lineStart = lineStart; + } + }; + function point(x, y) { + x = project(x, y); + stream.point(x[0], x[1]); + } + function lineStart() { + x0 = NaN; + resample.point = linePoint; + stream.lineStart(); + } + function linePoint(λ, φ) { + var c = d3_geo_cartesian([ λ, φ ]), p = project(λ, φ); + resampleLineTo(x0, y0, λ0, a0, b0, c0, x0 = p[0], y0 = p[1], λ0 = λ, a0 = c[0], b0 = c[1], c0 = c[2], maxDepth, stream); + stream.point(x0, y0); + } + function lineEnd() { + resample.point = point; + stream.lineEnd(); + } + function ringStart() { + lineStart(); + resample.point = ringPoint; + resample.lineEnd = ringEnd; + } + function ringPoint(λ, φ) { + linePoint(λ00 = λ, φ00 = φ), x00 = x0, y00 = y0, a00 = a0, b00 = b0, c00 = c0; + resample.point = linePoint; + } + function ringEnd() { + resampleLineTo(x0, y0, λ0, a0, b0, c0, x00, y00, λ00, a00, b00, c00, maxDepth, stream); + resample.lineEnd = lineEnd; + lineEnd(); + } + return resample; + } + function resampleLineTo(x0, y0, λ0, a0, b0, c0, x1, y1, λ1, a1, b1, c1, depth, stream) { + var dx = x1 - x0, dy = y1 - y0, d2 = dx * dx + dy * dy; + if (d2 > 4 * δ2 && depth--) { + var a = a0 + a1, b = b0 + b1, c = c0 + c1, m = Math.sqrt(a * a + b * b + c * c), φ2 = Math.asin(c /= m), λ2 = abs(abs(c) - 1) < ε || abs(λ0 - λ1) < ε ? (λ0 + λ1) / 2 : Math.atan2(b, a), p = project(λ2, φ2), x2 = p[0], y2 = p[1], dx2 = x2 - x0, dy2 = y2 - y0, dz = dy * dx2 - dx * dy2; + if (dz * dz / d2 > δ2 || abs((dx * dx2 + dy * dy2) / d2 - .5) > .3 || a0 * a1 + b0 * b1 + c0 * c1 < cosMinDistance) { + resampleLineTo(x0, y0, λ0, a0, b0, c0, x2, y2, λ2, a /= m, b /= m, c, depth, stream); + stream.point(x2, y2); + resampleLineTo(x2, y2, λ2, a, b, c, x1, y1, λ1, a1, b1, c1, depth, stream); + } + } + } + resample.precision = function(_) { + if (!arguments.length) return Math.sqrt(δ2); + maxDepth = (δ2 = _ * _) > 0 && 16; + return resample; + }; + return resample; + } + d3.geo.path = function() { + var pointRadius = 4.5, projection, context, projectStream, contextStream, cacheStream; + function path(object) { + if (object) { + if (typeof pointRadius === "function") contextStream.pointRadius(+pointRadius.apply(this, arguments)); + if (!cacheStream || !cacheStream.valid) cacheStream = projectStream(contextStream); + d3.geo.stream(object, cacheStream); + } + return contextStream.result(); + } + path.area = function(object) { + d3_geo_pathAreaSum = 0; + d3.geo.stream(object, projectStream(d3_geo_pathArea)); + return d3_geo_pathAreaSum; + }; + path.centroid = function(object) { + d3_geo_centroidX0 = d3_geo_centroidY0 = d3_geo_centroidZ0 = d3_geo_centroidX1 = d3_geo_centroidY1 = d3_geo_centroidZ1 = d3_geo_centroidX2 = d3_geo_centroidY2 = d3_geo_centroidZ2 = 0; + d3.geo.stream(object, projectStream(d3_geo_pathCentroid)); + return d3_geo_centroidZ2 ? [ d3_geo_centroidX2 / d3_geo_centroidZ2, d3_geo_centroidY2 / d3_geo_centroidZ2 ] : d3_geo_centroidZ1 ? [ d3_geo_centroidX1 / d3_geo_centroidZ1, d3_geo_centroidY1 / d3_geo_centroidZ1 ] : d3_geo_centroidZ0 ? [ d3_geo_centroidX0 / d3_geo_centroidZ0, d3_geo_centroidY0 / d3_geo_centroidZ0 ] : [ NaN, NaN ]; + }; + path.bounds = function(object) { + d3_geo_pathBoundsX1 = d3_geo_pathBoundsY1 = -(d3_geo_pathBoundsX0 = d3_geo_pathBoundsY0 = Infinity); + d3.geo.stream(object, projectStream(d3_geo_pathBounds)); + return [ [ d3_geo_pathBoundsX0, d3_geo_pathBoundsY0 ], [ d3_geo_pathBoundsX1, d3_geo_pathBoundsY1 ] ]; + }; + path.projection = function(_) { + if (!arguments.length) return projection; + projectStream = (projection = _) ? _.stream || d3_geo_pathProjectStream(_) : d3_identity; + return reset(); + }; + path.context = function(_) { + if (!arguments.length) return context; + contextStream = (context = _) == null ? new d3_geo_pathBuffer() : new d3_geo_pathContext(_); + if (typeof pointRadius !== "function") contextStream.pointRadius(pointRadius); + return reset(); + }; + path.pointRadius = function(_) { + if (!arguments.length) return pointRadius; + pointRadius = typeof _ === "function" ? _ : (contextStream.pointRadius(+_), +_); + return path; + }; + function reset() { + cacheStream = null; + return path; + } + return path.projection(d3.geo.albersUsa()).context(null); + }; + function d3_geo_pathProjectStream(project) { + var resample = d3_geo_resample(function(x, y) { + return project([ x * d3_degrees, y * d3_degrees ]); + }); + return function(stream) { + return d3_geo_projectionRadians(resample(stream)); + }; + } + d3.geo.transform = function(methods) { + return { + stream: function(stream) { + var transform = new d3_geo_transform(stream); + for (var k in methods) transform[k] = methods[k]; + return transform; + } + }; + }; + function d3_geo_transform(stream) { + this.stream = stream; + } + d3_geo_transform.prototype = { + point: function(x, y) { + this.stream.point(x, y); + }, + sphere: function() { + this.stream.sphere(); + }, + lineStart: function() { + this.stream.lineStart(); + }, + lineEnd: function() { + this.stream.lineEnd(); + }, + polygonStart: function() { + this.stream.polygonStart(); + }, + polygonEnd: function() { + this.stream.polygonEnd(); + } + }; + function d3_geo_transformPoint(stream, point) { + return { + point: point, + sphere: function() { + stream.sphere(); + }, + lineStart: function() { + stream.lineStart(); + }, + lineEnd: function() { + stream.lineEnd(); + }, + polygonStart: function() { + stream.polygonStart(); + }, + polygonEnd: function() { + stream.polygonEnd(); + } + }; + } + d3.geo.projection = d3_geo_projection; + d3.geo.projectionMutator = d3_geo_projectionMutator; + function d3_geo_projection(project) { + return d3_geo_projectionMutator(function() { + return project; + })(); + } + function d3_geo_projectionMutator(projectAt) { + var project, rotate, projectRotate, projectResample = d3_geo_resample(function(x, y) { + x = project(x, y); + return [ x[0] * k + δx, δy - x[1] * k ]; + }), k = 150, x = 480, y = 250, λ = 0, φ = 0, δλ = 0, δφ = 0, δγ = 0, δx, δy, preclip = d3_geo_clipAntimeridian, postclip = d3_identity, clipAngle = null, clipExtent = null, stream; + function projection(point) { + point = projectRotate(point[0] * d3_radians, point[1] * d3_radians); + return [ point[0] * k + δx, δy - point[1] * k ]; + } + function invert(point) { + point = projectRotate.invert((point[0] - δx) / k, (δy - point[1]) / k); + return point && [ point[0] * d3_degrees, point[1] * d3_degrees ]; + } + projection.stream = function(output) { + if (stream) stream.valid = false; + stream = d3_geo_projectionRadians(preclip(rotate, projectResample(postclip(output)))); + stream.valid = true; + return stream; + }; + projection.clipAngle = function(_) { + if (!arguments.length) return clipAngle; + preclip = _ == null ? (clipAngle = _, d3_geo_clipAntimeridian) : d3_geo_clipCircle((clipAngle = +_) * d3_radians); + return invalidate(); + }; + projection.clipExtent = function(_) { + if (!arguments.length) return clipExtent; + clipExtent = _; + postclip = _ ? d3_geo_clipExtent(_[0][0], _[0][1], _[1][0], _[1][1]) : d3_identity; + return invalidate(); + }; + projection.scale = function(_) { + if (!arguments.length) return k; + k = +_; + return reset(); + }; + projection.translate = function(_) { + if (!arguments.length) return [ x, y ]; + x = +_[0]; + y = +_[1]; + return reset(); + }; + projection.center = function(_) { + if (!arguments.length) return [ λ * d3_degrees, φ * d3_degrees ]; + λ = _[0] % 360 * d3_radians; + φ = _[1] % 360 * d3_radians; + return reset(); + }; + projection.rotate = function(_) { + if (!arguments.length) return [ δλ * d3_degrees, δφ * d3_degrees, δγ * d3_degrees ]; + δλ = _[0] % 360 * d3_radians; + δφ = _[1] % 360 * d3_radians; + δγ = _.length > 2 ? _[2] % 360 * d3_radians : 0; + return reset(); + }; + d3.rebind(projection, projectResample, "precision"); + function reset() { + projectRotate = d3_geo_compose(rotate = d3_geo_rotation(δλ, δφ, δγ), project); + var center = project(λ, φ); + δx = x - center[0] * k; + δy = y + center[1] * k; + return invalidate(); + } + function invalidate() { + if (stream) stream.valid = false, stream = null; + return projection; + } + return function() { + project = projectAt.apply(this, arguments); + projection.invert = project.invert && invert; + return reset(); + }; + } + function d3_geo_projectionRadians(stream) { + return d3_geo_transformPoint(stream, function(x, y) { + stream.point(x * d3_radians, y * d3_radians); + }); + } + function d3_geo_equirectangular(λ, φ) { + return [ λ, φ ]; + } + (d3.geo.equirectangular = function() { + return d3_geo_projection(d3_geo_equirectangular); + }).raw = d3_geo_equirectangular.invert = d3_geo_equirectangular; + d3.geo.rotation = function(rotate) { + rotate = d3_geo_rotation(rotate[0] % 360 * d3_radians, rotate[1] * d3_radians, rotate.length > 2 ? rotate[2] * d3_radians : 0); + function forward(coordinates) { + coordinates = rotate(coordinates[0] * d3_radians, coordinates[1] * d3_radians); + return coordinates[0] *= d3_degrees, coordinates[1] *= d3_degrees, coordinates; + } + forward.invert = function(coordinates) { + coordinates = rotate.invert(coordinates[0] * d3_radians, coordinates[1] * d3_radians); + return coordinates[0] *= d3_degrees, coordinates[1] *= d3_degrees, coordinates; + }; + return forward; + }; + function d3_geo_identityRotation(λ, φ) { + return [ λ > π ? λ - τ : λ < -π ? λ + τ : λ, φ ]; + } + d3_geo_identityRotation.invert = d3_geo_equirectangular; + function d3_geo_rotation(δλ, δφ, δγ) { + return δλ ? δφ || δγ ? d3_geo_compose(d3_geo_rotationλ(δλ), d3_geo_rotationφγ(δφ, δγ)) : d3_geo_rotationλ(δλ) : δφ || δγ ? d3_geo_rotationφγ(δφ, δγ) : d3_geo_identityRotation; + } + function d3_geo_forwardRotationλ(δλ) { + return function(λ, φ) { + return λ += δλ, [ λ > π ? λ - τ : λ < -π ? λ + τ : λ, φ ]; + }; + } + function d3_geo_rotationλ(δλ) { + var rotation = d3_geo_forwardRotationλ(δλ); + rotation.invert = d3_geo_forwardRotationλ(-δλ); + return rotation; + } + function d3_geo_rotationφγ(δφ, δγ) { + var cosδφ = Math.cos(δφ), sinδφ = Math.sin(δφ), cosδγ = Math.cos(δγ), sinδγ = Math.sin(δγ); + function rotation(λ, φ) { + var cosφ = Math.cos(φ), x = Math.cos(λ) * cosφ, y = Math.sin(λ) * cosφ, z = Math.sin(φ), k = z * cosδφ + x * sinδφ; + return [ Math.atan2(y * cosδγ - k * sinδγ, x * cosδφ - z * sinδφ), d3_asin(k * cosδγ + y * sinδγ) ]; + } + rotation.invert = function(λ, φ) { + var cosφ = Math.cos(φ), x = Math.cos(λ) * cosφ, y = Math.sin(λ) * cosφ, z = Math.sin(φ), k = z * cosδγ - y * sinδγ; + return [ Math.atan2(y * cosδγ + z * sinδγ, x * cosδφ + k * sinδφ), d3_asin(k * cosδφ - x * sinδφ) ]; + }; + return rotation; + } + d3.geo.circle = function() { + var origin = [ 0, 0 ], angle, precision = 6, interpolate; + function circle() { + var center = typeof origin === "function" ? origin.apply(this, arguments) : origin, rotate = d3_geo_rotation(-center[0] * d3_radians, -center[1] * d3_radians, 0).invert, ring = []; + interpolate(null, null, 1, { + point: function(x, y) { + ring.push(x = rotate(x, y)); + x[0] *= d3_degrees, x[1] *= d3_degrees; + } + }); + return { + type: "Polygon", + coordinates: [ ring ] + }; + } + circle.origin = function(x) { + if (!arguments.length) return origin; + origin = x; + return circle; + }; + circle.angle = function(x) { + if (!arguments.length) return angle; + interpolate = d3_geo_circleInterpolate((angle = +x) * d3_radians, precision * d3_radians); + return circle; + }; + circle.precision = function(_) { + if (!arguments.length) return precision; + interpolate = d3_geo_circleInterpolate(angle * d3_radians, (precision = +_) * d3_radians); + return circle; + }; + return circle.angle(90); + }; + function d3_geo_circleInterpolate(radius, precision) { + var cr = Math.cos(radius), sr = Math.sin(radius); + return function(from, to, direction, listener) { + var step = direction * precision; + if (from != null) { + from = d3_geo_circleAngle(cr, from); + to = d3_geo_circleAngle(cr, to); + if (direction > 0 ? from < to : from > to) from += direction * τ; + } else { + from = radius + direction * τ; + to = radius - .5 * step; + } + for (var point, t = from; direction > 0 ? t > to : t < to; t -= step) { + listener.point((point = d3_geo_spherical([ cr, -sr * Math.cos(t), -sr * Math.sin(t) ]))[0], point[1]); + } + }; + } + function d3_geo_circleAngle(cr, point) { + var a = d3_geo_cartesian(point); + a[0] -= cr; + d3_geo_cartesianNormalize(a); + var angle = d3_acos(-a[1]); + return ((-a[2] < 0 ? -angle : angle) + 2 * Math.PI - ε) % (2 * Math.PI); + } + d3.geo.distance = function(a, b) { + var Δλ = (b[0] - a[0]) * d3_radians, φ0 = a[1] * d3_radians, φ1 = b[1] * d3_radians, sinΔλ = Math.sin(Δλ), cosΔλ = Math.cos(Δλ), sinφ0 = Math.sin(φ0), cosφ0 = Math.cos(φ0), sinφ1 = Math.sin(φ1), cosφ1 = Math.cos(φ1), t; + return Math.atan2(Math.sqrt((t = cosφ1 * sinΔλ) * t + (t = cosφ0 * sinφ1 - sinφ0 * cosφ1 * cosΔλ) * t), sinφ0 * sinφ1 + cosφ0 * cosφ1 * cosΔλ); + }; + d3.geo.graticule = function() { + var x1, x0, X1, X0, y1, y0, Y1, Y0, dx = 10, dy = dx, DX = 90, DY = 360, x, y, X, Y, precision = 2.5; + function graticule() { + return { + type: "MultiLineString", + coordinates: lines() + }; + } + function lines() { + return d3.range(Math.ceil(X0 / DX) * DX, X1, DX).map(X).concat(d3.range(Math.ceil(Y0 / DY) * DY, Y1, DY).map(Y)).concat(d3.range(Math.ceil(x0 / dx) * dx, x1, dx).filter(function(x) { + return abs(x % DX) > ε; + }).map(x)).concat(d3.range(Math.ceil(y0 / dy) * dy, y1, dy).filter(function(y) { + return abs(y % DY) > ε; + }).map(y)); + } + graticule.lines = function() { + return lines().map(function(coordinates) { + return { + type: "LineString", + coordinates: coordinates + }; + }); + }; + graticule.outline = function() { + return { + type: "Polygon", + coordinates: [ X(X0).concat(Y(Y1).slice(1), X(X1).reverse().slice(1), Y(Y0).reverse().slice(1)) ] + }; + }; + graticule.extent = function(_) { + if (!arguments.length) return graticule.minorExtent(); + return graticule.majorExtent(_).minorExtent(_); + }; + graticule.majorExtent = function(_) { + if (!arguments.length) return [ [ X0, Y0 ], [ X1, Y1 ] ]; + X0 = +_[0][0], X1 = +_[1][0]; + Y0 = +_[0][1], Y1 = +_[1][1]; + if (X0 > X1) _ = X0, X0 = X1, X1 = _; + if (Y0 > Y1) _ = Y0, Y0 = Y1, Y1 = _; + return graticule.precision(precision); + }; + graticule.minorExtent = function(_) { + if (!arguments.length) return [ [ x0, y0 ], [ x1, y1 ] ]; + x0 = +_[0][0], x1 = +_[1][0]; + y0 = +_[0][1], y1 = +_[1][1]; + if (x0 > x1) _ = x0, x0 = x1, x1 = _; + if (y0 > y1) _ = y0, y0 = y1, y1 = _; + return graticule.precision(precision); + }; + graticule.step = function(_) { + if (!arguments.length) return graticule.minorStep(); + return graticule.majorStep(_).minorStep(_); + }; + graticule.majorStep = function(_) { + if (!arguments.length) return [ DX, DY ]; + DX = +_[0], DY = +_[1]; + return graticule; + }; + graticule.minorStep = function(_) { + if (!arguments.length) return [ dx, dy ]; + dx = +_[0], dy = +_[1]; + return graticule; + }; + graticule.precision = function(_) { + if (!arguments.length) return precision; + precision = +_; + x = d3_geo_graticuleX(y0, y1, 90); + y = d3_geo_graticuleY(x0, x1, precision); + X = d3_geo_graticuleX(Y0, Y1, 90); + Y = d3_geo_graticuleY(X0, X1, precision); + return graticule; + }; + return graticule.majorExtent([ [ -180, -90 + ε ], [ 180, 90 - ε ] ]).minorExtent([ [ -180, -80 - ε ], [ 180, 80 + ε ] ]); + }; + function d3_geo_graticuleX(y0, y1, dy) { + var y = d3.range(y0, y1 - ε, dy).concat(y1); + return function(x) { + return y.map(function(y) { + return [ x, y ]; + }); + }; + } + function d3_geo_graticuleY(x0, x1, dx) { + var x = d3.range(x0, x1 - ε, dx).concat(x1); + return function(y) { + return x.map(function(x) { + return [ x, y ]; + }); + }; + } + function d3_source(d) { + return d.source; + } + function d3_target(d) { + return d.target; + } + d3.geo.greatArc = function() { + var source = d3_source, source_, target = d3_target, target_; + function greatArc() { + return { + type: "LineString", + coordinates: [ source_ || source.apply(this, arguments), target_ || target.apply(this, arguments) ] + }; + } + greatArc.distance = function() { + return d3.geo.distance(source_ || source.apply(this, arguments), target_ || target.apply(this, arguments)); + }; + greatArc.source = function(_) { + if (!arguments.length) return source; + source = _, source_ = typeof _ === "function" ? null : _; + return greatArc; + }; + greatArc.target = function(_) { + if (!arguments.length) return target; + target = _, target_ = typeof _ === "function" ? null : _; + return greatArc; + }; + greatArc.precision = function() { + return arguments.length ? greatArc : 0; + }; + return greatArc; + }; + d3.geo.interpolate = function(source, target) { + return d3_geo_interpolate(source[0] * d3_radians, source[1] * d3_radians, target[0] * d3_radians, target[1] * d3_radians); + }; + function d3_geo_interpolate(x0, y0, x1, y1) { + var cy0 = Math.cos(y0), sy0 = Math.sin(y0), cy1 = Math.cos(y1), sy1 = Math.sin(y1), kx0 = cy0 * Math.cos(x0), ky0 = cy0 * Math.sin(x0), kx1 = cy1 * Math.cos(x1), ky1 = cy1 * Math.sin(x1), d = 2 * Math.asin(Math.sqrt(d3_haversin(y1 - y0) + cy0 * cy1 * d3_haversin(x1 - x0))), k = 1 / Math.sin(d); + var interpolate = d ? function(t) { + var B = Math.sin(t *= d) * k, A = Math.sin(d - t) * k, x = A * kx0 + B * kx1, y = A * ky0 + B * ky1, z = A * sy0 + B * sy1; + return [ Math.atan2(y, x) * d3_degrees, Math.atan2(z, Math.sqrt(x * x + y * y)) * d3_degrees ]; + } : function() { + return [ x0 * d3_degrees, y0 * d3_degrees ]; + }; + interpolate.distance = d; + return interpolate; + } + d3.geo.length = function(object) { + d3_geo_lengthSum = 0; + d3.geo.stream(object, d3_geo_length); + return d3_geo_lengthSum; + }; + var d3_geo_lengthSum; + var d3_geo_length = { + sphere: d3_noop, + point: d3_noop, + lineStart: d3_geo_lengthLineStart, + lineEnd: d3_noop, + polygonStart: d3_noop, + polygonEnd: d3_noop + }; + function d3_geo_lengthLineStart() { + var λ0, sinφ0, cosφ0; + d3_geo_length.point = function(λ, φ) { + λ0 = λ * d3_radians, sinφ0 = Math.sin(φ *= d3_radians), cosφ0 = Math.cos(φ); + d3_geo_length.point = nextPoint; + }; + d3_geo_length.lineEnd = function() { + d3_geo_length.point = d3_geo_length.lineEnd = d3_noop; + }; + function nextPoint(λ, φ) { + var sinφ = Math.sin(φ *= d3_radians), cosφ = Math.cos(φ), t = abs((λ *= d3_radians) - λ0), cosΔλ = Math.cos(t); + d3_geo_lengthSum += Math.atan2(Math.sqrt((t = cosφ * Math.sin(t)) * t + (t = cosφ0 * sinφ - sinφ0 * cosφ * cosΔλ) * t), sinφ0 * sinφ + cosφ0 * cosφ * cosΔλ); + λ0 = λ, sinφ0 = sinφ, cosφ0 = cosφ; + } + } + function d3_geo_azimuthal(scale, angle) { + function azimuthal(λ, φ) { + var cosλ = Math.cos(λ), cosφ = Math.cos(φ), k = scale(cosλ * cosφ); + return [ k * cosφ * Math.sin(λ), k * Math.sin(φ) ]; + } + azimuthal.invert = function(x, y) { + var ρ = Math.sqrt(x * x + y * y), c = angle(ρ), sinc = Math.sin(c), cosc = Math.cos(c); + return [ Math.atan2(x * sinc, ρ * cosc), Math.asin(ρ && y * sinc / ρ) ]; + }; + return azimuthal; + } + var d3_geo_azimuthalEqualArea = d3_geo_azimuthal(function(cosλcosφ) { + return Math.sqrt(2 / (1 + cosλcosφ)); + }, function(ρ) { + return 2 * Math.asin(ρ / 2); + }); + (d3.geo.azimuthalEqualArea = function() { + return d3_geo_projection(d3_geo_azimuthalEqualArea); + }).raw = d3_geo_azimuthalEqualArea; + var d3_geo_azimuthalEquidistant = d3_geo_azimuthal(function(cosλcosφ) { + var c = Math.acos(cosλcosφ); + return c && c / Math.sin(c); + }, d3_identity); + (d3.geo.azimuthalEquidistant = function() { + return d3_geo_projection(d3_geo_azimuthalEquidistant); + }).raw = d3_geo_azimuthalEquidistant; + function d3_geo_conicConformal(φ0, φ1) { + var cosφ0 = Math.cos(φ0), t = function(φ) { + return Math.tan(π / 4 + φ / 2); + }, n = φ0 === φ1 ? Math.sin(φ0) : Math.log(cosφ0 / Math.cos(φ1)) / Math.log(t(φ1) / t(φ0)), F = cosφ0 * Math.pow(t(φ0), n) / n; + if (!n) return d3_geo_mercator; + function forward(λ, φ) { + if (F > 0) { + if (φ < -halfπ + ε) φ = -halfπ + ε; + } else { + if (φ > halfπ - ε) φ = halfπ - ε; + } + var ρ = F / Math.pow(t(φ), n); + return [ ρ * Math.sin(n * λ), F - ρ * Math.cos(n * λ) ]; + } + forward.invert = function(x, y) { + var ρ0_y = F - y, ρ = d3_sgn(n) * Math.sqrt(x * x + ρ0_y * ρ0_y); + return [ Math.atan2(x, ρ0_y) / n, 2 * Math.atan(Math.pow(F / ρ, 1 / n)) - halfπ ]; + }; + return forward; + } + (d3.geo.conicConformal = function() { + return d3_geo_conic(d3_geo_conicConformal); + }).raw = d3_geo_conicConformal; + function d3_geo_conicEquidistant(φ0, φ1) { + var cosφ0 = Math.cos(φ0), n = φ0 === φ1 ? Math.sin(φ0) : (cosφ0 - Math.cos(φ1)) / (φ1 - φ0), G = cosφ0 / n + φ0; + if (abs(n) < ε) return d3_geo_equirectangular; + function forward(λ, φ) { + var ρ = G - φ; + return [ ρ * Math.sin(n * λ), G - ρ * Math.cos(n * λ) ]; + } + forward.invert = function(x, y) { + var ρ0_y = G - y; + return [ Math.atan2(x, ρ0_y) / n, G - d3_sgn(n) * Math.sqrt(x * x + ρ0_y * ρ0_y) ]; + }; + return forward; + } + (d3.geo.conicEquidistant = function() { + return d3_geo_conic(d3_geo_conicEquidistant); + }).raw = d3_geo_conicEquidistant; + var d3_geo_gnomonic = d3_geo_azimuthal(function(cosλcosφ) { + return 1 / cosλcosφ; + }, Math.atan); + (d3.geo.gnomonic = function() { + return d3_geo_projection(d3_geo_gnomonic); + }).raw = d3_geo_gnomonic; + function d3_geo_mercator(λ, φ) { + return [ λ, Math.log(Math.tan(π / 4 + φ / 2)) ]; + } + d3_geo_mercator.invert = function(x, y) { + return [ x, 2 * Math.atan(Math.exp(y)) - halfπ ]; + }; + function d3_geo_mercatorProjection(project) { + var m = d3_geo_projection(project), scale = m.scale, translate = m.translate, clipExtent = m.clipExtent, clipAuto; + m.scale = function() { + var v = scale.apply(m, arguments); + return v === m ? clipAuto ? m.clipExtent(null) : m : v; + }; + m.translate = function() { + var v = translate.apply(m, arguments); + return v === m ? clipAuto ? m.clipExtent(null) : m : v; + }; + m.clipExtent = function(_) { + var v = clipExtent.apply(m, arguments); + if (v === m) { + if (clipAuto = _ == null) { + var k = π * scale(), t = translate(); + clipExtent([ [ t[0] - k, t[1] - k ], [ t[0] + k, t[1] + k ] ]); + } + } else if (clipAuto) { + v = null; + } + return v; + }; + return m.clipExtent(null); + } + (d3.geo.mercator = function() { + return d3_geo_mercatorProjection(d3_geo_mercator); + }).raw = d3_geo_mercator; + var d3_geo_orthographic = d3_geo_azimuthal(function() { + return 1; + }, Math.asin); + (d3.geo.orthographic = function() { + return d3_geo_projection(d3_geo_orthographic); + }).raw = d3_geo_orthographic; + var d3_geo_stereographic = d3_geo_azimuthal(function(cosλcosφ) { + return 1 / (1 + cosλcosφ); + }, function(ρ) { + return 2 * Math.atan(ρ); + }); + (d3.geo.stereographic = function() { + return d3_geo_projection(d3_geo_stereographic); + }).raw = d3_geo_stereographic; + function d3_geo_transverseMercator(λ, φ) { + return [ Math.log(Math.tan(π / 4 + φ / 2)), -λ ]; + } + d3_geo_transverseMercator.invert = function(x, y) { + return [ -y, 2 * Math.atan(Math.exp(x)) - halfπ ]; + }; + (d3.geo.transverseMercator = function() { + var projection = d3_geo_mercatorProjection(d3_geo_transverseMercator), center = projection.center, rotate = projection.rotate; + projection.center = function(_) { + return _ ? center([ -_[1], _[0] ]) : (_ = center(), [ _[1], -_[0] ]); + }; + projection.rotate = function(_) { + return _ ? rotate([ _[0], _[1], _.length > 2 ? _[2] + 90 : 90 ]) : (_ = rotate(), + [ _[0], _[1], _[2] - 90 ]); + }; + return rotate([ 0, 0, 90 ]); + }).raw = d3_geo_transverseMercator; + d3.geom = {}; + function d3_geom_pointX(d) { + return d[0]; + } + function d3_geom_pointY(d) { + return d[1]; + } + d3.geom.hull = function(vertices) { + var x = d3_geom_pointX, y = d3_geom_pointY; + if (arguments.length) return hull(vertices); + function hull(data) { + if (data.length < 3) return []; + var fx = d3_functor(x), fy = d3_functor(y), i, n = data.length, points = [], flippedPoints = []; + for (i = 0; i < n; i++) { + points.push([ +fx.call(this, data[i], i), +fy.call(this, data[i], i), i ]); + } + points.sort(d3_geom_hullOrder); + for (i = 0; i < n; i++) flippedPoints.push([ points[i][0], -points[i][1] ]); + var upper = d3_geom_hullUpper(points), lower = d3_geom_hullUpper(flippedPoints); + var skipLeft = lower[0] === upper[0], skipRight = lower[lower.length - 1] === upper[upper.length - 1], polygon = []; + for (i = upper.length - 1; i >= 0; --i) polygon.push(data[points[upper[i]][2]]); + for (i = +skipLeft; i < lower.length - skipRight; ++i) polygon.push(data[points[lower[i]][2]]); + return polygon; + } + hull.x = function(_) { + return arguments.length ? (x = _, hull) : x; + }; + hull.y = function(_) { + return arguments.length ? (y = _, hull) : y; + }; + return hull; + }; + function d3_geom_hullUpper(points) { + var n = points.length, hull = [ 0, 1 ], hs = 2; + for (var i = 2; i < n; i++) { + while (hs > 1 && d3_cross2d(points[hull[hs - 2]], points[hull[hs - 1]], points[i]) <= 0) --hs; + hull[hs++] = i; + } + return hull.slice(0, hs); + } + function d3_geom_hullOrder(a, b) { + return a[0] - b[0] || a[1] - b[1]; + } + d3.geom.polygon = function(coordinates) { + d3_subclass(coordinates, d3_geom_polygonPrototype); + return coordinates; + }; + var d3_geom_polygonPrototype = d3.geom.polygon.prototype = []; + d3_geom_polygonPrototype.area = function() { + var i = -1, n = this.length, a, b = this[n - 1], area = 0; + while (++i < n) { + a = b; + b = this[i]; + area += a[1] * b[0] - a[0] * b[1]; + } + return area * .5; + }; + d3_geom_polygonPrototype.centroid = function(k) { + var i = -1, n = this.length, x = 0, y = 0, a, b = this[n - 1], c; + if (!arguments.length) k = -1 / (6 * this.area()); + while (++i < n) { + a = b; + b = this[i]; + c = a[0] * b[1] - b[0] * a[1]; + x += (a[0] + b[0]) * c; + y += (a[1] + b[1]) * c; + } + return [ x * k, y * k ]; + }; + d3_geom_polygonPrototype.clip = function(subject) { + var input, closed = d3_geom_polygonClosed(subject), i = -1, n = this.length - d3_geom_polygonClosed(this), j, m, a = this[n - 1], b, c, d; + while (++i < n) { + input = subject.slice(); + subject.length = 0; + b = this[i]; + c = input[(m = input.length - closed) - 1]; + j = -1; + while (++j < m) { + d = input[j]; + if (d3_geom_polygonInside(d, a, b)) { + if (!d3_geom_polygonInside(c, a, b)) { + subject.push(d3_geom_polygonIntersect(c, d, a, b)); + } + subject.push(d); + } else if (d3_geom_polygonInside(c, a, b)) { + subject.push(d3_geom_polygonIntersect(c, d, a, b)); + } + c = d; + } + if (closed) subject.push(subject[0]); + a = b; + } + return subject; + }; + function d3_geom_polygonInside(p, a, b) { + return (b[0] - a[0]) * (p[1] - a[1]) < (b[1] - a[1]) * (p[0] - a[0]); + } + function d3_geom_polygonIntersect(c, d, a, b) { + var x1 = c[0], x3 = a[0], x21 = d[0] - x1, x43 = b[0] - x3, y1 = c[1], y3 = a[1], y21 = d[1] - y1, y43 = b[1] - y3, ua = (x43 * (y1 - y3) - y43 * (x1 - x3)) / (y43 * x21 - x43 * y21); + return [ x1 + ua * x21, y1 + ua * y21 ]; + } + function d3_geom_polygonClosed(coordinates) { + var a = coordinates[0], b = coordinates[coordinates.length - 1]; + return !(a[0] - b[0] || a[1] - b[1]); + } + var d3_geom_voronoiEdges, d3_geom_voronoiCells, d3_geom_voronoiBeaches, d3_geom_voronoiBeachPool = [], d3_geom_voronoiFirstCircle, d3_geom_voronoiCircles, d3_geom_voronoiCirclePool = []; + function d3_geom_voronoiBeach() { + d3_geom_voronoiRedBlackNode(this); + this.edge = this.site = this.circle = null; + } + function d3_geom_voronoiCreateBeach(site) { + var beach = d3_geom_voronoiBeachPool.pop() || new d3_geom_voronoiBeach(); + beach.site = site; + return beach; + } + function d3_geom_voronoiDetachBeach(beach) { + d3_geom_voronoiDetachCircle(beach); + d3_geom_voronoiBeaches.remove(beach); + d3_geom_voronoiBeachPool.push(beach); + d3_geom_voronoiRedBlackNode(beach); + } + function d3_geom_voronoiRemoveBeach(beach) { + var circle = beach.circle, x = circle.x, y = circle.cy, vertex = { + x: x, + y: y + }, previous = beach.P, next = beach.N, disappearing = [ beach ]; + d3_geom_voronoiDetachBeach(beach); + var lArc = previous; + while (lArc.circle && abs(x - lArc.circle.x) < ε && abs(y - lArc.circle.cy) < ε) { + previous = lArc.P; + disappearing.unshift(lArc); + d3_geom_voronoiDetachBeach(lArc); + lArc = previous; + } + disappearing.unshift(lArc); + d3_geom_voronoiDetachCircle(lArc); + var rArc = next; + while (rArc.circle && abs(x - rArc.circle.x) < ε && abs(y - rArc.circle.cy) < ε) { + next = rArc.N; + disappearing.push(rArc); + d3_geom_voronoiDetachBeach(rArc); + rArc = next; + } + disappearing.push(rArc); + d3_geom_voronoiDetachCircle(rArc); + var nArcs = disappearing.length, iArc; + for (iArc = 1; iArc < nArcs; ++iArc) { + rArc = disappearing[iArc]; + lArc = disappearing[iArc - 1]; + d3_geom_voronoiSetEdgeEnd(rArc.edge, lArc.site, rArc.site, vertex); + } + lArc = disappearing[0]; + rArc = disappearing[nArcs - 1]; + rArc.edge = d3_geom_voronoiCreateEdge(lArc.site, rArc.site, null, vertex); + d3_geom_voronoiAttachCircle(lArc); + d3_geom_voronoiAttachCircle(rArc); + } + function d3_geom_voronoiAddBeach(site) { + var x = site.x, directrix = site.y, lArc, rArc, dxl, dxr, node = d3_geom_voronoiBeaches._; + while (node) { + dxl = d3_geom_voronoiLeftBreakPoint(node, directrix) - x; + if (dxl > ε) node = node.L; else { + dxr = x - d3_geom_voronoiRightBreakPoint(node, directrix); + if (dxr > ε) { + if (!node.R) { + lArc = node; + break; + } + node = node.R; + } else { + if (dxl > -ε) { + lArc = node.P; + rArc = node; + } else if (dxr > -ε) { + lArc = node; + rArc = node.N; + } else { + lArc = rArc = node; + } + break; + } + } + } + var newArc = d3_geom_voronoiCreateBeach(site); + d3_geom_voronoiBeaches.insert(lArc, newArc); + if (!lArc && !rArc) return; + if (lArc === rArc) { + d3_geom_voronoiDetachCircle(lArc); + rArc = d3_geom_voronoiCreateBeach(lArc.site); + d3_geom_voronoiBeaches.insert(newArc, rArc); + newArc.edge = rArc.edge = d3_geom_voronoiCreateEdge(lArc.site, newArc.site); + d3_geom_voronoiAttachCircle(lArc); + d3_geom_voronoiAttachCircle(rArc); + return; + } + if (!rArc) { + newArc.edge = d3_geom_voronoiCreateEdge(lArc.site, newArc.site); + return; + } + d3_geom_voronoiDetachCircle(lArc); + d3_geom_voronoiDetachCircle(rArc); + var lSite = lArc.site, ax = lSite.x, ay = lSite.y, bx = site.x - ax, by = site.y - ay, rSite = rArc.site, cx = rSite.x - ax, cy = rSite.y - ay, d = 2 * (bx * cy - by * cx), hb = bx * bx + by * by, hc = cx * cx + cy * cy, vertex = { + x: (cy * hb - by * hc) / d + ax, + y: (bx * hc - cx * hb) / d + ay + }; + d3_geom_voronoiSetEdgeEnd(rArc.edge, lSite, rSite, vertex); + newArc.edge = d3_geom_voronoiCreateEdge(lSite, site, null, vertex); + rArc.edge = d3_geom_voronoiCreateEdge(site, rSite, null, vertex); + d3_geom_voronoiAttachCircle(lArc); + d3_geom_voronoiAttachCircle(rArc); + } + function d3_geom_voronoiLeftBreakPoint(arc, directrix) { + var site = arc.site, rfocx = site.x, rfocy = site.y, pby2 = rfocy - directrix; + if (!pby2) return rfocx; + var lArc = arc.P; + if (!lArc) return -Infinity; + site = lArc.site; + var lfocx = site.x, lfocy = site.y, plby2 = lfocy - directrix; + if (!plby2) return lfocx; + var hl = lfocx - rfocx, aby2 = 1 / pby2 - 1 / plby2, b = hl / plby2; + if (aby2) return (-b + Math.sqrt(b * b - 2 * aby2 * (hl * hl / (-2 * plby2) - lfocy + plby2 / 2 + rfocy - pby2 / 2))) / aby2 + rfocx; + return (rfocx + lfocx) / 2; + } + function d3_geom_voronoiRightBreakPoint(arc, directrix) { + var rArc = arc.N; + if (rArc) return d3_geom_voronoiLeftBreakPoint(rArc, directrix); + var site = arc.site; + return site.y === directrix ? site.x : Infinity; + } + function d3_geom_voronoiCell(site) { + this.site = site; + this.edges = []; + } + d3_geom_voronoiCell.prototype.prepare = function() { + var halfEdges = this.edges, iHalfEdge = halfEdges.length, edge; + while (iHalfEdge--) { + edge = halfEdges[iHalfEdge].edge; + if (!edge.b || !edge.a) halfEdges.splice(iHalfEdge, 1); + } + halfEdges.sort(d3_geom_voronoiHalfEdgeOrder); + return halfEdges.length; + }; + function d3_geom_voronoiCloseCells(extent) { + var x0 = extent[0][0], x1 = extent[1][0], y0 = extent[0][1], y1 = extent[1][1], x2, y2, x3, y3, cells = d3_geom_voronoiCells, iCell = cells.length, cell, iHalfEdge, halfEdges, nHalfEdges, start, end; + while (iCell--) { + cell = cells[iCell]; + if (!cell || !cell.prepare()) continue; + halfEdges = cell.edges; + nHalfEdges = halfEdges.length; + iHalfEdge = 0; + while (iHalfEdge < nHalfEdges) { + end = halfEdges[iHalfEdge].end(), x3 = end.x, y3 = end.y; + start = halfEdges[++iHalfEdge % nHalfEdges].start(), x2 = start.x, y2 = start.y; + if (abs(x3 - x2) > ε || abs(y3 - y2) > ε) { + halfEdges.splice(iHalfEdge, 0, new d3_geom_voronoiHalfEdge(d3_geom_voronoiCreateBorderEdge(cell.site, end, abs(x3 - x0) < ε && y1 - y3 > ε ? { + x: x0, + y: abs(x2 - x0) < ε ? y2 : y1 + } : abs(y3 - y1) < ε && x1 - x3 > ε ? { + x: abs(y2 - y1) < ε ? x2 : x1, + y: y1 + } : abs(x3 - x1) < ε && y3 - y0 > ε ? { + x: x1, + y: abs(x2 - x1) < ε ? y2 : y0 + } : abs(y3 - y0) < ε && x3 - x0 > ε ? { + x: abs(y2 - y0) < ε ? x2 : x0, + y: y0 + } : null), cell.site, null)); + ++nHalfEdges; + } + } + } + } + function d3_geom_voronoiHalfEdgeOrder(a, b) { + return b.angle - a.angle; + } + function d3_geom_voronoiCircle() { + d3_geom_voronoiRedBlackNode(this); + this.x = this.y = this.arc = this.site = this.cy = null; + } + function d3_geom_voronoiAttachCircle(arc) { + var lArc = arc.P, rArc = arc.N; + if (!lArc || !rArc) return; + var lSite = lArc.site, cSite = arc.site, rSite = rArc.site; + if (lSite === rSite) return; + var bx = cSite.x, by = cSite.y, ax = lSite.x - bx, ay = lSite.y - by, cx = rSite.x - bx, cy = rSite.y - by; + var d = 2 * (ax * cy - ay * cx); + if (d >= -ε2) return; + var ha = ax * ax + ay * ay, hc = cx * cx + cy * cy, x = (cy * ha - ay * hc) / d, y = (ax * hc - cx * ha) / d, cy = y + by; + var circle = d3_geom_voronoiCirclePool.pop() || new d3_geom_voronoiCircle(); + circle.arc = arc; + circle.site = cSite; + circle.x = x + bx; + circle.y = cy + Math.sqrt(x * x + y * y); + circle.cy = cy; + arc.circle = circle; + var before = null, node = d3_geom_voronoiCircles._; + while (node) { + if (circle.y < node.y || circle.y === node.y && circle.x <= node.x) { + if (node.L) node = node.L; else { + before = node.P; + break; + } + } else { + if (node.R) node = node.R; else { + before = node; + break; + } + } + } + d3_geom_voronoiCircles.insert(before, circle); + if (!before) d3_geom_voronoiFirstCircle = circle; + } + function d3_geom_voronoiDetachCircle(arc) { + var circle = arc.circle; + if (circle) { + if (!circle.P) d3_geom_voronoiFirstCircle = circle.N; + d3_geom_voronoiCircles.remove(circle); + d3_geom_voronoiCirclePool.push(circle); + d3_geom_voronoiRedBlackNode(circle); + arc.circle = null; + } + } + function d3_geom_voronoiClipEdges(extent) { + var edges = d3_geom_voronoiEdges, clip = d3_geom_clipLine(extent[0][0], extent[0][1], extent[1][0], extent[1][1]), i = edges.length, e; + while (i--) { + e = edges[i]; + if (!d3_geom_voronoiConnectEdge(e, extent) || !clip(e) || abs(e.a.x - e.b.x) < ε && abs(e.a.y - e.b.y) < ε) { + e.a = e.b = null; + edges.splice(i, 1); + } + } + } + function d3_geom_voronoiConnectEdge(edge, extent) { + var vb = edge.b; + if (vb) return true; + var va = edge.a, x0 = extent[0][0], x1 = extent[1][0], y0 = extent[0][1], y1 = extent[1][1], lSite = edge.l, rSite = edge.r, lx = lSite.x, ly = lSite.y, rx = rSite.x, ry = rSite.y, fx = (lx + rx) / 2, fy = (ly + ry) / 2, fm, fb; + if (ry === ly) { + if (fx < x0 || fx >= x1) return; + if (lx > rx) { + if (!va) va = { + x: fx, + y: y0 + }; else if (va.y >= y1) return; + vb = { + x: fx, + y: y1 + }; + } else { + if (!va) va = { + x: fx, + y: y1 + }; else if (va.y < y0) return; + vb = { + x: fx, + y: y0 + }; + } + } else { + fm = (lx - rx) / (ry - ly); + fb = fy - fm * fx; + if (fm < -1 || fm > 1) { + if (lx > rx) { + if (!va) va = { + x: (y0 - fb) / fm, + y: y0 + }; else if (va.y >= y1) return; + vb = { + x: (y1 - fb) / fm, + y: y1 + }; + } else { + if (!va) va = { + x: (y1 - fb) / fm, + y: y1 + }; else if (va.y < y0) return; + vb = { + x: (y0 - fb) / fm, + y: y0 + }; + } + } else { + if (ly < ry) { + if (!va) va = { + x: x0, + y: fm * x0 + fb + }; else if (va.x >= x1) return; + vb = { + x: x1, + y: fm * x1 + fb + }; + } else { + if (!va) va = { + x: x1, + y: fm * x1 + fb + }; else if (va.x < x0) return; + vb = { + x: x0, + y: fm * x0 + fb + }; + } + } + } + edge.a = va; + edge.b = vb; + return true; + } + function d3_geom_voronoiEdge(lSite, rSite) { + this.l = lSite; + this.r = rSite; + this.a = this.b = null; + } + function d3_geom_voronoiCreateEdge(lSite, rSite, va, vb) { + var edge = new d3_geom_voronoiEdge(lSite, rSite); + d3_geom_voronoiEdges.push(edge); + if (va) d3_geom_voronoiSetEdgeEnd(edge, lSite, rSite, va); + if (vb) d3_geom_voronoiSetEdgeEnd(edge, rSite, lSite, vb); + d3_geom_voronoiCells[lSite.i].edges.push(new d3_geom_voronoiHalfEdge(edge, lSite, rSite)); + d3_geom_voronoiCells[rSite.i].edges.push(new d3_geom_voronoiHalfEdge(edge, rSite, lSite)); + return edge; + } + function d3_geom_voronoiCreateBorderEdge(lSite, va, vb) { + var edge = new d3_geom_voronoiEdge(lSite, null); + edge.a = va; + edge.b = vb; + d3_geom_voronoiEdges.push(edge); + return edge; + } + function d3_geom_voronoiSetEdgeEnd(edge, lSite, rSite, vertex) { + if (!edge.a && !edge.b) { + edge.a = vertex; + edge.l = lSite; + edge.r = rSite; + } else if (edge.l === rSite) { + edge.b = vertex; + } else { + edge.a = vertex; + } + } + function d3_geom_voronoiHalfEdge(edge, lSite, rSite) { + var va = edge.a, vb = edge.b; + this.edge = edge; + this.site = lSite; + this.angle = rSite ? Math.atan2(rSite.y - lSite.y, rSite.x - lSite.x) : edge.l === lSite ? Math.atan2(vb.x - va.x, va.y - vb.y) : Math.atan2(va.x - vb.x, vb.y - va.y); + } + d3_geom_voronoiHalfEdge.prototype = { + start: function() { + return this.edge.l === this.site ? this.edge.a : this.edge.b; + }, + end: function() { + return this.edge.l === this.site ? this.edge.b : this.edge.a; + } + }; + function d3_geom_voronoiRedBlackTree() { + this._ = null; + } + function d3_geom_voronoiRedBlackNode(node) { + node.U = node.C = node.L = node.R = node.P = node.N = null; + } + d3_geom_voronoiRedBlackTree.prototype = { + insert: function(after, node) { + var parent, grandpa, uncle; + if (after) { + node.P = after; + node.N = after.N; + if (after.N) after.N.P = node; + after.N = node; + if (after.R) { + after = after.R; + while (after.L) after = after.L; + after.L = node; + } else { + after.R = node; + } + parent = after; + } else if (this._) { + after = d3_geom_voronoiRedBlackFirst(this._); + node.P = null; + node.N = after; + after.P = after.L = node; + parent = after; + } else { + node.P = node.N = null; + this._ = node; + parent = null; + } + node.L = node.R = null; + node.U = parent; + node.C = true; + after = node; + while (parent && parent.C) { + grandpa = parent.U; + if (parent === grandpa.L) { + uncle = grandpa.R; + if (uncle && uncle.C) { + parent.C = uncle.C = false; + grandpa.C = true; + after = grandpa; + } else { + if (after === parent.R) { + d3_geom_voronoiRedBlackRotateLeft(this, parent); + after = parent; + parent = after.U; + } + parent.C = false; + grandpa.C = true; + d3_geom_voronoiRedBlackRotateRight(this, grandpa); + } + } else { + uncle = grandpa.L; + if (uncle && uncle.C) { + parent.C = uncle.C = false; + grandpa.C = true; + after = grandpa; + } else { + if (after === parent.L) { + d3_geom_voronoiRedBlackRotateRight(this, parent); + after = parent; + parent = after.U; + } + parent.C = false; + grandpa.C = true; + d3_geom_voronoiRedBlackRotateLeft(this, grandpa); + } + } + parent = after.U; + } + this._.C = false; + }, + remove: function(node) { + if (node.N) node.N.P = node.P; + if (node.P) node.P.N = node.N; + node.N = node.P = null; + var parent = node.U, sibling, left = node.L, right = node.R, next, red; + if (!left) next = right; else if (!right) next = left; else next = d3_geom_voronoiRedBlackFirst(right); + if (parent) { + if (parent.L === node) parent.L = next; else parent.R = next; + } else { + this._ = next; + } + if (left && right) { + red = next.C; + next.C = node.C; + next.L = left; + left.U = next; + if (next !== right) { + parent = next.U; + next.U = node.U; + node = next.R; + parent.L = node; + next.R = right; + right.U = next; + } else { + next.U = parent; + parent = next; + node = next.R; + } + } else { + red = node.C; + node = next; + } + if (node) node.U = parent; + if (red) return; + if (node && node.C) { + node.C = false; + return; + } + do { + if (node === this._) break; + if (node === parent.L) { + sibling = parent.R; + if (sibling.C) { + sibling.C = false; + parent.C = true; + d3_geom_voronoiRedBlackRotateLeft(this, parent); + sibling = parent.R; + } + if (sibling.L && sibling.L.C || sibling.R && sibling.R.C) { + if (!sibling.R || !sibling.R.C) { + sibling.L.C = false; + sibling.C = true; + d3_geom_voronoiRedBlackRotateRight(this, sibling); + sibling = parent.R; + } + sibling.C = parent.C; + parent.C = sibling.R.C = false; + d3_geom_voronoiRedBlackRotateLeft(this, parent); + node = this._; + break; + } + } else { + sibling = parent.L; + if (sibling.C) { + sibling.C = false; + parent.C = true; + d3_geom_voronoiRedBlackRotateRight(this, parent); + sibling = parent.L; + } + if (sibling.L && sibling.L.C || sibling.R && sibling.R.C) { + if (!sibling.L || !sibling.L.C) { + sibling.R.C = false; + sibling.C = true; + d3_geom_voronoiRedBlackRotateLeft(this, sibling); + sibling = parent.L; + } + sibling.C = parent.C; + parent.C = sibling.L.C = false; + d3_geom_voronoiRedBlackRotateRight(this, parent); + node = this._; + break; + } + } + sibling.C = true; + node = parent; + parent = parent.U; + } while (!node.C); + if (node) node.C = false; + } + }; + function d3_geom_voronoiRedBlackRotateLeft(tree, node) { + var p = node, q = node.R, parent = p.U; + if (parent) { + if (parent.L === p) parent.L = q; else parent.R = q; + } else { + tree._ = q; + } + q.U = parent; + p.U = q; + p.R = q.L; + if (p.R) p.R.U = p; + q.L = p; + } + function d3_geom_voronoiRedBlackRotateRight(tree, node) { + var p = node, q = node.L, parent = p.U; + if (parent) { + if (parent.L === p) parent.L = q; else parent.R = q; + } else { + tree._ = q; + } + q.U = parent; + p.U = q; + p.L = q.R; + if (p.L) p.L.U = p; + q.R = p; + } + function d3_geom_voronoiRedBlackFirst(node) { + while (node.L) node = node.L; + return node; + } + function d3_geom_voronoi(sites, bbox) { + var site = sites.sort(d3_geom_voronoiVertexOrder).pop(), x0, y0, circle; + d3_geom_voronoiEdges = []; + d3_geom_voronoiCells = new Array(sites.length); + d3_geom_voronoiBeaches = new d3_geom_voronoiRedBlackTree(); + d3_geom_voronoiCircles = new d3_geom_voronoiRedBlackTree(); + while (true) { + circle = d3_geom_voronoiFirstCircle; + if (site && (!circle || site.y < circle.y || site.y === circle.y && site.x < circle.x)) { + if (site.x !== x0 || site.y !== y0) { + d3_geom_voronoiCells[site.i] = new d3_geom_voronoiCell(site); + d3_geom_voronoiAddBeach(site); + x0 = site.x, y0 = site.y; + } + site = sites.pop(); + } else if (circle) { + d3_geom_voronoiRemoveBeach(circle.arc); + } else { + break; + } + } + if (bbox) d3_geom_voronoiClipEdges(bbox), d3_geom_voronoiCloseCells(bbox); + var diagram = { + cells: d3_geom_voronoiCells, + edges: d3_geom_voronoiEdges + }; + d3_geom_voronoiBeaches = d3_geom_voronoiCircles = d3_geom_voronoiEdges = d3_geom_voronoiCells = null; + return diagram; + } + function d3_geom_voronoiVertexOrder(a, b) { + return b.y - a.y || b.x - a.x; + } + d3.geom.voronoi = function(points) { + var x = d3_geom_pointX, y = d3_geom_pointY, fx = x, fy = y, clipExtent = d3_geom_voronoiClipExtent; + if (points) return voronoi(points); + function voronoi(data) { + var polygons = new Array(data.length), x0 = clipExtent[0][0], y0 = clipExtent[0][1], x1 = clipExtent[1][0], y1 = clipExtent[1][1]; + d3_geom_voronoi(sites(data), clipExtent).cells.forEach(function(cell, i) { + var edges = cell.edges, site = cell.site, polygon = polygons[i] = edges.length ? edges.map(function(e) { + var s = e.start(); + return [ s.x, s.y ]; + }) : site.x >= x0 && site.x <= x1 && site.y >= y0 && site.y <= y1 ? [ [ x0, y1 ], [ x1, y1 ], [ x1, y0 ], [ x0, y0 ] ] : []; + polygon.point = data[i]; + }); + return polygons; + } + function sites(data) { + return data.map(function(d, i) { + return { + x: Math.round(fx(d, i) / ε) * ε, + y: Math.round(fy(d, i) / ε) * ε, + i: i + }; + }); + } + voronoi.links = function(data) { + return d3_geom_voronoi(sites(data)).edges.filter(function(edge) { + return edge.l && edge.r; + }).map(function(edge) { + return { + source: data[edge.l.i], + target: data[edge.r.i] + }; + }); + }; + voronoi.triangles = function(data) { + var triangles = []; + d3_geom_voronoi(sites(data)).cells.forEach(function(cell, i) { + var site = cell.site, edges = cell.edges.sort(d3_geom_voronoiHalfEdgeOrder), j = -1, m = edges.length, e0, s0, e1 = edges[m - 1].edge, s1 = e1.l === site ? e1.r : e1.l; + while (++j < m) { + e0 = e1; + s0 = s1; + e1 = edges[j].edge; + s1 = e1.l === site ? e1.r : e1.l; + if (i < s0.i && i < s1.i && d3_geom_voronoiTriangleArea(site, s0, s1) < 0) { + triangles.push([ data[i], data[s0.i], data[s1.i] ]); + } + } + }); + return triangles; + }; + voronoi.x = function(_) { + return arguments.length ? (fx = d3_functor(x = _), voronoi) : x; + }; + voronoi.y = function(_) { + return arguments.length ? (fy = d3_functor(y = _), voronoi) : y; + }; + voronoi.clipExtent = function(_) { + if (!arguments.length) return clipExtent === d3_geom_voronoiClipExtent ? null : clipExtent; + clipExtent = _ == null ? d3_geom_voronoiClipExtent : _; + return voronoi; + }; + voronoi.size = function(_) { + if (!arguments.length) return clipExtent === d3_geom_voronoiClipExtent ? null : clipExtent && clipExtent[1]; + return voronoi.clipExtent(_ && [ [ 0, 0 ], _ ]); + }; + return voronoi; + }; + var d3_geom_voronoiClipExtent = [ [ -1e6, -1e6 ], [ 1e6, 1e6 ] ]; + function d3_geom_voronoiTriangleArea(a, b, c) { + return (a.x - c.x) * (b.y - a.y) - (a.x - b.x) * (c.y - a.y); + } + d3.geom.delaunay = function(vertices) { + return d3.geom.voronoi().triangles(vertices); + }; + d3.geom.quadtree = function(points, x1, y1, x2, y2) { + var x = d3_geom_pointX, y = d3_geom_pointY, compat; + if (compat = arguments.length) { + x = d3_geom_quadtreeCompatX; + y = d3_geom_quadtreeCompatY; + if (compat === 3) { + y2 = y1; + x2 = x1; + y1 = x1 = 0; + } + return quadtree(points); + } + function quadtree(data) { + var d, fx = d3_functor(x), fy = d3_functor(y), xs, ys, i, n, x1_, y1_, x2_, y2_; + if (x1 != null) { + x1_ = x1, y1_ = y1, x2_ = x2, y2_ = y2; + } else { + x2_ = y2_ = -(x1_ = y1_ = Infinity); + xs = [], ys = []; + n = data.length; + if (compat) for (i = 0; i < n; ++i) { + d = data[i]; + if (d.x < x1_) x1_ = d.x; + if (d.y < y1_) y1_ = d.y; + if (d.x > x2_) x2_ = d.x; + if (d.y > y2_) y2_ = d.y; + xs.push(d.x); + ys.push(d.y); + } else for (i = 0; i < n; ++i) { + var x_ = +fx(d = data[i], i), y_ = +fy(d, i); + if (x_ < x1_) x1_ = x_; + if (y_ < y1_) y1_ = y_; + if (x_ > x2_) x2_ = x_; + if (y_ > y2_) y2_ = y_; + xs.push(x_); + ys.push(y_); + } + } + var dx = x2_ - x1_, dy = y2_ - y1_; + if (dx > dy) y2_ = y1_ + dx; else x2_ = x1_ + dy; + function insert(n, d, x, y, x1, y1, x2, y2) { + if (isNaN(x) || isNaN(y)) return; + if (n.leaf) { + var nx = n.x, ny = n.y; + if (nx != null) { + if (abs(nx - x) + abs(ny - y) < .01) { + insertChild(n, d, x, y, x1, y1, x2, y2); + } else { + var nPoint = n.point; + n.x = n.y = n.point = null; + insertChild(n, nPoint, nx, ny, x1, y1, x2, y2); + insertChild(n, d, x, y, x1, y1, x2, y2); + } + } else { + n.x = x, n.y = y, n.point = d; + } + } else { + insertChild(n, d, x, y, x1, y1, x2, y2); + } + } + function insertChild(n, d, x, y, x1, y1, x2, y2) { + var xm = (x1 + x2) * .5, ym = (y1 + y2) * .5, right = x >= xm, below = y >= ym, i = below << 1 | right; + n.leaf = false; + n = n.nodes[i] || (n.nodes[i] = d3_geom_quadtreeNode()); + if (right) x1 = xm; else x2 = xm; + if (below) y1 = ym; else y2 = ym; + insert(n, d, x, y, x1, y1, x2, y2); + } + var root = d3_geom_quadtreeNode(); + root.add = function(d) { + insert(root, d, +fx(d, ++i), +fy(d, i), x1_, y1_, x2_, y2_); + }; + root.visit = function(f) { + d3_geom_quadtreeVisit(f, root, x1_, y1_, x2_, y2_); + }; + root.find = function(point) { + return d3_geom_quadtreeFind(root, point[0], point[1], x1_, y1_, x2_, y2_); + }; + i = -1; + if (x1 == null) { + while (++i < n) { + insert(root, data[i], xs[i], ys[i], x1_, y1_, x2_, y2_); + } + --i; + } else data.forEach(root.add); + xs = ys = data = d = null; + return root; + } + quadtree.x = function(_) { + return arguments.length ? (x = _, quadtree) : x; + }; + quadtree.y = function(_) { + return arguments.length ? (y = _, quadtree) : y; + }; + quadtree.extent = function(_) { + if (!arguments.length) return x1 == null ? null : [ [ x1, y1 ], [ x2, y2 ] ]; + if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = +_[0][0], y1 = +_[0][1], x2 = +_[1][0], + y2 = +_[1][1]; + return quadtree; + }; + quadtree.size = function(_) { + if (!arguments.length) return x1 == null ? null : [ x2 - x1, y2 - y1 ]; + if (_ == null) x1 = y1 = x2 = y2 = null; else x1 = y1 = 0, x2 = +_[0], y2 = +_[1]; + return quadtree; + }; + return quadtree; + }; + function d3_geom_quadtreeCompatX(d) { + return d.x; + } + function d3_geom_quadtreeCompatY(d) { + return d.y; + } + function d3_geom_quadtreeNode() { + return { + leaf: true, + nodes: [], + point: null, + x: null, + y: null + }; + } + function d3_geom_quadtreeVisit(f, node, x1, y1, x2, y2) { + if (!f(node, x1, y1, x2, y2)) { + var sx = (x1 + x2) * .5, sy = (y1 + y2) * .5, children = node.nodes; + if (children[0]) d3_geom_quadtreeVisit(f, children[0], x1, y1, sx, sy); + if (children[1]) d3_geom_quadtreeVisit(f, children[1], sx, y1, x2, sy); + if (children[2]) d3_geom_quadtreeVisit(f, children[2], x1, sy, sx, y2); + if (children[3]) d3_geom_quadtreeVisit(f, children[3], sx, sy, x2, y2); + } + } + function d3_geom_quadtreeFind(root, x, y, x0, y0, x3, y3) { + var minDistance2 = Infinity, closestPoint; + (function find(node, x1, y1, x2, y2) { + if (x1 > x3 || y1 > y3 || x2 < x0 || y2 < y0) return; + if (point = node.point) { + var point, dx = x - node.x, dy = y - node.y, distance2 = dx * dx + dy * dy; + if (distance2 < minDistance2) { + var distance = Math.sqrt(minDistance2 = distance2); + x0 = x - distance, y0 = y - distance; + x3 = x + distance, y3 = y + distance; + closestPoint = point; + } + } + var children = node.nodes, xm = (x1 + x2) * .5, ym = (y1 + y2) * .5, right = x >= xm, below = y >= ym; + for (var i = below << 1 | right, j = i + 4; i < j; ++i) { + if (node = children[i & 3]) switch (i & 3) { + case 0: + find(node, x1, y1, xm, ym); + break; + + case 1: + find(node, xm, y1, x2, ym); + break; + + case 2: + find(node, x1, ym, xm, y2); + break; + + case 3: + find(node, xm, ym, x2, y2); + break; + } + } + })(root, x0, y0, x3, y3); + return closestPoint; + } + d3.interpolateRgb = d3_interpolateRgb; + function d3_interpolateRgb(a, b) { + a = d3.rgb(a); + b = d3.rgb(b); + var ar = a.r, ag = a.g, ab = a.b, br = b.r - ar, bg = b.g - ag, bb = b.b - ab; + return function(t) { + return "#" + d3_rgb_hex(Math.round(ar + br * t)) + d3_rgb_hex(Math.round(ag + bg * t)) + d3_rgb_hex(Math.round(ab + bb * t)); + }; + } + d3.interpolateObject = d3_interpolateObject; + function d3_interpolateObject(a, b) { + var i = {}, c = {}, k; + for (k in a) { + if (k in b) { + i[k] = d3_interpolate(a[k], b[k]); + } else { + c[k] = a[k]; + } + } + for (k in b) { + if (!(k in a)) { + c[k] = b[k]; + } + } + return function(t) { + for (k in i) c[k] = i[k](t); + return c; + }; + } + d3.interpolateNumber = d3_interpolateNumber; + function d3_interpolateNumber(a, b) { + a = +a, b = +b; + return function(t) { + return a * (1 - t) + b * t; + }; + } + d3.interpolateString = d3_interpolateString; + function d3_interpolateString(a, b) { + var bi = d3_interpolate_numberA.lastIndex = d3_interpolate_numberB.lastIndex = 0, am, bm, bs, i = -1, s = [], q = []; + a = a + "", b = b + ""; + while ((am = d3_interpolate_numberA.exec(a)) && (bm = d3_interpolate_numberB.exec(b))) { + if ((bs = bm.index) > bi) { + bs = b.slice(bi, bs); + if (s[i]) s[i] += bs; else s[++i] = bs; + } + if ((am = am[0]) === (bm = bm[0])) { + if (s[i]) s[i] += bm; else s[++i] = bm; + } else { + s[++i] = null; + q.push({ + i: i, + x: d3_interpolateNumber(am, bm) + }); + } + bi = d3_interpolate_numberB.lastIndex; + } + if (bi < b.length) { + bs = b.slice(bi); + if (s[i]) s[i] += bs; else s[++i] = bs; + } + return s.length < 2 ? q[0] ? (b = q[0].x, function(t) { + return b(t) + ""; + }) : function() { + return b; + } : (b = q.length, function(t) { + for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t); + return s.join(""); + }); + } + var d3_interpolate_numberA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, d3_interpolate_numberB = new RegExp(d3_interpolate_numberA.source, "g"); + d3.interpolate = d3_interpolate; + function d3_interpolate(a, b) { + var i = d3.interpolators.length, f; + while (--i >= 0 && !(f = d3.interpolators[i](a, b))) ; + return f; + } + d3.interpolators = [ function(a, b) { + var t = typeof b; + return (t === "string" ? d3_rgb_names.has(b.toLowerCase()) || /^(#|rgb\(|hsl\()/i.test(b) ? d3_interpolateRgb : d3_interpolateString : b instanceof d3_color ? d3_interpolateRgb : Array.isArray(b) ? d3_interpolateArray : t === "object" && isNaN(b) ? d3_interpolateObject : d3_interpolateNumber)(a, b); + } ]; + d3.interpolateArray = d3_interpolateArray; + function d3_interpolateArray(a, b) { + var x = [], c = [], na = a.length, nb = b.length, n0 = Math.min(a.length, b.length), i; + for (i = 0; i < n0; ++i) x.push(d3_interpolate(a[i], b[i])); + for (;i < na; ++i) c[i] = a[i]; + for (;i < nb; ++i) c[i] = b[i]; + return function(t) { + for (i = 0; i < n0; ++i) c[i] = x[i](t); + return c; + }; + } + var d3_ease_default = function() { + return d3_identity; + }; + var d3_ease = d3.map({ + linear: d3_ease_default, + poly: d3_ease_poly, + quad: function() { + return d3_ease_quad; + }, + cubic: function() { + return d3_ease_cubic; + }, + sin: function() { + return d3_ease_sin; + }, + exp: function() { + return d3_ease_exp; + }, + circle: function() { + return d3_ease_circle; + }, + elastic: d3_ease_elastic, + back: d3_ease_back, + bounce: function() { + return d3_ease_bounce; + } + }); + var d3_ease_mode = d3.map({ + "in": d3_identity, + out: d3_ease_reverse, + "in-out": d3_ease_reflect, + "out-in": function(f) { + return d3_ease_reflect(d3_ease_reverse(f)); + } + }); + d3.ease = function(name) { + var i = name.indexOf("-"), t = i >= 0 ? name.slice(0, i) : name, m = i >= 0 ? name.slice(i + 1) : "in"; + t = d3_ease.get(t) || d3_ease_default; + m = d3_ease_mode.get(m) || d3_identity; + return d3_ease_clamp(m(t.apply(null, d3_arraySlice.call(arguments, 1)))); + }; + function d3_ease_clamp(f) { + return function(t) { + return t <= 0 ? 0 : t >= 1 ? 1 : f(t); + }; + } + function d3_ease_reverse(f) { + return function(t) { + return 1 - f(1 - t); + }; + } + function d3_ease_reflect(f) { + return function(t) { + return .5 * (t < .5 ? f(2 * t) : 2 - f(2 - 2 * t)); + }; + } + function d3_ease_quad(t) { + return t * t; + } + function d3_ease_cubic(t) { + return t * t * t; + } + function d3_ease_cubicInOut(t) { + if (t <= 0) return 0; + if (t >= 1) return 1; + var t2 = t * t, t3 = t2 * t; + return 4 * (t < .5 ? t3 : 3 * (t - t2) + t3 - .75); + } + function d3_ease_poly(e) { + return function(t) { + return Math.pow(t, e); + }; + } + function d3_ease_sin(t) { + return 1 - Math.cos(t * halfπ); + } + function d3_ease_exp(t) { + return Math.pow(2, 10 * (t - 1)); + } + function d3_ease_circle(t) { + return 1 - Math.sqrt(1 - t * t); + } + function d3_ease_elastic(a, p) { + var s; + if (arguments.length < 2) p = .45; + if (arguments.length) s = p / τ * Math.asin(1 / a); else a = 1, s = p / 4; + return function(t) { + return 1 + a * Math.pow(2, -10 * t) * Math.sin((t - s) * τ / p); + }; + } + function d3_ease_back(s) { + if (!s) s = 1.70158; + return function(t) { + return t * t * ((s + 1) * t - s); + }; + } + function d3_ease_bounce(t) { + return t < 1 / 2.75 ? 7.5625 * t * t : t < 2 / 2.75 ? 7.5625 * (t -= 1.5 / 2.75) * t + .75 : t < 2.5 / 2.75 ? 7.5625 * (t -= 2.25 / 2.75) * t + .9375 : 7.5625 * (t -= 2.625 / 2.75) * t + .984375; + } + d3.interpolateHcl = d3_interpolateHcl; + function d3_interpolateHcl(a, b) { + a = d3.hcl(a); + b = d3.hcl(b); + var ah = a.h, ac = a.c, al = a.l, bh = b.h - ah, bc = b.c - ac, bl = b.l - al; + if (isNaN(bc)) bc = 0, ac = isNaN(ac) ? b.c : ac; + if (isNaN(bh)) bh = 0, ah = isNaN(ah) ? b.h : ah; else if (bh > 180) bh -= 360; else if (bh < -180) bh += 360; + return function(t) { + return d3_hcl_lab(ah + bh * t, ac + bc * t, al + bl * t) + ""; + }; + } + d3.interpolateHsl = d3_interpolateHsl; + function d3_interpolateHsl(a, b) { + a = d3.hsl(a); + b = d3.hsl(b); + var ah = a.h, as = a.s, al = a.l, bh = b.h - ah, bs = b.s - as, bl = b.l - al; + if (isNaN(bs)) bs = 0, as = isNaN(as) ? b.s : as; + if (isNaN(bh)) bh = 0, ah = isNaN(ah) ? b.h : ah; else if (bh > 180) bh -= 360; else if (bh < -180) bh += 360; + return function(t) { + return d3_hsl_rgb(ah + bh * t, as + bs * t, al + bl * t) + ""; + }; + } + d3.interpolateLab = d3_interpolateLab; + function d3_interpolateLab(a, b) { + a = d3.lab(a); + b = d3.lab(b); + var al = a.l, aa = a.a, ab = a.b, bl = b.l - al, ba = b.a - aa, bb = b.b - ab; + return function(t) { + return d3_lab_rgb(al + bl * t, aa + ba * t, ab + bb * t) + ""; + }; + } + d3.interpolateRound = d3_interpolateRound; + function d3_interpolateRound(a, b) { + b -= a; + return function(t) { + return Math.round(a + b * t); + }; + } + d3.transform = function(string) { + var g = d3_document.createElementNS(d3.ns.prefix.svg, "g"); + return (d3.transform = function(string) { + if (string != null) { + g.setAttribute("transform", string); + var t = g.transform.baseVal.consolidate(); + } + return new d3_transform(t ? t.matrix : d3_transformIdentity); + })(string); + }; + function d3_transform(m) { + var r0 = [ m.a, m.b ], r1 = [ m.c, m.d ], kx = d3_transformNormalize(r0), kz = d3_transformDot(r0, r1), ky = d3_transformNormalize(d3_transformCombine(r1, r0, -kz)) || 0; + if (r0[0] * r1[1] < r1[0] * r0[1]) { + r0[0] *= -1; + r0[1] *= -1; + kx *= -1; + kz *= -1; + } + this.rotate = (kx ? Math.atan2(r0[1], r0[0]) : Math.atan2(-r1[0], r1[1])) * d3_degrees; + this.translate = [ m.e, m.f ]; + this.scale = [ kx, ky ]; + this.skew = ky ? Math.atan2(kz, ky) * d3_degrees : 0; + } + d3_transform.prototype.toString = function() { + return "translate(" + this.translate + ")rotate(" + this.rotate + ")skewX(" + this.skew + ")scale(" + this.scale + ")"; + }; + function d3_transformDot(a, b) { + return a[0] * b[0] + a[1] * b[1]; + } + function d3_transformNormalize(a) { + var k = Math.sqrt(d3_transformDot(a, a)); + if (k) { + a[0] /= k; + a[1] /= k; + } + return k; + } + function d3_transformCombine(a, b, k) { + a[0] += k * b[0]; + a[1] += k * b[1]; + return a; + } + var d3_transformIdentity = { + a: 1, + b: 0, + c: 0, + d: 1, + e: 0, + f: 0 + }; + d3.interpolateTransform = d3_interpolateTransform; + function d3_interpolateTransformPop(s) { + return s.length ? s.pop() + "," : ""; + } + function d3_interpolateTranslate(ta, tb, s, q) { + if (ta[0] !== tb[0] || ta[1] !== tb[1]) { + var i = s.push("translate(", null, ",", null, ")"); + q.push({ + i: i - 4, + x: d3_interpolateNumber(ta[0], tb[0]) + }, { + i: i - 2, + x: d3_interpolateNumber(ta[1], tb[1]) + }); + } else if (tb[0] || tb[1]) { + s.push("translate(" + tb + ")"); + } + } + function d3_interpolateRotate(ra, rb, s, q) { + if (ra !== rb) { + if (ra - rb > 180) rb += 360; else if (rb - ra > 180) ra += 360; + q.push({ + i: s.push(d3_interpolateTransformPop(s) + "rotate(", null, ")") - 2, + x: d3_interpolateNumber(ra, rb) + }); + } else if (rb) { + s.push(d3_interpolateTransformPop(s) + "rotate(" + rb + ")"); + } + } + function d3_interpolateSkew(wa, wb, s, q) { + if (wa !== wb) { + q.push({ + i: s.push(d3_interpolateTransformPop(s) + "skewX(", null, ")") - 2, + x: d3_interpolateNumber(wa, wb) + }); + } else if (wb) { + s.push(d3_interpolateTransformPop(s) + "skewX(" + wb + ")"); + } + } + function d3_interpolateScale(ka, kb, s, q) { + if (ka[0] !== kb[0] || ka[1] !== kb[1]) { + var i = s.push(d3_interpolateTransformPop(s) + "scale(", null, ",", null, ")"); + q.push({ + i: i - 4, + x: d3_interpolateNumber(ka[0], kb[0]) + }, { + i: i - 2, + x: d3_interpolateNumber(ka[1], kb[1]) + }); + } else if (kb[0] !== 1 || kb[1] !== 1) { + s.push(d3_interpolateTransformPop(s) + "scale(" + kb + ")"); + } + } + function d3_interpolateTransform(a, b) { + var s = [], q = []; + a = d3.transform(a), b = d3.transform(b); + d3_interpolateTranslate(a.translate, b.translate, s, q); + d3_interpolateRotate(a.rotate, b.rotate, s, q); + d3_interpolateSkew(a.skew, b.skew, s, q); + d3_interpolateScale(a.scale, b.scale, s, q); + a = b = null; + return function(t) { + var i = -1, n = q.length, o; + while (++i < n) s[(o = q[i]).i] = o.x(t); + return s.join(""); + }; + } + function d3_uninterpolateNumber(a, b) { + b = (b -= a = +a) || 1 / b; + return function(x) { + return (x - a) / b; + }; + } + function d3_uninterpolateClamp(a, b) { + b = (b -= a = +a) || 1 / b; + return function(x) { + return Math.max(0, Math.min(1, (x - a) / b)); + }; + } + d3.layout = {}; + d3.layout.bundle = function() { + return function(links) { + var paths = [], i = -1, n = links.length; + while (++i < n) paths.push(d3_layout_bundlePath(links[i])); + return paths; + }; + }; + function d3_layout_bundlePath(link) { + var start = link.source, end = link.target, lca = d3_layout_bundleLeastCommonAncestor(start, end), points = [ start ]; + while (start !== lca) { + start = start.parent; + points.push(start); + } + var k = points.length; + while (end !== lca) { + points.splice(k, 0, end); + end = end.parent; + } + return points; + } + function d3_layout_bundleAncestors(node) { + var ancestors = [], parent = node.parent; + while (parent != null) { + ancestors.push(node); + node = parent; + parent = parent.parent; + } + ancestors.push(node); + return ancestors; + } + function d3_layout_bundleLeastCommonAncestor(a, b) { + if (a === b) return a; + var aNodes = d3_layout_bundleAncestors(a), bNodes = d3_layout_bundleAncestors(b), aNode = aNodes.pop(), bNode = bNodes.pop(), sharedNode = null; + while (aNode === bNode) { + sharedNode = aNode; + aNode = aNodes.pop(); + bNode = bNodes.pop(); + } + return sharedNode; + } + d3.layout.chord = function() { + var chord = {}, chords, groups, matrix, n, padding = 0, sortGroups, sortSubgroups, sortChords; + function relayout() { + var subgroups = {}, groupSums = [], groupIndex = d3.range(n), subgroupIndex = [], k, x, x0, i, j; + chords = []; + groups = []; + k = 0, i = -1; + while (++i < n) { + x = 0, j = -1; + while (++j < n) { + x += matrix[i][j]; + } + groupSums.push(x); + subgroupIndex.push(d3.range(n)); + k += x; + } + if (sortGroups) { + groupIndex.sort(function(a, b) { + return sortGroups(groupSums[a], groupSums[b]); + }); + } + if (sortSubgroups) { + subgroupIndex.forEach(function(d, i) { + d.sort(function(a, b) { + return sortSubgroups(matrix[i][a], matrix[i][b]); + }); + }); + } + k = (τ - padding * n) / k; + x = 0, i = -1; + while (++i < n) { + x0 = x, j = -1; + while (++j < n) { + var di = groupIndex[i], dj = subgroupIndex[di][j], v = matrix[di][dj], a0 = x, a1 = x += v * k; + subgroups[di + "-" + dj] = { + index: di, + subindex: dj, + startAngle: a0, + endAngle: a1, + value: v + }; + } + groups[di] = { + index: di, + startAngle: x0, + endAngle: x, + value: groupSums[di] + }; + x += padding; + } + i = -1; + while (++i < n) { + j = i - 1; + while (++j < n) { + var source = subgroups[i + "-" + j], target = subgroups[j + "-" + i]; + if (source.value || target.value) { + chords.push(source.value < target.value ? { + source: target, + target: source + } : { + source: source, + target: target + }); + } + } + } + if (sortChords) resort(); + } + function resort() { + chords.sort(function(a, b) { + return sortChords((a.source.value + a.target.value) / 2, (b.source.value + b.target.value) / 2); + }); + } + chord.matrix = function(x) { + if (!arguments.length) return matrix; + n = (matrix = x) && matrix.length; + chords = groups = null; + return chord; + }; + chord.padding = function(x) { + if (!arguments.length) return padding; + padding = x; + chords = groups = null; + return chord; + }; + chord.sortGroups = function(x) { + if (!arguments.length) return sortGroups; + sortGroups = x; + chords = groups = null; + return chord; + }; + chord.sortSubgroups = function(x) { + if (!arguments.length) return sortSubgroups; + sortSubgroups = x; + chords = null; + return chord; + }; + chord.sortChords = function(x) { + if (!arguments.length) return sortChords; + sortChords = x; + if (chords) resort(); + return chord; + }; + chord.chords = function() { + if (!chords) relayout(); + return chords; + }; + chord.groups = function() { + if (!groups) relayout(); + return groups; + }; + return chord; + }; + d3.layout.force = function() { + var force = {}, event = d3.dispatch("start", "tick", "end"), timer, size = [ 1, 1 ], drag, alpha, friction = .9, linkDistance = d3_layout_forceLinkDistance, linkStrength = d3_layout_forceLinkStrength, charge = -30, chargeDistance2 = d3_layout_forceChargeDistance2, gravity = .1, theta2 = .64, nodes = [], links = [], distances, strengths, charges; + function repulse(node) { + return function(quad, x1, _, x2) { + if (quad.point !== node) { + var dx = quad.cx - node.x, dy = quad.cy - node.y, dw = x2 - x1, dn = dx * dx + dy * dy; + if (dw * dw / theta2 < dn) { + if (dn < chargeDistance2) { + var k = quad.charge / dn; + node.px -= dx * k; + node.py -= dy * k; + } + return true; + } + if (quad.point && dn && dn < chargeDistance2) { + var k = quad.pointCharge / dn; + node.px -= dx * k; + node.py -= dy * k; + } + } + return !quad.charge; + }; + } + force.tick = function() { + if ((alpha *= .99) < .005) { + timer = null; + event.end({ + type: "end", + alpha: alpha = 0 + }); + return true; + } + var n = nodes.length, m = links.length, q, i, o, s, t, l, k, x, y; + for (i = 0; i < m; ++i) { + o = links[i]; + s = o.source; + t = o.target; + x = t.x - s.x; + y = t.y - s.y; + if (l = x * x + y * y) { + l = alpha * strengths[i] * ((l = Math.sqrt(l)) - distances[i]) / l; + x *= l; + y *= l; + t.x -= x * (k = s.weight + t.weight ? s.weight / (s.weight + t.weight) : .5); + t.y -= y * k; + s.x += x * (k = 1 - k); + s.y += y * k; + } + } + if (k = alpha * gravity) { + x = size[0] / 2; + y = size[1] / 2; + i = -1; + if (k) while (++i < n) { + o = nodes[i]; + o.x += (x - o.x) * k; + o.y += (y - o.y) * k; + } + } + if (charge) { + d3_layout_forceAccumulate(q = d3.geom.quadtree(nodes), alpha, charges); + i = -1; + while (++i < n) { + if (!(o = nodes[i]).fixed) { + q.visit(repulse(o)); + } + } + } + i = -1; + while (++i < n) { + o = nodes[i]; + if (o.fixed) { + o.x = o.px; + o.y = o.py; + } else { + o.x -= (o.px - (o.px = o.x)) * friction; + o.y -= (o.py - (o.py = o.y)) * friction; + } + } + event.tick({ + type: "tick", + alpha: alpha + }); + }; + force.nodes = function(x) { + if (!arguments.length) return nodes; + nodes = x; + return force; + }; + force.links = function(x) { + if (!arguments.length) return links; + links = x; + return force; + }; + force.size = function(x) { + if (!arguments.length) return size; + size = x; + return force; + }; + force.linkDistance = function(x) { + if (!arguments.length) return linkDistance; + linkDistance = typeof x === "function" ? x : +x; + return force; + }; + force.distance = force.linkDistance; + force.linkStrength = function(x) { + if (!arguments.length) return linkStrength; + linkStrength = typeof x === "function" ? x : +x; + return force; + }; + force.friction = function(x) { + if (!arguments.length) return friction; + friction = +x; + return force; + }; + force.charge = function(x) { + if (!arguments.length) return charge; + charge = typeof x === "function" ? x : +x; + return force; + }; + force.chargeDistance = function(x) { + if (!arguments.length) return Math.sqrt(chargeDistance2); + chargeDistance2 = x * x; + return force; + }; + force.gravity = function(x) { + if (!arguments.length) return gravity; + gravity = +x; + return force; + }; + force.theta = function(x) { + if (!arguments.length) return Math.sqrt(theta2); + theta2 = x * x; + return force; + }; + force.alpha = function(x) { + if (!arguments.length) return alpha; + x = +x; + if (alpha) { + if (x > 0) { + alpha = x; + } else { + timer.c = null, timer.t = NaN, timer = null; + event.end({ + type: "end", + alpha: alpha = 0 + }); + } + } else if (x > 0) { + event.start({ + type: "start", + alpha: alpha = x + }); + timer = d3_timer(force.tick); + } + return force; + }; + force.start = function() { + var i, n = nodes.length, m = links.length, w = size[0], h = size[1], neighbors, o; + for (i = 0; i < n; ++i) { + (o = nodes[i]).index = i; + o.weight = 0; + } + for (i = 0; i < m; ++i) { + o = links[i]; + if (typeof o.source == "number") o.source = nodes[o.source]; + if (typeof o.target == "number") o.target = nodes[o.target]; + ++o.source.weight; + ++o.target.weight; + } + for (i = 0; i < n; ++i) { + o = nodes[i]; + if (isNaN(o.x)) o.x = position("x", w); + if (isNaN(o.y)) o.y = position("y", h); + if (isNaN(o.px)) o.px = o.x; + if (isNaN(o.py)) o.py = o.y; + } + distances = []; + if (typeof linkDistance === "function") for (i = 0; i < m; ++i) distances[i] = +linkDistance.call(this, links[i], i); else for (i = 0; i < m; ++i) distances[i] = linkDistance; + strengths = []; + if (typeof linkStrength === "function") for (i = 0; i < m; ++i) strengths[i] = +linkStrength.call(this, links[i], i); else for (i = 0; i < m; ++i) strengths[i] = linkStrength; + charges = []; + if (typeof charge === "function") for (i = 0; i < n; ++i) charges[i] = +charge.call(this, nodes[i], i); else for (i = 0; i < n; ++i) charges[i] = charge; + function position(dimension, size) { + if (!neighbors) { + neighbors = new Array(n); + for (j = 0; j < n; ++j) { + neighbors[j] = []; + } + for (j = 0; j < m; ++j) { + var o = links[j]; + neighbors[o.source.index].push(o.target); + neighbors[o.target.index].push(o.source); + } + } + var candidates = neighbors[i], j = -1, l = candidates.length, x; + while (++j < l) if (!isNaN(x = candidates[j][dimension])) return x; + return Math.random() * size; + } + return force.resume(); + }; + force.resume = function() { + return force.alpha(.1); + }; + force.stop = function() { + return force.alpha(0); + }; + force.drag = function() { + if (!drag) drag = d3.behavior.drag().origin(d3_identity).on("dragstart.force", d3_layout_forceDragstart).on("drag.force", dragmove).on("dragend.force", d3_layout_forceDragend); + if (!arguments.length) return drag; + this.on("mouseover.force", d3_layout_forceMouseover).on("mouseout.force", d3_layout_forceMouseout).call(drag); + }; + function dragmove(d) { + d.px = d3.event.x, d.py = d3.event.y; + force.resume(); + } + return d3.rebind(force, event, "on"); + }; + function d3_layout_forceDragstart(d) { + d.fixed |= 2; + } + function d3_layout_forceDragend(d) { + d.fixed &= ~6; + } + function d3_layout_forceMouseover(d) { + d.fixed |= 4; + d.px = d.x, d.py = d.y; + } + function d3_layout_forceMouseout(d) { + d.fixed &= ~4; + } + function d3_layout_forceAccumulate(quad, alpha, charges) { + var cx = 0, cy = 0; + quad.charge = 0; + if (!quad.leaf) { + var nodes = quad.nodes, n = nodes.length, i = -1, c; + while (++i < n) { + c = nodes[i]; + if (c == null) continue; + d3_layout_forceAccumulate(c, alpha, charges); + quad.charge += c.charge; + cx += c.charge * c.cx; + cy += c.charge * c.cy; + } + } + if (quad.point) { + if (!quad.leaf) { + quad.point.x += Math.random() - .5; + quad.point.y += Math.random() - .5; + } + var k = alpha * charges[quad.point.index]; + quad.charge += quad.pointCharge = k; + cx += k * quad.point.x; + cy += k * quad.point.y; + } + quad.cx = cx / quad.charge; + quad.cy = cy / quad.charge; + } + var d3_layout_forceLinkDistance = 20, d3_layout_forceLinkStrength = 1, d3_layout_forceChargeDistance2 = Infinity; + d3.layout.hierarchy = function() { + var sort = d3_layout_hierarchySort, children = d3_layout_hierarchyChildren, value = d3_layout_hierarchyValue; + function hierarchy(root) { + var stack = [ root ], nodes = [], node; + root.depth = 0; + while ((node = stack.pop()) != null) { + nodes.push(node); + if ((childs = children.call(hierarchy, node, node.depth)) && (n = childs.length)) { + var n, childs, child; + while (--n >= 0) { + stack.push(child = childs[n]); + child.parent = node; + child.depth = node.depth + 1; + } + if (value) node.value = 0; + node.children = childs; + } else { + if (value) node.value = +value.call(hierarchy, node, node.depth) || 0; + delete node.children; + } + } + d3_layout_hierarchyVisitAfter(root, function(node) { + var childs, parent; + if (sort && (childs = node.children)) childs.sort(sort); + if (value && (parent = node.parent)) parent.value += node.value; + }); + return nodes; + } + hierarchy.sort = function(x) { + if (!arguments.length) return sort; + sort = x; + return hierarchy; + }; + hierarchy.children = function(x) { + if (!arguments.length) return children; + children = x; + return hierarchy; + }; + hierarchy.value = function(x) { + if (!arguments.length) return value; + value = x; + return hierarchy; + }; + hierarchy.revalue = function(root) { + if (value) { + d3_layout_hierarchyVisitBefore(root, function(node) { + if (node.children) node.value = 0; + }); + d3_layout_hierarchyVisitAfter(root, function(node) { + var parent; + if (!node.children) node.value = +value.call(hierarchy, node, node.depth) || 0; + if (parent = node.parent) parent.value += node.value; + }); + } + return root; + }; + return hierarchy; + }; + function d3_layout_hierarchyRebind(object, hierarchy) { + d3.rebind(object, hierarchy, "sort", "children", "value"); + object.nodes = object; + object.links = d3_layout_hierarchyLinks; + return object; + } + function d3_layout_hierarchyVisitBefore(node, callback) { + var nodes = [ node ]; + while ((node = nodes.pop()) != null) { + callback(node); + if ((children = node.children) && (n = children.length)) { + var n, children; + while (--n >= 0) nodes.push(children[n]); + } + } + } + function d3_layout_hierarchyVisitAfter(node, callback) { + var nodes = [ node ], nodes2 = []; + while ((node = nodes.pop()) != null) { + nodes2.push(node); + if ((children = node.children) && (n = children.length)) { + var i = -1, n, children; + while (++i < n) nodes.push(children[i]); + } + } + while ((node = nodes2.pop()) != null) { + callback(node); + } + } + function d3_layout_hierarchyChildren(d) { + return d.children; + } + function d3_layout_hierarchyValue(d) { + return d.value; + } + function d3_layout_hierarchySort(a, b) { + return b.value - a.value; + } + function d3_layout_hierarchyLinks(nodes) { + return d3.merge(nodes.map(function(parent) { + return (parent.children || []).map(function(child) { + return { + source: parent, + target: child + }; + }); + })); + } + d3.layout.partition = function() { + var hierarchy = d3.layout.hierarchy(), size = [ 1, 1 ]; + function position(node, x, dx, dy) { + var children = node.children; + node.x = x; + node.y = node.depth * dy; + node.dx = dx; + node.dy = dy; + if (children && (n = children.length)) { + var i = -1, n, c, d; + dx = node.value ? dx / node.value : 0; + while (++i < n) { + position(c = children[i], x, d = c.value * dx, dy); + x += d; + } + } + } + function depth(node) { + var children = node.children, d = 0; + if (children && (n = children.length)) { + var i = -1, n; + while (++i < n) d = Math.max(d, depth(children[i])); + } + return 1 + d; + } + function partition(d, i) { + var nodes = hierarchy.call(this, d, i); + position(nodes[0], 0, size[0], size[1] / depth(nodes[0])); + return nodes; + } + partition.size = function(x) { + if (!arguments.length) return size; + size = x; + return partition; + }; + return d3_layout_hierarchyRebind(partition, hierarchy); + }; + d3.layout.pie = function() { + var value = Number, sort = d3_layout_pieSortByValue, startAngle = 0, endAngle = τ, padAngle = 0; + function pie(data) { + var n = data.length, values = data.map(function(d, i) { + return +value.call(pie, d, i); + }), a = +(typeof startAngle === "function" ? startAngle.apply(this, arguments) : startAngle), da = (typeof endAngle === "function" ? endAngle.apply(this, arguments) : endAngle) - a, p = Math.min(Math.abs(da) / n, +(typeof padAngle === "function" ? padAngle.apply(this, arguments) : padAngle)), pa = p * (da < 0 ? -1 : 1), sum = d3.sum(values), k = sum ? (da - n * pa) / sum : 0, index = d3.range(n), arcs = [], v; + if (sort != null) index.sort(sort === d3_layout_pieSortByValue ? function(i, j) { + return values[j] - values[i]; + } : function(i, j) { + return sort(data[i], data[j]); + }); + index.forEach(function(i) { + arcs[i] = { + data: data[i], + value: v = values[i], + startAngle: a, + endAngle: a += v * k + pa, + padAngle: p + }; + }); + return arcs; + } + pie.value = function(_) { + if (!arguments.length) return value; + value = _; + return pie; + }; + pie.sort = function(_) { + if (!arguments.length) return sort; + sort = _; + return pie; + }; + pie.startAngle = function(_) { + if (!arguments.length) return startAngle; + startAngle = _; + return pie; + }; + pie.endAngle = function(_) { + if (!arguments.length) return endAngle; + endAngle = _; + return pie; + }; + pie.padAngle = function(_) { + if (!arguments.length) return padAngle; + padAngle = _; + return pie; + }; + return pie; + }; + var d3_layout_pieSortByValue = {}; + d3.layout.stack = function() { + var values = d3_identity, order = d3_layout_stackOrderDefault, offset = d3_layout_stackOffsetZero, out = d3_layout_stackOut, x = d3_layout_stackX, y = d3_layout_stackY; + function stack(data, index) { + if (!(n = data.length)) return data; + var series = data.map(function(d, i) { + return values.call(stack, d, i); + }); + var points = series.map(function(d) { + return d.map(function(v, i) { + return [ x.call(stack, v, i), y.call(stack, v, i) ]; + }); + }); + var orders = order.call(stack, points, index); + series = d3.permute(series, orders); + points = d3.permute(points, orders); + var offsets = offset.call(stack, points, index); + var m = series[0].length, n, i, j, o; + for (j = 0; j < m; ++j) { + out.call(stack, series[0][j], o = offsets[j], points[0][j][1]); + for (i = 1; i < n; ++i) { + out.call(stack, series[i][j], o += points[i - 1][j][1], points[i][j][1]); + } + } + return data; + } + stack.values = function(x) { + if (!arguments.length) return values; + values = x; + return stack; + }; + stack.order = function(x) { + if (!arguments.length) return order; + order = typeof x === "function" ? x : d3_layout_stackOrders.get(x) || d3_layout_stackOrderDefault; + return stack; + }; + stack.offset = function(x) { + if (!arguments.length) return offset; + offset = typeof x === "function" ? x : d3_layout_stackOffsets.get(x) || d3_layout_stackOffsetZero; + return stack; + }; + stack.x = function(z) { + if (!arguments.length) return x; + x = z; + return stack; + }; + stack.y = function(z) { + if (!arguments.length) return y; + y = z; + return stack; + }; + stack.out = function(z) { + if (!arguments.length) return out; + out = z; + return stack; + }; + return stack; + }; + function d3_layout_stackX(d) { + return d.x; + } + function d3_layout_stackY(d) { + return d.y; + } + function d3_layout_stackOut(d, y0, y) { + d.y0 = y0; + d.y = y; + } + var d3_layout_stackOrders = d3.map({ + "inside-out": function(data) { + var n = data.length, i, j, max = data.map(d3_layout_stackMaxIndex), sums = data.map(d3_layout_stackReduceSum), index = d3.range(n).sort(function(a, b) { + return max[a] - max[b]; + }), top = 0, bottom = 0, tops = [], bottoms = []; + for (i = 0; i < n; ++i) { + j = index[i]; + if (top < bottom) { + top += sums[j]; + tops.push(j); + } else { + bottom += sums[j]; + bottoms.push(j); + } + } + return bottoms.reverse().concat(tops); + }, + reverse: function(data) { + return d3.range(data.length).reverse(); + }, + "default": d3_layout_stackOrderDefault + }); + var d3_layout_stackOffsets = d3.map({ + silhouette: function(data) { + var n = data.length, m = data[0].length, sums = [], max = 0, i, j, o, y0 = []; + for (j = 0; j < m; ++j) { + for (i = 0, o = 0; i < n; i++) o += data[i][j][1]; + if (o > max) max = o; + sums.push(o); + } + for (j = 0; j < m; ++j) { + y0[j] = (max - sums[j]) / 2; + } + return y0; + }, + wiggle: function(data) { + var n = data.length, x = data[0], m = x.length, i, j, k, s1, s2, s3, dx, o, o0, y0 = []; + y0[0] = o = o0 = 0; + for (j = 1; j < m; ++j) { + for (i = 0, s1 = 0; i < n; ++i) s1 += data[i][j][1]; + for (i = 0, s2 = 0, dx = x[j][0] - x[j - 1][0]; i < n; ++i) { + for (k = 0, s3 = (data[i][j][1] - data[i][j - 1][1]) / (2 * dx); k < i; ++k) { + s3 += (data[k][j][1] - data[k][j - 1][1]) / dx; + } + s2 += s3 * data[i][j][1]; + } + y0[j] = o -= s1 ? s2 / s1 * dx : 0; + if (o < o0) o0 = o; + } + for (j = 0; j < m; ++j) y0[j] -= o0; + return y0; + }, + expand: function(data) { + var n = data.length, m = data[0].length, k = 1 / n, i, j, o, y0 = []; + for (j = 0; j < m; ++j) { + for (i = 0, o = 0; i < n; i++) o += data[i][j][1]; + if (o) for (i = 0; i < n; i++) data[i][j][1] /= o; else for (i = 0; i < n; i++) data[i][j][1] = k; + } + for (j = 0; j < m; ++j) y0[j] = 0; + return y0; + }, + zero: d3_layout_stackOffsetZero + }); + function d3_layout_stackOrderDefault(data) { + return d3.range(data.length); + } + function d3_layout_stackOffsetZero(data) { + var j = -1, m = data[0].length, y0 = []; + while (++j < m) y0[j] = 0; + return y0; + } + function d3_layout_stackMaxIndex(array) { + var i = 1, j = 0, v = array[0][1], k, n = array.length; + for (;i < n; ++i) { + if ((k = array[i][1]) > v) { + j = i; + v = k; + } + } + return j; + } + function d3_layout_stackReduceSum(d) { + return d.reduce(d3_layout_stackSum, 0); + } + function d3_layout_stackSum(p, d) { + return p + d[1]; + } + d3.layout.histogram = function() { + var frequency = true, valuer = Number, ranger = d3_layout_histogramRange, binner = d3_layout_histogramBinSturges; + function histogram(data, i) { + var bins = [], values = data.map(valuer, this), range = ranger.call(this, values, i), thresholds = binner.call(this, range, values, i), bin, i = -1, n = values.length, m = thresholds.length - 1, k = frequency ? 1 : 1 / n, x; + while (++i < m) { + bin = bins[i] = []; + bin.dx = thresholds[i + 1] - (bin.x = thresholds[i]); + bin.y = 0; + } + if (m > 0) { + i = -1; + while (++i < n) { + x = values[i]; + if (x >= range[0] && x <= range[1]) { + bin = bins[d3.bisect(thresholds, x, 1, m) - 1]; + bin.y += k; + bin.push(data[i]); + } + } + } + return bins; + } + histogram.value = function(x) { + if (!arguments.length) return valuer; + valuer = x; + return histogram; + }; + histogram.range = function(x) { + if (!arguments.length) return ranger; + ranger = d3_functor(x); + return histogram; + }; + histogram.bins = function(x) { + if (!arguments.length) return binner; + binner = typeof x === "number" ? function(range) { + return d3_layout_histogramBinFixed(range, x); + } : d3_functor(x); + return histogram; + }; + histogram.frequency = function(x) { + if (!arguments.length) return frequency; + frequency = !!x; + return histogram; + }; + return histogram; + }; + function d3_layout_histogramBinSturges(range, values) { + return d3_layout_histogramBinFixed(range, Math.ceil(Math.log(values.length) / Math.LN2 + 1)); + } + function d3_layout_histogramBinFixed(range, n) { + var x = -1, b = +range[0], m = (range[1] - b) / n, f = []; + while (++x <= n) f[x] = m * x + b; + return f; + } + function d3_layout_histogramRange(values) { + return [ d3.min(values), d3.max(values) ]; + } + d3.layout.pack = function() { + var hierarchy = d3.layout.hierarchy().sort(d3_layout_packSort), padding = 0, size = [ 1, 1 ], radius; + function pack(d, i) { + var nodes = hierarchy.call(this, d, i), root = nodes[0], w = size[0], h = size[1], r = radius == null ? Math.sqrt : typeof radius === "function" ? radius : function() { + return radius; + }; + root.x = root.y = 0; + d3_layout_hierarchyVisitAfter(root, function(d) { + d.r = +r(d.value); + }); + d3_layout_hierarchyVisitAfter(root, d3_layout_packSiblings); + if (padding) { + var dr = padding * (radius ? 1 : Math.max(2 * root.r / w, 2 * root.r / h)) / 2; + d3_layout_hierarchyVisitAfter(root, function(d) { + d.r += dr; + }); + d3_layout_hierarchyVisitAfter(root, d3_layout_packSiblings); + d3_layout_hierarchyVisitAfter(root, function(d) { + d.r -= dr; + }); + } + d3_layout_packTransform(root, w / 2, h / 2, radius ? 1 : 1 / Math.max(2 * root.r / w, 2 * root.r / h)); + return nodes; + } + pack.size = function(_) { + if (!arguments.length) return size; + size = _; + return pack; + }; + pack.radius = function(_) { + if (!arguments.length) return radius; + radius = _ == null || typeof _ === "function" ? _ : +_; + return pack; + }; + pack.padding = function(_) { + if (!arguments.length) return padding; + padding = +_; + return pack; + }; + return d3_layout_hierarchyRebind(pack, hierarchy); + }; + function d3_layout_packSort(a, b) { + return a.value - b.value; + } + function d3_layout_packInsert(a, b) { + var c = a._pack_next; + a._pack_next = b; + b._pack_prev = a; + b._pack_next = c; + c._pack_prev = b; + } + function d3_layout_packSplice(a, b) { + a._pack_next = b; + b._pack_prev = a; + } + function d3_layout_packIntersects(a, b) { + var dx = b.x - a.x, dy = b.y - a.y, dr = a.r + b.r; + return .999 * dr * dr > dx * dx + dy * dy; + } + function d3_layout_packSiblings(node) { + if (!(nodes = node.children) || !(n = nodes.length)) return; + var nodes, xMin = Infinity, xMax = -Infinity, yMin = Infinity, yMax = -Infinity, a, b, c, i, j, k, n; + function bound(node) { + xMin = Math.min(node.x - node.r, xMin); + xMax = Math.max(node.x + node.r, xMax); + yMin = Math.min(node.y - node.r, yMin); + yMax = Math.max(node.y + node.r, yMax); + } + nodes.forEach(d3_layout_packLink); + a = nodes[0]; + a.x = -a.r; + a.y = 0; + bound(a); + if (n > 1) { + b = nodes[1]; + b.x = b.r; + b.y = 0; + bound(b); + if (n > 2) { + c = nodes[2]; + d3_layout_packPlace(a, b, c); + bound(c); + d3_layout_packInsert(a, c); + a._pack_prev = c; + d3_layout_packInsert(c, b); + b = a._pack_next; + for (i = 3; i < n; i++) { + d3_layout_packPlace(a, b, c = nodes[i]); + var isect = 0, s1 = 1, s2 = 1; + for (j = b._pack_next; j !== b; j = j._pack_next, s1++) { + if (d3_layout_packIntersects(j, c)) { + isect = 1; + break; + } + } + if (isect == 1) { + for (k = a._pack_prev; k !== j._pack_prev; k = k._pack_prev, s2++) { + if (d3_layout_packIntersects(k, c)) { + break; + } + } + } + if (isect) { + if (s1 < s2 || s1 == s2 && b.r < a.r) d3_layout_packSplice(a, b = j); else d3_layout_packSplice(a = k, b); + i--; + } else { + d3_layout_packInsert(a, c); + b = c; + bound(c); + } + } + } + } + var cx = (xMin + xMax) / 2, cy = (yMin + yMax) / 2, cr = 0; + for (i = 0; i < n; i++) { + c = nodes[i]; + c.x -= cx; + c.y -= cy; + cr = Math.max(cr, c.r + Math.sqrt(c.x * c.x + c.y * c.y)); + } + node.r = cr; + nodes.forEach(d3_layout_packUnlink); + } + function d3_layout_packLink(node) { + node._pack_next = node._pack_prev = node; + } + function d3_layout_packUnlink(node) { + delete node._pack_next; + delete node._pack_prev; + } + function d3_layout_packTransform(node, x, y, k) { + var children = node.children; + node.x = x += k * node.x; + node.y = y += k * node.y; + node.r *= k; + if (children) { + var i = -1, n = children.length; + while (++i < n) d3_layout_packTransform(children[i], x, y, k); + } + } + function d3_layout_packPlace(a, b, c) { + var db = a.r + c.r, dx = b.x - a.x, dy = b.y - a.y; + if (db && (dx || dy)) { + var da = b.r + c.r, dc = dx * dx + dy * dy; + da *= da; + db *= db; + var x = .5 + (db - da) / (2 * dc), y = Math.sqrt(Math.max(0, 2 * da * (db + dc) - (db -= dc) * db - da * da)) / (2 * dc); + c.x = a.x + x * dx + y * dy; + c.y = a.y + x * dy - y * dx; + } else { + c.x = a.x + db; + c.y = a.y; + } + } + d3.layout.tree = function() { + var hierarchy = d3.layout.hierarchy().sort(null).value(null), separation = d3_layout_treeSeparation, size = [ 1, 1 ], nodeSize = null; + function tree(d, i) { + var nodes = hierarchy.call(this, d, i), root0 = nodes[0], root1 = wrapTree(root0); + d3_layout_hierarchyVisitAfter(root1, firstWalk), root1.parent.m = -root1.z; + d3_layout_hierarchyVisitBefore(root1, secondWalk); + if (nodeSize) d3_layout_hierarchyVisitBefore(root0, sizeNode); else { + var left = root0, right = root0, bottom = root0; + d3_layout_hierarchyVisitBefore(root0, function(node) { + if (node.x < left.x) left = node; + if (node.x > right.x) right = node; + if (node.depth > bottom.depth) bottom = node; + }); + var tx = separation(left, right) / 2 - left.x, kx = size[0] / (right.x + separation(right, left) / 2 + tx), ky = size[1] / (bottom.depth || 1); + d3_layout_hierarchyVisitBefore(root0, function(node) { + node.x = (node.x + tx) * kx; + node.y = node.depth * ky; + }); + } + return nodes; + } + function wrapTree(root0) { + var root1 = { + A: null, + children: [ root0 ] + }, queue = [ root1 ], node1; + while ((node1 = queue.pop()) != null) { + for (var children = node1.children, child, i = 0, n = children.length; i < n; ++i) { + queue.push((children[i] = child = { + _: children[i], + parent: node1, + children: (child = children[i].children) && child.slice() || [], + A: null, + a: null, + z: 0, + m: 0, + c: 0, + s: 0, + t: null, + i: i + }).a = child); + } + } + return root1.children[0]; + } + function firstWalk(v) { + var children = v.children, siblings = v.parent.children, w = v.i ? siblings[v.i - 1] : null; + if (children.length) { + d3_layout_treeShift(v); + var midpoint = (children[0].z + children[children.length - 1].z) / 2; + if (w) { + v.z = w.z + separation(v._, w._); + v.m = v.z - midpoint; + } else { + v.z = midpoint; + } + } else if (w) { + v.z = w.z + separation(v._, w._); + } + v.parent.A = apportion(v, w, v.parent.A || siblings[0]); + } + function secondWalk(v) { + v._.x = v.z + v.parent.m; + v.m += v.parent.m; + } + function apportion(v, w, ancestor) { + if (w) { + var vip = v, vop = v, vim = w, vom = vip.parent.children[0], sip = vip.m, sop = vop.m, sim = vim.m, som = vom.m, shift; + while (vim = d3_layout_treeRight(vim), vip = d3_layout_treeLeft(vip), vim && vip) { + vom = d3_layout_treeLeft(vom); + vop = d3_layout_treeRight(vop); + vop.a = v; + shift = vim.z + sim - vip.z - sip + separation(vim._, vip._); + if (shift > 0) { + d3_layout_treeMove(d3_layout_treeAncestor(vim, v, ancestor), v, shift); + sip += shift; + sop += shift; + } + sim += vim.m; + sip += vip.m; + som += vom.m; + sop += vop.m; + } + if (vim && !d3_layout_treeRight(vop)) { + vop.t = vim; + vop.m += sim - sop; + } + if (vip && !d3_layout_treeLeft(vom)) { + vom.t = vip; + vom.m += sip - som; + ancestor = v; + } + } + return ancestor; + } + function sizeNode(node) { + node.x *= size[0]; + node.y = node.depth * size[1]; + } + tree.separation = function(x) { + if (!arguments.length) return separation; + separation = x; + return tree; + }; + tree.size = function(x) { + if (!arguments.length) return nodeSize ? null : size; + nodeSize = (size = x) == null ? sizeNode : null; + return tree; + }; + tree.nodeSize = function(x) { + if (!arguments.length) return nodeSize ? size : null; + nodeSize = (size = x) == null ? null : sizeNode; + return tree; + }; + return d3_layout_hierarchyRebind(tree, hierarchy); + }; + function d3_layout_treeSeparation(a, b) { + return a.parent == b.parent ? 1 : 2; + } + function d3_layout_treeLeft(v) { + var children = v.children; + return children.length ? children[0] : v.t; + } + function d3_layout_treeRight(v) { + var children = v.children, n; + return (n = children.length) ? children[n - 1] : v.t; + } + function d3_layout_treeMove(wm, wp, shift) { + var change = shift / (wp.i - wm.i); + wp.c -= change; + wp.s += shift; + wm.c += change; + wp.z += shift; + wp.m += shift; + } + function d3_layout_treeShift(v) { + var shift = 0, change = 0, children = v.children, i = children.length, w; + while (--i >= 0) { + w = children[i]; + w.z += shift; + w.m += shift; + shift += w.s + (change += w.c); + } + } + function d3_layout_treeAncestor(vim, v, ancestor) { + return vim.a.parent === v.parent ? vim.a : ancestor; + } + d3.layout.cluster = function() { + var hierarchy = d3.layout.hierarchy().sort(null).value(null), separation = d3_layout_treeSeparation, size = [ 1, 1 ], nodeSize = false; + function cluster(d, i) { + var nodes = hierarchy.call(this, d, i), root = nodes[0], previousNode, x = 0; + d3_layout_hierarchyVisitAfter(root, function(node) { + var children = node.children; + if (children && children.length) { + node.x = d3_layout_clusterX(children); + node.y = d3_layout_clusterY(children); + } else { + node.x = previousNode ? x += separation(node, previousNode) : 0; + node.y = 0; + previousNode = node; + } + }); + var left = d3_layout_clusterLeft(root), right = d3_layout_clusterRight(root), x0 = left.x - separation(left, right) / 2, x1 = right.x + separation(right, left) / 2; + d3_layout_hierarchyVisitAfter(root, nodeSize ? function(node) { + node.x = (node.x - root.x) * size[0]; + node.y = (root.y - node.y) * size[1]; + } : function(node) { + node.x = (node.x - x0) / (x1 - x0) * size[0]; + node.y = (1 - (root.y ? node.y / root.y : 1)) * size[1]; + }); + return nodes; + } + cluster.separation = function(x) { + if (!arguments.length) return separation; + separation = x; + return cluster; + }; + cluster.size = function(x) { + if (!arguments.length) return nodeSize ? null : size; + nodeSize = (size = x) == null; + return cluster; + }; + cluster.nodeSize = function(x) { + if (!arguments.length) return nodeSize ? size : null; + nodeSize = (size = x) != null; + return cluster; + }; + return d3_layout_hierarchyRebind(cluster, hierarchy); + }; + function d3_layout_clusterY(children) { + return 1 + d3.max(children, function(child) { + return child.y; + }); + } + function d3_layout_clusterX(children) { + return children.reduce(function(x, child) { + return x + child.x; + }, 0) / children.length; + } + function d3_layout_clusterLeft(node) { + var children = node.children; + return children && children.length ? d3_layout_clusterLeft(children[0]) : node; + } + function d3_layout_clusterRight(node) { + var children = node.children, n; + return children && (n = children.length) ? d3_layout_clusterRight(children[n - 1]) : node; + } + d3.layout.treemap = function() { + var hierarchy = d3.layout.hierarchy(), round = Math.round, size = [ 1, 1 ], padding = null, pad = d3_layout_treemapPadNull, sticky = false, stickies, mode = "squarify", ratio = .5 * (1 + Math.sqrt(5)); + function scale(children, k) { + var i = -1, n = children.length, child, area; + while (++i < n) { + area = (child = children[i]).value * (k < 0 ? 0 : k); + child.area = isNaN(area) || area <= 0 ? 0 : area; + } + } + function squarify(node) { + var children = node.children; + if (children && children.length) { + var rect = pad(node), row = [], remaining = children.slice(), child, best = Infinity, score, u = mode === "slice" ? rect.dx : mode === "dice" ? rect.dy : mode === "slice-dice" ? node.depth & 1 ? rect.dy : rect.dx : Math.min(rect.dx, rect.dy), n; + scale(remaining, rect.dx * rect.dy / node.value); + row.area = 0; + while ((n = remaining.length) > 0) { + row.push(child = remaining[n - 1]); + row.area += child.area; + if (mode !== "squarify" || (score = worst(row, u)) <= best) { + remaining.pop(); + best = score; + } else { + row.area -= row.pop().area; + position(row, u, rect, false); + u = Math.min(rect.dx, rect.dy); + row.length = row.area = 0; + best = Infinity; + } + } + if (row.length) { + position(row, u, rect, true); + row.length = row.area = 0; + } + children.forEach(squarify); + } + } + function stickify(node) { + var children = node.children; + if (children && children.length) { + var rect = pad(node), remaining = children.slice(), child, row = []; + scale(remaining, rect.dx * rect.dy / node.value); + row.area = 0; + while (child = remaining.pop()) { + row.push(child); + row.area += child.area; + if (child.z != null) { + position(row, child.z ? rect.dx : rect.dy, rect, !remaining.length); + row.length = row.area = 0; + } + } + children.forEach(stickify); + } + } + function worst(row, u) { + var s = row.area, r, rmax = 0, rmin = Infinity, i = -1, n = row.length; + while (++i < n) { + if (!(r = row[i].area)) continue; + if (r < rmin) rmin = r; + if (r > rmax) rmax = r; + } + s *= s; + u *= u; + return s ? Math.max(u * rmax * ratio / s, s / (u * rmin * ratio)) : Infinity; + } + function position(row, u, rect, flush) { + var i = -1, n = row.length, x = rect.x, y = rect.y, v = u ? round(row.area / u) : 0, o; + if (u == rect.dx) { + if (flush || v > rect.dy) v = rect.dy; + while (++i < n) { + o = row[i]; + o.x = x; + o.y = y; + o.dy = v; + x += o.dx = Math.min(rect.x + rect.dx - x, v ? round(o.area / v) : 0); + } + o.z = true; + o.dx += rect.x + rect.dx - x; + rect.y += v; + rect.dy -= v; + } else { + if (flush || v > rect.dx) v = rect.dx; + while (++i < n) { + o = row[i]; + o.x = x; + o.y = y; + o.dx = v; + y += o.dy = Math.min(rect.y + rect.dy - y, v ? round(o.area / v) : 0); + } + o.z = false; + o.dy += rect.y + rect.dy - y; + rect.x += v; + rect.dx -= v; + } + } + function treemap(d) { + var nodes = stickies || hierarchy(d), root = nodes[0]; + root.x = root.y = 0; + if (root.value) root.dx = size[0], root.dy = size[1]; else root.dx = root.dy = 0; + if (stickies) hierarchy.revalue(root); + scale([ root ], root.dx * root.dy / root.value); + (stickies ? stickify : squarify)(root); + if (sticky) stickies = nodes; + return nodes; + } + treemap.size = function(x) { + if (!arguments.length) return size; + size = x; + return treemap; + }; + treemap.padding = function(x) { + if (!arguments.length) return padding; + function padFunction(node) { + var p = x.call(treemap, node, node.depth); + return p == null ? d3_layout_treemapPadNull(node) : d3_layout_treemapPad(node, typeof p === "number" ? [ p, p, p, p ] : p); + } + function padConstant(node) { + return d3_layout_treemapPad(node, x); + } + var type; + pad = (padding = x) == null ? d3_layout_treemapPadNull : (type = typeof x) === "function" ? padFunction : type === "number" ? (x = [ x, x, x, x ], + padConstant) : padConstant; + return treemap; + }; + treemap.round = function(x) { + if (!arguments.length) return round != Number; + round = x ? Math.round : Number; + return treemap; + }; + treemap.sticky = function(x) { + if (!arguments.length) return sticky; + sticky = x; + stickies = null; + return treemap; + }; + treemap.ratio = function(x) { + if (!arguments.length) return ratio; + ratio = x; + return treemap; + }; + treemap.mode = function(x) { + if (!arguments.length) return mode; + mode = x + ""; + return treemap; + }; + return d3_layout_hierarchyRebind(treemap, hierarchy); + }; + function d3_layout_treemapPadNull(node) { + return { + x: node.x, + y: node.y, + dx: node.dx, + dy: node.dy + }; + } + function d3_layout_treemapPad(node, padding) { + var x = node.x + padding[3], y = node.y + padding[0], dx = node.dx - padding[1] - padding[3], dy = node.dy - padding[0] - padding[2]; + if (dx < 0) { + x += dx / 2; + dx = 0; + } + if (dy < 0) { + y += dy / 2; + dy = 0; + } + return { + x: x, + y: y, + dx: dx, + dy: dy + }; + } + d3.random = { + normal: function(µ, σ) { + var n = arguments.length; + if (n < 2) σ = 1; + if (n < 1) µ = 0; + return function() { + var x, y, r; + do { + x = Math.random() * 2 - 1; + y = Math.random() * 2 - 1; + r = x * x + y * y; + } while (!r || r > 1); + return µ + σ * x * Math.sqrt(-2 * Math.log(r) / r); + }; + }, + logNormal: function() { + var random = d3.random.normal.apply(d3, arguments); + return function() { + return Math.exp(random()); + }; + }, + bates: function(m) { + var random = d3.random.irwinHall(m); + return function() { + return random() / m; + }; + }, + irwinHall: function(m) { + return function() { + for (var s = 0, j = 0; j < m; j++) s += Math.random(); + return s; + }; + } + }; + d3.scale = {}; + function d3_scaleExtent(domain) { + var start = domain[0], stop = domain[domain.length - 1]; + return start < stop ? [ start, stop ] : [ stop, start ]; + } + function d3_scaleRange(scale) { + return scale.rangeExtent ? scale.rangeExtent() : d3_scaleExtent(scale.range()); + } + function d3_scale_bilinear(domain, range, uninterpolate, interpolate) { + var u = uninterpolate(domain[0], domain[1]), i = interpolate(range[0], range[1]); + return function(x) { + return i(u(x)); + }; + } + function d3_scale_nice(domain, nice) { + var i0 = 0, i1 = domain.length - 1, x0 = domain[i0], x1 = domain[i1], dx; + if (x1 < x0) { + dx = i0, i0 = i1, i1 = dx; + dx = x0, x0 = x1, x1 = dx; + } + domain[i0] = nice.floor(x0); + domain[i1] = nice.ceil(x1); + return domain; + } + function d3_scale_niceStep(step) { + return step ? { + floor: function(x) { + return Math.floor(x / step) * step; + }, + ceil: function(x) { + return Math.ceil(x / step) * step; + } + } : d3_scale_niceIdentity; + } + var d3_scale_niceIdentity = { + floor: d3_identity, + ceil: d3_identity + }; + function d3_scale_polylinear(domain, range, uninterpolate, interpolate) { + var u = [], i = [], j = 0, k = Math.min(domain.length, range.length) - 1; + if (domain[k] < domain[0]) { + domain = domain.slice().reverse(); + range = range.slice().reverse(); + } + while (++j <= k) { + u.push(uninterpolate(domain[j - 1], domain[j])); + i.push(interpolate(range[j - 1], range[j])); + } + return function(x) { + var j = d3.bisect(domain, x, 1, k) - 1; + return i[j](u[j](x)); + }; + } + d3.scale.linear = function() { + return d3_scale_linear([ 0, 1 ], [ 0, 1 ], d3_interpolate, false); + }; + function d3_scale_linear(domain, range, interpolate, clamp) { + var output, input; + function rescale() { + var linear = Math.min(domain.length, range.length) > 2 ? d3_scale_polylinear : d3_scale_bilinear, uninterpolate = clamp ? d3_uninterpolateClamp : d3_uninterpolateNumber; + output = linear(domain, range, uninterpolate, interpolate); + input = linear(range, domain, uninterpolate, d3_interpolate); + return scale; + } + function scale(x) { + return output(x); + } + scale.invert = function(y) { + return input(y); + }; + scale.domain = function(x) { + if (!arguments.length) return domain; + domain = x.map(Number); + return rescale(); + }; + scale.range = function(x) { + if (!arguments.length) return range; + range = x; + return rescale(); + }; + scale.rangeRound = function(x) { + return scale.range(x).interpolate(d3_interpolateRound); + }; + scale.clamp = function(x) { + if (!arguments.length) return clamp; + clamp = x; + return rescale(); + }; + scale.interpolate = function(x) { + if (!arguments.length) return interpolate; + interpolate = x; + return rescale(); + }; + scale.ticks = function(m) { + return d3_scale_linearTicks(domain, m); + }; + scale.tickFormat = function(m, format) { + return d3_scale_linearTickFormat(domain, m, format); + }; + scale.nice = function(m) { + d3_scale_linearNice(domain, m); + return rescale(); + }; + scale.copy = function() { + return d3_scale_linear(domain, range, interpolate, clamp); + }; + return rescale(); + } + function d3_scale_linearRebind(scale, linear) { + return d3.rebind(scale, linear, "range", "rangeRound", "interpolate", "clamp"); + } + function d3_scale_linearNice(domain, m) { + d3_scale_nice(domain, d3_scale_niceStep(d3_scale_linearTickRange(domain, m)[2])); + d3_scale_nice(domain, d3_scale_niceStep(d3_scale_linearTickRange(domain, m)[2])); + return domain; + } + function d3_scale_linearTickRange(domain, m) { + if (m == null) m = 10; + var extent = d3_scaleExtent(domain), span = extent[1] - extent[0], step = Math.pow(10, Math.floor(Math.log(span / m) / Math.LN10)), err = m / span * step; + if (err <= .15) step *= 10; else if (err <= .35) step *= 5; else if (err <= .75) step *= 2; + extent[0] = Math.ceil(extent[0] / step) * step; + extent[1] = Math.floor(extent[1] / step) * step + step * .5; + extent[2] = step; + return extent; + } + function d3_scale_linearTicks(domain, m) { + return d3.range.apply(d3, d3_scale_linearTickRange(domain, m)); + } + function d3_scale_linearTickFormat(domain, m, format) { + var range = d3_scale_linearTickRange(domain, m); + if (format) { + var match = d3_format_re.exec(format); + match.shift(); + if (match[8] === "s") { + var prefix = d3.formatPrefix(Math.max(abs(range[0]), abs(range[1]))); + if (!match[7]) match[7] = "." + d3_scale_linearPrecision(prefix.scale(range[2])); + match[8] = "f"; + format = d3.format(match.join("")); + return function(d) { + return format(prefix.scale(d)) + prefix.symbol; + }; + } + if (!match[7]) match[7] = "." + d3_scale_linearFormatPrecision(match[8], range); + format = match.join(""); + } else { + format = ",." + d3_scale_linearPrecision(range[2]) + "f"; + } + return d3.format(format); + } + var d3_scale_linearFormatSignificant = { + s: 1, + g: 1, + p: 1, + r: 1, + e: 1 + }; + function d3_scale_linearPrecision(value) { + return -Math.floor(Math.log(value) / Math.LN10 + .01); + } + function d3_scale_linearFormatPrecision(type, range) { + var p = d3_scale_linearPrecision(range[2]); + return type in d3_scale_linearFormatSignificant ? Math.abs(p - d3_scale_linearPrecision(Math.max(abs(range[0]), abs(range[1])))) + +(type !== "e") : p - (type === "%") * 2; + } + d3.scale.log = function() { + return d3_scale_log(d3.scale.linear().domain([ 0, 1 ]), 10, true, [ 1, 10 ]); + }; + function d3_scale_log(linear, base, positive, domain) { + function log(x) { + return (positive ? Math.log(x < 0 ? 0 : x) : -Math.log(x > 0 ? 0 : -x)) / Math.log(base); + } + function pow(x) { + return positive ? Math.pow(base, x) : -Math.pow(base, -x); + } + function scale(x) { + return linear(log(x)); + } + scale.invert = function(x) { + return pow(linear.invert(x)); + }; + scale.domain = function(x) { + if (!arguments.length) return domain; + positive = x[0] >= 0; + linear.domain((domain = x.map(Number)).map(log)); + return scale; + }; + scale.base = function(_) { + if (!arguments.length) return base; + base = +_; + linear.domain(domain.map(log)); + return scale; + }; + scale.nice = function() { + var niced = d3_scale_nice(domain.map(log), positive ? Math : d3_scale_logNiceNegative); + linear.domain(niced); + domain = niced.map(pow); + return scale; + }; + scale.ticks = function() { + var extent = d3_scaleExtent(domain), ticks = [], u = extent[0], v = extent[1], i = Math.floor(log(u)), j = Math.ceil(log(v)), n = base % 1 ? 2 : base; + if (isFinite(j - i)) { + if (positive) { + for (;i < j; i++) for (var k = 1; k < n; k++) ticks.push(pow(i) * k); + ticks.push(pow(i)); + } else { + ticks.push(pow(i)); + for (;i++ < j; ) for (var k = n - 1; k > 0; k--) ticks.push(pow(i) * k); + } + for (i = 0; ticks[i] < u; i++) {} + for (j = ticks.length; ticks[j - 1] > v; j--) {} + ticks = ticks.slice(i, j); + } + return ticks; + }; + scale.tickFormat = function(n, format) { + if (!arguments.length) return d3_scale_logFormat; + if (arguments.length < 2) format = d3_scale_logFormat; else if (typeof format !== "function") format = d3.format(format); + var k = Math.max(1, base * n / scale.ticks().length); + return function(d) { + var i = d / pow(Math.round(log(d))); + if (i * base < base - .5) i *= base; + return i <= k ? format(d) : ""; + }; + }; + scale.copy = function() { + return d3_scale_log(linear.copy(), base, positive, domain); + }; + return d3_scale_linearRebind(scale, linear); + } + var d3_scale_logFormat = d3.format(".0e"), d3_scale_logNiceNegative = { + floor: function(x) { + return -Math.ceil(-x); + }, + ceil: function(x) { + return -Math.floor(-x); + } + }; + d3.scale.pow = function() { + return d3_scale_pow(d3.scale.linear(), 1, [ 0, 1 ]); + }; + function d3_scale_pow(linear, exponent, domain) { + var powp = d3_scale_powPow(exponent), powb = d3_scale_powPow(1 / exponent); + function scale(x) { + return linear(powp(x)); + } + scale.invert = function(x) { + return powb(linear.invert(x)); + }; + scale.domain = function(x) { + if (!arguments.length) return domain; + linear.domain((domain = x.map(Number)).map(powp)); + return scale; + }; + scale.ticks = function(m) { + return d3_scale_linearTicks(domain, m); + }; + scale.tickFormat = function(m, format) { + return d3_scale_linearTickFormat(domain, m, format); + }; + scale.nice = function(m) { + return scale.domain(d3_scale_linearNice(domain, m)); + }; + scale.exponent = function(x) { + if (!arguments.length) return exponent; + powp = d3_scale_powPow(exponent = x); + powb = d3_scale_powPow(1 / exponent); + linear.domain(domain.map(powp)); + return scale; + }; + scale.copy = function() { + return d3_scale_pow(linear.copy(), exponent, domain); + }; + return d3_scale_linearRebind(scale, linear); + } + function d3_scale_powPow(e) { + return function(x) { + return x < 0 ? -Math.pow(-x, e) : Math.pow(x, e); + }; + } + d3.scale.sqrt = function() { + return d3.scale.pow().exponent(.5); + }; + d3.scale.ordinal = function() { + return d3_scale_ordinal([], { + t: "range", + a: [ [] ] + }); + }; + function d3_scale_ordinal(domain, ranger) { + var index, range, rangeBand; + function scale(x) { + return range[((index.get(x) || (ranger.t === "range" ? index.set(x, domain.push(x)) : NaN)) - 1) % range.length]; + } + function steps(start, step) { + return d3.range(domain.length).map(function(i) { + return start + step * i; + }); + } + scale.domain = function(x) { + if (!arguments.length) return domain; + domain = []; + index = new d3_Map(); + var i = -1, n = x.length, xi; + while (++i < n) if (!index.has(xi = x[i])) index.set(xi, domain.push(xi)); + return scale[ranger.t].apply(scale, ranger.a); + }; + scale.range = function(x) { + if (!arguments.length) return range; + range = x; + rangeBand = 0; + ranger = { + t: "range", + a: arguments + }; + return scale; + }; + scale.rangePoints = function(x, padding) { + if (arguments.length < 2) padding = 0; + var start = x[0], stop = x[1], step = domain.length < 2 ? (start = (start + stop) / 2, + 0) : (stop - start) / (domain.length - 1 + padding); + range = steps(start + step * padding / 2, step); + rangeBand = 0; + ranger = { + t: "rangePoints", + a: arguments + }; + return scale; + }; + scale.rangeRoundPoints = function(x, padding) { + if (arguments.length < 2) padding = 0; + var start = x[0], stop = x[1], step = domain.length < 2 ? (start = stop = Math.round((start + stop) / 2), + 0) : (stop - start) / (domain.length - 1 + padding) | 0; + range = steps(start + Math.round(step * padding / 2 + (stop - start - (domain.length - 1 + padding) * step) / 2), step); + rangeBand = 0; + ranger = { + t: "rangeRoundPoints", + a: arguments + }; + return scale; + }; + scale.rangeBands = function(x, padding, outerPadding) { + if (arguments.length < 2) padding = 0; + if (arguments.length < 3) outerPadding = padding; + var reverse = x[1] < x[0], start = x[reverse - 0], stop = x[1 - reverse], step = (stop - start) / (domain.length - padding + 2 * outerPadding); + range = steps(start + step * outerPadding, step); + if (reverse) range.reverse(); + rangeBand = step * (1 - padding); + ranger = { + t: "rangeBands", + a: arguments + }; + return scale; + }; + scale.rangeRoundBands = function(x, padding, outerPadding) { + if (arguments.length < 2) padding = 0; + if (arguments.length < 3) outerPadding = padding; + var reverse = x[1] < x[0], start = x[reverse - 0], stop = x[1 - reverse], step = Math.floor((stop - start) / (domain.length - padding + 2 * outerPadding)); + range = steps(start + Math.round((stop - start - (domain.length - padding) * step) / 2), step); + if (reverse) range.reverse(); + rangeBand = Math.round(step * (1 - padding)); + ranger = { + t: "rangeRoundBands", + a: arguments + }; + return scale; + }; + scale.rangeBand = function() { + return rangeBand; + }; + scale.rangeExtent = function() { + return d3_scaleExtent(ranger.a[0]); + }; + scale.copy = function() { + return d3_scale_ordinal(domain, ranger); + }; + return scale.domain(domain); + } + d3.scale.category10 = function() { + return d3.scale.ordinal().range(d3_category10); + }; + d3.scale.category20 = function() { + return d3.scale.ordinal().range(d3_category20); + }; + d3.scale.category20b = function() { + return d3.scale.ordinal().range(d3_category20b); + }; + d3.scale.category20c = function() { + return d3.scale.ordinal().range(d3_category20c); + }; + var d3_category10 = [ 2062260, 16744206, 2924588, 14034728, 9725885, 9197131, 14907330, 8355711, 12369186, 1556175 ].map(d3_rgbString); + var d3_category20 = [ 2062260, 11454440, 16744206, 16759672, 2924588, 10018698, 14034728, 16750742, 9725885, 12955861, 9197131, 12885140, 14907330, 16234194, 8355711, 13092807, 12369186, 14408589, 1556175, 10410725 ].map(d3_rgbString); + var d3_category20b = [ 3750777, 5395619, 7040719, 10264286, 6519097, 9216594, 11915115, 13556636, 9202993, 12426809, 15186514, 15190932, 8666169, 11356490, 14049643, 15177372, 8077683, 10834324, 13528509, 14589654 ].map(d3_rgbString); + var d3_category20c = [ 3244733, 7057110, 10406625, 13032431, 15095053, 16616764, 16625259, 16634018, 3253076, 7652470, 10607003, 13101504, 7695281, 10394312, 12369372, 14342891, 6513507, 9868950, 12434877, 14277081 ].map(d3_rgbString); + d3.scale.quantile = function() { + return d3_scale_quantile([], []); + }; + function d3_scale_quantile(domain, range) { + var thresholds; + function rescale() { + var k = 0, q = range.length; + thresholds = []; + while (++k < q) thresholds[k - 1] = d3.quantile(domain, k / q); + return scale; + } + function scale(x) { + if (!isNaN(x = +x)) return range[d3.bisect(thresholds, x)]; + } + scale.domain = function(x) { + if (!arguments.length) return domain; + domain = x.map(d3_number).filter(d3_numeric).sort(d3_ascending); + return rescale(); + }; + scale.range = function(x) { + if (!arguments.length) return range; + range = x; + return rescale(); + }; + scale.quantiles = function() { + return thresholds; + }; + scale.invertExtent = function(y) { + y = range.indexOf(y); + return y < 0 ? [ NaN, NaN ] : [ y > 0 ? thresholds[y - 1] : domain[0], y < thresholds.length ? thresholds[y] : domain[domain.length - 1] ]; + }; + scale.copy = function() { + return d3_scale_quantile(domain, range); + }; + return rescale(); + } + d3.scale.quantize = function() { + return d3_scale_quantize(0, 1, [ 0, 1 ]); + }; + function d3_scale_quantize(x0, x1, range) { + var kx, i; + function scale(x) { + return range[Math.max(0, Math.min(i, Math.floor(kx * (x - x0))))]; + } + function rescale() { + kx = range.length / (x1 - x0); + i = range.length - 1; + return scale; + } + scale.domain = function(x) { + if (!arguments.length) return [ x0, x1 ]; + x0 = +x[0]; + x1 = +x[x.length - 1]; + return rescale(); + }; + scale.range = function(x) { + if (!arguments.length) return range; + range = x; + return rescale(); + }; + scale.invertExtent = function(y) { + y = range.indexOf(y); + y = y < 0 ? NaN : y / kx + x0; + return [ y, y + 1 / kx ]; + }; + scale.copy = function() { + return d3_scale_quantize(x0, x1, range); + }; + return rescale(); + } + d3.scale.threshold = function() { + return d3_scale_threshold([ .5 ], [ 0, 1 ]); + }; + function d3_scale_threshold(domain, range) { + function scale(x) { + if (x <= x) return range[d3.bisect(domain, x)]; + } + scale.domain = function(_) { + if (!arguments.length) return domain; + domain = _; + return scale; + }; + scale.range = function(_) { + if (!arguments.length) return range; + range = _; + return scale; + }; + scale.invertExtent = function(y) { + y = range.indexOf(y); + return [ domain[y - 1], domain[y] ]; + }; + scale.copy = function() { + return d3_scale_threshold(domain, range); + }; + return scale; + } + d3.scale.identity = function() { + return d3_scale_identity([ 0, 1 ]); + }; + function d3_scale_identity(domain) { + function identity(x) { + return +x; + } + identity.invert = identity; + identity.domain = identity.range = function(x) { + if (!arguments.length) return domain; + domain = x.map(identity); + return identity; + }; + identity.ticks = function(m) { + return d3_scale_linearTicks(domain, m); + }; + identity.tickFormat = function(m, format) { + return d3_scale_linearTickFormat(domain, m, format); + }; + identity.copy = function() { + return d3_scale_identity(domain); + }; + return identity; + } + d3.svg = {}; + function d3_zero() { + return 0; + } + d3.svg.arc = function() { + var innerRadius = d3_svg_arcInnerRadius, outerRadius = d3_svg_arcOuterRadius, cornerRadius = d3_zero, padRadius = d3_svg_arcAuto, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle, padAngle = d3_svg_arcPadAngle; + function arc() { + var r0 = Math.max(0, +innerRadius.apply(this, arguments)), r1 = Math.max(0, +outerRadius.apply(this, arguments)), a0 = startAngle.apply(this, arguments) - halfπ, a1 = endAngle.apply(this, arguments) - halfπ, da = Math.abs(a1 - a0), cw = a0 > a1 ? 0 : 1; + if (r1 < r0) rc = r1, r1 = r0, r0 = rc; + if (da >= τε) return circleSegment(r1, cw) + (r0 ? circleSegment(r0, 1 - cw) : "") + "Z"; + var rc, cr, rp, ap, p0 = 0, p1 = 0, x0, y0, x1, y1, x2, y2, x3, y3, path = []; + if (ap = (+padAngle.apply(this, arguments) || 0) / 2) { + rp = padRadius === d3_svg_arcAuto ? Math.sqrt(r0 * r0 + r1 * r1) : +padRadius.apply(this, arguments); + if (!cw) p1 *= -1; + if (r1) p1 = d3_asin(rp / r1 * Math.sin(ap)); + if (r0) p0 = d3_asin(rp / r0 * Math.sin(ap)); + } + if (r1) { + x0 = r1 * Math.cos(a0 + p1); + y0 = r1 * Math.sin(a0 + p1); + x1 = r1 * Math.cos(a1 - p1); + y1 = r1 * Math.sin(a1 - p1); + var l1 = Math.abs(a1 - a0 - 2 * p1) <= π ? 0 : 1; + if (p1 && d3_svg_arcSweep(x0, y0, x1, y1) === cw ^ l1) { + var h1 = (a0 + a1) / 2; + x0 = r1 * Math.cos(h1); + y0 = r1 * Math.sin(h1); + x1 = y1 = null; + } + } else { + x0 = y0 = 0; + } + if (r0) { + x2 = r0 * Math.cos(a1 - p0); + y2 = r0 * Math.sin(a1 - p0); + x3 = r0 * Math.cos(a0 + p0); + y3 = r0 * Math.sin(a0 + p0); + var l0 = Math.abs(a0 - a1 + 2 * p0) <= π ? 0 : 1; + if (p0 && d3_svg_arcSweep(x2, y2, x3, y3) === 1 - cw ^ l0) { + var h0 = (a0 + a1) / 2; + x2 = r0 * Math.cos(h0); + y2 = r0 * Math.sin(h0); + x3 = y3 = null; + } + } else { + x2 = y2 = 0; + } + if (da > ε && (rc = Math.min(Math.abs(r1 - r0) / 2, +cornerRadius.apply(this, arguments))) > .001) { + cr = r0 < r1 ^ cw ? 0 : 1; + var rc1 = rc, rc0 = rc; + if (da < π) { + var oc = x3 == null ? [ x2, y2 ] : x1 == null ? [ x0, y0 ] : d3_geom_polygonIntersect([ x0, y0 ], [ x3, y3 ], [ x1, y1 ], [ x2, y2 ]), ax = x0 - oc[0], ay = y0 - oc[1], bx = x1 - oc[0], by = y1 - oc[1], kc = 1 / Math.sin(Math.acos((ax * bx + ay * by) / (Math.sqrt(ax * ax + ay * ay) * Math.sqrt(bx * bx + by * by))) / 2), lc = Math.sqrt(oc[0] * oc[0] + oc[1] * oc[1]); + rc0 = Math.min(rc, (r0 - lc) / (kc - 1)); + rc1 = Math.min(rc, (r1 - lc) / (kc + 1)); + } + if (x1 != null) { + var t30 = d3_svg_arcCornerTangents(x3 == null ? [ x2, y2 ] : [ x3, y3 ], [ x0, y0 ], r1, rc1, cw), t12 = d3_svg_arcCornerTangents([ x1, y1 ], [ x2, y2 ], r1, rc1, cw); + if (rc === rc1) { + path.push("M", t30[0], "A", rc1, ",", rc1, " 0 0,", cr, " ", t30[1], "A", r1, ",", r1, " 0 ", 1 - cw ^ d3_svg_arcSweep(t30[1][0], t30[1][1], t12[1][0], t12[1][1]), ",", cw, " ", t12[1], "A", rc1, ",", rc1, " 0 0,", cr, " ", t12[0]); + } else { + path.push("M", t30[0], "A", rc1, ",", rc1, " 0 1,", cr, " ", t12[0]); + } + } else { + path.push("M", x0, ",", y0); + } + if (x3 != null) { + var t03 = d3_svg_arcCornerTangents([ x0, y0 ], [ x3, y3 ], r0, -rc0, cw), t21 = d3_svg_arcCornerTangents([ x2, y2 ], x1 == null ? [ x0, y0 ] : [ x1, y1 ], r0, -rc0, cw); + if (rc === rc0) { + path.push("L", t21[0], "A", rc0, ",", rc0, " 0 0,", cr, " ", t21[1], "A", r0, ",", r0, " 0 ", cw ^ d3_svg_arcSweep(t21[1][0], t21[1][1], t03[1][0], t03[1][1]), ",", 1 - cw, " ", t03[1], "A", rc0, ",", rc0, " 0 0,", cr, " ", t03[0]); + } else { + path.push("L", t21[0], "A", rc0, ",", rc0, " 0 0,", cr, " ", t03[0]); + } + } else { + path.push("L", x2, ",", y2); + } + } else { + path.push("M", x0, ",", y0); + if (x1 != null) path.push("A", r1, ",", r1, " 0 ", l1, ",", cw, " ", x1, ",", y1); + path.push("L", x2, ",", y2); + if (x3 != null) path.push("A", r0, ",", r0, " 0 ", l0, ",", 1 - cw, " ", x3, ",", y3); + } + path.push("Z"); + return path.join(""); + } + function circleSegment(r1, cw) { + return "M0," + r1 + "A" + r1 + "," + r1 + " 0 1," + cw + " 0," + -r1 + "A" + r1 + "," + r1 + " 0 1," + cw + " 0," + r1; + } + arc.innerRadius = function(v) { + if (!arguments.length) return innerRadius; + innerRadius = d3_functor(v); + return arc; + }; + arc.outerRadius = function(v) { + if (!arguments.length) return outerRadius; + outerRadius = d3_functor(v); + return arc; + }; + arc.cornerRadius = function(v) { + if (!arguments.length) return cornerRadius; + cornerRadius = d3_functor(v); + return arc; + }; + arc.padRadius = function(v) { + if (!arguments.length) return padRadius; + padRadius = v == d3_svg_arcAuto ? d3_svg_arcAuto : d3_functor(v); + return arc; + }; + arc.startAngle = function(v) { + if (!arguments.length) return startAngle; + startAngle = d3_functor(v); + return arc; + }; + arc.endAngle = function(v) { + if (!arguments.length) return endAngle; + endAngle = d3_functor(v); + return arc; + }; + arc.padAngle = function(v) { + if (!arguments.length) return padAngle; + padAngle = d3_functor(v); + return arc; + }; + arc.centroid = function() { + var r = (+innerRadius.apply(this, arguments) + +outerRadius.apply(this, arguments)) / 2, a = (+startAngle.apply(this, arguments) + +endAngle.apply(this, arguments)) / 2 - halfπ; + return [ Math.cos(a) * r, Math.sin(a) * r ]; + }; + return arc; + }; + var d3_svg_arcAuto = "auto"; + function d3_svg_arcInnerRadius(d) { + return d.innerRadius; + } + function d3_svg_arcOuterRadius(d) { + return d.outerRadius; + } + function d3_svg_arcStartAngle(d) { + return d.startAngle; + } + function d3_svg_arcEndAngle(d) { + return d.endAngle; + } + function d3_svg_arcPadAngle(d) { + return d && d.padAngle; + } + function d3_svg_arcSweep(x0, y0, x1, y1) { + return (x0 - x1) * y0 - (y0 - y1) * x0 > 0 ? 0 : 1; + } + function d3_svg_arcCornerTangents(p0, p1, r1, rc, cw) { + var x01 = p0[0] - p1[0], y01 = p0[1] - p1[1], lo = (cw ? rc : -rc) / Math.sqrt(x01 * x01 + y01 * y01), ox = lo * y01, oy = -lo * x01, x1 = p0[0] + ox, y1 = p0[1] + oy, x2 = p1[0] + ox, y2 = p1[1] + oy, x3 = (x1 + x2) / 2, y3 = (y1 + y2) / 2, dx = x2 - x1, dy = y2 - y1, d2 = dx * dx + dy * dy, r = r1 - rc, D = x1 * y2 - x2 * y1, d = (dy < 0 ? -1 : 1) * Math.sqrt(Math.max(0, r * r * d2 - D * D)), cx0 = (D * dy - dx * d) / d2, cy0 = (-D * dx - dy * d) / d2, cx1 = (D * dy + dx * d) / d2, cy1 = (-D * dx + dy * d) / d2, dx0 = cx0 - x3, dy0 = cy0 - y3, dx1 = cx1 - x3, dy1 = cy1 - y3; + if (dx0 * dx0 + dy0 * dy0 > dx1 * dx1 + dy1 * dy1) cx0 = cx1, cy0 = cy1; + return [ [ cx0 - ox, cy0 - oy ], [ cx0 * r1 / r, cy0 * r1 / r ] ]; + } + function d3_svg_line(projection) { + var x = d3_geom_pointX, y = d3_geom_pointY, defined = d3_true, interpolate = d3_svg_lineLinear, interpolateKey = interpolate.key, tension = .7; + function line(data) { + var segments = [], points = [], i = -1, n = data.length, d, fx = d3_functor(x), fy = d3_functor(y); + function segment() { + segments.push("M", interpolate(projection(points), tension)); + } + while (++i < n) { + if (defined.call(this, d = data[i], i)) { + points.push([ +fx.call(this, d, i), +fy.call(this, d, i) ]); + } else if (points.length) { + segment(); + points = []; + } + } + if (points.length) segment(); + return segments.length ? segments.join("") : null; + } + line.x = function(_) { + if (!arguments.length) return x; + x = _; + return line; + }; + line.y = function(_) { + if (!arguments.length) return y; + y = _; + return line; + }; + line.defined = function(_) { + if (!arguments.length) return defined; + defined = _; + return line; + }; + line.interpolate = function(_) { + if (!arguments.length) return interpolateKey; + if (typeof _ === "function") interpolateKey = interpolate = _; else interpolateKey = (interpolate = d3_svg_lineInterpolators.get(_) || d3_svg_lineLinear).key; + return line; + }; + line.tension = function(_) { + if (!arguments.length) return tension; + tension = _; + return line; + }; + return line; + } + d3.svg.line = function() { + return d3_svg_line(d3_identity); + }; + var d3_svg_lineInterpolators = d3.map({ + linear: d3_svg_lineLinear, + "linear-closed": d3_svg_lineLinearClosed, + step: d3_svg_lineStep, + "step-before": d3_svg_lineStepBefore, + "step-after": d3_svg_lineStepAfter, + basis: d3_svg_lineBasis, + "basis-open": d3_svg_lineBasisOpen, + "basis-closed": d3_svg_lineBasisClosed, + bundle: d3_svg_lineBundle, + cardinal: d3_svg_lineCardinal, + "cardinal-open": d3_svg_lineCardinalOpen, + "cardinal-closed": d3_svg_lineCardinalClosed, + monotone: d3_svg_lineMonotone + }); + d3_svg_lineInterpolators.forEach(function(key, value) { + value.key = key; + value.closed = /-closed$/.test(key); + }); + function d3_svg_lineLinear(points) { + return points.length > 1 ? points.join("L") : points + "Z"; + } + function d3_svg_lineLinearClosed(points) { + return points.join("L") + "Z"; + } + function d3_svg_lineStep(points) { + var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; + while (++i < n) path.push("H", (p[0] + (p = points[i])[0]) / 2, "V", p[1]); + if (n > 1) path.push("H", p[0]); + return path.join(""); + } + function d3_svg_lineStepBefore(points) { + var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; + while (++i < n) path.push("V", (p = points[i])[1], "H", p[0]); + return path.join(""); + } + function d3_svg_lineStepAfter(points) { + var i = 0, n = points.length, p = points[0], path = [ p[0], ",", p[1] ]; + while (++i < n) path.push("H", (p = points[i])[0], "V", p[1]); + return path.join(""); + } + function d3_svg_lineCardinalOpen(points, tension) { + return points.length < 4 ? d3_svg_lineLinear(points) : points[1] + d3_svg_lineHermite(points.slice(1, -1), d3_svg_lineCardinalTangents(points, tension)); + } + function d3_svg_lineCardinalClosed(points, tension) { + return points.length < 3 ? d3_svg_lineLinearClosed(points) : points[0] + d3_svg_lineHermite((points.push(points[0]), + points), d3_svg_lineCardinalTangents([ points[points.length - 2] ].concat(points, [ points[1] ]), tension)); + } + function d3_svg_lineCardinal(points, tension) { + return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite(points, d3_svg_lineCardinalTangents(points, tension)); + } + function d3_svg_lineHermite(points, tangents) { + if (tangents.length < 1 || points.length != tangents.length && points.length != tangents.length + 2) { + return d3_svg_lineLinear(points); + } + var quad = points.length != tangents.length, path = "", p0 = points[0], p = points[1], t0 = tangents[0], t = t0, pi = 1; + if (quad) { + path += "Q" + (p[0] - t0[0] * 2 / 3) + "," + (p[1] - t0[1] * 2 / 3) + "," + p[0] + "," + p[1]; + p0 = points[1]; + pi = 2; + } + if (tangents.length > 1) { + t = tangents[1]; + p = points[pi]; + pi++; + path += "C" + (p0[0] + t0[0]) + "," + (p0[1] + t0[1]) + "," + (p[0] - t[0]) + "," + (p[1] - t[1]) + "," + p[0] + "," + p[1]; + for (var i = 2; i < tangents.length; i++, pi++) { + p = points[pi]; + t = tangents[i]; + path += "S" + (p[0] - t[0]) + "," + (p[1] - t[1]) + "," + p[0] + "," + p[1]; + } + } + if (quad) { + var lp = points[pi]; + path += "Q" + (p[0] + t[0] * 2 / 3) + "," + (p[1] + t[1] * 2 / 3) + "," + lp[0] + "," + lp[1]; + } + return path; + } + function d3_svg_lineCardinalTangents(points, tension) { + var tangents = [], a = (1 - tension) / 2, p0, p1 = points[0], p2 = points[1], i = 1, n = points.length; + while (++i < n) { + p0 = p1; + p1 = p2; + p2 = points[i]; + tangents.push([ a * (p2[0] - p0[0]), a * (p2[1] - p0[1]) ]); + } + return tangents; + } + function d3_svg_lineBasis(points) { + if (points.length < 3) return d3_svg_lineLinear(points); + var i = 1, n = points.length, pi = points[0], x0 = pi[0], y0 = pi[1], px = [ x0, x0, x0, (pi = points[1])[0] ], py = [ y0, y0, y0, pi[1] ], path = [ x0, ",", y0, "L", d3_svg_lineDot4(d3_svg_lineBasisBezier3, px), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, py) ]; + points.push(points[n - 1]); + while (++i <= n) { + pi = points[i]; + px.shift(); + px.push(pi[0]); + py.shift(); + py.push(pi[1]); + d3_svg_lineBasisBezier(path, px, py); + } + points.pop(); + path.push("L", pi); + return path.join(""); + } + function d3_svg_lineBasisOpen(points) { + if (points.length < 4) return d3_svg_lineLinear(points); + var path = [], i = -1, n = points.length, pi, px = [ 0 ], py = [ 0 ]; + while (++i < 3) { + pi = points[i]; + px.push(pi[0]); + py.push(pi[1]); + } + path.push(d3_svg_lineDot4(d3_svg_lineBasisBezier3, px) + "," + d3_svg_lineDot4(d3_svg_lineBasisBezier3, py)); + --i; + while (++i < n) { + pi = points[i]; + px.shift(); + px.push(pi[0]); + py.shift(); + py.push(pi[1]); + d3_svg_lineBasisBezier(path, px, py); + } + return path.join(""); + } + function d3_svg_lineBasisClosed(points) { + var path, i = -1, n = points.length, m = n + 4, pi, px = [], py = []; + while (++i < 4) { + pi = points[i % n]; + px.push(pi[0]); + py.push(pi[1]); + } + path = [ d3_svg_lineDot4(d3_svg_lineBasisBezier3, px), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, py) ]; + --i; + while (++i < m) { + pi = points[i % n]; + px.shift(); + px.push(pi[0]); + py.shift(); + py.push(pi[1]); + d3_svg_lineBasisBezier(path, px, py); + } + return path.join(""); + } + function d3_svg_lineBundle(points, tension) { + var n = points.length - 1; + if (n) { + var x0 = points[0][0], y0 = points[0][1], dx = points[n][0] - x0, dy = points[n][1] - y0, i = -1, p, t; + while (++i <= n) { + p = points[i]; + t = i / n; + p[0] = tension * p[0] + (1 - tension) * (x0 + t * dx); + p[1] = tension * p[1] + (1 - tension) * (y0 + t * dy); + } + } + return d3_svg_lineBasis(points); + } + function d3_svg_lineDot4(a, b) { + return a[0] * b[0] + a[1] * b[1] + a[2] * b[2] + a[3] * b[3]; + } + var d3_svg_lineBasisBezier1 = [ 0, 2 / 3, 1 / 3, 0 ], d3_svg_lineBasisBezier2 = [ 0, 1 / 3, 2 / 3, 0 ], d3_svg_lineBasisBezier3 = [ 0, 1 / 6, 2 / 3, 1 / 6 ]; + function d3_svg_lineBasisBezier(path, x, y) { + path.push("C", d3_svg_lineDot4(d3_svg_lineBasisBezier1, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier1, y), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier2, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier2, y), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, x), ",", d3_svg_lineDot4(d3_svg_lineBasisBezier3, y)); + } + function d3_svg_lineSlope(p0, p1) { + return (p1[1] - p0[1]) / (p1[0] - p0[0]); + } + function d3_svg_lineFiniteDifferences(points) { + var i = 0, j = points.length - 1, m = [], p0 = points[0], p1 = points[1], d = m[0] = d3_svg_lineSlope(p0, p1); + while (++i < j) { + m[i] = (d + (d = d3_svg_lineSlope(p0 = p1, p1 = points[i + 1]))) / 2; + } + m[i] = d; + return m; + } + function d3_svg_lineMonotoneTangents(points) { + var tangents = [], d, a, b, s, m = d3_svg_lineFiniteDifferences(points), i = -1, j = points.length - 1; + while (++i < j) { + d = d3_svg_lineSlope(points[i], points[i + 1]); + if (abs(d) < ε) { + m[i] = m[i + 1] = 0; + } else { + a = m[i] / d; + b = m[i + 1] / d; + s = a * a + b * b; + if (s > 9) { + s = d * 3 / Math.sqrt(s); + m[i] = s * a; + m[i + 1] = s * b; + } + } + } + i = -1; + while (++i <= j) { + s = (points[Math.min(j, i + 1)][0] - points[Math.max(0, i - 1)][0]) / (6 * (1 + m[i] * m[i])); + tangents.push([ s || 0, m[i] * s || 0 ]); + } + return tangents; + } + function d3_svg_lineMonotone(points) { + return points.length < 3 ? d3_svg_lineLinear(points) : points[0] + d3_svg_lineHermite(points, d3_svg_lineMonotoneTangents(points)); + } + d3.svg.line.radial = function() { + var line = d3_svg_line(d3_svg_lineRadial); + line.radius = line.x, delete line.x; + line.angle = line.y, delete line.y; + return line; + }; + function d3_svg_lineRadial(points) { + var point, i = -1, n = points.length, r, a; + while (++i < n) { + point = points[i]; + r = point[0]; + a = point[1] - halfπ; + point[0] = r * Math.cos(a); + point[1] = r * Math.sin(a); + } + return points; + } + function d3_svg_area(projection) { + var x0 = d3_geom_pointX, x1 = d3_geom_pointX, y0 = 0, y1 = d3_geom_pointY, defined = d3_true, interpolate = d3_svg_lineLinear, interpolateKey = interpolate.key, interpolateReverse = interpolate, L = "L", tension = .7; + function area(data) { + var segments = [], points0 = [], points1 = [], i = -1, n = data.length, d, fx0 = d3_functor(x0), fy0 = d3_functor(y0), fx1 = x0 === x1 ? function() { + return x; + } : d3_functor(x1), fy1 = y0 === y1 ? function() { + return y; + } : d3_functor(y1), x, y; + function segment() { + segments.push("M", interpolate(projection(points1), tension), L, interpolateReverse(projection(points0.reverse()), tension), "Z"); + } + while (++i < n) { + if (defined.call(this, d = data[i], i)) { + points0.push([ x = +fx0.call(this, d, i), y = +fy0.call(this, d, i) ]); + points1.push([ +fx1.call(this, d, i), +fy1.call(this, d, i) ]); + } else if (points0.length) { + segment(); + points0 = []; + points1 = []; + } + } + if (points0.length) segment(); + return segments.length ? segments.join("") : null; + } + area.x = function(_) { + if (!arguments.length) return x1; + x0 = x1 = _; + return area; + }; + area.x0 = function(_) { + if (!arguments.length) return x0; + x0 = _; + return area; + }; + area.x1 = function(_) { + if (!arguments.length) return x1; + x1 = _; + return area; + }; + area.y = function(_) { + if (!arguments.length) return y1; + y0 = y1 = _; + return area; + }; + area.y0 = function(_) { + if (!arguments.length) return y0; + y0 = _; + return area; + }; + area.y1 = function(_) { + if (!arguments.length) return y1; + y1 = _; + return area; + }; + area.defined = function(_) { + if (!arguments.length) return defined; + defined = _; + return area; + }; + area.interpolate = function(_) { + if (!arguments.length) return interpolateKey; + if (typeof _ === "function") interpolateKey = interpolate = _; else interpolateKey = (interpolate = d3_svg_lineInterpolators.get(_) || d3_svg_lineLinear).key; + interpolateReverse = interpolate.reverse || interpolate; + L = interpolate.closed ? "M" : "L"; + return area; + }; + area.tension = function(_) { + if (!arguments.length) return tension; + tension = _; + return area; + }; + return area; + } + d3_svg_lineStepBefore.reverse = d3_svg_lineStepAfter; + d3_svg_lineStepAfter.reverse = d3_svg_lineStepBefore; + d3.svg.area = function() { + return d3_svg_area(d3_identity); + }; + d3.svg.area.radial = function() { + var area = d3_svg_area(d3_svg_lineRadial); + area.radius = area.x, delete area.x; + area.innerRadius = area.x0, delete area.x0; + area.outerRadius = area.x1, delete area.x1; + area.angle = area.y, delete area.y; + area.startAngle = area.y0, delete area.y0; + area.endAngle = area.y1, delete area.y1; + return area; + }; + d3.svg.chord = function() { + var source = d3_source, target = d3_target, radius = d3_svg_chordRadius, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle; + function chord(d, i) { + var s = subgroup(this, source, d, i), t = subgroup(this, target, d, i); + return "M" + s.p0 + arc(s.r, s.p1, s.a1 - s.a0) + (equals(s, t) ? curve(s.r, s.p1, s.r, s.p0) : curve(s.r, s.p1, t.r, t.p0) + arc(t.r, t.p1, t.a1 - t.a0) + curve(t.r, t.p1, s.r, s.p0)) + "Z"; + } + function subgroup(self, f, d, i) { + var subgroup = f.call(self, d, i), r = radius.call(self, subgroup, i), a0 = startAngle.call(self, subgroup, i) - halfπ, a1 = endAngle.call(self, subgroup, i) - halfπ; + return { + r: r, + a0: a0, + a1: a1, + p0: [ r * Math.cos(a0), r * Math.sin(a0) ], + p1: [ r * Math.cos(a1), r * Math.sin(a1) ] + }; + } + function equals(a, b) { + return a.a0 == b.a0 && a.a1 == b.a1; + } + function arc(r, p, a) { + return "A" + r + "," + r + " 0 " + +(a > π) + ",1 " + p; + } + function curve(r0, p0, r1, p1) { + return "Q 0,0 " + p1; + } + chord.radius = function(v) { + if (!arguments.length) return radius; + radius = d3_functor(v); + return chord; + }; + chord.source = function(v) { + if (!arguments.length) return source; + source = d3_functor(v); + return chord; + }; + chord.target = function(v) { + if (!arguments.length) return target; + target = d3_functor(v); + return chord; + }; + chord.startAngle = function(v) { + if (!arguments.length) return startAngle; + startAngle = d3_functor(v); + return chord; + }; + chord.endAngle = function(v) { + if (!arguments.length) return endAngle; + endAngle = d3_functor(v); + return chord; + }; + return chord; + }; + function d3_svg_chordRadius(d) { + return d.radius; + } + d3.svg.diagonal = function() { + var source = d3_source, target = d3_target, projection = d3_svg_diagonalProjection; + function diagonal(d, i) { + var p0 = source.call(this, d, i), p3 = target.call(this, d, i), m = (p0.y + p3.y) / 2, p = [ p0, { + x: p0.x, + y: m + }, { + x: p3.x, + y: m + }, p3 ]; + p = p.map(projection); + return "M" + p[0] + "C" + p[1] + " " + p[2] + " " + p[3]; + } + diagonal.source = function(x) { + if (!arguments.length) return source; + source = d3_functor(x); + return diagonal; + }; + diagonal.target = function(x) { + if (!arguments.length) return target; + target = d3_functor(x); + return diagonal; + }; + diagonal.projection = function(x) { + if (!arguments.length) return projection; + projection = x; + return diagonal; + }; + return diagonal; + }; + function d3_svg_diagonalProjection(d) { + return [ d.x, d.y ]; + } + d3.svg.diagonal.radial = function() { + var diagonal = d3.svg.diagonal(), projection = d3_svg_diagonalProjection, projection_ = diagonal.projection; + diagonal.projection = function(x) { + return arguments.length ? projection_(d3_svg_diagonalRadialProjection(projection = x)) : projection; + }; + return diagonal; + }; + function d3_svg_diagonalRadialProjection(projection) { + return function() { + var d = projection.apply(this, arguments), r = d[0], a = d[1] - halfπ; + return [ r * Math.cos(a), r * Math.sin(a) ]; + }; + } + d3.svg.symbol = function() { + var type = d3_svg_symbolType, size = d3_svg_symbolSize; + function symbol(d, i) { + return (d3_svg_symbols.get(type.call(this, d, i)) || d3_svg_symbolCircle)(size.call(this, d, i)); + } + symbol.type = function(x) { + if (!arguments.length) return type; + type = d3_functor(x); + return symbol; + }; + symbol.size = function(x) { + if (!arguments.length) return size; + size = d3_functor(x); + return symbol; + }; + return symbol; + }; + function d3_svg_symbolSize() { + return 64; + } + function d3_svg_symbolType() { + return "circle"; + } + function d3_svg_symbolCircle(size) { + var r = Math.sqrt(size / π); + return "M0," + r + "A" + r + "," + r + " 0 1,1 0," + -r + "A" + r + "," + r + " 0 1,1 0," + r + "Z"; + } + var d3_svg_symbols = d3.map({ + circle: d3_svg_symbolCircle, + cross: function(size) { + var r = Math.sqrt(size / 5) / 2; + return "M" + -3 * r + "," + -r + "H" + -r + "V" + -3 * r + "H" + r + "V" + -r + "H" + 3 * r + "V" + r + "H" + r + "V" + 3 * r + "H" + -r + "V" + r + "H" + -3 * r + "Z"; + }, + diamond: function(size) { + var ry = Math.sqrt(size / (2 * d3_svg_symbolTan30)), rx = ry * d3_svg_symbolTan30; + return "M0," + -ry + "L" + rx + ",0" + " 0," + ry + " " + -rx + ",0" + "Z"; + }, + square: function(size) { + var r = Math.sqrt(size) / 2; + return "M" + -r + "," + -r + "L" + r + "," + -r + " " + r + "," + r + " " + -r + "," + r + "Z"; + }, + "triangle-down": function(size) { + var rx = Math.sqrt(size / d3_svg_symbolSqrt3), ry = rx * d3_svg_symbolSqrt3 / 2; + return "M0," + ry + "L" + rx + "," + -ry + " " + -rx + "," + -ry + "Z"; + }, + "triangle-up": function(size) { + var rx = Math.sqrt(size / d3_svg_symbolSqrt3), ry = rx * d3_svg_symbolSqrt3 / 2; + return "M0," + -ry + "L" + rx + "," + ry + " " + -rx + "," + ry + "Z"; + } + }); + d3.svg.symbolTypes = d3_svg_symbols.keys(); + var d3_svg_symbolSqrt3 = Math.sqrt(3), d3_svg_symbolTan30 = Math.tan(30 * d3_radians); + d3_selectionPrototype.transition = function(name) { + var id = d3_transitionInheritId || ++d3_transitionId, ns = d3_transitionNamespace(name), subgroups = [], subgroup, node, transition = d3_transitionInherit || { + time: Date.now(), + ease: d3_ease_cubicInOut, + delay: 0, + duration: 250 + }; + for (var j = -1, m = this.length; ++j < m; ) { + subgroups.push(subgroup = []); + for (var group = this[j], i = -1, n = group.length; ++i < n; ) { + if (node = group[i]) d3_transitionNode(node, i, ns, id, transition); + subgroup.push(node); + } + } + return d3_transition(subgroups, ns, id); + }; + d3_selectionPrototype.interrupt = function(name) { + return this.each(name == null ? d3_selection_interrupt : d3_selection_interruptNS(d3_transitionNamespace(name))); + }; + var d3_selection_interrupt = d3_selection_interruptNS(d3_transitionNamespace()); + function d3_selection_interruptNS(ns) { + return function() { + var lock, activeId, active; + if ((lock = this[ns]) && (active = lock[activeId = lock.active])) { + active.timer.c = null; + active.timer.t = NaN; + if (--lock.count) delete lock[activeId]; else delete this[ns]; + lock.active += .5; + active.event && active.event.interrupt.call(this, this.__data__, active.index); + } + }; + } + function d3_transition(groups, ns, id) { + d3_subclass(groups, d3_transitionPrototype); + groups.namespace = ns; + groups.id = id; + return groups; + } + var d3_transitionPrototype = [], d3_transitionId = 0, d3_transitionInheritId, d3_transitionInherit; + d3_transitionPrototype.call = d3_selectionPrototype.call; + d3_transitionPrototype.empty = d3_selectionPrototype.empty; + d3_transitionPrototype.node = d3_selectionPrototype.node; + d3_transitionPrototype.size = d3_selectionPrototype.size; + d3.transition = function(selection, name) { + return selection && selection.transition ? d3_transitionInheritId ? selection.transition(name) : selection : d3.selection().transition(selection); + }; + d3.transition.prototype = d3_transitionPrototype; + d3_transitionPrototype.select = function(selector) { + var id = this.id, ns = this.namespace, subgroups = [], subgroup, subnode, node; + selector = d3_selection_selector(selector); + for (var j = -1, m = this.length; ++j < m; ) { + subgroups.push(subgroup = []); + for (var group = this[j], i = -1, n = group.length; ++i < n; ) { + if ((node = group[i]) && (subnode = selector.call(node, node.__data__, i, j))) { + if ("__data__" in node) subnode.__data__ = node.__data__; + d3_transitionNode(subnode, i, ns, id, node[ns][id]); + subgroup.push(subnode); + } else { + subgroup.push(null); + } + } + } + return d3_transition(subgroups, ns, id); + }; + d3_transitionPrototype.selectAll = function(selector) { + var id = this.id, ns = this.namespace, subgroups = [], subgroup, subnodes, node, subnode, transition; + selector = d3_selection_selectorAll(selector); + for (var j = -1, m = this.length; ++j < m; ) { + for (var group = this[j], i = -1, n = group.length; ++i < n; ) { + if (node = group[i]) { + transition = node[ns][id]; + subnodes = selector.call(node, node.__data__, i, j); + subgroups.push(subgroup = []); + for (var k = -1, o = subnodes.length; ++k < o; ) { + if (subnode = subnodes[k]) d3_transitionNode(subnode, k, ns, id, transition); + subgroup.push(subnode); + } + } + } + } + return d3_transition(subgroups, ns, id); + }; + d3_transitionPrototype.filter = function(filter) { + var subgroups = [], subgroup, group, node; + if (typeof filter !== "function") filter = d3_selection_filter(filter); + for (var j = 0, m = this.length; j < m; j++) { + subgroups.push(subgroup = []); + for (var group = this[j], i = 0, n = group.length; i < n; i++) { + if ((node = group[i]) && filter.call(node, node.__data__, i, j)) { + subgroup.push(node); + } + } + } + return d3_transition(subgroups, this.namespace, this.id); + }; + d3_transitionPrototype.tween = function(name, tween) { + var id = this.id, ns = this.namespace; + if (arguments.length < 2) return this.node()[ns][id].tween.get(name); + return d3_selection_each(this, tween == null ? function(node) { + node[ns][id].tween.remove(name); + } : function(node) { + node[ns][id].tween.set(name, tween); + }); + }; + function d3_transition_tween(groups, name, value, tween) { + var id = groups.id, ns = groups.namespace; + return d3_selection_each(groups, typeof value === "function" ? function(node, i, j) { + node[ns][id].tween.set(name, tween(value.call(node, node.__data__, i, j))); + } : (value = tween(value), function(node) { + node[ns][id].tween.set(name, value); + })); + } + d3_transitionPrototype.attr = function(nameNS, value) { + if (arguments.length < 2) { + for (value in nameNS) this.attr(value, nameNS[value]); + return this; + } + var interpolate = nameNS == "transform" ? d3_interpolateTransform : d3_interpolate, name = d3.ns.qualify(nameNS); + function attrNull() { + this.removeAttribute(name); + } + function attrNullNS() { + this.removeAttributeNS(name.space, name.local); + } + function attrTween(b) { + return b == null ? attrNull : (b += "", function() { + var a = this.getAttribute(name), i; + return a !== b && (i = interpolate(a, b), function(t) { + this.setAttribute(name, i(t)); + }); + }); + } + function attrTweenNS(b) { + return b == null ? attrNullNS : (b += "", function() { + var a = this.getAttributeNS(name.space, name.local), i; + return a !== b && (i = interpolate(a, b), function(t) { + this.setAttributeNS(name.space, name.local, i(t)); + }); + }); + } + return d3_transition_tween(this, "attr." + nameNS, value, name.local ? attrTweenNS : attrTween); + }; + d3_transitionPrototype.attrTween = function(nameNS, tween) { + var name = d3.ns.qualify(nameNS); + function attrTween(d, i) { + var f = tween.call(this, d, i, this.getAttribute(name)); + return f && function(t) { + this.setAttribute(name, f(t)); + }; + } + function attrTweenNS(d, i) { + var f = tween.call(this, d, i, this.getAttributeNS(name.space, name.local)); + return f && function(t) { + this.setAttributeNS(name.space, name.local, f(t)); + }; + } + return this.tween("attr." + nameNS, name.local ? attrTweenNS : attrTween); + }; + d3_transitionPrototype.style = function(name, value, priority) { + var n = arguments.length; + if (n < 3) { + if (typeof name !== "string") { + if (n < 2) value = ""; + for (priority in name) this.style(priority, name[priority], value); + return this; + } + priority = ""; + } + function styleNull() { + this.style.removeProperty(name); + } + function styleString(b) { + return b == null ? styleNull : (b += "", function() { + var a = d3_window(this).getComputedStyle(this, null).getPropertyValue(name), i; + return a !== b && (i = d3_interpolate(a, b), function(t) { + this.style.setProperty(name, i(t), priority); + }); + }); + } + return d3_transition_tween(this, "style." + name, value, styleString); + }; + d3_transitionPrototype.styleTween = function(name, tween, priority) { + if (arguments.length < 3) priority = ""; + function styleTween(d, i) { + var f = tween.call(this, d, i, d3_window(this).getComputedStyle(this, null).getPropertyValue(name)); + return f && function(t) { + this.style.setProperty(name, f(t), priority); + }; + } + return this.tween("style." + name, styleTween); + }; + d3_transitionPrototype.text = function(value) { + return d3_transition_tween(this, "text", value, d3_transition_text); + }; + function d3_transition_text(b) { + if (b == null) b = ""; + return function() { + this.textContent = b; + }; + } + d3_transitionPrototype.remove = function() { + var ns = this.namespace; + return this.each("end.transition", function() { + var p; + if (this[ns].count < 2 && (p = this.parentNode)) p.removeChild(this); + }); + }; + d3_transitionPrototype.ease = function(value) { + var id = this.id, ns = this.namespace; + if (arguments.length < 1) return this.node()[ns][id].ease; + if (typeof value !== "function") value = d3.ease.apply(d3, arguments); + return d3_selection_each(this, function(node) { + node[ns][id].ease = value; + }); + }; + d3_transitionPrototype.delay = function(value) { + var id = this.id, ns = this.namespace; + if (arguments.length < 1) return this.node()[ns][id].delay; + return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { + node[ns][id].delay = +value.call(node, node.__data__, i, j); + } : (value = +value, function(node) { + node[ns][id].delay = value; + })); + }; + d3_transitionPrototype.duration = function(value) { + var id = this.id, ns = this.namespace; + if (arguments.length < 1) return this.node()[ns][id].duration; + return d3_selection_each(this, typeof value === "function" ? function(node, i, j) { + node[ns][id].duration = Math.max(1, value.call(node, node.__data__, i, j)); + } : (value = Math.max(1, value), function(node) { + node[ns][id].duration = value; + })); + }; + d3_transitionPrototype.each = function(type, listener) { + var id = this.id, ns = this.namespace; + if (arguments.length < 2) { + var inherit = d3_transitionInherit, inheritId = d3_transitionInheritId; + try { + d3_transitionInheritId = id; + d3_selection_each(this, function(node, i, j) { + d3_transitionInherit = node[ns][id]; + type.call(node, node.__data__, i, j); + }); + } finally { + d3_transitionInherit = inherit; + d3_transitionInheritId = inheritId; + } + } else { + d3_selection_each(this, function(node) { + var transition = node[ns][id]; + (transition.event || (transition.event = d3.dispatch("start", "end", "interrupt"))).on(type, listener); + }); + } + return this; + }; + d3_transitionPrototype.transition = function() { + var id0 = this.id, id1 = ++d3_transitionId, ns = this.namespace, subgroups = [], subgroup, group, node, transition; + for (var j = 0, m = this.length; j < m; j++) { + subgroups.push(subgroup = []); + for (var group = this[j], i = 0, n = group.length; i < n; i++) { + if (node = group[i]) { + transition = node[ns][id0]; + d3_transitionNode(node, i, ns, id1, { + time: transition.time, + ease: transition.ease, + delay: transition.delay + transition.duration, + duration: transition.duration + }); + } + subgroup.push(node); + } + } + return d3_transition(subgroups, ns, id1); + }; + function d3_transitionNamespace(name) { + return name == null ? "__transition__" : "__transition_" + name + "__"; + } + function d3_transitionNode(node, i, ns, id, inherit) { + var lock = node[ns] || (node[ns] = { + active: 0, + count: 0 + }), transition = lock[id], time, timer, duration, ease, tweens; + function schedule(elapsed) { + var delay = transition.delay; + timer.t = delay + time; + if (delay <= elapsed) return start(elapsed - delay); + timer.c = start; + } + function start(elapsed) { + var activeId = lock.active, active = lock[activeId]; + if (active) { + active.timer.c = null; + active.timer.t = NaN; + --lock.count; + delete lock[activeId]; + active.event && active.event.interrupt.call(node, node.__data__, active.index); + } + for (var cancelId in lock) { + if (+cancelId < id) { + var cancel = lock[cancelId]; + cancel.timer.c = null; + cancel.timer.t = NaN; + --lock.count; + delete lock[cancelId]; + } + } + timer.c = tick; + d3_timer(function() { + if (timer.c && tick(elapsed || 1)) { + timer.c = null; + timer.t = NaN; + } + return 1; + }, 0, time); + lock.active = id; + transition.event && transition.event.start.call(node, node.__data__, i); + tweens = []; + transition.tween.forEach(function(key, value) { + if (value = value.call(node, node.__data__, i)) { + tweens.push(value); + } + }); + ease = transition.ease; + duration = transition.duration; + } + function tick(elapsed) { + var t = elapsed / duration, e = ease(t), n = tweens.length; + while (n > 0) { + tweens[--n].call(node, e); + } + if (t >= 1) { + transition.event && transition.event.end.call(node, node.__data__, i); + if (--lock.count) delete lock[id]; else delete node[ns]; + return 1; + } + } + if (!transition) { + time = inherit.time; + timer = d3_timer(schedule, 0, time); + transition = lock[id] = { + tween: new d3_Map(), + time: time, + timer: timer, + delay: inherit.delay, + duration: inherit.duration, + ease: inherit.ease, + index: i + }; + inherit = null; + ++lock.count; + } + } + d3.svg.axis = function() { + var scale = d3.scale.linear(), orient = d3_svg_axisDefaultOrient, innerTickSize = 6, outerTickSize = 6, tickPadding = 3, tickArguments_ = [ 10 ], tickValues = null, tickFormat_; + function axis(g) { + g.each(function() { + var g = d3.select(this); + var scale0 = this.__chart__ || scale, scale1 = this.__chart__ = scale.copy(); + var ticks = tickValues == null ? scale1.ticks ? scale1.ticks.apply(scale1, tickArguments_) : scale1.domain() : tickValues, tickFormat = tickFormat_ == null ? scale1.tickFormat ? scale1.tickFormat.apply(scale1, tickArguments_) : d3_identity : tickFormat_, tick = g.selectAll(".tick").data(ticks, scale1), tickEnter = tick.enter().insert("g", ".domain").attr("class", "tick").style("opacity", ε), tickExit = d3.transition(tick.exit()).style("opacity", ε).remove(), tickUpdate = d3.transition(tick.order()).style("opacity", 1), tickSpacing = Math.max(innerTickSize, 0) + tickPadding, tickTransform; + var range = d3_scaleRange(scale1), path = g.selectAll(".domain").data([ 0 ]), pathUpdate = (path.enter().append("path").attr("class", "domain"), + d3.transition(path)); + tickEnter.append("line"); + tickEnter.append("text"); + var lineEnter = tickEnter.select("line"), lineUpdate = tickUpdate.select("line"), text = tick.select("text").text(tickFormat), textEnter = tickEnter.select("text"), textUpdate = tickUpdate.select("text"), sign = orient === "top" || orient === "left" ? -1 : 1, x1, x2, y1, y2; + if (orient === "bottom" || orient === "top") { + tickTransform = d3_svg_axisX, x1 = "x", y1 = "y", x2 = "x2", y2 = "y2"; + text.attr("dy", sign < 0 ? "0em" : ".71em").style("text-anchor", "middle"); + pathUpdate.attr("d", "M" + range[0] + "," + sign * outerTickSize + "V0H" + range[1] + "V" + sign * outerTickSize); + } else { + tickTransform = d3_svg_axisY, x1 = "y", y1 = "x", x2 = "y2", y2 = "x2"; + text.attr("dy", ".32em").style("text-anchor", sign < 0 ? "end" : "start"); + pathUpdate.attr("d", "M" + sign * outerTickSize + "," + range[0] + "H0V" + range[1] + "H" + sign * outerTickSize); + } + lineEnter.attr(y2, sign * innerTickSize); + textEnter.attr(y1, sign * tickSpacing); + lineUpdate.attr(x2, 0).attr(y2, sign * innerTickSize); + textUpdate.attr(x1, 0).attr(y1, sign * tickSpacing); + if (scale1.rangeBand) { + var x = scale1, dx = x.rangeBand() / 2; + scale0 = scale1 = function(d) { + return x(d) + dx; + }; + } else if (scale0.rangeBand) { + scale0 = scale1; + } else { + tickExit.call(tickTransform, scale1, scale0); + } + tickEnter.call(tickTransform, scale0, scale1); + tickUpdate.call(tickTransform, scale1, scale1); + }); + } + axis.scale = function(x) { + if (!arguments.length) return scale; + scale = x; + return axis; + }; + axis.orient = function(x) { + if (!arguments.length) return orient; + orient = x in d3_svg_axisOrients ? x + "" : d3_svg_axisDefaultOrient; + return axis; + }; + axis.ticks = function() { + if (!arguments.length) return tickArguments_; + tickArguments_ = d3_array(arguments); + return axis; + }; + axis.tickValues = function(x) { + if (!arguments.length) return tickValues; + tickValues = x; + return axis; + }; + axis.tickFormat = function(x) { + if (!arguments.length) return tickFormat_; + tickFormat_ = x; + return axis; + }; + axis.tickSize = function(x) { + var n = arguments.length; + if (!n) return innerTickSize; + innerTickSize = +x; + outerTickSize = +arguments[n - 1]; + return axis; + }; + axis.innerTickSize = function(x) { + if (!arguments.length) return innerTickSize; + innerTickSize = +x; + return axis; + }; + axis.outerTickSize = function(x) { + if (!arguments.length) return outerTickSize; + outerTickSize = +x; + return axis; + }; + axis.tickPadding = function(x) { + if (!arguments.length) return tickPadding; + tickPadding = +x; + return axis; + }; + axis.tickSubdivide = function() { + return arguments.length && axis; + }; + return axis; + }; + var d3_svg_axisDefaultOrient = "bottom", d3_svg_axisOrients = { + top: 1, + right: 1, + bottom: 1, + left: 1 + }; + function d3_svg_axisX(selection, x0, x1) { + selection.attr("transform", function(d) { + var v0 = x0(d); + return "translate(" + (isFinite(v0) ? v0 : x1(d)) + ",0)"; + }); + } + function d3_svg_axisY(selection, y0, y1) { + selection.attr("transform", function(d) { + var v0 = y0(d); + return "translate(0," + (isFinite(v0) ? v0 : y1(d)) + ")"; + }); + } + d3.svg.brush = function() { + var event = d3_eventDispatch(brush, "brushstart", "brush", "brushend"), x = null, y = null, xExtent = [ 0, 0 ], yExtent = [ 0, 0 ], xExtentDomain, yExtentDomain, xClamp = true, yClamp = true, resizes = d3_svg_brushResizes[0]; + function brush(g) { + g.each(function() { + var g = d3.select(this).style("pointer-events", "all").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)").on("mousedown.brush", brushstart).on("touchstart.brush", brushstart); + var background = g.selectAll(".background").data([ 0 ]); + background.enter().append("rect").attr("class", "background").style("visibility", "hidden").style("cursor", "crosshair"); + g.selectAll(".extent").data([ 0 ]).enter().append("rect").attr("class", "extent").style("cursor", "move"); + var resize = g.selectAll(".resize").data(resizes, d3_identity); + resize.exit().remove(); + resize.enter().append("g").attr("class", function(d) { + return "resize " + d; + }).style("cursor", function(d) { + return d3_svg_brushCursor[d]; + }).append("rect").attr("x", function(d) { + return /[ew]$/.test(d) ? -3 : null; + }).attr("y", function(d) { + return /^[ns]/.test(d) ? -3 : null; + }).attr("width", 6).attr("height", 6).style("visibility", "hidden"); + resize.style("display", brush.empty() ? "none" : null); + var gUpdate = d3.transition(g), backgroundUpdate = d3.transition(background), range; + if (x) { + range = d3_scaleRange(x); + backgroundUpdate.attr("x", range[0]).attr("width", range[1] - range[0]); + redrawX(gUpdate); + } + if (y) { + range = d3_scaleRange(y); + backgroundUpdate.attr("y", range[0]).attr("height", range[1] - range[0]); + redrawY(gUpdate); + } + redraw(gUpdate); + }); + } + brush.event = function(g) { + g.each(function() { + var event_ = event.of(this, arguments), extent1 = { + x: xExtent, + y: yExtent, + i: xExtentDomain, + j: yExtentDomain + }, extent0 = this.__chart__ || extent1; + this.__chart__ = extent1; + if (d3_transitionInheritId) { + d3.select(this).transition().each("start.brush", function() { + xExtentDomain = extent0.i; + yExtentDomain = extent0.j; + xExtent = extent0.x; + yExtent = extent0.y; + event_({ + type: "brushstart" + }); + }).tween("brush:brush", function() { + var xi = d3_interpolateArray(xExtent, extent1.x), yi = d3_interpolateArray(yExtent, extent1.y); + xExtentDomain = yExtentDomain = null; + return function(t) { + xExtent = extent1.x = xi(t); + yExtent = extent1.y = yi(t); + event_({ + type: "brush", + mode: "resize" + }); + }; + }).each("end.brush", function() { + xExtentDomain = extent1.i; + yExtentDomain = extent1.j; + event_({ + type: "brush", + mode: "resize" + }); + event_({ + type: "brushend" + }); + }); + } else { + event_({ + type: "brushstart" + }); + event_({ + type: "brush", + mode: "resize" + }); + event_({ + type: "brushend" + }); + } + }); + }; + function redraw(g) { + g.selectAll(".resize").attr("transform", function(d) { + return "translate(" + xExtent[+/e$/.test(d)] + "," + yExtent[+/^s/.test(d)] + ")"; + }); + } + function redrawX(g) { + g.select(".extent").attr("x", xExtent[0]); + g.selectAll(".extent,.n>rect,.s>rect").attr("width", xExtent[1] - xExtent[0]); + } + function redrawY(g) { + g.select(".extent").attr("y", yExtent[0]); + g.selectAll(".extent,.e>rect,.w>rect").attr("height", yExtent[1] - yExtent[0]); + } + function brushstart() { + var target = this, eventTarget = d3.select(d3.event.target), event_ = event.of(target, arguments), g = d3.select(target), resizing = eventTarget.datum(), resizingX = !/^(n|s)$/.test(resizing) && x, resizingY = !/^(e|w)$/.test(resizing) && y, dragging = eventTarget.classed("extent"), dragRestore = d3_event_dragSuppress(target), center, origin = d3.mouse(target), offset; + var w = d3.select(d3_window(target)).on("keydown.brush", keydown).on("keyup.brush", keyup); + if (d3.event.changedTouches) { + w.on("touchmove.brush", brushmove).on("touchend.brush", brushend); + } else { + w.on("mousemove.brush", brushmove).on("mouseup.brush", brushend); + } + g.interrupt().selectAll("*").interrupt(); + if (dragging) { + origin[0] = xExtent[0] - origin[0]; + origin[1] = yExtent[0] - origin[1]; + } else if (resizing) { + var ex = +/w$/.test(resizing), ey = +/^n/.test(resizing); + offset = [ xExtent[1 - ex] - origin[0], yExtent[1 - ey] - origin[1] ]; + origin[0] = xExtent[ex]; + origin[1] = yExtent[ey]; + } else if (d3.event.altKey) center = origin.slice(); + g.style("pointer-events", "none").selectAll(".resize").style("display", null); + d3.select("body").style("cursor", eventTarget.style("cursor")); + event_({ + type: "brushstart" + }); + brushmove(); + function keydown() { + if (d3.event.keyCode == 32) { + if (!dragging) { + center = null; + origin[0] -= xExtent[1]; + origin[1] -= yExtent[1]; + dragging = 2; + } + d3_eventPreventDefault(); + } + } + function keyup() { + if (d3.event.keyCode == 32 && dragging == 2) { + origin[0] += xExtent[1]; + origin[1] += yExtent[1]; + dragging = 0; + d3_eventPreventDefault(); + } + } + function brushmove() { + var point = d3.mouse(target), moved = false; + if (offset) { + point[0] += offset[0]; + point[1] += offset[1]; + } + if (!dragging) { + if (d3.event.altKey) { + if (!center) center = [ (xExtent[0] + xExtent[1]) / 2, (yExtent[0] + yExtent[1]) / 2 ]; + origin[0] = xExtent[+(point[0] < center[0])]; + origin[1] = yExtent[+(point[1] < center[1])]; + } else center = null; + } + if (resizingX && move1(point, x, 0)) { + redrawX(g); + moved = true; + } + if (resizingY && move1(point, y, 1)) { + redrawY(g); + moved = true; + } + if (moved) { + redraw(g); + event_({ + type: "brush", + mode: dragging ? "move" : "resize" + }); + } + } + function move1(point, scale, i) { + var range = d3_scaleRange(scale), r0 = range[0], r1 = range[1], position = origin[i], extent = i ? yExtent : xExtent, size = extent[1] - extent[0], min, max; + if (dragging) { + r0 -= position; + r1 -= size + position; + } + min = (i ? yClamp : xClamp) ? Math.max(r0, Math.min(r1, point[i])) : point[i]; + if (dragging) { + max = (min += position) + size; + } else { + if (center) position = Math.max(r0, Math.min(r1, 2 * center[i] - min)); + if (position < min) { + max = min; + min = position; + } else { + max = position; + } + } + if (extent[0] != min || extent[1] != max) { + if (i) yExtentDomain = null; else xExtentDomain = null; + extent[0] = min; + extent[1] = max; + return true; + } + } + function brushend() { + brushmove(); + g.style("pointer-events", "all").selectAll(".resize").style("display", brush.empty() ? "none" : null); + d3.select("body").style("cursor", null); + w.on("mousemove.brush", null).on("mouseup.brush", null).on("touchmove.brush", null).on("touchend.brush", null).on("keydown.brush", null).on("keyup.brush", null); + dragRestore(); + event_({ + type: "brushend" + }); + } + } + brush.x = function(z) { + if (!arguments.length) return x; + x = z; + resizes = d3_svg_brushResizes[!x << 1 | !y]; + return brush; + }; + brush.y = function(z) { + if (!arguments.length) return y; + y = z; + resizes = d3_svg_brushResizes[!x << 1 | !y]; + return brush; + }; + brush.clamp = function(z) { + if (!arguments.length) return x && y ? [ xClamp, yClamp ] : x ? xClamp : y ? yClamp : null; + if (x && y) xClamp = !!z[0], yClamp = !!z[1]; else if (x) xClamp = !!z; else if (y) yClamp = !!z; + return brush; + }; + brush.extent = function(z) { + var x0, x1, y0, y1, t; + if (!arguments.length) { + if (x) { + if (xExtentDomain) { + x0 = xExtentDomain[0], x1 = xExtentDomain[1]; + } else { + x0 = xExtent[0], x1 = xExtent[1]; + if (x.invert) x0 = x.invert(x0), x1 = x.invert(x1); + if (x1 < x0) t = x0, x0 = x1, x1 = t; + } + } + if (y) { + if (yExtentDomain) { + y0 = yExtentDomain[0], y1 = yExtentDomain[1]; + } else { + y0 = yExtent[0], y1 = yExtent[1]; + if (y.invert) y0 = y.invert(y0), y1 = y.invert(y1); + if (y1 < y0) t = y0, y0 = y1, y1 = t; + } + } + return x && y ? [ [ x0, y0 ], [ x1, y1 ] ] : x ? [ x0, x1 ] : y && [ y0, y1 ]; + } + if (x) { + x0 = z[0], x1 = z[1]; + if (y) x0 = x0[0], x1 = x1[0]; + xExtentDomain = [ x0, x1 ]; + if (x.invert) x0 = x(x0), x1 = x(x1); + if (x1 < x0) t = x0, x0 = x1, x1 = t; + if (x0 != xExtent[0] || x1 != xExtent[1]) xExtent = [ x0, x1 ]; + } + if (y) { + y0 = z[0], y1 = z[1]; + if (x) y0 = y0[1], y1 = y1[1]; + yExtentDomain = [ y0, y1 ]; + if (y.invert) y0 = y(y0), y1 = y(y1); + if (y1 < y0) t = y0, y0 = y1, y1 = t; + if (y0 != yExtent[0] || y1 != yExtent[1]) yExtent = [ y0, y1 ]; + } + return brush; + }; + brush.clear = function() { + if (!brush.empty()) { + xExtent = [ 0, 0 ], yExtent = [ 0, 0 ]; + xExtentDomain = yExtentDomain = null; + } + return brush; + }; + brush.empty = function() { + return !!x && xExtent[0] == xExtent[1] || !!y && yExtent[0] == yExtent[1]; + }; + return d3.rebind(brush, event, "on"); + }; + var d3_svg_brushCursor = { + n: "ns-resize", + e: "ew-resize", + s: "ns-resize", + w: "ew-resize", + nw: "nwse-resize", + ne: "nesw-resize", + se: "nwse-resize", + sw: "nesw-resize" + }; + var d3_svg_brushResizes = [ [ "n", "e", "s", "w", "nw", "ne", "se", "sw" ], [ "e", "w" ], [ "n", "s" ], [] ]; + var d3_time_format = d3_time.format = d3_locale_enUS.timeFormat; + var d3_time_formatUtc = d3_time_format.utc; + var d3_time_formatIso = d3_time_formatUtc("%Y-%m-%dT%H:%M:%S.%LZ"); + d3_time_format.iso = Date.prototype.toISOString && +new Date("2000-01-01T00:00:00.000Z") ? d3_time_formatIsoNative : d3_time_formatIso; + function d3_time_formatIsoNative(date) { + return date.toISOString(); + } + d3_time_formatIsoNative.parse = function(string) { + var date = new Date(string); + return isNaN(date) ? null : date; + }; + d3_time_formatIsoNative.toString = d3_time_formatIso.toString; + d3_time.second = d3_time_interval(function(date) { + return new d3_date(Math.floor(date / 1e3) * 1e3); + }, function(date, offset) { + date.setTime(date.getTime() + Math.floor(offset) * 1e3); + }, function(date) { + return date.getSeconds(); + }); + d3_time.seconds = d3_time.second.range; + d3_time.seconds.utc = d3_time.second.utc.range; + d3_time.minute = d3_time_interval(function(date) { + return new d3_date(Math.floor(date / 6e4) * 6e4); + }, function(date, offset) { + date.setTime(date.getTime() + Math.floor(offset) * 6e4); + }, function(date) { + return date.getMinutes(); + }); + d3_time.minutes = d3_time.minute.range; + d3_time.minutes.utc = d3_time.minute.utc.range; + d3_time.hour = d3_time_interval(function(date) { + var timezone = date.getTimezoneOffset() / 60; + return new d3_date((Math.floor(date / 36e5 - timezone) + timezone) * 36e5); + }, function(date, offset) { + date.setTime(date.getTime() + Math.floor(offset) * 36e5); + }, function(date) { + return date.getHours(); + }); + d3_time.hours = d3_time.hour.range; + d3_time.hours.utc = d3_time.hour.utc.range; + d3_time.month = d3_time_interval(function(date) { + date = d3_time.day(date); + date.setDate(1); + return date; + }, function(date, offset) { + date.setMonth(date.getMonth() + offset); + }, function(date) { + return date.getMonth(); + }); + d3_time.months = d3_time.month.range; + d3_time.months.utc = d3_time.month.utc.range; + function d3_time_scale(linear, methods, format) { + function scale(x) { + return linear(x); + } + scale.invert = function(x) { + return d3_time_scaleDate(linear.invert(x)); + }; + scale.domain = function(x) { + if (!arguments.length) return linear.domain().map(d3_time_scaleDate); + linear.domain(x); + return scale; + }; + function tickMethod(extent, count) { + var span = extent[1] - extent[0], target = span / count, i = d3.bisect(d3_time_scaleSteps, target); + return i == d3_time_scaleSteps.length ? [ methods.year, d3_scale_linearTickRange(extent.map(function(d) { + return d / 31536e6; + }), count)[2] ] : !i ? [ d3_time_scaleMilliseconds, d3_scale_linearTickRange(extent, count)[2] ] : methods[target / d3_time_scaleSteps[i - 1] < d3_time_scaleSteps[i] / target ? i - 1 : i]; + } + scale.nice = function(interval, skip) { + var domain = scale.domain(), extent = d3_scaleExtent(domain), method = interval == null ? tickMethod(extent, 10) : typeof interval === "number" && tickMethod(extent, interval); + if (method) interval = method[0], skip = method[1]; + function skipped(date) { + return !isNaN(date) && !interval.range(date, d3_time_scaleDate(+date + 1), skip).length; + } + return scale.domain(d3_scale_nice(domain, skip > 1 ? { + floor: function(date) { + while (skipped(date = interval.floor(date))) date = d3_time_scaleDate(date - 1); + return date; + }, + ceil: function(date) { + while (skipped(date = interval.ceil(date))) date = d3_time_scaleDate(+date + 1); + return date; + } + } : interval)); + }; + scale.ticks = function(interval, skip) { + var extent = d3_scaleExtent(scale.domain()), method = interval == null ? tickMethod(extent, 10) : typeof interval === "number" ? tickMethod(extent, interval) : !interval.range && [ { + range: interval + }, skip ]; + if (method) interval = method[0], skip = method[1]; + return interval.range(extent[0], d3_time_scaleDate(+extent[1] + 1), skip < 1 ? 1 : skip); + }; + scale.tickFormat = function() { + return format; + }; + scale.copy = function() { + return d3_time_scale(linear.copy(), methods, format); + }; + return d3_scale_linearRebind(scale, linear); + } + function d3_time_scaleDate(t) { + return new Date(t); + } + var d3_time_scaleSteps = [ 1e3, 5e3, 15e3, 3e4, 6e4, 3e5, 9e5, 18e5, 36e5, 108e5, 216e5, 432e5, 864e5, 1728e5, 6048e5, 2592e6, 7776e6, 31536e6 ]; + var d3_time_scaleLocalMethods = [ [ d3_time.second, 1 ], [ d3_time.second, 5 ], [ d3_time.second, 15 ], [ d3_time.second, 30 ], [ d3_time.minute, 1 ], [ d3_time.minute, 5 ], [ d3_time.minute, 15 ], [ d3_time.minute, 30 ], [ d3_time.hour, 1 ], [ d3_time.hour, 3 ], [ d3_time.hour, 6 ], [ d3_time.hour, 12 ], [ d3_time.day, 1 ], [ d3_time.day, 2 ], [ d3_time.week, 1 ], [ d3_time.month, 1 ], [ d3_time.month, 3 ], [ d3_time.year, 1 ] ]; + var d3_time_scaleLocalFormat = d3_time_format.multi([ [ ".%L", function(d) { + return d.getMilliseconds(); + } ], [ ":%S", function(d) { + return d.getSeconds(); + } ], [ "%I:%M", function(d) { + return d.getMinutes(); + } ], [ "%I %p", function(d) { + return d.getHours(); + } ], [ "%a %d", function(d) { + return d.getDay() && d.getDate() != 1; + } ], [ "%b %d", function(d) { + return d.getDate() != 1; + } ], [ "%B", function(d) { + return d.getMonth(); + } ], [ "%Y", d3_true ] ]); + var d3_time_scaleMilliseconds = { + range: function(start, stop, step) { + return d3.range(Math.ceil(start / step) * step, +stop, step).map(d3_time_scaleDate); + }, + floor: d3_identity, + ceil: d3_identity + }; + d3_time_scaleLocalMethods.year = d3_time.year; + d3_time.scale = function() { + return d3_time_scale(d3.scale.linear(), d3_time_scaleLocalMethods, d3_time_scaleLocalFormat); + }; + var d3_time_scaleUtcMethods = d3_time_scaleLocalMethods.map(function(m) { + return [ m[0].utc, m[1] ]; + }); + var d3_time_scaleUtcFormat = d3_time_formatUtc.multi([ [ ".%L", function(d) { + return d.getUTCMilliseconds(); + } ], [ ":%S", function(d) { + return d.getUTCSeconds(); + } ], [ "%I:%M", function(d) { + return d.getUTCMinutes(); + } ], [ "%I %p", function(d) { + return d.getUTCHours(); + } ], [ "%a %d", function(d) { + return d.getUTCDay() && d.getUTCDate() != 1; + } ], [ "%b %d", function(d) { + return d.getUTCDate() != 1; + } ], [ "%B", function(d) { + return d.getUTCMonth(); + } ], [ "%Y", d3_true ] ]); + d3_time_scaleUtcMethods.year = d3_time.year.utc; + d3_time.scale.utc = function() { + return d3_time_scale(d3.scale.linear(), d3_time_scaleUtcMethods, d3_time_scaleUtcFormat); + }; + d3.text = d3_xhrType(function(request) { + return request.responseText; + }); + d3.json = function(url, callback) { + return d3_xhr(url, "application/json", d3_json, callback); + }; + function d3_json(request) { + return JSON.parse(request.responseText); + } + d3.html = function(url, callback) { + return d3_xhr(url, "text/html", d3_html, callback); + }; + function d3_html(request) { + var range = d3_document.createRange(); + range.selectNode(d3_document.body); + return range.createContextualFragment(request.responseText); + } + d3.xml = d3_xhrType(function(request) { + return request.responseXML; + }); + if (typeof define === "function" && define.amd) this.d3 = d3, define(d3); else if (typeof module === "object" && module.exports) module.exports = d3; else this.d3 = d3; +}(); diff --git a/guix/graph.js b/guix/graph.js new file mode 100644 index 0000000000..ad8279395d --- /dev/null +++ b/guix/graph.js @@ -0,0 +1,129 @@ +// GNU Guix --- Functional package management for GNU +// Copyright © 2016 Ricardo Wurmus +// +// This file is part of GNU Guix. +// +// GNU Guix is free software; you can redistribute it and/or modify it +// under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 3 of the License, or (at +// your option) any later version. +// +// GNU Guix is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with GNU Guix. If not, see . + +var outerRadius = Math.max(nodeArray.length * 15, 500) / 2, + innerRadius = outerRadius - Math.min(nodeArray.length * 5, 200), + width = outerRadius * 2, + height = outerRadius * 2, + colors = d3.scale.category20c(), + matrix = []; + +function neighborsOf (node) { + return links.filter(function (e) { + return e.source === node; + }).map(function (e) { + return e.target; + }); +} + +function zoomed () { + zoomer.attr("transform", + "translate(" + d3.event.translate + ")" + + "scale(" + d3.event.scale + ")"); +} + +function fade (opacity, root) { + return function (g, i) { + root.selectAll("g path.chord") + .filter(function (d) { + return d.source.index != i && d.target.index != i; + }) + .transition() + .style("opacity", opacity); + }; +} + +// Now that we have all nodes in an object we can replace each reference +// with the actual node object. +links.forEach(function (link) { + link.target = nodes[link.target]; + link.source = nodes[link.source]; +}); + +// Construct a square matrix for package dependencies +nodeArray.forEach(function (d, index, arr) { + var source = index, + row = matrix[source]; + if (!row) { + row = matrix[source] = []; + for (var i = -1; ++i < arr.length;) row[i] = 0; + } + neighborsOf(d).forEach(function (d) { row[d.index]++; }); +}); + +// chord layout +var chord = d3.layout.chord() + .padding(0.01) + .sortSubgroups(d3.descending) + .sortChords(d3.descending) + .matrix(matrix); + +var arc = d3.svg.arc() + .innerRadius(innerRadius) + .outerRadius(innerRadius + 20); + +var zoom = d3.behavior.zoom() + .scaleExtent([0.1, 10]) + .on("zoom", zoomed); + +var svg = d3.select("body").append("svg") + .attr("width", "100%") + .attr("height", "100%") + .attr('viewBox', '0 0 ' + Math.min(width, height) + ' ' + Math.min(width, height)) + .attr('preserveAspectRatio', 'xMinYMin') + .call(zoom); + +var zoomer = svg.append("g"); + +var container = zoomer.append("g") + .attr("transform", "translate(" + outerRadius + "," + outerRadius + ")"); + +// Group for arcs and labels +var g = container.selectAll(".group") + .data(chord.groups) + .enter().append("g") + .attr("class", "group") + .on("mouseout", fade(1, container)) + .on("mouseover", fade(0.1, container)); + +// Draw one segment per package +g.append("path") + .style("fill", function (d) { return colors(d.index); }) + .style("stroke", function (d) { return colors(d.index); }) + .attr("d", arc); + +// Add circular labels +g.append("text") + .each(function (d) { d.angle = (d.startAngle + d.endAngle) / 2; }) + .attr("dy", ".35em") + .attr("transform", function (d) { + return "rotate(" + (d.angle * 180 / Math.PI - 90) + ")" + + "translate(" + (innerRadius + 26) + ")" + + (d.angle > Math.PI ? "rotate(180)" : ""); + }) + .style("text-anchor", function (d) { return d.angle > Math.PI ? "end" : null; }) + .text(function (d) { return nodeArray[d.index].label; }); + +// Draw chords from source to target; color by source. +container.selectAll(".chord") + .data(chord.chords) + .enter().append("path") + .attr("class", "chord") + .style("stroke", function (d) { return d3.rgb(colors(d.source.index)).darker(); }) + .style("fill", function (d) { return colors(d.source.index); }) + .attr("d", d3.svg.chord().radius(innerRadius)); diff --git a/guix/graph.scm b/guix/graph.scm index 93ff9ef81a..0d4cd83667 100644 --- a/guix/graph.scm +++ b/guix/graph.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015, 2016, 2020 Ludovic Courtès +;;; Copyright © 2015, 2016, 2020, 2021 Ludovic Courtès ;;; Copyright © 2016 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. @@ -274,11 +274,11 @@ text { var nodes = {}, nodeArray = [], links = []; -" (search-path %load-path "d3.v3.js"))) +" (search-path %load-path "guix/d3.v3.js"))) (define (emit-d3js-epilogue port) (format port "" - (search-path %load-path "graph.js"))) + (search-path %load-path "guix/graph.js"))) (define (emit-d3js-node id label port) (format port "\ diff --git a/guix/self.scm b/guix/self.scm index 7cda6656c9..e2e3198057 100644 --- a/guix/self.scm +++ b/guix/self.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2020 Martin Becze ;;; ;;; This file is part of GNU Guix. @@ -880,6 +880,11 @@ itself." (name name)) (scheme-modules* source "guix")) (list *core-modules*) + + #:extra-files + `(("guix/graph.js" ,(local-file "../guix/graph.js")) + ("guix/d3.v3.js" ,(local-file "../guix/d3.v3.js"))) + #:extensions dependencies #:guile-for-build guile-for-build)) -- cgit v1.2.3 From 01b59dea747bbb6e4097b26c79a24f2e5d261a1c Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Mon, 4 Jan 2021 23:58:28 +0100 Subject: gnu: Add guile-jwt. * gnu/packages/curl.scm (guile-jwt): New variable. --- gnu/packages/curl.scm | 2 +- gnu/packages/guile-xyz.scm | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index 33a2188d70..06f0c8ba5b 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2017 Efraim Flashner ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice ;;; Copyright © 2018 Roel Janssen -;;; Copyright © 2019 Ricardo Wurmus +;;; Copyright © 2019, 2021 Ricardo Wurmus ;;; Copyright © 2020 Jakub Kądziołka ;;; Copyright © 2020 Dale Mellor ;;; diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index cfb6397c80..8a6c769873 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -4236,6 +4236,38 @@ directory of its argument if it does not exist.") (home-page "https://mkdir-p.divoplade.fr") (license license:asl2.0))) +(define-public guile-jwt + (package + (name "guile-jwt") + (version "0.2.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/aconchillo/guile-jwt") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1p8sapiv5im18rjnzc8xnw6y7dr661rycf9g10z5ww0dl4rfz3z1")))) + (build-system gnu-build-system) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake) + ("pkg-config" ,pkg-config))) + (propagated-inputs + `(("guile-json" ,guile-json-4))) + (inputs + `(("guile" ,guile-3.0))) + (home-page "https://github.com/aconchillo/guile-jwt") + (synopsis "JSON Web Token library for Guile") + (description + "guile-jwt is a JSON Web Token module for Guile. JSON Web Tokens are an +open, industry standard (RFC 7519) method for representing claims securely +between two parties. guile-jwt allows you to decode, verify and generate +JWT. Supported algorithms: HS256, HS384, HS512.") + (license license:gpl3+))) + (define-public guile-sodium (package (name "guile-sodium") -- cgit v1.2.3 From 84e31f3c29e1f2f0e329c0bf105cce6ee1ff153f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 5 Jan 2021 00:10:08 +0100 Subject: gnu: Add guile-udev. * gnu/packages/guile-xyz.scm (guile-udev): New variable. --- gnu/packages/guile-xyz.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 8a6c769873..097266345a 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -1811,6 +1811,37 @@ users and in some situations.") (define-public guile3.0-wisp (deprecated-package "guile3.0-wisp" guile-wisp)) +(define-public guile-udev + (package + (name "guile-udev") + (version "0.1.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/artyom-poptsov/guile-udev") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1l6csncjqnx58c6c3wdl7rshnhk4pzhjq2q8lnkg483564s9w5py")))) + (build-system gnu-build-system) + (native-inputs + `(("autoconf" ,autoconf-wrapper) + ("automake" ,automake) + ("gettext" ,gettext-minimal) + ("libtool" ,libtool) + ("texinfo" ,texinfo) + ("pkg-config" ,pkg-config) + ("which" ,which))) + (inputs + `(("guile" ,guile-3.0) + ("eudev" ,eudev))) + (home-page "https://github.com/artyom-poptsov/guile-udev") + (synopsis "Guile bindings to libudev") + (description + "Guile-Udev provides GNU Guile bindings to libudev.") + (license license:gpl3+))) + (define-public guile-sly (package (name "guile-sly") -- cgit v1.2.3 From f40ddf95a34944673cd6262b7aae0c643e653ff9 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 5 Jan 2021 00:10:45 +0100 Subject: gnu: artanis: Fix typo. * gnu/packages/guile-xyz.scm (artanis): Fix typo. --- gnu/packages/guile-xyz.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 097266345a..92aee2f2e9 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -164,7 +164,7 @@ ;; projects. ;; TODO: Add guile-dbi and guile-dbd optional dependencies. (propagated-inputs - `(("guile-json" ,guile-json-1) ; This ia already using guile-2.2. + `(("guile-json" ,guile-json-1) ; This is already using guile-2.2. ("guile-readline" ,guile2.2-readline) ("guile-redis" ,guile2.2-redis))) (native-inputs -- cgit v1.2.3 From 58a5746e7361c317e352920745fbe2ad01e2e802 Mon Sep 17 00:00:00 2001 From: Oleh Malyi Date: Tue, 5 Jan 2021 00:23:38 +0000 Subject: gnu: Add stiff. * gnu/packages/image-processing.scm (stiff): New variable. Co-authored-by: Sharlatan Hellseher Signed-off-by: Leo Famulari --- gnu/packages/image-processing.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index 8d31029963..388e91d31a 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Vinicius Monego ;;; Copyright © 2020 Pierre Neidhardt ;;; Copyright © 2020 Brendan Tildesley +;;; Copyright © 2021 Oleh Malyi ;;; ;;; This file is part of GNU Guix. ;;; @@ -1064,3 +1065,27 @@ this project. Scan Tailer Advanced is a fork of Scan Tailer that merges Scan Tailor Featured and Scan Tailor Enhanced versions as well as including many more bug fixes.") (license license:gpl3+)))) + +(define-public stiff + (package + (name "stiff") + (version "2.4.0") + (source + (origin + (method url-fetch) + (uri (string-append "https://www.astromatic.net/download/stiff/stiff-" + version ".tar.gz")) + (sha256 + (base32 "14m92dskzw7bwsr64ha4p0mj3ndv13gwcbfic3qxrs3zq5353s7l")))) + (build-system gnu-build-system) + (inputs + `(("libtiff" ,libtiff) + ("zlib" ,zlib) + ("libjpeg-turbo" ,libjpeg-turbo))) + (home-page "https://www.astromatic.net/software/stiff") + (synopsis "Convert scientific FITS images to TIFF format") + (description + "STIFF is a program that converts scientific @acronym{FITS, Flexible Image +Transport System} images to the more popular TIFF format for illustration +purposes.") + (license license:gpl3+))) -- cgit v1.2.3 From c25285b6a155365a73c1f84e42397b2cd01d3023 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 5 Jan 2021 12:53:07 +0200 Subject: gnu: parallel: Update to 20201222. * gnu/packages/parallel.scm (parallel): Update to 20201222. --- gnu/packages/parallel.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/parallel.scm b/gnu/packages/parallel.scm index 3f03792ffd..4bece3be26 100644 --- a/gnu/packages/parallel.scm +++ b/gnu/packages/parallel.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2014, 2020 Eric Bavier ;;; Copyright © 2015 Mark H Weaver -;;; Copyright © 2015, 2016, 2017, 2018, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2020, 2021 Efraim Flashner ;;; Copyright © 2016 Pjotr Prins ;;; Copyright © 2016 Andreas Enge ;;; Copyright © 2016, 2020 Ricardo Wurmus @@ -55,14 +55,14 @@ (define-public parallel (package (name "parallel") - (version "20201122") + (version "20201222") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/parallel/parallel-" version ".tar.bz2")) (sha256 - (base32 "0c7zrb26xhbn48kvxs01qyj1vhwrpzkm11xxvi23njb6qi1bz82d")))) + (base32 "13kxg2vmy20ciiv1gp96g33bmvma1nh5d66jdix1fqj6xjaizr5n")))) (build-system gnu-build-system) (arguments `(#:phases -- cgit v1.2.3 From e3281657c8a97e32169fcc7e178f3fbbab7c88b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?= Date: Mon, 28 Dec 2020 10:36:48 +0100 Subject: gnu: smalltalk: Fix integer multiplication overflow. * gnu/local.mk (dist_patch_DATA): Add Smalltalk patch. * gnu/packages/patches/smalltalk-multiplication-overflow.patch: Patch from upstream commit 72ada189aba0283c551ead16635c1983968080b8. * gnu/packages/smalltalk.scm (smalltalk): Use patch and link with gmp and lightning libraries instead of the included source. --- gnu/local.mk | 1 + .../smalltalk-multiplication-overflow.patch | 121 +++++++++++++++++++++ gnu/packages/smalltalk.scm | 47 +++++++- 3 files changed, 164 insertions(+), 5 deletions(-) create mode 100644 gnu/packages/patches/smalltalk-multiplication-overflow.patch diff --git a/gnu/local.mk b/gnu/local.mk index 53a67e6ffe..2e026cb252 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1451,6 +1451,7 @@ dist_patch_DATA = \ %D%/packages/patches/sdl-pango-header-guard.patch \ %D%/packages/patches/sdl-pango-matrix_declarations.patch \ %D%/packages/patches/sdl-pango-sans-serif.patch \ + %D%/packages/patches/smalltalk-multiplication-overflow.patch \ %D%/packages/patches/sqlite-hurd.patch \ %D%/packages/patches/sunxi-tools-remove-sys-io.patch \ %D%/packages/patches/patchutils-test-perms.patch \ diff --git a/gnu/packages/patches/smalltalk-multiplication-overflow.patch b/gnu/packages/patches/smalltalk-multiplication-overflow.patch new file mode 100644 index 0000000000..7a0b4d02f7 --- /dev/null +++ b/gnu/packages/patches/smalltalk-multiplication-overflow.patch @@ -0,0 +1,121 @@ +Extracted from this commit without the ChangeLog to avoid conflicts: +http://git.savannah.gnu.org/cgit/smalltalk.git/commit/?id=72ada189aba0283c551ead16635c1983968080b8 + +The upstream commit message is +From 72ada189aba0283c551ead16635c1983968080b8 Mon Sep 17 00:00:00 2001 +From: Holger Hans Peter Freyther +Date: Sat, 7 Nov 2015 18:09:31 +0100 +Subject: libgst: Add alternative multiplication overflow check + +Apple clang on OSX and the version on FreeBSD optimize the +multiplication check away. Clang introduced a family of +builtins to do the multiplication and check for the overflow +and GCC made the API usable. For clang we would need to know +if intptr_t is of type int, long int, long long int and +then use the smul, smull smulll. +Luckily clang is adopting the better interface and this is +what we are starting to use now. This means the new code +will be used on GCC5 (and later) and some future versions of +clang. + +2015-11-07 Holger Hans Peter Freyther + + * build-aux/overflow-builtins.m4: Add new macro. + * configure.ac: Use GST_C_OVERFLOW_BUILTINS macro. + +2015-11-07 Holger Hans Peter Freyther + + * interp.inl: Add alternative mul_with_check implementation. +--- + ChangeLog | 5 +++++ + build-aux/overflow-builtins.m4 | 23 +++++++++++++++++++++++ + configure.ac | 1 + + libgst/ChangeLog | 4 ++++ + libgst/interp.inl | 22 ++++++++++++++++++++++ + 5 files changed, 55 insertions(+) + create mode 100644 build-aux/overflow-builtins.m4 + +diff --git a/build-aux/overflow-builtins.m4 b/build-aux/overflow-builtins.m4 +new file mode 100644 +index 00000000..9d050196 +--- /dev/null ++++ b/build-aux/overflow-builtins.m4 +@@ -0,0 +1,23 @@ ++dnl Check whether the host supports synchronization builtins. ++ ++AC_DEFUN([GST_C_OVERFLOW_BUILTINS], [ ++ AC_REQUIRE([AC_CANONICAL_HOST]) ++ AC_CACHE_CHECK([whether the host supports __builtin_mul_overflow], ++ gst_cv_have_builtin_mul_overflow, [ ++ save_CFLAGS="$CFLAGS" ++ case $host in ++ i?86-apple-darwin*) ;; ++ i?86-*-*) CFLAGS="$CFLAGS -march=i486" ;; ++ esac ++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[int foovar = 0;]], [[ ++if (__builtin_mul_overflow(44444, 55555, &foovar)) ++ return 23;]])], ++ [gst_cv_have_builtin_mul_overflow=yes], ++ [gst_cv_have_builtin_mul_overflow=no]) ++ CFLAGS="$save_CFLAGS" ++ ]) ++ if test $gst_cv_have_builtin_mul_overflow = yes; then ++ AC_DEFINE(HAVE_OVERFLOW_BUILTINS, 1, ++ [Define to 1 if the host supports __builtin_*_overflow builtins]) ++ fi ++]) +diff --git a/configure.ac b/configure.ac +index e789be45..0bac23ef 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -243,6 +243,7 @@ GST_C_SYNC_BUILTINS + if test $gst_cv_have_sync_fetch_and_add = no; then + AC_MSG_ERROR([Synchronization primitives not found, please use a newer compiler.]) + fi ++GST_C_OVERFLOW_BUILTINS + + GST_LOCK + AC_SYS_LARGEFILE +diff --git a/libgst/interp.inl b/libgst/interp.inl +index e18e27c7..dbc631bc 100644 +--- a/libgst/interp.inl ++++ b/libgst/interp.inl +@@ -159,6 +159,27 @@ sub_with_check (OOP op1, OOP op2, mst_Boolean *overflow) + OOP + mul_with_check (OOP op1, OOP op2, mst_Boolean *overflow) + { ++#ifdef HAVE_OVERFLOW_BUILTINS ++ intptr_t a = TO_INT (op1); ++ intptr_t b = TO_INT (op2); ++ intptr_t result; ++ ++ if (__builtin_mul_overflow(a, b, &result)) ++ { ++ *overflow = true; ++ return FROM_INT(0); ++ } ++ ++ ++ if (result < MIN_ST_INT || result > MAX_ST_INT) ++ { ++ *overflow = true; ++ return FROM_INT(0); ++ } ++ ++ *overflow = false; ++ return FROM_INT(result); ++#else + intptr_t a = TO_INT (op1); + intptr_t b = TO_INT (op2); + intmax_t result = (intmax_t)a * b; +@@ -188,6 +209,7 @@ mul_with_check (OOP op1, OOP op2, mst_Boolean *overflow) + } + + return FROM_INT (0); ++#endif + } + + /* State of the random generator. +-- +2.29.2 + diff --git a/gnu/packages/smalltalk.scm b/gnu/packages/smalltalk.scm index 5d35f563e2..742a9b89c4 100644 --- a/gnu/packages/smalltalk.scm +++ b/gnu/packages/smalltalk.scm @@ -26,6 +26,8 @@ #:use-module (guix download) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) + #:use-module (gnu packages) + #:use-module (gnu packages assembly) #:use-module (gnu packages audio) #:use-module (gnu packages autotools) #:use-module (gnu packages base) @@ -36,6 +38,7 @@ #:use-module (gnu packages libffi) #:use-module (gnu packages libsigsegv) #:use-module (gnu packages linux) + #:use-module (gnu packages multiprecision) #:use-module (gnu packages pkg-config) #:use-module (gnu packages pulseaudio) #:use-module (gnu packages xorg)) @@ -51,18 +54,52 @@ version ".tar.xz")) (sha256 (base32 - "1k2ssrapfzhngc7bg1zrnd9n2vyxp9c9m70byvsma6wapbvib6l1")))) + "1k2ssrapfzhngc7bg1zrnd9n2vyxp9c9m70byvsma6wapbvib6l1")) + ;; XXX: To be removed with the next release of Smalltalk. + (patches (search-patches "smalltalk-multiplication-overflow.patch")))) (build-system gnu-build-system) (native-inputs - `(("libffi" ,libffi) + `(("pkg-config" ,pkg-config) + ;; XXX: To be removed with the next release of Smalltalk. + ("autoconf" ,autoconf) + ("automake" ,automake) + ("libtool" ,libtool))) + ;; TODO: These optional dependencies raise the closure size to ~1 GiB + ;; from the current ~100 MiB, although some of them might be very + ;; useful for end users: + ;; - freeglut + ;; - glib + ;; - gobject-introspection + ;; - gtk+-2 + ;; - tcl/tk + ;; - SDL (sdl-union) + ;; - sqlite + ;; - zlib + (inputs + `(("gmp" ,gmp) + ("libffi" ,libffi) ("libltdl" ,libltdl) ("libsigsegv" ,libsigsegv) - ("pkg-config" ,pkg-config))) - (inputs - `(("zip" ,zip))) + ("lightning" ,lightning) + ("zip" ,zip))) (arguments `(#:phases (modify-phases %standard-phases + ;; XXX: To be removed with the next release of Smalltalk. + ;; The overflow patch modifies configure.ac, therefore remove + ;; old configure script and enforce an autoreconf. + (add-before 'bootstrap 'remove-unpatched-configure + (lambda _ + (delete-file "configure") + #t)) + ;; XXX: To be removed with the next release of Smalltalk. + ;; We don't want to regenerate the info files. + (add-after 'build 'keep-generated-info-manual + (lambda _ + (for-each (lambda (file) + (invoke "touch" file)) + (find-files "doc" "\\.info")) + #t)) (add-before 'configure 'fix-libc (lambda _ (let ((libc (assoc-ref %build-inputs "libc"))) -- cgit v1.2.3 From df965a54e1f18dfd62ec8479623f61f4bddb9760 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?= Date: Mon, 28 Dec 2020 11:42:31 +0100 Subject: gnu: smalltalk: Update to version 3.2.91. * gnu/packages/smalltalk.scm (smalltalk): Update to 3.2.91. Co-Authored-By: Holger Peters --- gnu/packages/smalltalk.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gnu/packages/smalltalk.scm b/gnu/packages/smalltalk.scm index 742a9b89c4..ea1798ac13 100644 --- a/gnu/packages/smalltalk.scm +++ b/gnu/packages/smalltalk.scm @@ -46,15 +46,16 @@ (define-public smalltalk (package (name "smalltalk") - (version "3.2.5") + (version "3.2.91") (source (origin (method url-fetch) - (uri (string-append "mirror://gnu/smalltalk/smalltalk-" + ;; XXX: Revert to mirror://gnu with the next release of Smalltalk. + (uri (string-append "https://alpha.gnu.org/gnu/smalltalk/smalltalk-" version ".tar.xz")) (sha256 (base32 - "1k2ssrapfzhngc7bg1zrnd9n2vyxp9c9m70byvsma6wapbvib6l1")) + "1zb2h5cbz1cwybqjl24lflw359lwj7sjvvhwb4x6miypzhwq4qh0")) ;; XXX: To be removed with the next release of Smalltalk. (patches (search-patches "smalltalk-multiplication-overflow.patch")))) (build-system gnu-build-system) -- cgit v1.2.3 From 324117c06bb1ef6ec550bde1d407821e14735310 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Mon, 4 Jan 2021 18:33:42 +0100 Subject: gnu: crypto++: Update to 8.4.0. * gnu/packages/crypto.scm (crypto++): Update to 8.4.0. Signed-off-by: Efraim Flashner --- gnu/packages/crypto.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index 8226497b81..6683f1cd78 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -717,7 +717,7 @@ data on your platform, so the seed itself will be as random as possible. (define-public crypto++ (package (name "crypto++") - (version "8.3.0") + (version "8.4.0") (source (origin (method url-fetch/zipbomb) (uri (string-append "https://cryptopp.com/cryptopp" @@ -725,7 +725,7 @@ data on your platform, so the seed itself will be as random as possible. ".zip")) (sha256 (base32 - "16jqxvsyjjpyyb89fj2h8mgb0m07vlqvggifbrk7qcqwddda2f6v")))) + "16kvfm11xv7j9a3yykzysjgw38a9b7lnc5n5x5h82g395k6ybxf0")))) (build-system gnu-build-system) (arguments `(#:make-flags -- cgit v1.2.3 From effacc281c758236bbba9a1f4fd7791baa303a96 Mon Sep 17 00:00:00 2001 From: Ryan Prior Date: Tue, 5 Jan 2021 05:13:22 +0000 Subject: gnu: visidata: Update to 2.1.1. * gnu/packages/visidata.scm (visidata): Update to 2.1.1. Signed-off-by: Efraim Flashner --- gnu/packages/visidata.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/visidata.scm b/gnu/packages/visidata.scm index db126eb4ff..c802c088b3 100644 --- a/gnu/packages/visidata.scm +++ b/gnu/packages/visidata.scm @@ -31,14 +31,14 @@ (define-public visidata (package (name "visidata") - (version "2.1") + (version "2.1.1") (source (origin (method url-fetch) (uri (pypi-uri "visidata" version)) (sha256 (base32 - "15y6yif0h610ill57ck85l8n5faw849caw6rhf95rd0x67hkikaa")))) + "0sn0hnlrrbydgwdza20g2zdlchsas39hbkxzyxnrc13sp26zmmnx")))) (build-system python-build-system) (arguments '(#:phases -- cgit v1.2.3 From 957f0c40327ce00f53db22737e3775ce616ac258 Mon Sep 17 00:00:00 2001 From: Andy Tai Date: Mon, 14 Dec 2020 23:31:39 -0800 Subject: gnu: terminator: Update to 1.92. * gnu/packages/gnome.scm (terminator): Update to 1.92. [source]: Use new upstream URI. [inputs]: Remove python2-psutil. Replace python2-pycairo, python2-pygobject with python- versions. Add dbus-glib, gtk+. Move gobject-introspection ... [native-inputs]: ... to here. Add python-psutil, python-pytest-runner, python-pytest. [propagated-inputs]: Add pyhton-configobj. [arguments]: Build with python3. Adjust 'wrap-program phase to also wrap with package's own python output. [home-page]: Update to new upstream URI. Signed-off-by: Efraim Flashner --- gnu/packages/gnome.scm | 43 +++++++++++++++++++++++++++---------------- 1 file changed, 27 insertions(+), 16 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 634b251031..f0d94ab1fe 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -56,6 +56,7 @@ ;;; Copyright © 2020 Arun Isaac ;;; Copyright © 2020 Michael Rohleder ;;; Copyright © 2020 Tim Gesthuizen +;;; Copyright © 2020 Andy Tai ;;; ;;; This file is part of GNU Guix. ;;; @@ -10859,32 +10860,37 @@ advanced image management tool") (define-public terminator (package (name "terminator") - (version "1.91") + (version "1.92") (source (origin (method url-fetch) - (uri (string-append "https://launchpad.net/" name "/" - "gtk3/" version "/" "+download/" + (uri (string-append "https://github.com/gnome-" name "/" name "/" + "releases/download/v" version "/" name "-" version ".tar.gz")) (sha256 (base32 - "0sdyqwydmdnh7j6mn74vrywz35m416kqsbxbrqcnv5ak08y6xxwm")))) + "1wbkfp0nk6x9bcwi681zy30qmrp4h754sdz6b7hi9j22mmvdd50z")))) (build-system python-build-system) (native-inputs - `(("intltool" ,intltool) + `(("gettext" ,gettext-minimal) ("glib:bin" ,glib "bin") ; for glib-compile-resources - ("gettext" ,gettext-minimal) - ("pkg-config" ,pkg-config))) + ("gobject-introspection" ,gobject-introspection) + ("intltool" ,intltool) + ("pkg-config" ,pkg-config) + ("python-psutil" ,python-psutil) + ("python-pytest-runner" ,python-pytest-runner) + ("python-pytest" ,python-pytest))) (inputs `(("cairo" ,cairo) - ("gobject-introspection" ,gobject-introspection) + ("dbus-glib" ,dbus-glib) ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) - ("python2-pycairo" ,python2-pycairo) - ("python2-pygobject" ,python2-pygobject) - ("python2-psutil" ,python2-psutil) + ("gtk+" ,gtk+) + ("python-pycairo" ,python-pycairo) + ("python-pygobject" ,python-pygobject) ("vte" ,vte))) + (propagated-inputs + `(("python-configobj" ,python-configobj))) (arguments - `(#:python ,python-2 ; Python 3 isn't supported - #:imported-modules ((guix build glib-or-gtk-build-system) + `(#:imported-modules ((guix build glib-or-gtk-build-system) ,@%python-build-system-modules) #:modules ((guix build python-build-system) ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) @@ -10895,14 +10901,19 @@ advanced image management tool") 'install 'wrap-program (lambda* (#:key outputs #:allow-other-keys) (let ((prog (string-append (assoc-ref outputs "out") - "/bin/terminator"))) + "/bin/terminator")) + (pylib (string-append (assoc-ref outputs "out") + "/lib/python" + ,(version-major+minor + (package-version python)) + "/site-packages"))) (wrap-program prog - `("PYTHONPATH" = (,(getenv "PYTHONPATH"))) + `("PYTHONPATH" = (,(getenv "PYTHONPATH") ,pylib)) `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))) #t))) (add-after 'wrap-program 'glib-or-gtk-wrap (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))))) - (home-page "https://gnometerminator.blogspot.com/") + (home-page "https://gnome-terminator.org/") (synopsis "Store and run multiple GNOME terminals in one window") (description "Terminator allows you to run multiple GNOME terminals in a grid and -- cgit v1.2.3 From 31651ff6cd2ffdd008c9fc92ea17caa9df137848 Mon Sep 17 00:00:00 2001 From: Z572 <873216071@qq.com> Date: Fri, 25 Dec 2020 20:06:53 +0800 Subject: gnu: Add akregator. * gnu/packages/kde.scm (akregator): New variable. Signed-off-by: Efraim Flashner --- gnu/packages/kde.scm | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm index 999633d78c..12d54a0b5d 100644 --- a/gnu/packages/kde.scm +++ b/gnu/packages/kde.scm @@ -49,6 +49,7 @@ #:use-module (gnu packages curl) #:use-module (gnu packages djvu) #:use-module (gnu packages documentation) + #:use-module (gnu packages gnupg) #:use-module (gnu packages ebook) #:use-module (gnu packages flex) #:use-module (gnu packages fontutils) @@ -141,6 +142,77 @@ This package contains GUI widgets for baloo.") (license ;; LGPL for libraries, FDL for documentation (list license:lgpl2.1+ license:fdl1.2+)))) +(define-public akregator + (package + (name "akregator") + (version "20.04.1") + (source + (origin + (method url-fetch) + (uri (string-append "mirror://kde/stable/release-service/" version + "/src/akregator-" version ".tar.xz")) + (sha256 + (base32 "1711yhwsdq9iyc3wm3a4xmz81p73hvvc0h58sasc89ifpry50k2p")))) + (build-system qt-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'install 'wrap-qt-process-path + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin/akregator")) + (qt-process-path (string-append + (assoc-ref inputs "qtwebengine") + "/lib/qt5/libexec/QtWebEngineProcess"))) + (wrap-program bin + `("QTWEBENGINEPROCESS_PATH" = (,qt-process-path))) + #t)))))) + (native-inputs + `(("extra-cmake-modules" ,extra-cmake-modules) + ("kdoctools" ,kdoctools))) + (inputs + `(("akonadi" ,akonadi) + ("akonadi-contacts" ,akonadi-contacts) + ("akonadi-mime" ,akonadi-mime) + ("boost" ,boost) + ("breeze-icons" ,breeze-icons) + ("gpgme" ,gpgme) + ("grantlee" ,grantlee) + ("grantleetheme" ,grantleetheme) + ("kcmutils" ,kcmutils) + ("kcontacts" ,kcontacts) + ("kcrash" ,kcrash) + ("kimap" ,kimap) + ("kitemmodels" ,kitemmodels) + ("kmessagelib" ,kmessagelib) + ("kmime" ,kmime) + ("knotifications" ,knotifications) + ("knotifyconfig" ,knotifyconfig) + ("kontactinterface" ,kontactinterface) + ("kpimcommon" ,kpimcommon) + ("kpimtextedit" ,kpimtextedit) + ("kqtquickcharts" ,kqtquickcharts) + ("ktexteditor" ,ktexteditor) + ("kuserfeedback" ,kuserfeedback) + ("libkdepim" ,libkdepim) + ("libkleo" ,libkleo) + ("qgpgme" ,qgpgme) + ("qtbase" ,qtbase) + ("qtdeclarative" ,qtdeclarative) + ("qtwebchannel" ,qtwebchannel) + ("qtwebengine" ,qtwebengine) + ("syndication" ,syndication))) + (home-page "https://apps.kde.org/en/akregator") + (synopsis "KDE Feed Reader") + (description + "Akregator is a news feed reader. It enables you to follow news +sites, blogs and other RSS/Atom-enabled websites without the need to manually +check for updates using a web browser. Akregator is designed to be both easy to +use and to be powerful enough to read hundreds of news sources conveniently. +It comes with a fast search, advanced archiving functionality and an internal +browser for easy news reading.") + (license license:gpl2+))) + (define-public kdenlive (let ((version "20.08.3")) (package -- cgit v1.2.3 From b684d45d10936f85d14c0997b56c8d7be7013aca Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Tue, 5 Jan 2021 19:25:10 +0100 Subject: gnu: moreutils: Update to 0.65. * gnu/packages/moreutils.scm (moreutils): Update to 0.65. --- gnu/packages/moreutils.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/moreutils.scm b/gnu/packages/moreutils.scm index 55a6d0b568..9e3bf0fc29 100644 --- a/gnu/packages/moreutils.scm +++ b/gnu/packages/moreutils.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer ;;; Copyright © 2016, 2017, 2019 Efraim Flashner -;;; Copyright © 2016, 2017, 2018, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2018, 2020, 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -30,7 +30,7 @@ (define-public moreutils (package (name "moreutils") - (version "0.64") + (version "0.65") (source (origin (method url-fetch) @@ -42,7 +42,7 @@ "http://drabczyk.org/" name "-" version ".tar.gz"))) (sha256 - (base32 "1v3hazb9i5y6b3vx4giiszvc2zk2pjjvq88xlk1maasw5ia07lpy")))) + (base32 "10c8b4bwnli4gxwvgmgkc5kin1ksrxsnxmigs7y4rrh4aaszdjb0")))) (build-system gnu-build-system) ;; For building the manual pages. (native-inputs -- cgit v1.2.3 From a5d82fd3932319dd32936f29c97983a99577ed1d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Tue, 5 Jan 2021 19:59:23 +0100 Subject: gnu: python-prompt-toolkit: Update to 3.0.9. * gnu/packages/python-xyz.scm (python-prompt-toolkit): Update to 3.0.9. --- gnu/packages/python-xyz.scm | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index c4fbadb42b..ab10668a01 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -31,7 +31,7 @@ ;;; Copyright © 2016, 2017, 2019 Alex Vong ;;; Copyright © 2016, 2017, 2018 Arun Isaac ;;; Copyright © 2016, 2017, 2018, 2020 Julien Lepiller -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016, 2017 Thomas Danckaert ;;; Copyright © 2017 Carlo Zancanaro ;;; Copyright © 2017 Frederick M. Muriithi @@ -13601,13 +13601,13 @@ collections of data.") (define-public python-prompt-toolkit (package (name "python-prompt-toolkit") - (version "3.0.7") + (version "3.0.9") (source (origin (method url-fetch) (uri (pypi-uri "prompt_toolkit" version)) (sha256 - (base32 "12a4pyrpnm3vcrvx7lb4cglp220lbvi336mhn2k2nzcgy82lcbw2")))) + (base32 "0bvjp62cs6aj9lrh7njzxdjgg8pjfw3qgmr551243d9ivmcapvn5")))) (build-system python-build-system) (arguments `(#:phases @@ -13624,8 +13624,7 @@ collections of data.") `(("python-wcwidth" ,python-wcwidth))) (native-inputs `(("python-pytest" ,python-pytest))) - (home-page - "https://github.com/prompt-toolkit/python-prompt-toolkit") + (home-page "https://github.com/prompt-toolkit/python-prompt-toolkit") (synopsis "Library for building command line interfaces in Python") (description "Prompt-Toolkit is a library for building interactive command line -- cgit v1.2.3 From 08157e1586015eacc6256dfde432515a067d33cf Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 14:31:13 +0100 Subject: gnu: Add rust-extend-0.1. * gnu/packages/crates-io.scm (rust-extend-0.1): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 5b19476e42..f9aa75c168 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9873,6 +9873,34 @@ blocking data structures.") testing.") (license (list license:expat license:asl2.0)))) +(define-public rust-extend-0.1 + (package + (name "rust-extend") + (version "0.1.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "extend" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "01azyniinxrwng13hkj450gplp1ajslbqzksjg4dk6655sks6zgl")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags '("--release" "--" "--skip=test::test_ui" ) + #:cargo-inputs + (("rust-proc-macro-error" ,rust-proc-macro-error-1) + ("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-trybuild" ,rust-trybuild-1)))) + (home-page "https://github.com/davidpdrsn/extend") + (synopsis "Create extensions for types you don't own") + (description + "This crates creates extensions for types you don't own with extension +traits but without the boilerplate.") + (license license:expat))) + (define-public rust-fake-simd-0.1 (package (name "rust-fake-simd") -- cgit v1.2.3 From 99f73895c09089955ca51b52e3b8c9ac6d12b67d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 15:38:40 +0100 Subject: gnu: Add rust-assert-json-diff-1. * gnu/packages/crates-io.scm (rust-assert-json-diff-1): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f9aa75c168..dfc1c282e6 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1175,6 +1175,36 @@ standard library.") "File system fixtures and assertions for testing.") (license (list license:expat license:asl2.0)))) +(define-public rust-assert-json-diff-1 + (package + (name "rust-assert-json-diff") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "assert-json-diff" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1h2w4n8f8a1n9sc8snka0arzw5x95ky5k8i7603z3lhkcplwnna2")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-extend" ,rust-extend-0.1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1)) + #:cargo-development-inputs + (("rust-version-sync" ,rust-version-sync-0.8)))) + (home-page "https://github.com/davidpdrsn/assert-json-diff") + (synopsis "Easily compare two JSON values and get great output") + (description + "This crate includes macros for comparing two serializable values +by diffing their JSON representations. It is designed to give much +more helpful error messages than the standard @code{assert_eq!. It +basically does a diff of the two objects and tells you the exact +differences. This is useful when asserting that two large JSON +objects are the same.") + (license license:expat))) + (define-public rust-assert-matches-1.3 (package (name "rust-assert-matches") -- cgit v1.2.3 From 9cb0167b72d0acba1cc554543161538a1c36de36 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 15:52:54 +0100 Subject: gnu: Add rust-mockito-0.23. * gnu/packages/crates-io.scm (rust-mockito-0.23): New variable. --- gnu/packages/crates-io.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index dfc1c282e6..c6ebf74be8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18448,6 +18448,40 @@ IOCP and Async I/O abstractions.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.3)))))) +(define-public rust-mockito-0.23 + (package + (name "rust-mockito") + (version "0.23.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "mockito" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0kh2wg24441miqcnrp2miaapphn8wgm18x23yjq45pajsjxfd0mf")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags + '("--release" + "--" + "--skip=test_assert_with_last_unmatched_request" + "--skip=test_assert_with_last_unmatched_request_and_headers") + #:cargo-inputs + (("rust-assert-json-diff" ,rust-assert-json-diff-1) + ("rust-colored" ,rust-colored-1) + ("rust-difference" ,rust-difference-2) + ("rust-httparse" ,rust-httparse-1) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-percent-encoding" ,rust-percent-encoding-2) + ("rust-rand" ,rust-rand-0.7) + ("rust-regex" ,rust-regex-1) + ("rust-serde-json" ,rust-serde-json-1)))) + (home-page "https://github.com/lipanski/mockito") + (synopsis "HTTP mocking for Rust") + (description "This crate provides HTTP mocking for Rust.") + (license license:expat))) + (define-public rust-model-0.1 (package (name "rust-model") -- cgit v1.2.3 From b4161c61234b051665f8806d91768ce93586a5c2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 19:17:59 +0100 Subject: gnu: Add rust-sluice-0.5. * gnu/packages/crates-io.scm (rust-sluice-0.5): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c6ebf74be8..eaf30faf4f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30800,6 +30800,36 @@ data type.") license:expat license:asl2.0)))) +(define-public rust-sluice-0.5 + (package + (name "rust-sluice") + (version "0.5.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "sluice" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1w9brs9dqyvr2w7cs5nxkp2wggw2xh76bc4qq0p4yxwfvhgfs94f")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-io" ,rust-futures-io-0.3)) + #:cargo-development-inputs + (("rust-cfg-if" ,rust-cfg-if-1) + ("rust-criterion" ,rust-criterion-0.3) + ("rust-futures" ,rust-futures-0.3) + ("rust-quickcheck" ,rust-quickcheck-0.9) + ("rust-quickcheck-macros" ,rust-quickcheck-macros-0.9)))) + (home-page "https://github.com/sagebind/sluice") + (synopsis "Ring buffer for byte buffers, FIFO queues, and SPSC channels") + (description + "This package provides asynchronous byte buffers and pipes for concurrent +I/O programming.") + (license license:expat))) + (define-public rust-smallvec-1 (package (name "rust-smallvec") -- cgit v1.2.3 From c8ffcf7e6c83a6dfcc853a2fb1e6c53a2ff71b09 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 21:22:37 +0100 Subject: gnu: Add rust-nanorand-0.4. * gnu/packages/crates-io.scm (rust-nanorand-0.4): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index eaf30faf4f..1e1d5b8006 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18611,6 +18611,30 @@ libmysqlclient.") quick compile time, and minimal dependencies.") (license license:zlib))) +(define-public rust-nanorand-0.4 + (package + (inherit rust-nanorand-0.5) + (name "rust-nanorand") + (version "0.4.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "nanorand" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1ifpjgir1a6lw64jkb6la5hb8j5jvqq70nmxgzjj0cjf13jd3kys")))) + (arguments + `(#:skip-build? #true ;error with pre-release randomize + #:cargo-inputs + (("rust-getrandom" ,rust-getrandom-0.2) + ("rust-zeroize" ,rust-zeroize-1)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.3) + ("rust-fastrand" ,rust-fastrand-1) + ("rust-hex" ,rust-hex-0.4) + ("rust-random-fast-rng" ,rust-random-fast-rng-0.1) + ("rust-randomize" ,rust-randomize-4)))))) + (define-public rust-nasm-rs-0.2 (package (name "rust-nasm-rs") -- cgit v1.2.3 From c221a8979459dc8432f8ddc7e507ff65b4d4056c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 21:23:27 +0100 Subject: gnu: Add rust-flume-0.9. * gnu/packages/crates-io.scm (rust-flume-0.9): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1e1d5b8006..039a329a48 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -10634,6 +10634,26 @@ crate.") "This package provides a fast multi-producer channel.") (license (list license:asl2.0 license:expat)))) +(define-public rust-flume-0.9 + (package + (inherit rust-flume-0.10) + (name "rust-flume") + (version "0.9.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "flume" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0ck1w9881848xjjk93nxqsvnxfp4xsaysxxn23a210bg2amsvsqv")))) + (arguments + `(#:skip-build? #true + #:cargo-inputs + (("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-nanorand" ,rust-nanorand-0.4) + ("rust-spinning-top" ,rust-spinning-top-0.2)))))) + (define-public rust-fnv-1 (package (name "rust-fnv") -- cgit v1.2.3 From c0fde7184e51a88f3d3fbef85882286558531832 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 21:27:44 +0100 Subject: gnu: Add rust-enum-to-u8-slice-derive-0.1. * gnu/packages/crates-io.scm (rust-enum-to-u8-slice-derive-0.1): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 039a329a48..cadcc2e679 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9423,6 +9423,29 @@ accessor functions on enums.") ("rust-quote" ,rust-quote-0.6) ("rust-syn" ,rust-syn-0.15)))))) +(define-public rust-enum-to-u8-slice-derive-0.1 + (package + (name "rust-enum-to-u8-slice-derive") + (version "0.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "enum_to_u8_slice_derive" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0hvzi74pnh5a7f4klrk0dz45l0mgcy5l3zajjhjsxzws28js4yc4")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-quote" ,rust-quote-0.3) + ("rust-syn" ,rust-syn-0.11)))) + (home-page "https://github.com/mesalock-linux/enum_to_u8_slice_derive") + (synopsis "Convert enum to u8 slice ref") + (description + "This package provides a simple fork of @code{enum_to_str_derive}, +convert enum to u8 slice ref.") + (license license:bsd-3))) + (define-public rust-env-logger-0.7 (package (name "rust-env-logger") -- cgit v1.2.3 From aeb3c2e72f79032763ca4cd59801fd7832a5f9ac Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 21:34:52 +0100 Subject: gnu: Add rust-mesalink-1. * gnu/packages/crates-io.scm (rust-mesalink-1): New variable. --- gnu/packages/crates-io.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index cadcc2e679..b68539dad0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -18029,6 +18029,50 @@ proofs. It automates the Fiat-Shamir transform, so that by using Merlin, non-interactive protocols can be implemented as if they were interactive.") (license license:expat))) +(define-public rust-mesalink-1 + (package + (name "rust-mesalink") + (version "1.1.0-cratesio") + (source + (origin + (method url-fetch) + (uri (crate-uri "mesalink" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "02lp27j5vxdc95bf5g983yr660cm6vljikk0yqry4j6cjvfnyq85")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-test-flags + '("--release" + "--" + "--skip=libssl::ssl::tests::early_data_to_mesalink_io" + "--skip=libssl::ssl::tests::get_ssl_fd" + "--skip=libssl::ssl::tests::ssl_on_nonblocking_socket") + #:cargo-inputs + (("rust-base64" ,rust-base64-0.10) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-enum-to-u8-slice-derive" ,rust-enum-to-u8-slice-derive-0.1) + ("rust-env-logger" ,rust-env-logger-0.6) + ("rust-jemallocator" ,rust-jemallocator-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-parking-lot" ,rust-parking-lot-0.9) + ("rust-ring" ,rust-ring-0.16) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-sct" ,rust-sct-0.6) + ("rust-untrusted" ,rust-untrusted-0.7) + ("rust-walkdir" ,rust-walkdir-2) + ("rust-webpki" ,rust-webpki-0.21) + ("rust-webpki-roots" ,rust-webpki-roots-0.17)) + #:cargo-development-inputs + (("rust-cfg-if" ,rust-cfg-if-1)))) + (home-page "https://github.com/mesalock-linux/mesalink") + (synopsis "Memory-safe and OpenSSL-compatible TLS library") + (description + "MesaLink is a memory-safe and OpenSSL-compatible TLS library +based on Rustls and Ring.") + (license license:bsd-3))) + (define-public rust-metadeps-1.1 (package (name "rust-metadeps") -- cgit v1.2.3 From b14f5582949e57d106e3b937f11701b52ef028ab Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 21:42:03 +0100 Subject: gnu: rust-curl-sys-0.4: Update to 0.4.39+curl-7.74.0. * gnu/packages/crates-io.scm (rust-curl-sys-0.4): Update to 0.4.39+curl-7.74.0. [arguments]: Add rust-mesalink to Cargo inputs. Add rust-cfg-if to Cargo development inputs. --- gnu/packages/crates-io.scm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index b68539dad0..d18e130faf 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7123,7 +7123,7 @@ use with bindgen.") (define-public rust-curl-sys-0.4 (package (name "rust-curl-sys") - (version "0.4.20") + (version "0.4.39+curl-7.74.0") (source (origin (method url-fetch) @@ -7131,7 +7131,7 @@ use with bindgen.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 - "02542zmvl3fpdqf7ai4cqnamm4albx9j645dkjx5qr1myq8ax42y")) + "0x7qhq7c3b1vmp3740yiigzm09qvkzpdf578jjrs0s3v3s3cxa07")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "curl") #t)))) @@ -7141,11 +7141,14 @@ use with bindgen.") (("rust-libc" ,rust-libc-0.2) ("rust-libnghttp2-sys" ,rust-libnghttp2-sys-0.1) ("rust-libz-sys" ,rust-libz-sys-1) + ("rust-mesalink" ,rust-mesalink-1) ("rust-openssl-sys" ,rust-openssl-sys-0.9) ("rust-winapi" ,rust-winapi-0.3) ("rust-cc" ,rust-cc-1) ("rust-pkg-config" ,rust-pkg-config-0.3) - ("rust-vcpkg" ,rust-vcpkg-0.2)))) + ("rust-vcpkg" ,rust-vcpkg-0.2)) + #:cargo-development-inputs + (("rust-cfg-if" ,rust-cfg-if-1)))) (native-inputs `(("pkg-config" ,pkg-config))) (inputs -- cgit v1.2.3 From 6d1b9d15dc211370f9c889e542cfaceb4f45154d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 22:05:56 +0100 Subject: gnu: Add rust-curl-0.4. * gnu/packages/crates-io.scm (rust-curl-0.4): New variable. --- gnu/packages/crates-io.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d18e130faf..fdd7e2dd07 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7120,6 +7120,46 @@ Transparency logs for use with sct crate.") use with bindgen.") (license (list license:expat license:asl2.0)))) +(define-public rust-curl-0.4 + (package + (name "rust-curl") + (version "0.4.34") + (source + (origin + (method url-fetch) + (uri (crate-uri "curl" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0vkm6fyizf8m9yxpv3n5pm9ag3bwlyqa6nz2ga8qkzm5y4m1cs72")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;require internet access + #:cargo-inputs + (("rust-curl-sys" ,rust-curl-sys-0.4) + ("rust-libc" ,rust-libc-0.2) + ("rust-openssl-probe" ,rust-openssl-probe-0.1) + ("rust-openssl-sys" ,rust-openssl-sys-0.9) + ("rust-schannel" ,rust-schannel-0.1) + ("rust-socket2" ,rust-socket2-0.3) + ("rust-winapi" ,rust-winapi-0.3)) + #:cargo-development-inputs + (("rust-anyhow" ,rust-anyhow-1) + ("rust-mio" ,rust-mio-0.6) + ("rust-mio-extras" ,rust-mio-extras-2)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("curl" ,curl) + ("nghttp2" ,nghttp2) + ("openssl" ,openssl) + ("zlib" ,zlib))) + (home-page "https://github.com/alexcrichton/curl-rust") + (synopsis "Rust bindings to libcurl for making HTTP requests") + (description + "This package provides Rust bindings to libcurl for making HTTP +requests") + (license license:expat))) + (define-public rust-curl-sys-0.4 (package (name "rust-curl-sys") -- cgit v1.2.3 From f7a32161ed1ba24b99f6fb5727441a342b1fbbc1 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 22:14:51 +0100 Subject: gnu: Add rust-env-logger-0.8. * gnu/packages/crates-io.scm (rust-env-logger-0.8): New variable. (rust-env-logger-0.7): Inherit from above. --- gnu/packages/crates-io.scm | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index fdd7e2dd07..54220dece1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9489,8 +9489,35 @@ accessor functions on enums.") convert enum to u8 slice ref.") (license license:bsd-3))) +(define-public rust-env-logger-0.8 + (package + (name "rust-env-logger") + (version "0.8.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "env-logger" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "07k6m6igz02g2b1v7nims7vd8azwxrav43xl14a6rjmxnikcnvpj")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-atty" ,rust-atty-0.2) + ("rust-humantime" ,rust-humantime-2) + ("rust-log" ,rust-log-0.4) + ("rust-regex" ,rust-regex-1) + ("rust-termcolor" ,rust-termcolor-1)))) + (home-page "https://github.com/sebasmagri/env_logger/") + (synopsis "Logging implementation for @code{log}") + (description + "This package provides a logging implementation for @code{log} which +is configured via an environment variable.") + (license (list license:expat license:asl2.0)))) + (define-public rust-env-logger-0.7 (package + (inherit rust-env-logger-0.8) (name "rust-env-logger") (version "0.7.1") (source @@ -9502,7 +9529,6 @@ convert enum to u8 slice ref.") (sha256 (base32 "0djx8h8xfib43g5w94r1m1mkky5spcw4wblzgnhiyg5vnfxknls4")))) - (build-system cargo-build-system) (arguments `(#:skip-build? #t #:cargo-inputs @@ -9510,13 +9536,7 @@ convert enum to u8 slice ref.") ("rust-humantime" ,rust-humantime-1) ("rust-log" ,rust-log-0.4) ("rust-regex" ,rust-regex-1) - ("rust-termcolor" ,rust-termcolor-1)))) - (home-page "https://github.com/sebasmagri/env_logger/") - (synopsis "Logging implementation for @code{log}") - (description - "This package provides a logging implementation for @code{log} which -is configured via an environment variable.") - (license (list license:expat license:asl2.0)))) + ("rust-termcolor" ,rust-termcolor-1)))))) (define-public rust-env-logger-0.6 (package -- cgit v1.2.3 From 48f6705d1c14c56d6b540ff5bc2ce6e9e60eb6c5 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 22:22:18 +0100 Subject: gnu: Add rust-indicatif-0.15. * gnu/packages/crates-io.scm (rust-indicatif-0.15): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 54220dece1..a225b17e44 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14666,6 +14666,37 @@ removals, and it allows lookup of its elements by either hash table key or numerical index. A corresponding hash set type is also provided.") (license (list license:asl2.0 license:expat)))) +(define-public rust-indicatif-0.15 + (package + (name "rust-indicatif") + (version "0.15.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "indicatif" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1r4n50mclyi4c7b9c9mlma1rhchjamw71r3z8vgqcmp24mhvbakv")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-console" ,rust-console-0.13) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-number-prefix" ,rust-number-prefix-0.3) + ("rust-rayon" ,rust-rayon-1) + ("rust-regex" ,rust-regex-1) + ("rust-unicode-segmentation" ,rust-unicode-segmentation-1.6) + ("rust-unicode-width" ,rust-unicode-width-0.1)) + #:cargo-development-inputs + (("rust-rand" ,rust-rand-0.7) + ("rust-tokio" ,rust-tokio-0.2)))) + (home-page "https://github.com/mitsuhiko/indicatif") + (synopsis "Progress bar and CLI reporting library for Rust") + (description + "This package provides a progress bar and CLI reporting library for +Rust.") + (license license:expat))) + (define-public rust-inflate-0.4 (package (name "rust-inflate") -- cgit v1.2.3 From 9b8b86b3ca8ace2d9d7ef6957252f693d5cdf911 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 22:33:28 +0100 Subject: gnu: Add rust-insta-0.12. * gnu/packages/crates-io.scm (rust-insta-0.12): New variable. --- gnu/packages/crates-io.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a225b17e44..9939ac818b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14879,6 +14879,35 @@ written in Rust.") (description "This package provides a snapshot testing library for Rust.") (license license:asl2.0))) +(define-public rust-insta-0.12 + (package + (inherit rust-insta-0.16) + (name "rust-insta") + (version "0.12.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "insta" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0j8k8rfcbdvh2s3jfj9hj7mspl32rqxqa393cw55jhg8cb09sj8d")))) + (arguments + `(#:cargo-test-flags + '("--release" + "--" + "--skip=runtime::test_format_rust_expression") + #:cargo-inputs + (("rust-console" ,rust-console-0.9) + ("rust-difference" ,rust-difference-2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-pest" ,rust-pest-2) + ("rust-pest-derive" ,rust-pest-derive-2) + ("rust-ron" ,rust-ron-0.5) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-yaml" ,rust-serde-yaml-0.8) + ("rust-uuid" ,rust-uuid-0.8)))))) + (define-public rust-insta-0.8 (package (inherit rust-insta-0.16) -- cgit v1.2.3 From 3b6e3a5ff695c61ec7ff203c7b0d3524d619532c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 22:44:31 +0100 Subject: gnu: Add rust-test-case-1. * gnu/packages/crates-io.scm (rust-test-case-1): New variable. --- gnu/packages/crates-io.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9939ac818b..a147ff5522 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -33677,6 +33677,38 @@ return values to @code{std::io::Result} to indicate success or failure.") streams.") (license license:expat))) +(define-public rust-test-case-1 + (package + (name "rust-test-case") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "test-case" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1j33njgyr4cjhil14va909sg8s6ahzpgcmiaigdg7g22ica6950r")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;XXX: a single test fails, cannot skip it + #:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1) + ("rust-version-check" ,rust-version-check-0.9)) + #:cargo-development-inputs + (("rust-insta" ,rust-insta-0.12) + ("rust-lazy-static" ,rust-lazy-static-1)))) + (home-page "https://github.com/frondeus/test-case") + (synopsis "Procedural macro attribute for parametrized test cases") + (description + "This crate provides @code{#[test_case]} procedural macro attribute that +generates multiple parametrized tests using one body with different input +parameters. A test is generated for each data set passed in test_case +attribute. Under the hood, all test cases that share same body are grouped +into mod, giving clear and readable test results.") + (license license:expat))) + (define-public rust-tester-0.5 (package (name "rust-tester") -- cgit v1.2.3 From 3477732c4f8a23a460bf655df9c88e5e72ad76d0 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 23:14:27 +0100 Subject: gnu: Add rust-tracing-serde-0.1. * gnu/packages/crates-io.scm (rust-tracing-serde-0.1): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a147ff5522..2acd28217d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36034,6 +36034,32 @@ with tracing (optional, enabled by the env-logger feature). @end itemize") (license license:expat))) +(define-public rust-tracing-serde-0.1 + (package + (name "rust-tracing-serde") + (version "0.1.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "tracing-serde" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "12xjirg0b3cparjdhkd9pksrmv33gz7rdm4gfkvgk15v3x2flrgv")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-serde" ,rust-serde-1) + ("rust-tracing-core" ,rust-tracing-core-0.1)) + #:cargo-development-inputs + (("rust-serde-json" ,rust-serde-json-1)))) + (home-page "https://tokio.rs") + (synopsis "Compatibility layer for serializing trace data with +@code{serde}") + (description + "This package provides a compatibility layer for serializing trace data +with @code{serde}.") + (license license:expat))) + (define-public rust-tracing-subscriber-0.1 (package (name "rust-tracing-subscriber") -- cgit v1.2.3 From 98cff9b3958e87e1f8700a9608ba084dfa34e511 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 23:29:01 +0100 Subject: gnu: Add rust-sharded-slab-0.1. * gnu/packages/crates-io.scm (rust-sharded-slab-0.1): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2acd28217d..08263f1f4e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30459,6 +30459,32 @@ functions core functionality.") picking compatible shaders.") (license license:expat))) +(define-public rust-sharded-slab-0.1 + (package + (name "rust-sharded-slab") + (version "0.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "sharded-slab" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "09r1i2adjkm4flsj4l0j7x79gdyxz0hvivxdh2d8j5jfj6z22jbv")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-lazy-static" ,rust-lazy-static-1) + ("rust-loom" ,rust-loom-0.3)) + #:cargo-development-inputs + (("rust-cfg-if" ,rust-cfg-if-1) + ("rust-criterion" ,rust-criterion-0.3) + ("rust-proptest" ,rust-proptest-0.9)))) + (home-page "https://github.com/hawkw/sharded-slab") + (synopsis "Lock-free concurrent slab.") + (description "This package provides a lock-free concurrent slab.") + (license license:expat))) + (define-public rust-shared-child-0.3 (package (name "rust-shared-child") -- cgit v1.2.3 From daad21142ec076fc86f6e7db7745d3dd15915a27 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 23:36:43 +0100 Subject: gnu: rust-thread-local-1: Drop minor version from name. * gnu/packages/crates-io.scm (rust-thread-local-1): Drop minor version from name. (rust-thread-local-0.3): (rust-ref-cast-1.0): (rust-pathdiff-0.1): (rust-idna-0.1): (rust-grep-printer-0.1): Apply renaming. --- gnu/packages/crates-io.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 08263f1f4e..d5c502fb85 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -13084,7 +13084,7 @@ standard printing of search results, similar to grep itself.") ("rust-log" ,rust-log-0.4) ("rust-regex" ,rust-regex-1) ("rust-regex-syntax" ,rust-regex-syntax-0.6) - ("rust-thread-local" ,rust-thread-local-1.0)))) + ("rust-thread-local" ,rust-thread-local-1)))) (home-page "https://github.com/BurntSushi/ripgrep") (synopsis "Use Rust's regex library with the grep crate") (description @@ -14614,7 +14614,7 @@ let} expressions.") ("rust-memchr" ,rust-memchr-2) ("rust-regex" ,rust-regex-1) ("rust-same-file" ,rust-same-file-1.0) - ("rust-thread-local" ,rust-thread-local-1.0) + ("rust-thread-local" ,rust-thread-local-1) ("rust-walkdir" ,rust-walkdir-2) ("rust-winapi-util" ,rust-winapi-util-0.1)) #:cargo-development-inputs @@ -22244,7 +22244,7 @@ in pure Rust.") (("rust-libc" ,rust-libc-0.2) ("rust-log" ,rust-log-0.4) ("rust-pcre2-sys" ,rust-pcre2-sys-0.2) - ("rust-thread-local" ,rust-thread-local-1.0)))) + ("rust-thread-local" ,rust-thread-local-1)))) (native-inputs `(("pcre2" ,pcre2) ("pkg-config" ,pkg-config))) @@ -26101,7 +26101,7 @@ functionality.") (("rust-aho-corasick" ,rust-aho-corasick-0.7) ("rust-memchr" ,rust-memchr-2) ("rust-regex-syntax" ,rust-regex-syntax-0.6) - ("rust-thread-local" ,rust-thread-local-1.0)) + ("rust-thread-local" ,rust-thread-local-1)) #:cargo-development-inputs (("rust-lazy-static" ,rust-lazy-static-1) ("rust-quickcheck" ,rust-quickcheck-0.8) @@ -33917,7 +33917,7 @@ different for every thread.") (("rust-kernel32-sys" ,rust-kernel32-sys-0.2) ("rust-libc" ,rust-libc-0.2)))))) -(define-public rust-thread-local-1.0 +(define-public rust-thread-local-1 (package (name "rust-thread-local") (version "1.0.1") @@ -33941,7 +33941,7 @@ different for every thread.") (define-public rust-thread-local-0.3 (package - (inherit rust-thread-local-1.0) + (inherit rust-thread-local-1) (name "rust-thread-local") (version "0.3.6") (source -- cgit v1.2.3 From 439d39f851940a7b02b41626b9baec1ed41039fd Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 21 Dec 2020 23:44:14 +0100 Subject: gnu: Add rust-tracing-subscriber-0.2. * gnu/packages/crates-io.scm (rust-tracing-subscriber-0.2): New variable. (rust-tracing-subscriber-0.1): Inherit from above. --- gnu/packages/crates-io.scm | 73 +++++++++++++++++++++++++++++++++++----------- 1 file changed, 56 insertions(+), 17 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d5c502fb85..f77c6b0f96 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36086,8 +36086,63 @@ with tracing (optional, enabled by the env-logger feature). with @code{serde}.") (license license:expat))) +(define-public rust-tracing-subscriber-0.2 + (package + (name "rust-tracing-subscriber") + (version "0.2.15") + (source + (origin + (method url-fetch) + (uri (crate-uri "tracing-subscriber" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "009lxq14kmakv16sh6r7fy0264xbvs81kg6yr57lwnaciw68zym1")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;missing test files + #:cargo-inputs + (("rust-ansi-term" ,rust-ansi-term-0.12) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-matchers" ,rust-matchers-0.0) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-regex" ,rust-regex-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-sharded-slab" ,rust-sharded-slab-0.1) + ("rust-smallvec" ,rust-smallvec-1) + ("rust-thread-local" ,rust-thread-local-1) + ("rust-tracing" ,rust-tracing-0.1) + ("rust-tracing-core" ,rust-tracing-core-0.1) + ("rust-tracing-log" ,rust-tracing-log-0.1) + ("rust-tracing-serde" ,rust-tracing-serde-0.1)) + #:cargo-development-inputs + (("rust-criterion" ,rust-criterion-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-regex" ,rust-regex-1) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tracing" ,rust-tracing-0.1) + ("rust-tracing-futures" ,rust-tracing-futures-0.2) + ("rust-tracing-log" ,rust-tracing-log-0.1)))) + (home-page "https://tokio.rs") + (synopsis "Implement and compose tracing subscribers") + (description + "This package provides utilities for implementing and composing tracing +subscribers. + +Tracing is a framework for instrumenting Rust programs to collect scoped, +structured, and async-aware diagnostics. The Subscriber trait represents the +functionality necessary to collect this trace data. This crate contains tools +for composing subscribers out of smaller units of behaviour, and +batteries-included implementations of common subscriber functionality. + +Tracing-subscriber is intended for use by both Subscriber authors and +application authors using tracing to instrument their applications.") + (license license:expat))) + (define-public rust-tracing-subscriber-0.1 (package + (inherit rust-tracing-subscriber-0.2) (name "rust-tracing-subscriber") (version "0.1.6") (source @@ -36099,7 +36154,6 @@ with @code{serde}.") (sha256 (base32 "0i9fhlyz8mn2znpgmi5bv9y24pwpkkgfxs0rwcf6dl6djmjs2b0r")))) - (build-system cargo-build-system) (arguments `(#:tests? #f ; Some test files missing. #:cargo-inputs @@ -36117,22 +36171,7 @@ with @code{serde}.") (("rust-criterion" ,rust-criterion-0.3) ("rust-log" ,rust-log-0.4) ("rust-tracing" ,rust-tracing-0.1) - ("rust-tracing-log" ,rust-tracing-log-0.1)))) - (home-page "https://tokio.rs") - (synopsis "Implement and compose tracing subscribers") - (description - "Utilities for implementing and composing tracing subscribers. - -Tracing is a framework for instrumenting Rust programs to collect -scoped, structured, and async-aware diagnostics. The Subscriber trait -represents the functionality necessary to collect this trace -data. This crate contains tools for composing subscribers out of -smaller units of behaviour, and batteries-included implementations of -common subscriber functionality. - -Tracing-subscriber is intended for use by both Subscriber authors and -application authors using tracing to instrument their applications.") - (license license:expat))) + ("rust-tracing-log" ,rust-tracing-log-0.1)))))) (define-public rust-traitobject-0.1 (package -- cgit v1.2.3 From c00874ea108d08a8c98d7a311c058936bfe73422 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 17:39:35 +0100 Subject: gnu: Add rust-isahc-0.9. * gnu/packages/crates-io.scm (rust-isahc-0.9): New variable. --- gnu/packages/crates-io.scm | 60 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f77c6b0f96..aba4aa6e20 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15117,6 +15117,66 @@ network configuration for Windows.") enum like Option/Result.") (license license:expat))) +(define-public rust-isahc-0.9 + (package + (name "rust-isahc") + (version "0.9.14") + (source + (origin + (method url-fetch) + (uri (crate-uri "isahc" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "12iqz5fj0509pr813pds2fgdk649a0b6ipvy3pqjwb1ywh68m572")))) + (build-system cargo-build-system) + (arguments + ;; Build fails with "failed to run custom build command for `curl-sys + ;; v0.4.39+curl-7.74.0`". Skip for now. + `(#:skip-build? #true + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-crossbeam-utils" ,rust-crossbeam-utils-0.8) + ("rust-curl" ,rust-curl-0.4) + ("rust-curl-sys" ,rust-curl-sys-0.4) + ("rust-encoding-rs" ,rust-encoding-rs-0.8) + ("rust-flume" ,rust-flume-0.9) + ("rust-futures-lite" ,rust-futures-lite-1) + ("rust-http" ,rust-http-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-mime" ,rust-mime-0.3) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-publicsuffix" ,rust-publicsuffix-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-slab" ,rust-slab-0.4) + ("rust-sluice" ,rust-sluice-0.5) + ("rust-tracing" ,rust-tracing-0.1) + ("rust-tracing-futures" ,rust-tracing-futures-0.2) + ("rust-url" ,rust-url-2) + ("rust-waker-fn" ,rust-waker-fn-1)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.8) + ("rust-indicatif" ,rust-indicatif-0.15) + ("rust-structopt" ,rust-structopt-0.3) + ("rust-test-case" ,rust-test-case-1) + ("rust-tracing-subscriber" ,rust-tracing-subscriber-0.2)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("curl" ,curl) + ("openssl" ,openssl) + ("zlib" ,zlib))) + (home-page "https://github.com/sagebind/isahc") + (synopsis "Practical HTTP client") + (description + "Isahc is an acronym that stands for Incredible Streaming Asynchronous +HTTP Client. It is an asynchronous HTTP client for the Rust language. It +uses libcurl as an HTTP engine inside, and provides an easy-to-use API on top +that integrates with Rust idioms.") + (license license:expat))) + (define-public rust-ipnet-2 (package (name "rust-ipnet") -- cgit v1.2.3 From 1352555d85c0ac6428f39a9f57cc5066ed4c506d Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 17:49:52 +0100 Subject: gnu: Add rust-async-native-tls-0.3. * gnu/packages/crates-io.scm (rust-async-native-tls-0.3): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index aba4aa6e20..d99b438add 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1558,6 +1558,33 @@ primitives: @end itemize") (license (list license:asl2.0 license:expat)))) +(define-public rust-async-native-tls-0.3 + (package + (name "rust-async-native-tls") + (version "0.3.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-native-tls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0cwv4vbrvcbv58b51y1azfbszzgzhrzxx92q5nl6hk6kkf97m7ly")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;XXX: build when rust-async-std-1 is packaged + #:cargo-inputs + (;;("rust-async-std" ,rust-async-std-1) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-thiserror" ,rust-thiserror-1) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-url" ,rust-url-2)) + #:cargo-development-inputs + (("rust-threadpool" ,rust-threadpool-1.7)))) + (home-page "https://docs.rs/crate/async-native-tls/") + (synopsis "Native TLS using futures") + (description "Native TLS using futures") + (license (list license:expat license:asl2.0)))) + (define-public rust-async-net-1 (package (name "rust-async-net") -- cgit v1.2.3 From 912a34cd78d928bd19769a3b15cad70e21133b76 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 17:51:21 +0100 Subject: gnu: rust-httparse-1: Update to 1.3.4. * gnu/packages/crates-io.scm (rust-httparse-1): Update to 1.3.4. [arguments]: Do not skip build. --- gnu/packages/crates-io.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d99b438add..1d6fdb50c7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14188,7 +14188,7 @@ or response body.") (define-public rust-httparse-1 (package (name "rust-httparse") - (version "1.3.3") + (version "1.3.4") (source (origin (method url-fetch) @@ -14197,11 +14197,10 @@ or response body.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "10vsfx1b8drhif08fbi0ha9d3v1f3h80w42rxh0y3hrvzl64nwz8")))) + "1yf23ldnjwfkkhkca7f4w15mky9961gjz28dlwyybhphc7l9l5yd")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t - #:cargo-development-inputs + `(#:cargo-development-inputs (("rust-pico-sys" ,rust-pico-sys-0.0)))) (home-page "https://github.com/seanmonstar/httparse") (synopsis "Zero-copy HTTP/1.x parser") -- cgit v1.2.3 From 5629259b1472eebe920a3f2251ef10efd6c01474 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 17:56:58 +0100 Subject: gnu: rust-serde-derive-1: Update to 1.0.118. * gnu/packages/crates-io.scm (rust-serde-derive-1): Update to 1.0.118. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1d6fdb50c7..30be369baa 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -29705,7 +29705,7 @@ for the serde framework.") (define-public rust-serde-derive-1 (package (name "rust-serde-derive") - (version "1.0.117") + (version "1.0.118") (source (origin (method url-fetch) @@ -29713,7 +29713,7 @@ for the serde framework.") (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "0kn7ais3zv9ajbyc216qm14r61zwlm229815yd4anjmlmmraxlfb")))) + "1pvj4v8k107ichsnm7jgm9kxyi2lf971x52bmxhm5mcwd4k3akf8")))) (build-system cargo-build-system) (arguments `(#:cargo-inputs -- cgit v1.2.3 From adb7159caaa9409fb1697ff534c9e98cebdfaf02 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 17:58:16 +0100 Subject: gnu: rust-serde-1: Update to 1.0.118. * gnu/packages/crates-io.scm (rust-serde-1): Update to 1.0.118. --- gnu/packages/crates-io.scm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 30be369baa..9f4fdd8638 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -29435,7 +29435,7 @@ rules are rather complex. This crate implements the whole grammar." ) (define-public rust-serde-1 (package (name "rust-serde") - (version "1.0.117") + (version "1.0.118") (source (origin (method url-fetch) @@ -29443,10 +29443,13 @@ rules are rather complex. This crate implements the whole grammar." ) (file-name (string-append name "-" version ".crate")) (sha256 (base32 - "06nwyyma9hch1abjqj0y9cb09m1y6lbzbsc7jff6483pvs1sk3xq")))) + "0028kv3dh3ix5g7jfws22zb9hcqq4cnpwn2lnlpam1wxhmil5ih6")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + ;; Tests fail with "error: cannot find derive macro `Deserialize` in this + ;; scope". + `(#:tests? #false + #:cargo-inputs (("rust-serde-derive" ,rust-serde-derive-1)) #:cargo-development-inputs (("rust-serde-derive" ,rust-serde-derive-1)))) -- cgit v1.2.3 From d54597fb8ea90180ef1277876d9deeb04bfba1c1 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:15:28 +0100 Subject: gnu: rust-threadpool-1: Drop minor version from name. * gnu/packages/crates-io.scm (rust-threadpool-1): Drop minor version from name. (rust-async-mutex-1): (rust-tokio-sync-0.1): Apply renaming. --- gnu/packages/crates-io.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9f4fdd8638..7ea34b80b3 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1579,7 +1579,7 @@ primitives: ("rust-tokio" ,rust-tokio-0.2) ("rust-url" ,rust-url-2)) #:cargo-development-inputs - (("rust-threadpool" ,rust-threadpool-1.7)))) + (("rust-threadpool" ,rust-threadpool-1)))) (home-page "https://docs.rs/crate/async-native-tls/") (synopsis "Native TLS using futures") (description "Native TLS using futures") @@ -34063,7 +34063,7 @@ different for every thread.") `(#:cargo-inputs (("rust-thread-id" ,rust-thread-id-2.0)))))) -(define-public rust-threadpool-1.7 +(define-public rust-threadpool-1 (package (name "rust-threadpool") (version "1.7.1") @@ -35537,7 +35537,7 @@ futures-based code.") #:cargo-development-inputs (("rust-env-logger" ,rust-env-logger-0.5) ("rust-futures-cpupool" ,rust-futures-cpupool-0.1) - ("rust-threadpool" ,rust-threadpool-1.7)))) + ("rust-threadpool" ,rust-threadpool-1)))) (home-page "https://github.com/tokio-rs/tokio") (synopsis "Task scheduler backed by a work-stealing thread pool") -- cgit v1.2.3 From b3b4448340771e2e0f6596bc3e6c46ca37b283db Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 5 Jan 2021 22:27:18 +0200 Subject: gnu: rust-indicatif-0.15: Update dependant crates. * gnu/packages/crates-io.scm (rust-indicatif-0.15)[arguments]: Replace rust-unicode-segmentation-1.6 with rust-unicode-segmentation-1. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7ea34b80b3..a166b72e10 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -14711,7 +14711,7 @@ or numerical index. A corresponding hash set type is also provided.") ("rust-number-prefix" ,rust-number-prefix-0.3) ("rust-rayon" ,rust-rayon-1) ("rust-regex" ,rust-regex-1) - ("rust-unicode-segmentation" ,rust-unicode-segmentation-1.6) + ("rust-unicode-segmentation" ,rust-unicode-segmentation-1) ("rust-unicode-width" ,rust-unicode-width-0.1)) #:cargo-development-inputs (("rust-rand" ,rust-rand-0.7) -- cgit v1.2.3 From e77f7e7a5558b156908ab75e25e3fc89f8c832fd Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 5 Jan 2021 22:28:29 +0200 Subject: gnu: rust-fuzzy-matcher-0.3: Update dependant crates. * gnu/packages/crates-io.scm (rust-fuzzy-matcher-0.3)[arguments]: Replace rust-thread-local-1.0 with rust-thread-local-1. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a166b72e10..04f0ba4574 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -12038,7 +12038,7 @@ futures-rs library.") (build-system cargo-build-system) (arguments `(#:cargo-inputs - (("rust-thread-local" ,rust-thread-local-1.0)) + (("rust-thread-local" ,rust-thread-local-1)) #:cargo-development-inputs (("rust-termion" ,rust-termion-1.5)))) (home-page "https://github.com/lotabout/fuzzy-matcher") -- cgit v1.2.3 From 08b12d0e5c0a000108712cc19e3d5e6242d7a086 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 5 Jan 2021 22:43:24 +0200 Subject: gnu: nomacs: Satisfy guix lint. * gnu/packages/image-viewers.scm (nomacs)[source]: Add file-name field. [inputs]: Move qttools ... [native-inputs]: ... to here. --- gnu/packages/image-viewers.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/image-viewers.scm b/gnu/packages/image-viewers.scm index d9ee795b0f..0dae0a39f3 100644 --- a/gnu/packages/image-viewers.scm +++ b/gnu/packages/image-viewers.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2013, 2017, 2018, 2019, 2020 Ludovic Courtès ;;; Copyright © 2014 Ian Denhardt ;;; Copyright © 2015, 2016 Alex Kost -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2017 Alex Griffin ;;; Copyright © 2017 Nikita ;;; Copyright © 2017 Mathieu Othacehe @@ -695,6 +695,7 @@ to set X desktop background.") (uri (git-reference (url "https://github.com/nomacs/nomacs") (commit version))) + (file-name (git-file-name name version)) (sha256 (base32 "05d4hqg0gl3g9s2xf1hr7mc7g4cqarcap4nzxxa51fsphw2b8x16")))) @@ -730,10 +731,10 @@ to set X desktop background.") ("python" ,python-wrapper) ("quazip" ,quazip) ("qtbase" ,qtbase) - ("qtsvg" ,qtsvg) - ("qtlinguist" ,qttools))) + ("qtsvg" ,qtsvg))) (native-inputs - `(("pkg-config" ,pkg-config))) + `(("pkg-config" ,pkg-config) + ("qtlinguist" ,qttools))) (synopsis "Image viewer supporting all common formats") (description "Nomacs is a simple to use image lounge featuring semi-transparent widgets that display additional information such as metadata, -- cgit v1.2.3 From cf3ca5a7c848d6cce7541cb24a630be952b1397c Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Tue, 29 Dec 2020 10:43:12 +0100 Subject: gnu: xfce4-taskmanager: Update to 1.4.0. * gnu/packages/xfce.scm (xfce4-taskmanager): Update to 1.4.0. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 3b0ff54308..271e67094f 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1073,7 +1073,7 @@ the desktop wallpaper.") (define-public xfce4-taskmanager (package (name "xfce4-taskmanager") - (version "1.2.3") + (version "1.4.0") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/apps/" @@ -1081,7 +1081,7 @@ the desktop wallpaper.") "xfce4-taskmanager-" version ".tar.bz2")) (sha256 (base32 - "1i63bnvpjpblnd0d3l1v065x9q1cz74cvlab5hzd0q8zgkd49z6w")))) + "0hvx7qqkiyq81axcbkqfv39bn84x8gjzrybq3w3hkz0mzkfq8mk5")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From bd674829f23ea9759dc78b1cb43565fccb25abdd Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Mon, 28 Dec 2020 09:58:16 +0100 Subject: gnu: xfce4-cpugraph-plugin: Update to 1.2.0. * gnu/packages/xfce.scm (xfce4-cpugraph-plugin): Update to 1.2.0. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 271e67094f..c3a7aaa467 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1361,7 +1361,7 @@ A plugin for the Xfce panel is also available.") (define-public xfce4-cpugraph-plugin (package (name "xfce4-cpugraph-plugin") - (version "1.1.0") + (version "1.2.0") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1370,7 +1370,7 @@ A plugin for the Xfce panel is also available.") "/xfce4-cpugraph-plugin-" version ".tar.bz2")) (sha256 (base32 - "193bj1p54l4zrvgdjj0pvjn161d6dn82jh9invcy09sqwlj0mkiy")))) + "19rdc3k085z7bv8365g26vz6iy9dx2f4x4q3wszsjmq5pvdxsrkq")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From d33b7a2f1b7eb8ab55b2b1d45fe38e7b25794609 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Mon, 28 Dec 2020 10:10:15 +0100 Subject: gnu: xfce4-verve-plugin: Update to 2.0.1. * gnu/packages/xfce.scm (xfce4-verve-plugin): Update to 2.0.1. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index c3a7aaa467..c4f53dbb39 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -2034,7 +2034,7 @@ period.") (define-public xfce4-verve-plugin (package (name "xfce4-verve-plugin") - (version "2.0.0") + (version "2.0.1") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -2043,7 +2043,7 @@ period.") "/xfce4-verve-plugin-" version ".tar.bz2")) (sha256 (base32 - "1ljcmgc8ixrbz134ggxbbh4zzdnp7mhi9ay6s5hgrz28djx10rcy")))) + "09gqp0jb5ccjh7ny798n5cy9skdx3hpis4kgvjpl4vidnrg5xnpb")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 4246deaaeb6e83eeafb6cea0d2367554a49ab567 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Mon, 28 Dec 2020 10:06:05 +0100 Subject: gnu: xfce4-fsguard-plugin: Update to 1.1.2. * gnu/packages/xfce.scm (xfce4-fsguard-plugin): Update to 1.1.2. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index c4f53dbb39..215266db64 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1594,7 +1594,7 @@ this very convenient.") (define-public xfce4-fsguard-plugin (package (name "xfce4-fsguard-plugin") - (version "1.1.1") + (version "1.1.2") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1603,7 +1603,7 @@ this very convenient.") "/xfce4-fsguard-plugin-" version ".tar.bz2")) (sha256 (base32 - "05nmfkrmifm76bsywqmbjd1qdvzagv5cbvnwbkb57156j055vl6n")))) + "01a1an5z4kpgi68lk98q7wga7sx676fcbnrsd5cpq4d736ifdn37")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From f42c6bbb8e279045dbd358b25fc1d53cb1dfeeed Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 5 Jan 2021 23:16:24 +0100 Subject: gnu: emacs-vterm: Fix version. * gnu/packages/emacs-xyz.scm (emacs-vterm): Use proper version, from upstream. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index c5430fdc23..034d13b6a8 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -20754,8 +20754,8 @@ stored playlists.") (license license:gpl3+))) (define-public emacs-vterm - (let ((version "0") - (revision "4") + (let ((version "0.0.1") + (revision "0") (commit "a670b786539d3c8865d8f68fe0c67a2d4afbf1aa")) (package (name "emacs-vterm") -- cgit v1.2.3 From cf289d7cfa34315bf13b3114b9a5bf3d3c05ebea Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 5 Jan 2021 11:14:51 +0100 Subject: Discover extensions via GUIX_EXTENSIONS_PATH. * guix/scripts.scm (%command-categories): Add extension category. * guix/ui.scm (source-file-command): Also parse extensions files. (command-files): Accept an optional directory argument. (extension-directories): New procedure. (commands): Use it. (show-guix-help): Hide empty categories. (run-guix-command): Try loading an extension if there is no matching Guix command. --- guix/scripts.scm | 4 +++- guix/ui.scm | 65 +++++++++++++++++++++++++++++++++++++++----------------- 2 files changed, 49 insertions(+), 20 deletions(-) diff --git a/guix/scripts.scm b/guix/scripts.scm index 9792aaebe9..34cba35401 100644 --- a/guix/scripts.scm +++ b/guix/scripts.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2014 Deck Pickard ;;; Copyright © 2015, 2016 Alex Kost ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen +;;; Copyright © 2021 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -86,7 +87,8 @@ (development (G_ "software development commands")) (packaging (G_ "packaging commands")) (plumbing (G_ "plumbing commands")) - (internal (G_ "internal commands"))) + (internal (G_ "internal commands")) + (extension (G_ "extension commands"))) (define-syntax define-command (syntax-rules (category synopsis) diff --git a/guix/ui.scm b/guix/ui.scm index 0a1c9bd615..7f52518023 100644 --- a/guix/ui.scm +++ b/guix/ui.scm @@ -2021,10 +2021,11 @@ optionally contain a version number and an output name, as in these examples: on the 'define-command' top-level form found therein, or #f if FILE does not contain a 'define-command' form." (define command-name - (match (string-split file #\/) - ((_ ... "guix" "scripts" name) + (match (filter (negate string-null?) + (string-split file #\/)) + ((_ ... "guix" (or "scripts" "extensions") name) (list (file-sans-extension name))) - ((_ ... "guix" "scripts" first second) + ((_ ... "guix" (or "scripts" "extensions") first second) (list first (file-sans-extension second))))) ;; The strategy here is to parse FILE. This is much cheaper than a @@ -2046,24 +2047,34 @@ contain a 'define-command' form." (_ (loop))))))) -(define (command-files) +(define* (command-files #:optional directory) "Return the list of source files that define Guix sub-commands." - (define directory - (and=> (search-path %load-path "guix.scm") - (compose (cut string-append <> "/guix/scripts") - dirname))) + (define directory* + (or directory + (and=> (search-path %load-path "guix.scm") + (compose (cut string-append <> "/guix/scripts") + dirname)))) (define dot-scm? (cut string-suffix? ".scm" <>)) - (if directory - (map (cut string-append directory "/" <>) - (scandir directory dot-scm?)) + (if directory* + (map (cut string-append directory* "/" <>) + (scandir directory* dot-scm?)) '())) +(define (extension-directories) + "Return the list of directories containing Guix extensions." + (filter file-exists? + (parse-path + (getenv "GUIX_EXTENSIONS_PATH")))) + (define (commands) "Return the list of commands, alphabetically sorted." - (filter-map source-file-command (command-files))) + (filter-map source-file-command + (append (command-files) + (append-map command-files + (extension-directories))))) (define (show-guix-help) (define (internal? command) @@ -2098,9 +2109,14 @@ Run COMMAND with ARGS.\n")) (('internal . _) #t) ;hide internal commands ((category . synopsis) - (format #t "~% ~a~%" (G_ synopsis)) - (display-commands (filter (category-predicate category) - commands)))) + (let ((relevant-commands (filter (category-predicate category) + commands))) + ;; Only print categories that contain commands. + (match relevant-commands + ((one . more) + (format #t "~% ~a~%" (G_ synopsis)) + (display-commands relevant-commands)) + (_ #f))))) categories)) (show-bug-report-information)) @@ -2111,10 +2127,21 @@ found." (catch 'misc-error (lambda () (resolve-interface `(guix scripts ,command))) - (lambda - - (format (current-error-port) - (G_ "guix: ~a: command not found~%") command) - (show-guix-usage)))) + (lambda _ + ;; Check if there is a matching extension. + (catch 'misc-error + (lambda () + (match (search-path (extension-directories) + (format #f "~a.scm" command)) + (file + (load file) + (resolve-interface `(guix extensions ,command))) + (_ + (throw 'misc-error)))) + (lambda _ + (format (current-error-port) + (G_ "guix: ~a: command not found~%") command) + (show-guix-usage)))))) (let ((command-main (module-ref module (symbol-append 'guix- command)))) -- cgit v1.2.3 From 0e8ff57d148efa304f6be3c7ea590f58c6a7d02e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 00:33:38 +0100 Subject: gnu: emacs-csv-mode: Update to 1.14. * gnu/packages/emacs-xyz.scm (emacs-csv-mode): Update to 1.14. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 034d13b6a8..b26bd0c550 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -13703,14 +13703,14 @@ let users kill or mark things easily.") (define-public emacs-csv-mode (package (name "emacs-csv-mode") - (version "1.12") + (version "1.14") (source (origin (method url-fetch) (uri (string-append "https://elpa.gnu.org/packages/" "csv-mode-" version ".tar")) (sha256 - (base32 "0bya12smlrzwv4cbcmch4kg1fazp4k0ndrh1z17ix9p8c14d0v1j")))) + (base32 "1jz4134pk8dwzsqih9wybx4l9yl244cgcilw8rdnnqmm8i6vxgrp")))) (build-system emacs-build-system) (home-page "https://elpa.gnu.org/packages/csv-mode.html") (synopsis "Major mode for editing comma/char separated values") -- cgit v1.2.3 From e5f0ff0c906d6e9329019121e5ad4bf017b9b207 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Sun, 27 Dec 2020 18:46:20 +0100 Subject: gnu: xfce4-diskperf-plugin: Update to 2.6.3. * gnu/packages/xfce.scm (xfce4-diskperf-plugin): Update to 2.6.3. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 215266db64..fa8dc43633 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1532,7 +1532,7 @@ governor and frequencies supported and used by your system.") (define-public xfce4-diskperf-plugin (package (name "xfce4-diskperf-plugin") - (version "2.6.2") + (version "2.6.3") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1541,7 +1541,7 @@ governor and frequencies supported and used by your system.") "/xfce4-diskperf-plugin-" version ".tar.bz2")) (sha256 (base32 - "0i4nrsvwcn15g5gmnba9p07sad3c96x517l2lybdw8jqv91rhbpx")))) + "0n8wsnjvzw98z8r0f0zr8n2gicjz6hhislp86xrjh0r4xcnymcbk")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 0cb029a7cf877d554414e6e4cab506227e284c32 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Sun, 27 Dec 2020 18:46:22 +0100 Subject: gnu: xfce4-mailwatch-plugin: Update to 1.3.0. * gnu/packages/xfce.scm (xfce4-mailwatch-plugin): Update to 1.3.0. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index fa8dc43633..8cae63a9b3 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1683,7 +1683,7 @@ Caps, Scroll and Num Lock in Xfce panel.") (define-public xfce4-mailwatch-plugin (package (name "xfce4-mailwatch-plugin") - (version "1.2.0") + (version "1.3.0") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1692,7 +1692,7 @@ Caps, Scroll and Num Lock in Xfce panel.") "/xfce4-mailwatch-plugin-" version ".tar.bz2")) (sha256 (base32 - "1bfw3smwivr9mzdyq768biqrl4aq94zqi3xjzq6kqnd8561cqjk2")))) + "0bmykjhd3gs1737fl3zn5gg6f3vlncak2xqz89zv5018znz1xy90")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From d636094bd0c512c00b4f3c721871fb900839d2ad Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Sun, 27 Dec 2020 18:46:21 +0100 Subject: gnu: xfce4-mount-plugin: Update to 1.1.5. * gnu/packages/xfce.scm (xfce4-mount-plugin): Update to 1.1.5. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 8cae63a9b3..f3686b255a 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1764,7 +1764,7 @@ right-click menu (define-public xfce4-mount-plugin (package (name "xfce4-mount-plugin") - (version "1.1.3") + (version "1.1.5") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1773,7 +1773,7 @@ right-click menu "/xfce4-mount-plugin-" version ".tar.bz2")) (sha256 (base32 - "07lijjhimjrcyrhasr2299km6wm22xcd3fazdfpqvisbk1mvvrda")))) + "1hlfnlxwwx0hkm82mcz777f3i22x6bh6k3gzl0yjnm4yj9adjk2q")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 47172ca832fd0c87ca349ad6112df7c292d333a8 Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Sun, 27 Dec 2020 18:46:24 +0100 Subject: gnu: xfce4-systemload-plugin: Update to 1.2.4. * gnu/packages/xfce.scm (xfce4-systemload-plugin): Update to 1.2.4. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index f3686b255a..8ec2bbc4cf 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1948,7 +1948,7 @@ freedesktop.org specification.") (define-public xfce4-systemload-plugin (package (name "xfce4-systemload-plugin") - (version "1.2.3") + (version "1.2.4") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1957,7 +1957,7 @@ freedesktop.org specification.") "/xfce4-systemload-plugin-" version ".tar.bz2")) (sha256 (base32 - "0x87a8h5l3ashz1ksfaxcpn9a392jzlsbx5n5pga8g90fp2hf905")))) + "0dcqg13phlcri4i4g9752m4zfkcmidiqpjv4s3l3pfiwjbgvhc85")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 218ce8b9acd24f05456d337331e108ba8089709a Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Fri, 25 Dec 2020 11:07:43 +0100 Subject: gnu: xfce4-xkb-plugin: Update to 0.8.2. * gnu/packages/xfce.scm (xfce4-xkb-plugin): Update to 0.8.2. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 8ec2bbc4cf..e9c309c8c9 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -621,7 +621,7 @@ applications, and includes a search bar to search for applications.") (define-public xfce4-xkb-plugin (package (name "xfce4-xkb-plugin") - (version "0.8.1") + (version "0.8.2") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -629,7 +629,7 @@ applications, and includes a search bar to search for applications.") name "-" version ".tar.bz2")) (sha256 (base32 - "18b7cnaf3zxm598p2i47vim3kbbi8w923ia1hwabdph1c89cz7n1")))) + "0rvrz464y7ji989zvi2v85kg47444nqsdq9rv6k8dkbkdwzy2jxv")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 3ad2f7362a429a15f8af6a55e76e81747cc1f660 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Fri, 25 Dec 2020 11:11:41 +0100 Subject: gnu: xfce4-smartbookmark-plugin: Update to 0.5.2. * gnu/packages/xfce.scm (xfce4-smartbookmark-plugin): Update to 0.5.2. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index e9c309c8c9..9dda5dd229 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1862,7 +1862,7 @@ opens up a menu with the following: (define-public xfce4-smartbookmark-plugin (package (name "xfce4-smartbookmark-plugin") - (version "0.5.1") + (version "0.5.2") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1871,7 +1871,7 @@ opens up a menu with the following: "/xfce4-smartbookmark-plugin-" version ".tar.bz2")) (sha256 (base32 - "001nf2bqly8vm868qvafzgihc9463c488mkim24iw9g2s9ygna1y")))) + "1lyd64qc9w6qnpqjb5xk0mjq4l7riv6z7l9aws28clalb8prw9ra")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From a0e31f39f8e0cefc442d21235a2765ed31cdcc10 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Fri, 25 Dec 2020 11:15:13 +0100 Subject: gnu: xfce4-wavelan-plugin: Update to 0.6.2. * gnu/packages/xfce.scm (xfce4-wavelan-plugin): Update to 0.6.2. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 9dda5dd229..8f773bb51a 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -2068,7 +2068,7 @@ for the Xfce panel. It supports several features, such as: (define-public xfce4-wavelan-plugin (package (name "xfce4-wavelan-plugin") - (version "0.6.1") + (version "0.6.2") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -2077,7 +2077,7 @@ for the Xfce panel. It supports several features, such as: "/xfce4-wavelan-plugin-" version ".tar.bz2")) (sha256 (base32 - "05zdiq1igr1fcvnwlivg8g3szvxmlr3yc7jfj3bwgqrs0vm827zl")))) + "07a8nmc60in48licjj0gmwm77vb8divh1lb7jnib35n5a1ka6ypa")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 074baedc4916636baca6a50fd469fdaf3ea51731 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Fri, 25 Dec 2020 11:18:10 +0100 Subject: gnu: xfce4-datetime-plugin: Update to 0.8.1. * gnu/packages/xfce.scm (xfce4-datetime-plugin): Update to 0.8.1. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 8f773bb51a..99ac32e653 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1450,7 +1450,7 @@ each time a new earthquake occurs.") (define-public xfce4-datetime-plugin (package (name "xfce4-datetime-plugin") - (version "0.8.0") + (version "0.8.1") (source (origin (method url-fetch) (uri (string-append "https://archive.xfce.org/src/panel-plugins/" @@ -1459,7 +1459,7 @@ each time a new earthquake occurs.") "/xfce4-datetime-plugin-" version ".tar.bz2")) (sha256 (base32 - "1m7bmpvbmiz2xdffpg675qn80zx2n0cnlf842ppvh1q7zz18ndfd")))) + "0h15mxq5lawlxyr6h1vxc60rkf0rpmnv81l0f52mrswww9dz3xp9")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) -- cgit v1.2.3 From 12903a57dc83bf12e7171e186e9e95b0e7febce7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Tue, 5 Jan 2021 20:29:19 +0100 Subject: gnu: lilv: Update to 0.24.10. * gnu/packages/audio.scm (lilv): Update to 0.24.10. --- gnu/packages/audio.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index cf68ddf0d8..a4f5170a92 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -2343,14 +2343,14 @@ included are the command line utilities @code{send_osc} and @code{dump_osc}.") (define-public lilv (package (name "lilv") - (version "0.24.8") + (version "0.24.10") (source (origin (method url-fetch) (uri (string-append "https://download.drobilla.net/lilv-" version ".tar.bz2")) (sha256 (base32 - "0063i5zgf3d3accwmyx651hw0wh5ik7kji2hvfkcdbl1qia3dp6a")))) + "1565zy0yz46cf2f25pi46msdnzkj6bbhml9gfigdpjnsdlyskfyi")))) (build-system waf-build-system) (arguments `(#:tests? #f ; no check target -- cgit v1.2.3 From 853665ffff52816921f7f014c27854d1dd81fdd0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Tue, 5 Jan 2021 20:51:31 +0100 Subject: gnu: ispell: Update to 3.4.01. * gnu/packages/aspell.scm (ispell): Update to 3.4.01. --- gnu/packages/aspell.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/aspell.scm b/gnu/packages/aspell.scm index 7a6d20116f..76089333ce 100644 --- a/gnu/packages/aspell.scm +++ b/gnu/packages/aspell.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2016, 2017, 2019, 2020 Efraim Flashner ;;; Copyright © 2016 Christopher Andersson ;;; Copyright © 2016 Theodoros Foradis -;;; Copyright © 2016, 2017, 2019 Tobias Geerinckx-Rice +;;; Copyright © 2016, 2017, 2019, 2021 Tobias Geerinckx-Rice ;;; Copyright © 2019 Jens Mølgaard ;;; Copyright © 2020 Timotej Lazar ;;; Copyright © 2020 Marcin Karpezo @@ -476,15 +476,14 @@ under permissive licensing terms. See the 'Copyright' file.")))) (define-public ispell (package (name "ispell") - (version "3.4.00") + (version "3.4.01") (source (origin (method url-fetch) (uri (string-append "https://www.cs.hmc.edu/~geoff/tars/ispell-" version ".tar.gz")) (sha256 - (base32 - "1hmfnz55qzfpz7lz0r3m4kkv31smir92ks9s5l1iiwimhr2jxi2x")))) + (base32 "103vscg4bc7x2q84y18x1l75k54yhkw8lpza3qh8xxhcz5b0w7jb")))) (build-system gnu-build-system) (arguments `(#:parallel-build? #f -- cgit v1.2.3 From 0eacdd462e58845f48f1ff62d35a021ded8ab497 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Tue, 5 Jan 2021 20:58:04 +0100 Subject: gnu: lziprecover: Update to 1.22. * gnu/packages/compression.scm (lziprecover): Update to 1.22. --- gnu/packages/compression.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm index d7b821228a..7294a2eda6 100644 --- a/gnu/packages/compression.scm +++ b/gnu/packages/compression.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2016 Ben Woodcroft ;;; Copyright © 2016 Danny Milosavljevic -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016 David Craven ;;; Copyright © 2016, 2019, 2020 Kei Kebreau ;;; Copyright © 2016, 2018, 2019, 2020 Marius Bakke @@ -621,14 +621,14 @@ archiving. Lzip is a clean implementation of the LZMA algorithm.") (define-public lziprecover (package (name "lziprecover") - (version "1.21") + (version "1.22") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/lzip/lziprecover/" "lziprecover-" version ".tar.gz")) (sha256 (base32 - "094w2z8fz41yaq0gkyr61cl7pb1d7kchpl5dka7rvm3qvbb7ncd2")))) + "0qh8dnhr5rly2k9dnx43qqynqwqzi5kfb15pyd29qwppfl4qm5gx")))) (build-system gnu-build-system) (home-page "https://www.nongnu.org/lzip/lziprecover.html") (synopsis "Recover and decompress data from damaged lzip files") -- cgit v1.2.3 From c23541112d09d7bdf8b6dc5fed6717560249fad0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 00:39:48 +0100 Subject: gnu: Add jitterentropy-rngd. * gnu/packages/linux.scm (jitterentropy-rngd): New public variable. --- gnu/packages/linux.scm | 49 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index a8bb9db172..71f21aa687 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer ;;; Copyright © 2015, 2016, 2017, 2018, 2020 Efraim Flashner ;;; Copyright © 2016 Christopher Allan Webber -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016, 2017 Alex Kost ;;; Copyright © 2016 Raymond Nicholson ;;; Copyright © 2016 Mathieu Lirzin @@ -2245,6 +2245,53 @@ IPv6 packet filter. Both commands are targeted at system administrators.") (license license:gpl2+))) +(define-public jitterentropy-rngd + (package + (name "jitterentropy-rngd") + (version "1.2.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/smuellerDD/jitterentropy-rngd") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1fb8zfwhwkl1d8n4cdn7rdv5rwd75qgc00d36pmkl7wgnj3c9xda")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no test suite + #:make-flags + (list (string-append "CC=" ,(cc-for-target)) + (string-append "PREFIX=" (assoc-ref %outputs "out")) + "UNITDIR=$(PREFIX)/lib/systemd/system") + #:phases + (modify-phases %standard-phases + (delete 'configure)))) ; no ./configure script + (home-page "https://www.chronox.de/jent.html") + (synopsis "CPU jitter random number generator daemon") + (description + "This simple daemon feeds entropy from the CPU Jitter @acronym{RNG, random +number generator} core to the kernel Linux's entropy estimator. This prevents +the @file{/dev/random} device from blocking and should benefit users of the +preferred @file{/dev/urandom} and @code{getrandom()} interfaces too. + +The CPU Jitter RNG itself is part of the kernel and claims to provide good +entropy by collecting and magnifying differences in CPU execution time as +measured by the high-resolution timer built into modern CPUs. It requires no +additional hardware or external entropy source. + +The random bit stream generated by @command{jitterentropy-rngd} is not processed +by a cryptographically secure whitening function. Nonetheless, its authors +believe it to be a suitable source of cryptographically secure key material or +other cryptographically sensitive data. + +If you agree with them, start this daemon as early as possible to provide +properly seeded random numbers to services like SSH or those using TLS during +early boot when entropy may be low, especially in virtualised environments.") + (license (list license:bsd-3 ; or + license:gpl2+)))) + (define-public lsscsi (package (name "lsscsi") -- cgit v1.2.3 From e1e42eacf82d62a49b3da634c0b8dd9b8e962a3d Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Sun, 3 Jan 2021 17:32:31 +0100 Subject: gnu: xfce4-whiskermenu-plugin: Update to 2.5.1. * gnu/packages/xfce.scm (xfce4-whiskermenu-plugin): Update to 2.5.1. Signed-off-by: Kei Kebreau --- gnu/packages/xfce.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index 99ac32e653..2192f61dc7 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -577,7 +577,7 @@ keys for controlling the audio volume.") (define-public xfce4-whiskermenu-plugin (package (name "xfce4-whiskermenu-plugin") - (version "2.4.6") + (version "2.5.1") (source (origin (method url-fetch) @@ -585,7 +585,7 @@ keys for controlling the audio volume.") "xfce4-whiskermenu-plugin/" (version-major+minor version) "/" "xfce4-whiskermenu-plugin-" version ".tar.bz2")) (sha256 - (base32 "0i2pn8852x6zvlys4610knscscyjpha6wjzy7rljixbxr26d6x49")))) + (base32 "09b9i68pf5ghq6dj55s4h3fj07jd5zpn1fghjwnnwxmakj54y1xj")))) (build-system cmake-build-system) (native-inputs `(("pkg-config" ,pkg-config) -- cgit v1.2.3 From acc87fae1307ee1f516783f024c7f362784daa39 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 02:14:42 +0100 Subject: gnu: Add turbostat. * gnu/packages/linux.scm (turbostat): New public variable. --- gnu/packages/linux.scm | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 71f21aa687..e69aeee28e 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -5364,6 +5364,45 @@ be installed and loaded separately. Only the original vendor firmware is supported.") (license license:gpl3+))) +(define-public turbostat + (package + (name "turbostat") + ;; XXX turbostat reports a version like ‘20.09.30’ but using it here would + ;; make it harder to benefit from ‘free’ linux-libre package updates. + (version (package-version linux-libre)) + (source (package-source linux-libre)) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no test suite + #:make-flags + (list (string-append "CC=" ,(cc-for-target)) + (string-append "PREFIX=" (assoc-ref %outputs "out"))) + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'enter-subdirectory + (lambda _ + (chdir "tools/power/x86/turbostat") + #t)) + (delete 'configure)))) ; no configure script + (inputs + `(("libcap" ,libcap))) + (supported-systems '("i686-linux" "x86_64-linux")) + (home-page (package-home-page linux-libre)) + (synopsis "Report x86 processor frequency and idle statistics") + (description + "Turbostat reports x86 processor topology, frequency, idle power state +statistics, temperature, and power consumption. Some information is unavailable +on older processors. + +It can be used to identify machines that are inefficient in terms of power usage +or idle time, report the rate of @acronym{SMI, system management interrupt}s +occurring on the system, or verify the effects of power management tuning. + +@command{turbostat} reads hardware counters but doesn't write to them, so it +won't interfere with the OS or other running processes---including multiple +invocations of itself.") + (license license:gpl2))) + (define-public ntfs-3g (package (name "ntfs-3g") -- cgit v1.2.3 From c8118181f3e6aeb156b13c75e7b9bfce530742b7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 02:53:12 +0100 Subject: gnu: Add tmon. * gnu/packages/linux.scm (tmon): New public variable. --- gnu/packages/linux.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index e69aeee28e..4b2adeabed 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -5364,6 +5364,52 @@ be installed and loaded separately. Only the original vendor firmware is supported.") (license license:gpl3+))) +(define-public tmon + (package + (name "tmon") + ;; Tmon's ‘VERSION = 1.0’ hasn't been touched since 2013; the code has. + (version (package-version linux-libre)) + (source (package-source linux-libre)) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no test suite + #:make-flags + (list (string-append "CC=" ,(cc-for-target)) + (string-append "INSTALL_ROOT=" (assoc-ref %outputs "out")) + "BINDIR=bin") + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'enter-subdirectory + (lambda _ + (chdir "tools/thermal/tmon") + #t)) + (add-after 'install 'install-man-page + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (man8 (string-append out "/share/man/man8"))) + (install-file "tmon.8" man8) + #t))) + (delete 'configure)))) ; no configure script + (inputs + `(("ncurses" ,ncurses))) + (home-page (package-home-page linux-libre)) + (synopsis "Monitor and test the Linux thermal subsystem in real time") + (description + "Tmon is a tool to interact with the complex thermal subsystem of the +kernel Linux. It helps visualize thermal relationships and real-time thermal +data, tune and test cooling devices and sensors, and collect thermal data for +further analysis. + +As computers become smaller and more thermally constrained, more sensors are +added and new cooling capabilities introduced. Thermal relationships can change +dynamically. Their complexity grows exponentially among cooling devices, zones, +sensors, and trip points. + +Linux exposes this relationship through @file{/sys/class/thermal} with a matrix +of symbolic links, trip point bindings, and device instances. To traverse it +by hand is no trivial task: @command{tmon} aims to make it understandable.") + (license license:gpl2))) + (define-public turbostat (package (name "turbostat") -- cgit v1.2.3 From 1bb235ce00ffb92b9173621f6496387249a92260 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 02:59:26 +0100 Subject: gnu: tmon: Clarify licence. * gnu/packages/linux.scm (tmon)[license]: Comment that only the man page is GPL-2-only. --- gnu/packages/linux.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 4b2adeabed..bc405e3bf2 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -5408,7 +5408,8 @@ sensors, and trip points. Linux exposes this relationship through @file{/sys/class/thermal} with a matrix of symbolic links, trip point bindings, and device instances. To traverse it by hand is no trivial task: @command{tmon} aims to make it understandable.") - (license license:gpl2))) + (license (list license:gpl2+ ; the man page + license:gpl2)))) ; the actual rest (define-public turbostat (package -- cgit v1.2.3 From 4a9103df92f15f1da020b51e1b9cb4f079bdb4d0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 03:30:30 +0100 Subject: gnu: eid-mw: Update to 5.0.11. * gnu/packages/security-token.scm (eid-mw): Update to 5.0.11. --- gnu/packages/security-token.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 7d822f491f..9ae375d3ef 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2016 Mike Gerwitz ;;; Copyright © 2016 Marius Bakke ;;; Copyright © 2017 Thomas Danckaert -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2019 Ricardo Wurmus ;;; Copyright © 2018, 2019 Chris Marusich ;;; Copyright © 2018 Arun Isaac @@ -104,7 +104,7 @@ readers and is needed to communicate with such devices through the (define-public eid-mw (package (name "eid-mw") - (version "5.0.8") + (version "5.0.11") (source (origin (method git-fetch) @@ -113,7 +113,7 @@ readers and is needed to communicate with such devices through the (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1ckini00iz9w96n9hpkx6w2ivpfkd4yyxyhnmsl9n0k8x4j6jg5a")))) + (base32 "0590cz00cny749p99srv880gpgzvxaf9fwm2lghv3nw0qdsilss8")))) (build-system glib-or-gtk-build-system) (native-inputs `(("autoconf" ,autoconf) -- cgit v1.2.3 From c3350b9b91e8ef2548a76ec96f2f405e461839ff Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 03:34:54 +0100 Subject: gnu: eid-mw: Omit static libraries. * gnu/packages/security-token.scm (eid-mw)[arguments]: Add "--disable-static" to #:configure-flags. --- gnu/packages/security-token.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 9ae375d3ef..50e6a502ca 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm @@ -134,7 +134,9 @@ readers and is needed to communicate with such devices through the ("libxml2" ,libxml2) ("cyrus-sasl" ,cyrus-sasl))) (arguments - `(#:phases + `(#:configure-flags + (list "--disable-static") + #:phases (modify-phases %standard-phases (replace 'bootstrap (lambda _ -- cgit v1.2.3 From 333b9c815b3b291a0a3cc95560ff02a3c9a7e4c8 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 03:36:11 +0100 Subject: gnu: tmon: Clarify some more. * gnu/packages/linux.scm (tmon)[license]: Right wrong. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index bc405e3bf2..b5df847a53 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -5408,8 +5408,8 @@ sensors, and trip points. Linux exposes this relationship through @file{/sys/class/thermal} with a matrix of symbolic links, trip point bindings, and device instances. To traverse it by hand is no trivial task: @command{tmon} aims to make it understandable.") - (license (list license:gpl2+ ; the man page - license:gpl2)))) ; the actual rest + (license (list license:gpl2 ; the man page + license:gpl2+)))) ; the actual rest (define-public turbostat (package -- cgit v1.2.3 From 6ef7726805fe9ce6ede886a0a2ce59a35d547d9a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Wed, 6 Jan 2021 03:42:18 +0100 Subject: gnu: rcm: Update to 1.3.4. * gnu/packages/rcm.scm (rcm): Update to 1.3.4. --- gnu/packages/rcm.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/rcm.scm b/gnu/packages/rcm.scm index c61626d114..f8c7ba4200 100644 --- a/gnu/packages/rcm.scm +++ b/gnu/packages/rcm.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Josh Holland +;;; Copyright © 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -27,13 +28,13 @@ (define-public rcm (package (name "rcm") - (version "1.3.3") + (version "1.3.4") (source (origin (method url-fetch) (uri (string-append "https://thoughtbot.github.io/rcm/dist/rcm-" version ".tar.gz")) (sha256 - (base32 "1bqk7rrp1ckzvsvl9wghsr77m8xl3a7yc5gqdsisz492dx2j8mck")))) + (base32 "0jn2crdqcna0fyg7w7x1mcyjblzykd3lh4vdxhsd5x4w8hvsw4cv")))) (build-system gnu-build-system) (arguments '(#:phases (modify-phases %standard-phases -- cgit v1.2.3 From 6b64bba8d9a1bc4d14c4bd9cfd0cd450225bc5f1 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:01:09 +0200 Subject: gnu: moe: Update to 1.11. * gnu/packages/moe.scm (moe): Update to 1.11. --- gnu/packages/moe.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/moe.scm b/gnu/packages/moe.scm index 23df938ae7..6d16d1a7cc 100644 --- a/gnu/packages/moe.scm +++ b/gnu/packages/moe.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014, 2015, 2017 Eric Bavier -;;; Copyright © 2016, 2019 Efraim Flashner +;;; Copyright © 2016, 2019, 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -28,7 +28,7 @@ (define-public moe (package (name "moe") - (version "1.10") + (version "1.11") (source (origin (method url-fetch) @@ -36,7 +36,7 @@ version ".tar.lz")) (sha256 (base32 - "0fymywdiy9xqppcmvgs7mf7d3gfrky3jp5jkxs2l3v93asml9zcc")))) + "1yg2ln2mm6gzv61cxnv60dw1cr5bl2dhkjy685jrd3aabb7wpyqf")))) (build-system gnu-build-system) (native-inputs `(("lzip" ,lzip))) (inputs `(("ncurses" ,ncurses))) -- cgit v1.2.3 From 91bc4f4dfbefabca103390fb3916090f7f6ce80f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:20:19 +0200 Subject: gnu: readymedia: Clean-up origin code. * gnu/packages/upnp.scm (readymedia)[source]: Replace custom logic with string-replace-substring. --- gnu/packages/upnp.scm | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index aac2ae370f..9707639d24 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2018 Theodoros Foradis ;;; Copyright © 2019 Jens Mølgaard ;;; Copyright © 2020 Jan Wielkiewicz +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -132,11 +133,7 @@ and others.") (uri (git-reference (url "https://git.code.sf.net/p/minidlna/git") (commit (string-append - "v" - (string-map (match-lambda - (#\. #\_) - (chr chr)) - version))))) + "v" (string-replace-substring version "." "_"))))) (file-name (git-file-name name version)) (sha256 (base32 -- cgit v1.2.3 From de194a39d3d49c7424d08e04b675ff649035e7b1 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:22:26 +0200 Subject: gnu: upnp.scm: Use license prefix. * gnu/packages/upnp.scm: Use the 'license:' prefix to denote licences. --- gnu/packages/upnp.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index 9707639d24..fed5eb18ed 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -38,7 +38,7 @@ #:use-module (guix utils) #:use-module (guix download) #:use-module (guix git-download) - #:use-module (guix licenses) + #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (ice-9 match)) @@ -90,7 +90,7 @@ while running behind a UPnP-enabled router or firewall. Such applications include peer-to-peer applications, active-mode FTP clients, DCC file transfers over IRC, instant messaging, network games, and most server software.") (license - (x11-style "file://LICENSE" "See 'LICENSE' file in the distribution")))) + (license:x11-style "file://LICENSE" "See 'LICENSE' file in the distribution")))) (define-public libupnp (package @@ -121,7 +121,7 @@ API and code for building control points, devices, and bridges that are compliant with Version 1.0 of the Universal Plug and Play Device Architecture Specification and support several operating systems like Linux, *BSD, Solaris and others.") - (license bsd-3))) + (license license:bsd-3))) (define-public readymedia (package @@ -156,4 +156,4 @@ and others.") (description "ReadyMedia (formerly known as MiniDLNA) is a simple media server, which serves multimedia content to compatible clients on the network. It aims to be fully compliant with DLNA and UPnP-AV standards.") - (license gpl2))) + (license license:gpl2))) -- cgit v1.2.3 From 406008a2ac8b03317623a9967ec2e5fd3dca7650 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:34:29 +0200 Subject: gnu: readymedia: Update to 1.3.0. Fixes CVE-2020-28926. * gnu/packages/upnp.scm (readymedia): Update to 1.3.0. [arguments]: Add configure-flag to not record kernel version of build machine. Add phase to remove spurious substitution of ffmpeg libraries. [inputs]: Add zlib. --- gnu/packages/upnp.scm | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index fed5eb18ed..9106dd1beb 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -26,6 +26,7 @@ #:use-module (gnu packages) #:use-module (gnu packages gettext) #:use-module (gnu packages autotools) + #:use-module (gnu packages compression) #:use-module (gnu packages video) #:use-module (gnu packages photo) #:use-module (gnu packages image) @@ -126,7 +127,7 @@ and others.") (define-public readymedia (package (name "readymedia") - (version "1.2.1") + (version "1.3.0") (source (origin (method git-fetch) @@ -137,8 +138,17 @@ and others.") (file-name (git-file-name name version)) (sha256 (base32 - "160915yv38k0p5zmyncs12kkbbcd8m8fk9jq70fkfd5x6dz40xm4")))) + "0g04lffj37wdv5bnpl5faxpnmlj6bbk8y7ziaz2wp6h82g6kb5wj")))) (build-system gnu-build-system) + (arguments + `(#:configure-flags '("--with-os-name=Linux") ; uname -s + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda _ + (substitute* "Makefile.am" + ((".*LIBAVUTIL_LIBS.*") "")) + #t))))) (native-inputs `(("automake" ,automake) ("autoconf" ,autoconf) @@ -150,7 +160,8 @@ and others.") ("flac" ,flac) ("libvorbis" ,libvorbis) ("sqlite" ,sqlite) - ("ffmpeg" ,ffmpeg))) + ("ffmpeg" ,ffmpeg) + ("zlib" ,zlib))) (home-page "https://sourceforge.net/projects/minidlna/") (synopsis "DLNA/UPnP-AV media server") (description "ReadyMedia (formerly known as MiniDLNA) is a simple media -- cgit v1.2.3 From 7dfc2d2e7f7ff5b0e8210ed7710f3cc87841d29c Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:35:40 +0200 Subject: gnu: readymedia: Sort inputs alphabetically. * gnu/packages/upnp.scm (readymedia)[native-inputs]: Sort alphabetically. [inputs]: Same. --- gnu/packages/upnp.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index 9106dd1beb..79739691e8 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -150,17 +150,17 @@ and others.") ((".*LIBAVUTIL_LIBS.*") "")) #t))))) (native-inputs - `(("automake" ,automake) - ("autoconf" ,autoconf) + `(("autoconf" ,autoconf) + ("automake" ,automake) ("gettext" ,gettext-minimal))) (inputs - `(("libexif" ,libexif) - ("libjpeg" ,libjpeg-turbo) - ("libid3tag" ,libid3tag) + `(("ffmpeg" ,ffmpeg) ("flac" ,flac) + ("libexif" ,libexif) + ("libid3tag" ,libid3tag) + ("libjpeg" ,libjpeg-turbo) ("libvorbis" ,libvorbis) ("sqlite" ,sqlite) - ("ffmpeg" ,ffmpeg) ("zlib" ,zlib))) (home-page "https://sourceforge.net/projects/minidlna/") (synopsis "DLNA/UPnP-AV media server") -- cgit v1.2.3 From 6200fcabcf3491554e7ea5a2091eb86dbc0cfda6 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 09:37:02 +0200 Subject: gnu: upnp.scm: Sort package module imports alphabetically. * gnu/packages/upnp.scm: Sort package module imports alphabetically. --- gnu/packages/upnp.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnu/packages/upnp.scm b/gnu/packages/upnp.scm index 79739691e8..8f4e9952f2 100644 --- a/gnu/packages/upnp.scm +++ b/gnu/packages/upnp.scm @@ -24,17 +24,17 @@ (define-module (gnu packages upnp) #:use-module (gnu packages) - #:use-module (gnu packages gettext) #:use-module (gnu packages autotools) #:use-module (gnu packages compression) - #:use-module (gnu packages video) - #:use-module (gnu packages photo) + #:use-module (gnu packages gettext) #:use-module (gnu packages image) #:use-module (gnu packages mp3) + #:use-module (gnu packages photo) #:use-module (gnu packages pkg-config) - #:use-module (gnu packages xiph) - #:use-module (gnu packages sqlite) #:use-module (gnu packages python) + #:use-module (gnu packages sqlite) + #:use-module (gnu packages video) + #:use-module (gnu packages xiph) #:use-module (guix build-system gnu) #:use-module (guix utils) #:use-module (guix download) -- cgit v1.2.3 From 684d27c36fcb2cc911a0b77685b27d8839317ee7 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 6 Jan 2021 09:33:11 +0100 Subject: gnu: emacs-esxml: Update to 0.3.5. * gnu/packages/emacs-xyz.scm (emacs-esxml): Update to 0.3.5. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index b26bd0c550..3c8ea43eb5 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -14163,7 +14163,7 @@ Lisp.") (define-public emacs-esxml (package (name "emacs-esxml") - (version "0.3.4") + (version "0.3.5") (source (origin (method git-fetch) (uri (git-reference @@ -14172,7 +14172,7 @@ Lisp.") (file-name (git-file-name name version)) (sha256 (base32 - "00vv8a75wdklygdyr4km9mc2ismxak69c45jmcny41xl44rp9x8m")))) + "16jn404vfmsvm12wrf8iczqlgdf2iycbxrvalvzxnm2gr5dfzp7z")))) (build-system emacs-build-system) (arguments `(#:phases -- cgit v1.2.3 From f024a7ba604fb18721a056e65777ae969d8b9681 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Tue, 5 Jan 2021 22:54:17 +0100 Subject: gnu: gpsbabel: Update to 1.7.0. * gnu/packages/gps.scm (gpsbabel): Update to 1.7.0. [source]: Use git-fetch, remove obsolete patches. [inputs]: Add libusb. * gnu/packages/patches/gpsbabel-minizip.patch: Remove file. * gnu/packages/patches/gpsbabel-qstring.patch: Remove file. * gnu/local.mk (dist_patch_DATA): Remove entries. Signed-off-by: Efraim Flashner --- gnu/local.mk | 3 +- gnu/packages/gps.scm | 27 ++++++----- gnu/packages/patches/gpsbabel-minizip.patch | 13 ------ gnu/packages/patches/gpsbabel-qstring.patch | 69 ----------------------------- 4 files changed, 14 insertions(+), 98 deletions(-) delete mode 100644 gnu/packages/patches/gpsbabel-minizip.patch delete mode 100644 gnu/packages/patches/gpsbabel-qstring.patch diff --git a/gnu/local.mk b/gnu/local.mk index 2e026cb252..396baae4ab 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -39,6 +39,7 @@ # Copyright © 2020 Martin Becze # Copyright © 2020 Malte Frank Gerdes # Copyright © 2020 Vinicius Monego +# Copyright © 2021 Björn Höfling # # This file is part of GNU Guix. # @@ -1113,8 +1114,6 @@ dist_patch_DATA = \ %D%/packages/patches/go-skip-gc-test.patch \ %D%/packages/patches/gpm-glibc-2.26.patch \ %D%/packages/patches/gpodder-disable-updater.patch \ - %D%/packages/patches/gpsbabel-minizip.patch \ - %D%/packages/patches/gpsbabel-qstring.patch \ %D%/packages/patches/grantlee-merge-theme-dirs.patch \ %D%/packages/patches/grep-timing-sensitive-test.patch \ %D%/packages/patches/grocsvs-dont-use-admiral.patch \ diff --git a/gnu/packages/gps.scm b/gnu/packages/gps.scm index e0f489f8de..fdb64f0902 100644 --- a/gnu/packages/gps.scm +++ b/gnu/packages/gps.scm @@ -6,6 +6,7 @@ ;;; Copyright © 2020 Guillaume Le Vaillant ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2020 Marius Bakke +;;; Copyright © 2021 Björn Höfling ;;; ;;; This file is part of GNU Guix. ;;; @@ -51,21 +52,18 @@ (define-public gpsbabel (package (name "gpsbabel") - (version "1.5.4") + (version "1.7.0") (source (origin - (method url-fetch) - ;; XXX: Downloads from gpsbabel.org are hidden behind a POST, so - ;; get it from elsewhere. - (uri (string-append - "mirror://debian/pool/main/g/gpsbabel/gpsbabel_" - version ".orig.tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/gpsbabel/gpsbabel") + (commit (string-append + "gpsbabel_" + (string-replace-substring version "." "_"))))) + (file-name (git-file-name name version)) (sha256 (base32 - "19hykxhyl567gf8qcrl33qhv95w0g4vxw9r3h9b8d8plx9bnaf8l")) - (patches (search-patches - "gpsbabel-minizip.patch" - ;; XXX: Remove this patch on the next release. - "gpsbabel-qstring.patch")) + "010g0vd2f5knpq5p7qfnl31kv3r8m5sjdsafcinbj5gh02j2nzpy")) (modules '((guix build utils))) (snippet '(begin @@ -87,8 +85,9 @@ #:tests? #f)) (inputs `(("expat" ,expat) - ("zlib" ,zlib) - ("qtbase" ,qtbase))) + ("libusb" ,libusb) + ("qtbase" ,qtbase) + ("zlib" ,zlib))) (native-inputs `(("which" ,which) ("qttools" ,qttools) diff --git a/gnu/packages/patches/gpsbabel-minizip.patch b/gnu/packages/patches/gpsbabel-minizip.patch deleted file mode 100644 index 8f3bb36f57..0000000000 --- a/gnu/packages/patches/gpsbabel-minizip.patch +++ /dev/null @@ -1,13 +0,0 @@ -Patch taken from https://sources.debian.org/data/main/g/gpsbabel/1.5.3-2/debian/patches/use_minizip. - ---- a/Makefile.in -+++ b/Makefile.in -@@ -120,7 +120,7 @@ LIBOBJS = queue.o route.o waypt.o filter - src/core/usasciicodec.o\ - src/core/ziparchive.o \ - $(GARMIN) $(JEEPS) $(SHAPE) @ZLIB@ $(FMTS) $(FILTERS) --OBJS = main.o globals.o $(LIBOBJS) @FILEINFO@ -+OBJS = main.o globals.o $(MINIZIP) $(LIBOBJS) @FILEINFO@ - - DEPFILES = $(OBJS:.o=.d) - \ No newline at end of file diff --git a/gnu/packages/patches/gpsbabel-qstring.patch b/gnu/packages/patches/gpsbabel-qstring.patch deleted file mode 100644 index 8ba1a7213b..0000000000 --- a/gnu/packages/patches/gpsbabel-qstring.patch +++ /dev/null @@ -1,69 +0,0 @@ -Extracted from following patch of gpsbabel: -https://github.com/gpsbabel/gpsbabel/commit/604178aa8ad4d3c3ad218df24c1e9a6a1f683bb3 - -From 604178aa8ad4d3c3ad218df24c1e9a6a1f683bb3 Mon Sep 17 00:00:00 2001 -From: Harel Mazor -Date: Tue, 24 Jan 2017 00:35:04 +0200 -Subject: [PATCH] Added geojson read capablity, moved magic strings to - constants, fixed windows compilation issues. - ---- a/tef_xml.cc -+++ b/tef_xml.cc -@@ -72,11 +72,11 @@ tef_start(xg_string args, const QXmlStreamAttributes* attrv) - bool valid = false; - - foreach(QXmlStreamAttribute attr, *attrv) { -- if (attr.name().compare("Comment", Qt::CaseInsensitive) == 0) { -- if (attr.value().compare("TourExchangeFormat", Qt::CaseInsensitive) == 0) { -+ if (attr.name().compare(QString("Comment"), Qt::CaseInsensitive) == 0) { -+ if (attr.value().compare(QString("TourExchangeFormat"), Qt::CaseInsensitive) == 0) { - valid = true; - } -- } else if (attr.name().compare("Version", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("Version"), Qt::CaseInsensitive) == 0) { - version = attr.value().toString().toDouble(); - } - } -@@ -95,9 +95,9 @@ tef_header(xg_string args, const QXmlStreamAttributes* attrv) - { - route = route_head_alloc(); - foreach(QXmlStreamAttribute attr, *attrv) { -- if (attr.name().compare("Name", Qt::CaseInsensitive) == 0) { -+ if (attr.name().compare(QString("Name"), Qt::CaseInsensitive) == 0) { - route->rte_name = attr.value().toString().trimmed(); -- } else if (attr.name().compare("Software", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("Software"), Qt::CaseInsensitive) == 0) { - route->rte_desc = attr.value().toString().trimmed(); - } - } -@@ -248,20 +248,20 @@ tef_item_start(xg_string args, const QXmlStreamAttributes* attrv) - QString attrstr = attr.value().toString(); - QByteArray attrtext = attrstr.toUtf8(); - -- if (attr.name().compare("SegDescription", Qt::CaseInsensitive) == 0) { -+ if (attr.name().compare(QString("SegDescription"), Qt::CaseInsensitive) == 0) { - wpt_tmp->shortname = attrstr.trimmed(); -- } else if (attr.name().compare("PointDescription", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("PointDescription"), Qt::CaseInsensitive) == 0) { - wpt_tmp->description = attrstr.trimmed(); -- } else if (attr.name().compare("ViaStation", Qt::CaseInsensitive) == 0 && -- attr.value().compare("true", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("ViaStation"), Qt::CaseInsensitive) == 0 && -+ attr.value().compare(QString("true"), Qt::CaseInsensitive) == 0) { - wpt_tmp->wpt_flags.fmt_use = 1; /* only a flag */ - - /* new in TEF V2 */ -- } else if (attr.name().compare("Instruction", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("Instruction"), Qt::CaseInsensitive) == 0) { - wpt_tmp->description = attrstr.trimmed(); -- } else if (attr.name().compare("Altitude", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("Altitude"), Qt::CaseInsensitive) == 0) { - wpt_tmp->altitude = attrstr.toDouble(); -- } else if (attr.name().compare("TimeStamp", Qt::CaseInsensitive) == 0) { -+ } else if (attr.name().compare(QString("TimeStamp"), Qt::CaseInsensitive) == 0) { - /* nothing for the moment */ - } - } --- -2.16.1 - -- cgit v1.2.3 From d5ecfb491845aee1fb4079fc71d93ba00e4b10be Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 10:40:27 +0200 Subject: gnu: gpsbabel: Unbundle zlib. * gnu/packages/gps.scm (gpsbabel)[source]: Adjust snippet to remove bundled zlib and references from the Makefile. --- gnu/packages/gps.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gnu/packages/gps.scm b/gnu/packages/gps.scm index fdb64f0902..7ee1fc871d 100644 --- a/gnu/packages/gps.scm +++ b/gnu/packages/gps.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2021 Björn Höfling +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -67,6 +68,9 @@ (modules '((guix build utils))) (snippet '(begin + (delete-file-recursively "zlib") + (substitute* "Makefile.in" + ((" zlib/z.*\\.h") "")) ;; Delete files under GPL-compatible licences but never used ;; on GNU systems, rather than bloating the LICENSE field. (delete-file "gui/serial_mac.cc") ; Apple MIT -- cgit v1.2.3 From 3b141f2eb9939a0140e0e1cec8ef451a81d9e2dc Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 10:54:46 +0200 Subject: gnu: gpsbabel: Enable tests. * gnu/packages/patches/gps.scm (gpsbabel)[source]: Add patch. [arguments]: Enable tests. * gnu/packages/patches/gpsbabel-fix-i686-test.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + gnu/packages/gps.scm | 9 +---- gnu/packages/patches/gpsbabel-fix-i686-test.patch | 46 +++++++++++++++++++++++ 3 files changed, 49 insertions(+), 7 deletions(-) create mode 100644 gnu/packages/patches/gpsbabel-fix-i686-test.patch diff --git a/gnu/local.mk b/gnu/local.mk index 396baae4ab..1151d4642e 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1114,6 +1114,7 @@ dist_patch_DATA = \ %D%/packages/patches/go-skip-gc-test.patch \ %D%/packages/patches/gpm-glibc-2.26.patch \ %D%/packages/patches/gpodder-disable-updater.patch \ + %D%/packages/patches/gpsbabel-fix-i686-test.patch \ %D%/packages/patches/grantlee-merge-theme-dirs.patch \ %D%/packages/patches/grep-timing-sensitive-test.patch \ %D%/packages/patches/grocsvs-dont-use-admiral.patch \ diff --git a/gnu/packages/gps.scm b/gnu/packages/gps.scm index 7ee1fc871d..4fa3bcef19 100644 --- a/gnu/packages/gps.scm +++ b/gnu/packages/gps.scm @@ -65,6 +65,7 @@ (sha256 (base32 "010g0vd2f5knpq5p7qfnl31kv3r8m5sjdsafcinbj5gh02j2nzpy")) + (patches (search-patches "gpsbabel-fix-i686-test.patch")) (modules '((guix build utils))) (snippet '(begin @@ -80,13 +81,7 @@ ;; TODO: "make doc" requires Docbook & co. (arguments `(#:configure-flags - '("--with-zlib=system") - ;; On i686, 'raymarine.test' fails because of a rounding error: - ;; . As a workaround, disable tests - ;; on these platforms. - ;; FIXME: On x86_64 with -std=gnu++11 tests also fail due to rounding - ;; error. - #:tests? #f)) + '("--with-zlib=system"))) (inputs `(("expat" ,expat) ("libusb" ,libusb) diff --git a/gnu/packages/patches/gpsbabel-fix-i686-test.patch b/gnu/packages/patches/gpsbabel-fix-i686-test.patch new file mode 100644 index 0000000000..5ba0305113 --- /dev/null +++ b/gnu/packages/patches/gpsbabel-fix-i686-test.patch @@ -0,0 +1,46 @@ +https://github.com/gpsbabel/gpsbabel/commit/465a74194d53acea5c8d74c5cf3cb2940546ec92.patch +Can be removed next release + +From 465a74194d53acea5c8d74c5cf3cb2940546ec92 Mon Sep 17 00:00:00 2001 +From: tsteven4 <13596209+tsteven4@users.noreply.github.com> +Date: Fri, 7 Aug 2020 11:29:22 -0600 +Subject: [PATCH] fix i386 regression error with engima. (#620) + +this was motivated by the test failure seen at +https://buildd.debian.org/status/fetch.php?pkg=gpsbabel&arch=i386&ver=1.7.0%2Bds-4&stamp=1596794554&raw=0 +--- + enigma.cc | 13 ++++++++++--- + 1 file changed, 10 insertions(+), 3 deletions(-) + +diff --git a/enigma.cc b/enigma.cc +index 850f27b4e..32fea92d6 100644 +--- a/enigma.cc ++++ b/enigma.cc +@@ -21,9 +21,16 @@ + + */ + ++#include // for fabs, lround ++#include // for int32_t, uint8_t, uint32_t ++#include // for abs ++#include // for strlen, memcpy, memset ++ ++#include // for QString ++ + #include "defs.h" +-#include +-#include ++#include "gbfile.h" // for gbfclose, gbfopen_le, gbfread, gbfwrite, gbfile ++ + + #define MYNAME "Enigma binary route and waypoint file format" + +@@ -177,7 +184,7 @@ enigma_waypt_disp(const Waypoint* wpt) + le_write32(&ewpt.longitude, decToEnigmaPosition(wpt->longitude)); + ewpt.waypoint_type = WTYPE_WAYPOINT; + if (wpt->altitude != unknown_alt) { +- le_write32(&ewpt.data.wp_altitude, METERS_TO_FEET(wpt->altitude) + 1000); ++ le_write32(&ewpt.data.wp_altitude, lround(METERS_TO_FEET(wpt->altitude)) + 1000); + } + if (wpt->shortname != nullptr) { + ewpt.shortname_len = (uint8_t) min(6, strlen(CSTRc(wpt->shortname))); -- cgit v1.2.3 From 32ab45413269cf25ac93c7cfa2447dd4ca9d5948 Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Tue, 5 Jan 2021 20:07:05 -0300 Subject: gnu: cozy: Update to 0.7.8. * gnu/packages/ebook.scm (cozy): Update to 0.7.8. Signed-off-by: Efraim Flashner --- gnu/packages/ebook.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/ebook.scm b/gnu/packages/ebook.scm index e8dedf1cdd..47bbd1a789 100644 --- a/gnu/packages/ebook.scm +++ b/gnu/packages/ebook.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2017 Roel Janssen ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2020 Marius Bakke -;;; Copyright © 2020 Vinicius Monego +;;; Copyright © 2020, 2021 Vinicius Monego ;;; Copyright © 2020 Zheng Junjie <873216071@qq.com> ;;; ;;; This file is part of GNU Guix. @@ -443,7 +443,7 @@ following formats: (define-public cozy (package (name "cozy") - (version "0.7.6") + (version "0.7.8") (source (origin (method git-fetch) @@ -452,7 +452,7 @@ following formats: (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1pg0djhg4p32vxfwf6bfals31zf93m56fx1x4q5jhhdwmll7xl6w")))) + (base32 "0z2wj9g32aa5g9pw81q49iv1smb6yvlv9zs0vrzbx6mw8cj3c5d2")))) (build-system meson-build-system) (arguments `(#:glib-or-gtk? #t -- cgit v1.2.3 From 5296548a902b27ac341d460a3e28364d9a03ef41 Mon Sep 17 00:00:00 2001 From: Pierre Langlois Date: Wed, 6 Jan 2021 09:32:24 +0000 Subject: gnu: mu: Update to 1.4.14. * gnu/packages/mail.scm (mu): Update to 1.4.14. --- gnu/packages/mail.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index aaf474a5e0..5bdb4152cb 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -24,7 +24,7 @@ ;;; Copyright © 2017 Kyle Meyer ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018, 2020 Rene Saavedra -;;; Copyright © 2018, 2019, 2020 Pierre Langlois +;;; Copyright © 2018, 2019, 2020, 2021 Pierre Langlois ;;; Copyright © 2018 Alex Vong ;;; Copyright © 2018 Gábor Boskovits ;;; Copyright © 2018, 2019, 2020 Ricardo Wurmus @@ -1059,7 +1059,7 @@ security functionality including PGP, S/MIME, SSH, and SSL.") (define-public mu (package (name "mu") - (version "1.4.13") + (version "1.4.14") (source (origin (method url-fetch) (uri (string-append "https://github.com/djcb/mu/releases/" @@ -1067,7 +1067,7 @@ security functionality including PGP, S/MIME, SSH, and SSL.") "mu-" version ".tar.xz")) (sha256 (base32 - "13kfpr77qrnp3i5qnb5zd03frd3fdviggnl50973gdk0hr7m0smj")))) + "1fk0zyxajwyzp1f8yn7imbqq77s2w5cab5m9jla4zrybwkdi0r6z")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config) -- cgit v1.2.3 From caa22090e1489c3f48197d881744b15c9f3ee12b Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 6 Jan 2021 10:10:26 +0100 Subject: gnu: Add agnostic-lizard. * gnu/packages/lisp-xyz.scm (cl-agnostic-lizard, ecl-agnostic-lizard, sbcl-agnostic-lizard): New variables. --- gnu/packages/lisp-xyz.scm | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 56ca5b6136..1bdf9c954b 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2018 Benjamin Slade ;;; Copyright © 2018 Alex Vong -;;; Copyright © 2018, 2020 Pierre Neidhardt +;;; Copyright © 2018, 2020, 2021 Pierre Neidhardt ;;; Copyright © 2018, 2019 Pierre Langlois ;;; Copyright © 2019, 2020 Katherine Cox-Buday ;;; Copyright © 2019 Jesse Gildersleve @@ -12804,3 +12804,36 @@ compression/decompression using bindings to the libzstd C library.") (define-public ecl-zstd (sbcl-package->ecl-package sbcl-zstd)) + +(define-public sbcl-agnostic-lizard + (let ((commit "fe3a73719f05901c8819f8995a3ebae738257952") + (revision "1")) + (package + (name "sbcl-agnostic-lizard") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.common-lisp.net/mraskin/agnostic-lizard") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0ax78y8w4zlp5dcwyhz2nq7j3shi49qn31dkfg8lv2jlg7mkwh2d")))) + (build-system asdf-build-system/sbcl) + (synopsis "Almost correct portable code walker for Common Lisp") + (description + "Agnostic Lizard is a portable implementation of a code walker and in +particular of the macroexpand-all function (and macro) that makes a best +effort to be correct while not expecting much beyond what the Common Lisp +standard requires. + +It aims to be implementation-agnostic and to climb the syntax trees.") + (home-page "https://github.com/glv2/cl-zstd") + (license license:gpl3+)))) + +(define-public cl-agnostic-lizard + (sbcl-package->cl-source-package sbcl-agnostic-lizard)) + +(define-public ecl-agnostic-lizard + (sbcl-package->ecl-package sbcl-agnostic-lizard)) -- cgit v1.2.3 From 0c8abacf3acb9985b3c08b86184d7ef21f2986a4 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 6 Jan 2021 10:45:52 +0100 Subject: gnu: emacs-sly-stepper: Find required Common Lisp dependency. * gnu/packages/emacs-xyz.scm (emacs-sly-stepper)[inputs]: Add cl-agnostic-lizard. [arguments]: Patch Lisp file to find agnostic-lizard's absolute path. --- gnu/packages/emacs-xyz.scm | 29 +++++++++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 3c8ea43eb5..6c0561f397 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -34,7 +34,7 @@ ;;; Copyright © 2017, 2018, 2019, 2020 Maxim Cournoyer ;;; Copyright © 2018 Sohom Bhattacharjee ;;; Copyright © 2018, 2019 Mathieu Lirzin -;;; Copyright © 2018, 2019, 2020 Pierre Neidhardt +;;; Copyright © 2018, 2019, 2020, 2021 Pierre Neidhardt ;;; Copyright © 2018, 2019, 2020 Tim Gesthuizen ;;; Copyright © 2018, 2019 Jack Hill ;;; Copyright © 2018 Pierre-Antoine Rouby @@ -152,6 +152,7 @@ #:use-module (gnu packages image) #:use-module (gnu packages linux) #:use-module (gnu packages libevent) + #:use-module (gnu packages lisp-xyz) #:use-module (gnu packages lua) #:use-module (gnu packages music) #:use-module (gnu packages version-control) @@ -9750,6 +9751,8 @@ inside the source file.") (base32 "09ll9dv8fd5dgnki82hcd48nm4qdzzn8wpva0zzr69zkjwzf9v25")))) (build-system emacs-build-system) + (inputs + `(("cl-agnostic-lizard" ,cl-agnostic-lizard))) (propagated-inputs `(("emacs-sly" ,emacs-sly))) (arguments @@ -9765,7 +9768,29 @@ inside the source file.") (setenv "EMACSLOADPATH" (string-append sly "/share/emacs/site-lisp/contrib:" (getenv "EMACSLOADPATH")))) - #t))))) + #t)) + (add-after 'install 'find-agnostic-lizard + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (file (string-append out "/share/emacs/site-lisp/" + "slynk-stepper.lisp")) + (asd (string-append + (assoc-ref inputs "cl-agnostic-lizard") + "/share/common-lisp/systems/agnostic-lizard.asd"))) + ;; agnostic-lizard is found at runtime. + (substitute* file + (("\\(funcall \\(read-from-string \"asdf:load-system\"\\)") + (string-append + "(funcall (read-from-string \"asdf:load-asd\") \"" + asd + "\")\n (funcall (read-from-string \"asdf:load-system\")")) + ;; Upstream mistakenly requires Quicklisp. See + ;; https://github.com/joaotavora/sly-stepper/issues/2. + (("\\(funcall \\(read-from-string \"ql:quickload\"\\)") + (string-append + "(ignore-errors (funcall (read-from-string \"ql:quickload\") " + ":agnostic-lizard))")) + ((" :agnostic-lizard\\)") "")))))))) (synopsis "Portable Common Lisp stepper interface for Emacs") (description "This package features a new, portable, visual stepping facility for -- cgit v1.2.3 From 8480c65bb7e5e73345d5ca355d0a137796efa078 Mon Sep 17 00:00:00 2001 From: Morgan Smith Date: Mon, 4 Jan 2021 15:21:55 -0500 Subject: doc: Link to "Keyboard Layout" in "operating-system Reference" * doc/guix.texi (operating-system Reference): Link to the "Keyboard Layout" node. Signed-off-by: Mathieu Othacehe --- doc/guix.texi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/guix.texi b/doc/guix.texi index 0f6e95a65a..884224fce6 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -13359,7 +13359,8 @@ The default label includes the kernel name and version. @item @code{keyboard-layout} (default: @code{#f}) This field specifies the keyboard layout to use in the console. It can be either @code{#f}, in which case the default keyboard layout is used (usually -US English), or a @code{} record. +US English), or a @code{} record. @xref{Keyboard Layout}, +for more information. This keyboard layout is in effect as soon as the kernel has booted. For instance, it is the keyboard layout in effect when you type a passphrase if -- cgit v1.2.3 From 3be86365b34ae1ebac2b93f6ddd7cf09c543c94a Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Wed, 6 Jan 2021 13:46:22 +0100 Subject: gnu: emacs-sly: Update to 20210105 (fixes breaking issues). * gnu/packages/emacs-xyz.scm (emacs-sly): Update to 20210105. --- gnu/packages/emacs-xyz.scm | 115 +++++++++++++++++++++++---------------------- 1 file changed, 59 insertions(+), 56 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 6c0561f397..28e8d39234 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9531,61 +9531,64 @@ CIDER).") (define-public emacs-sly ;; Update together with sbcl-slynk. - (package - (name "emacs-sly") - (version "1.0.42") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/joaotavora/sly") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "10l867c4hgcpiajcfkz9g9vabp7y4bcgy51la6n9pqxrlg1fs455")))) - (build-system emacs-build-system) - (native-inputs - `(("texinfo" ,texinfo))) - (arguments - `(#:include (cons* "^contrib\\/" "^lib\\/" "^slynk\\/" %default-include) - #:phases - ;; The package provides autoloads. - (modify-phases %standard-phases - (delete 'make-autoloads) - (add-before 'install 'install-doc - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (info-dir (string-append out "/share/info")) - (doc-dir (string-append out "/share/doc/" - ,name "-" ,version)) - (doc-files '( ;; "doc/sly-refcard.pdf" ; See sly-refcard.pdf below. - "README.md" "NEWS.md" "PROBLEMS.md" - "CONTRIBUTING.md"))) - (with-directory-excursion "doc" - (substitute* "Makefile" - (("infodir=/usr/local/info") - (string-append "infodir=" info-dir)) - ;; Don't rebuild contributors.texi since we are not in - ;; the git repo. - (("contributors.texi: Makefile texinfo-tabulate.awk") - "contributors.texi:")) - (invoke "make" "html/index.html") - (invoke "make" "sly.info") - ;; TODO: We need minimal texlive with "preprint" package - ;; (for fullpage.sty). (invoke "make" "sly-refcard.pdf") - (install-file "sly.info" info-dir) - (copy-recursively "html" (string-append doc-dir "/html"))) - (for-each (lambda (f) - (install-file f doc-dir) - (delete-file f)) - doc-files) - (delete-file-recursively "doc") - #t)))))) - (home-page "https://github.com/joaotavora/sly") - (synopsis "Sylvester the Cat's Common Lisp IDE") - (description - "SLY is Sylvester the Cat's Common Lisp IDE. SLY is a fork of SLIME, and + (let ((commit "dffdf3caa12e964127d6eb45ba92ac0442cc5a48")) + ;; Latest stable 1.0.42 is broken: + ;; https://github.com/joaotavora/sly/issues/394. + (package + (name "emacs-sly") + (version (git-version "1.0.42" "1" commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/joaotavora/sly") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0vv185gz3rkfng5y79dijfnc11p92qdz2kdza05avjbpqfs6l0zn")))) + (build-system emacs-build-system) + (native-inputs + `(("texinfo" ,texinfo))) + (arguments + `(#:include (cons* "^contrib\\/" "^lib\\/" "^slynk\\/" %default-include) + #:phases + ;; The package provides autoloads. + (modify-phases %standard-phases + (delete 'make-autoloads) + (add-before 'install 'install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (info-dir (string-append out "/share/info")) + (doc-dir (string-append out "/share/doc/" + ,name "-" ,version)) + (doc-files '( ;; "doc/sly-refcard.pdf" ; See sly-refcard.pdf below. + "README.md" "NEWS.md" "PROBLEMS.md" + "CONTRIBUTING.md"))) + (with-directory-excursion "doc" + (substitute* "Makefile" + (("infodir=/usr/local/info") + (string-append "infodir=" info-dir)) + ;; Don't rebuild contributors.texi since we are not in + ;; the git repo. + (("contributors.texi: Makefile texinfo-tabulate.awk") + "contributors.texi:")) + (invoke "make" "html/index.html") + (invoke "make" "sly.info") + ;; TODO: We need minimal texlive with "preprint" package + ;; (for fullpage.sty). (invoke "make" "sly-refcard.pdf") + (install-file "sly.info" info-dir) + (copy-recursively "html" (string-append doc-dir "/html"))) + (for-each (lambda (f) + (install-file f doc-dir) + (delete-file f)) + doc-files) + (delete-file-recursively "doc") + #t)))))) + (home-page "https://github.com/joaotavora/sly") + (synopsis "Sylvester the Cat's Common Lisp IDE") + (description + "SLY is Sylvester the Cat's Common Lisp IDE. SLY is a fork of SLIME, and contains the following improvements over it: @enumerate @@ -9604,7 +9607,7 @@ highlight the object and remain stable throughout the REPL session; SLY tracks SLIME's bugfixes and all its familiar features (debugger, inspector, xref, etc.) are still available, but with better integration.") - (license license:gpl3+))) + (license license:gpl3+)))) (define-public emacs-sly-quicklisp (let ((commit "01ebe3976a244309f2e277c09206831135a0b66c") -- cgit v1.2.3 From 5f0cc5f9fbdc8d02628ce7b9c5aa0acb566f41aa Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 13:51:27 +0100 Subject: gnu: emacs-company-math: Update to 1.4. * gnu/packages/emacs-xyz.scm (emacs-company-math): Update to 1.4. [synopsis]: Slightly shorten it. [description]: Use proper capitalization. --- gnu/packages/emacs-xyz.scm | 48 ++++++++++++++++++++++------------------------ 1 file changed, 23 insertions(+), 25 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 28e8d39234..ffed61aadc 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2016, 2017 Roel Janssen ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016, 2019 Alex Griffin -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Nicolas Goaziou +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Nicolas Goaziou ;;; Copyright © 2016, 2017, 2018 Alex Vong ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Arun Isaac ;;; Copyright © 2017 Christopher Baines @@ -5402,30 +5402,28 @@ features: (license license:gpl3+))) (define-public emacs-company-math - (let ((commit "600e49449644f6835f9dc3501bc58461999e8ab9") - (revision "1")) - (package - (name "emacs-company-math") - (version (git-version "1.3" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/vspinu/company-math") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1ps2lpkzn8mjbpcbvvy1qz3xbgrh6951x8y9bsd1fm32drdph9lh")))) - (build-system emacs-build-system) - (propagated-inputs - `(("emacs-math-symbol-lists" ,emacs-math-symbol-lists) - ("emacs-company" ,emacs-company))) - (home-page "https://github.com/vspinu/company-math") - (synopsis "Completion backends for Unicode math symbols and @code{LaTeX} tags") - (description "This package provides a backend for use with -@code{company-mode} allowing for completion of common math symbols.") - (license license:gpl3+)))) + (package + (name "emacs-company-math") + (version "1.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/vspinu/company-math") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1y1fw926insgdl7ib9ynxjrxf3p6wfjkfxvf5vgdca7267cvcll1")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-math-symbol-lists" ,emacs-math-symbol-lists) + ("emacs-company" ,emacs-company))) + (home-page "https://github.com/vspinu/company-math") + (synopsis "Completion backends for math symbols and @code{LaTeX} tags") + (description + "This package provides a backend for use with Company mode allowing for +completion of common math symbols.") + (license license:gpl3+))) (define-public emacs-compdef (let ((commit "67104a38763cc819644f711248b170a43bce151b") -- cgit v1.2.3 From 288fe185e86763f5d18e2efe378b6c86c091fc6a Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Tue, 5 Jan 2021 20:24:23 +0000 Subject: gnu: Add cl-py-configparser. * gnu/packages/lisp-xyz.scm (cl-py-configparser, ecl-py-configparser, sbcl-py-configparser): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 1bdf9c954b..dba124f912 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -20,7 +20,7 @@ ;;; Copyright © 2020 Dimakis Dimakakos ;;; Copyright © 2020 Oleg Pykhalov ;;; Copyright © 2020 Adam Kandur -;;; Copyright © 2020 Sharlatan Hellseher +;;; Copyright © 2020, 2021 Sharlatan Hellseher ;;; ;;; This file is part of GNU Guix. ;;; @@ -1787,6 +1787,40 @@ named readtables, which is akin to package namespacing in Common Lisp.") (define-public ecl-named-readtables (sbcl-package->ecl-package sbcl-named-readtables)) +(define-public sbcl-py-configparser + ;; NOTE: (Sharlatan <2021-01-05 Tue> <19:52:19 UTC+0000>) Project updated last + ;; time 8y ago, it looks like abandoned. VCS of the project: + ;; https://svn.common-lisp.net/py-configparser/trunk + (package + (name "sbcl-py-configparser") + (version "1.0.3") + (source + (origin + (method url-fetch) + (uri (string-append + "https://common-lisp.net/project/py-configparser/releases/" + "py-configparser-" version ".tar.gz")) + (sha256 + (base32 "0i4rqz5cv7d7c2w81x5lwy05s6fbi3zikf4k5kpi3bkx3cabwdxj")))) + (build-system asdf-build-system/sbcl) + (inputs + `(("parse-number" ,sbcl-parse-number))) + (home-page "http://common-lisp.net/project/py-configparser/") + (synopsis "ConfigParser Python module functionality for Common Lisp") + (description "The py-configparser package implements the ConfigParser +Python module functionality in Common Lisp. In short, it implements reading +and writing of .INI-file style configuration files with sections containing +key/value pairs of configuration options. In line with the functionalities in +the python module, does this package implement basic interpolation of option +values in other options.") + (license license:expat))) + +(define-public cl-py-configparser + (sbcl-package->cl-source-package sbcl-py-configparser)) + +(define-public ecl-py-configparser + (sbcl-package->ecl-package sbcl-py-configparser)) + (define-public sbcl-pythonic-string-reader (let ((commit "47a70ba1e32362e03dad6ef8e6f36180b560f86a")) (package -- cgit v1.2.3 From 69c0526719fde3059acbc7a7f3ac039c87dd40f5 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Wed, 6 Jan 2021 13:57:50 +0100 Subject: gnu: sbcl-agnostic-lizard: Fix home-page. * gnu/packages/lisp-xyz.scm (sbcl-agnostic-lizard)[home-page]: Fix it. --- gnu/packages/lisp-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index dba124f912..82cfa677a9 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2018, 2019 Pierre Langlois ;;; Copyright © 2019, 2020 Katherine Cox-Buday ;;; Copyright © 2019 Jesse Gildersleve -;;; Copyright © 2019, 2020 Guillaume Le Vaillant +;;; Copyright © 2019, 2020, 2021 Guillaume Le Vaillant ;;; Copyright © 2019 Brett Gilio ;;; Copyright © 2020 Konrad Hinsen ;;; Copyright © 2020 Dimakis Dimakakos @@ -12863,7 +12863,7 @@ effort to be correct while not expecting much beyond what the Common Lisp standard requires. It aims to be implementation-agnostic and to climb the syntax trees.") - (home-page "https://github.com/glv2/cl-zstd") + (home-page "https://gitlab.common-lisp.net/mraskin/agnostic-lizard") (license license:gpl3+)))) (define-public cl-agnostic-lizard -- cgit v1.2.3 From 74783ba56e7b029a6bcd9c91bfc964c9ddc9f28c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 14:12:29 +0100 Subject: gnu: directfb: Fix home page. * gnu/packages/graphics.scm (directfb)[home-page]: Fix URL. The previous one was unrelated to the project. --- gnu/packages/graphics.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 1c46471e08..9879130e20 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -289,7 +289,7 @@ framebuffer graphics, audio output and input event.") (description "DirectFB is a graphics library which was designed with embedded systems in mind. It offers maximum hardware accelerated performance at a minimum of resource usage and overhead.") - (home-page "http://www.directfb.org/") + (home-page "https://github.com/deniskropp/DirectFB") (license license:lgpl2.1+))) (define-public flux -- cgit v1.2.3 From 61ec6dc63b4928f9c6c3ae2662ef4078390dcd5e Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Wed, 6 Jan 2021 14:29:11 +0100 Subject: gnu: sbcl-ironclad: Update to 0.54. * gnu/packages/lisp-xyz.scm (sbcl-ironclad): Update to 0.54. --- gnu/packages/lisp-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 82cfa677a9..c3205ad904 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -1724,7 +1724,7 @@ also be supported.") (define-public sbcl-ironclad (package (name "sbcl-ironclad") - (version "0.53") + (version "0.54") (source (origin (method git-fetch) @@ -1732,7 +1732,7 @@ also be supported.") (url "https://github.com/sharplispers/ironclad/") (commit (string-append "v" version)))) (sha256 - (base32 "01qdfa0jggqbwlsb3aw1iigvs5xhnddk6kn3abhan59956dsbp02")) + (base32 "07g0wpvfqq2yk23prs890d4qvbnr3xd6w8ssd88g89xdg483wpvk")) (file-name (git-file-name name version)))) (build-system asdf-build-system/sbcl) (native-inputs -- cgit v1.2.3 From ddb978728ff318e11f82f8c50eae7dd44d61c425 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 15:35:03 +0100 Subject: gnu: emacs-anzu: Update to 0.64. * gnu/packages/emacs-xyz.scm (emacs-anzu): Update to 0.64. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index ffed61aadc..94b954c3ec 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -14472,7 +14472,7 @@ directories of plain text notes, inspired by Notational Velocity.") (define-public emacs-anzu (package (name "emacs-anzu") - (version "0.62") + (version "0.64") (source (origin (method git-fetch) @@ -14481,7 +14481,7 @@ directories of plain text notes, inspired by Notational Velocity.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1lzvc0ihcbplir4hqfyxfqpsd78arz15gk92kmq4f8ggbkl37fan")))) + (base32 "1jfn5nm6r68wa0gn2k2zy6sdq6c8shw8x04ylzzm5cw7zm60jw0n")))) (build-system emacs-build-system) (home-page "https://github.com/syohex/emacs-anzu") (synopsis "Show number of matches in mode-line while searching") -- cgit v1.2.3 From 6be271460b9f8110f94dc7c363205153744ac9c5 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 17:52:45 +0200 Subject: gnu: python-cypari2: Update to 2.1.2. * gnu/packages/sagemath.scm (python-cypari2): Update to 2.1.2. --- gnu/packages/sagemath.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/sagemath.scm b/gnu/packages/sagemath.scm index 943e9ba5b9..7f060155ed 100644 --- a/gnu/packages/sagemath.scm +++ b/gnu/packages/sagemath.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2019 Nicolas Goaziou ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2020 Jakub Kądziołka +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -44,14 +45,14 @@ (define-public python-cypari2 (package (name "python-cypari2") - (version "2.1.1") + (version "2.1.2") (source (origin (method url-fetch) (uri (pypi-uri "cypari2" version)) (sha256 (base32 - "1nwkzgqvbw6361x0rpggy1q5nx663fswhpvg8md6xhqyfwpgc7nz")))) + "0ymc4i9y60aazscc1blivirkr1rflzz6akkmvfzyn5l7mgnlbk83")))) (build-system python-build-system) (native-inputs `(("python-cython" ,python-cython))) -- cgit v1.2.3 From 14829963367d18214546bb9ea7028436cd024965 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 18:26:39 +0100 Subject: gnu: emacs-xml-rpc: Update to 1.6.15. * gnu/packages/emacs-xyz.scm (emacs-xml-rpc): Update to 1.6.15. --- gnu/packages/emacs-xyz.scm | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 94b954c3ec..b85eec0bc8 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -18446,31 +18446,28 @@ server using XML-RPC.") (license license:gpl3+))) (define-public emacs-xml-rpc - (let ((commit "8f624f8b964e9145acb504e4457c9510e87dd93c") - (revision "1")) - (package - (name "emacs-xml-rpc") - (version (git-version "1.6.12" revision commit)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/hexmode/xml-rpc-el") - (commit commit))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0xa54z52rsfl3n0xgmbycj4zazp8ksgdwcq56swzs6wp72zlalmj")))) - (build-system emacs-build-system) - (home-page "https://github.com/hexmode/xml-rpc-el") - (synopsis "XML-RPC client for Emacs") - (description "This package provides an XML-RPC client for Emacs capable + (package + (name "emacs-xml-rpc") + (version "1.6.15") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/hexmode/xml-rpc-el") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "07vgwnk96i1vpsv2glg6kbkamjcs72xiznsa6xk7nl0nranzr3hd")))) + (build-system emacs-build-system) + (home-page "https://github.com/hexmode/xml-rpc-el") + (synopsis "XML-RPC client for Emacs") + (description "This package provides an XML-RPC client for Emacs capable of both synchronous and asynchronous method calls using the @code{url} package's async retrieval functionality. @file{xml-rpc.el} represents XML-RPC datatypes as Lisp values, automatically converting to and from the XML datastructures as needed, both for method parameters and return values, making using XML-RPC methods fairly transparent to the Lisp code.") - (license license:gpl3+)))) + (license license:gpl3+))) (define-public emacs-xpm (package -- cgit v1.2.3 From 206359a78877ceba4574147eb8c2f13a237dd359 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 18:28:39 +0100 Subject: gnu: emacs-xterm-color: Update to 2.0. * gnu/packages/emacs-xyz.scm (emacs-xterm-color): Update to 2.0. --- gnu/packages/emacs-xyz.scm | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index b85eec0bc8..689d3dd54b 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -23090,16 +23090,16 @@ work.") (define-public emacs-xterm-color (package (name "emacs-xterm-color") - (version "1.9") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/atomontage/xterm-color") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0i9ivc5xhl5y5v0l18kbhfg8s2abb9zaimyx951b8bc0f5as68xm")))) + (version "2.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/atomontage/xterm-color") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "127lq50q62x06kd1xrf8lyc4rkqbfhfy86gsx1x4x169am2xk397")))) (build-system emacs-build-system) (home-page "https://github.com/atomontage/xterm-color") (synopsis "ANSI & xterm-256 color text property translator for Emacs") -- cgit v1.2.3 From f2599411c230f431abd726531075b8b7e90bdfca Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:16:47 +0100 Subject: gnu: Add rust-actix-threadpool-0.3. * gnu/packages/crates-io.scm (rust-actix-threadpool-0.3): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 04f0ba4574..648b67d061 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -89,6 +89,32 @@ library in Rust.") (license license:expat))) +(define-public rust-actix-threadpool-0.3 + (package + (name "rust-actix-threadpool") + (version "0.3.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-threadpool" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0c0frk19ml94d01mvgv5g60mhq86gfi34c3lsfpvjm18016z02fj")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-derive-more" ,rust-derive-more-0.99) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-threadpool" ,rust-threadpool-1)))) + (home-page "https://actix.rs") + (synopsis "Actix thread pool for sync code") + (description "This package provides Actix thread pool for sync code.") + (license (list license:expat license:asl2.0)))) + (define-public rust-addr2line-0.11 (package (name "rust-addr2line") -- cgit v1.2.3 From 088bc589a6426386b4bd192308f8c25f7e550b54 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:20:10 +0100 Subject: gnu: Add rust-copyless-0.1. * gnu/packages/crates-io.scm (rust-copyless-0.1): New variable. --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 648b67d061..95a30eb60f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5778,6 +5778,25 @@ the path and domain matching rules specified in RFC6265. Split from the user_agent crate.") (license (list license:asl2.0 license:expat)))) +(define-public rust-copyless-0.1 + (package + (name "rust-copyless") + (version "0.1.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "copyless" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0dmmxsq3m0i6g9s2kj96n777qhmm7vjgv4r7agc2v6w6bl7rdpx2")))) + (build-system cargo-build-system) + (home-page "https://github.com/kvark/copyless") + (synopsis "Ways to eliminate @code{memcpy} calls") + (description + "This package provides ways to eliminate @code{memcpy} calls when using +the standard library.") + (license (list license:expat license:asl2.0)))) + (define-public rust-cordic-0.1 (package (name "rust-cordic") -- cgit v1.2.3 From f261ff5473cfca42d7771513e17dec9f8ed7c5bd Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:28:19 +0100 Subject: gnu: Add rust-actix-macros-0.1 and rust-actix-rt-1. * gnu/packages/crates-io.scm (rust-actix-macros-0.1): (rust-actix-rt-1): New variables. --- gnu/packages/crates-io.scm | 51 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 95a30eb60f..0d97002549 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -89,6 +89,57 @@ library in Rust.") (license license:expat))) +(define-public rust-actix-macros-0.1 + (package + (name "rust-actix-macros") + (version "0.1.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-macros" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0mfnprr8gy1gb5xcr18iwsv781hysvh7sr5xxg6ghyi61gh8rjml")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-actix-rt" ,rust-actix-rt-1) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-trybuild" ,rust-trybuild-1)))) + (home-page "https://actix.rs") + (synopsis "Actix runtime macros") + (description "This package provides Actix runtime macros.") + (license (list license:expat license:asl2.0)))) + +(define-public rust-actix-rt-1 + (package + (name "rust-actix-rt") + (version "1.1.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-rt" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "09xj7pxy0ng13rd6hya1md98dhk0586p4bsfrwmxxlg028lwqgql")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-actix-macros" ,rust-actix-macros-0.1) + ("rust-actix-threadpool" ,rust-actix-threadpool-0.3) + ("rust-copyless" ,rust-copyless-0.1) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-smallvec" ,rust-smallvec-1) + ("rust-tokio" ,rust-tokio-0.2)))) + (home-page "https://actix.rs") + (synopsis "Actix runtime") + (description "This package provides Actix runtime.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-threadpool-0.3 (package (name "rust-actix-threadpool") -- cgit v1.2.3 From 16acd9a4c4b7db6802f20e883d9afbac620613f4 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:39:06 +0100 Subject: gnu: Add rust-actix-codec-0.3. * gnu/packages/crates-io.scm (rust-actix-codec-0.3): New variable. --- gnu/packages/crates-io.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0d97002549..7b3824b204 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -89,6 +89,35 @@ library in Rust.") (license license:expat))) +(define-public rust-actix-codec-0.3 + (package + (name "rust-actix-codec") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-codec" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0w7506qd2f8q83z6l5lqx1363ks0ysx8f7qgvy8fknrq70xq7lbq")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-util" ,rust-tokio-util-0.3)))) + (home-page "https://actix.rs") + (synopsis "Codec utilities for working with framed protocols") + (description + "This package provides codec utilities for working with framed +protocols.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-macros-0.1 (package (name "rust-actix-macros") -- cgit v1.2.3 From ea4b4b4bc18be071e6df61812e67edd9e94a85d9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 18:49:15 +0100 Subject: gnu: Add rust-actix-service-1. * gnu/packages/crates-io.scm (rust-actix-service-1): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7b3824b204..917cb793e8 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -169,6 +169,33 @@ protocols.") (description "This package provides Actix runtime.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-service-1 + (package + (name "rust-actix-service") + (version "1.0.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-service" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1fw2b1cpxrpqk778mpvxv0cazj0pwjyb6khzs4syhnqvb1fl6lh0")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-futures-util" ,rust-futures-util-0.3) + ("rust-pin-project" ,rust-pin-project-0.4)) + #:cargo-development-inputs + (("rust-actix-rt" ,rust-actix-rt-1) + ("rust-criterion" ,rust-criterion-0.3)))) + (home-page "https://actix.rs") + (synopsis + "Service trait and combinators for asynchronous request/response") + (description + "This package provides a service trait and combinators for representing +asynchronous request/response operations.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-threadpool-0.3 (package (name "rust-actix-threadpool") -- cgit v1.2.3 From d793a0f81eb765110b635159b9b337aeb3fd258e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:06:49 +0100 Subject: gnu: Add rust-actix-utils-2. * gnu/packages/crates-io.scm (rust-actix-utils-2): New variable. --- gnu/packages/crates-io.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 917cb793e8..d707cccf48 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -222,6 +222,39 @@ asynchronous request/response operations.") (description "This package provides Actix thread pool for sync code.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-utils-2 + (package + (name "rust-actix-utils") + (version "2.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-utils" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0nkby6wpwcmjr3zcghd962l2hyjry0aayncyjzbx2ck6qpg2541f")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.3) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-either" ,rust-either-1) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-slab" ,rust-slab-0.4)))) + (home-page "https://actix.rs") + (synopsis "Network related services and utilities for the Actix ecosystem") + (description + "This package provides various network related services and utilities for +the Actix ecosystem.") + (license (list license:expat license:asl2.0)))) + (define-public rust-addr2line-0.11 (package (name "rust-addr2line") -- cgit v1.2.3 From 88d4cc0890c6a82e2c71859e0223ced6fe503a55 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:10:45 +0100 Subject: gnu: Add rust-actix-server-1. * gnu/packages/crates-io.scm (rust-actix-server-1): New variable. --- gnu/packages/crates-io.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d707cccf48..d8a6b1d712 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -169,6 +169,41 @@ protocols.") (description "This package provides Actix runtime.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-server-1 + (package + (name "rust-actix-server") + (version "1.0.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-server" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13khzd6pz9pqksxmw2syipfwq2gi5v9warx6pa24g8iccxp7wh25")))) + (build-system cargo-build-system) + (arguments + ;; Tests fail with "error[E0432]: unresolved import `bytes`" error. + `(#:tests? #false + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.3) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-utils" ,rust-actix-utils-2) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-mio" ,rust-mio-0.6) + ("rust-mio-uds" ,rust-mio-uds-0.6) + ("rust-num-cpus" ,rust-num-cpus-1) + ("rust-slab" ,rust-slab-0.4) + ("rust-socket2" ,rust-socket2-0.3)))) + (home-page "https://actix.rs") + (synopsis "General purpose TCP server built for the Actix ecosystem") + (description + "This package provides a general purpose TCP server built for the Actix +ecosystem.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-service-1 (package (name "rust-actix-service") -- cgit v1.2.3 From b6071e75a33b81ef3acc852082a5f8ef6ffaa111 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:17:35 +0100 Subject: gnu: Add rust-actix-testing-1. * gnu/packages/crates-io.scm (rust-actix-testing-1): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d8a6b1d712..9910bab75d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -231,6 +231,31 @@ ecosystem.") asynchronous request/response operations.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-testing-1 + (package + (name "rust-actix-testing") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-testing" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "073r3rlnz9km7w7zfhpj6snb453hhp7d354adbp79awrhyirq8s7")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-actix-macros" ,rust-actix-macros-0.1) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-server" ,rust-actix-server-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-log" ,rust-log-0.4) + ("rust-socket2" ,rust-socket2-0.3)))) + (home-page "https://actix.rs") + (synopsis "Actix testing utils") + (description "This package provides Actix testing utils.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-threadpool-0.3 (package (name "rust-actix-threadpool") -- cgit v1.2.3 From bb9236be5248cc04876a21ecca1fff1541f30dcc Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:20:17 +0100 Subject: gnu: Add rust-bytestring-0.1. * gnu/packages/crates-io.scm (rust-bytestring-0.1): New variable. --- gnu/packages/crates-io.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9910bab75d..2a35cb9f73 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4248,6 +4248,30 @@ little-endian.") #:cargo-development-inputs (("rust-rand" ,rust-rand-0.3)))))) +(define-public rust-bytestring-0.1 + (package + (name "rust-bytestring") + (version "0.1.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "bytestring" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0qzkncgky5p5vsdb9msmfg6d92dcs9idcjcr5nk7inkja7x0az7w")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-serde" ,rust-serde-1)) + #:cargo-development-inputs + (("rust-serde-json" ,rust-serde-json-1)))) + (home-page "https://actix.rs") + (synopsis "UTF-8 encoded string with Bytes as a storage") + (description + "This package provides a UTF-8 encoded string with Bytes as a storage.") + (license (list license:expat license:asl2.0)))) + (define-public rust-bzip2-0.4 (package (name "rust-bzip2") -- cgit v1.2.3 From 0122efe9b8eeb5809101e77e272d4357ba92f031 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:25:53 +0100 Subject: gnu: Add rust-actix-router-0.2. * gnu/packages/crates-io.scm (rust-actix-router-0.2): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2a35cb9f73..2e9f52f321 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -143,6 +143,32 @@ protocols.") (description "This package provides Actix runtime macros.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-router-0.2 + (package + (name "rust-actix-router") + (version "0.2.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-router" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0df2626hk4n4yki6j88v3k0gcm8pi5hdnm1mldyvyi8nvbdzgldv")))) + (build-system cargo-build-system) + (arguments + ;; Tests fail with "error[E0432]: unresolved import `serde_derive`". + `(#:tests? #false + #:cargo-inputs + (("rust-bytestring" ,rust-bytestring-0.1) + ("rust-http" ,rust-http-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-regex" ,rust-regex-1) + ("rust-serde" ,rust-serde-1)))) + (home-page "https://actix.rs") + (synopsis "Resource path matching library") + (description "This package provides resource path matching library.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-rt-1 (package (name "rust-actix-rt") -- cgit v1.2.3 From 52cc16b38b1b01b2bb354ed5510120856de15d39 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:27:41 +0100 Subject: gnu: Add rust-brotli-sys-0.3. * gnu/packages/crates-io.scm (rust-brotli-sys-0.3): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2e9f52f321..fc8e4b3177 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3786,6 +3786,27 @@ dependency on the rust stdlib. This makes it suitable for embedded devices and kernels.") (license (list license:bsd-3 license:expat)))) +(define-public rust-brotli-sys-0.3 + (package + (name "rust-brotli-sys") + (version "0.3.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "brotli-sys" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1kdfdbcba6zwa13xpjwgiplblkdf6vigxjbwwp6l2ascbylxwia4")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-cc" ,rust-cc-1) + ("rust-libc" ,rust-libc-0.2)))) + (home-page "https://github.com/alexcrichton/brotli2-rs") + (synopsis "Raw bindings to libbrotli") + (description "This package provides raw bindings to libbrotli.") + (license (list license:expat license:asl2.0)))) + (define-public rust-bs58-0.2 (package (name "rust-bs58") -- cgit v1.2.3 From 9cb973ed2f29e6dd13acbc0927fb55d9e43fb40c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 19:31:10 +0100 Subject: gnu: Add rust-brotli2-0.3. * gnu/packages/crates-io.scm (rust-brotli2-0.3): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index fc8e4b3177..3ba825331c 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -3807,6 +3807,31 @@ and kernels.") (description "This package provides raw bindings to libbrotli.") (license (list license:expat license:asl2.0)))) +(define-public rust-brotli2-0.3 + (package + (name "rust-brotli2") + (version "0.3.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "brotli2" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "13jnhpmfkqy2xar4lxrsk3rx3i12bgnarnsxq4arhc6yxb1kdc0c")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-brotli-sys" ,rust-brotli-sys-0.3) + ("rust-libc" ,rust-libc-0.2)) + #:cargo-development-inputs + (("rust-quickcheck" ,rust-quickcheck-0.4)))) + (home-page "https://github.com/alexcrichton/brotli2-rs") + (synopsis "Rust bindings to compression library libbrotli") + (description + "This package provides bindings to libbrotli to provide brotli +decompression and compression to Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-bs58-0.2 (package (name "rust-bs58") -- cgit v1.2.3 From bed6831cc094f71c443c544746b0fd73b951af27 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 21:30:52 +0100 Subject: gnu: Add rust-actix-codec-0.2. * gnu/packages/crates-io.scm (rust-actix-codec-0.2): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 3ba825331c..38de91dd70 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -118,6 +118,29 @@ library in Rust.") protocols.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-codec-0.2 + (package + (inherit rust-actix-codec-0.3) + (name "rust-actix-codec") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-codec" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "100k0n155fnnjqjz2s1gnwim2fp7s1mw942x0famg89cbh55zr89")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-sink" ,rust-futures-sink-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-util" ,rust-tokio-util-0.2)))))) + (define-public rust-actix-macros-0.1 (package (name "rust-actix-macros") -- cgit v1.2.3 From 4e9dbf6a48e109498ab6fd0a89c29e5e76242bb5 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 21:33:42 +0100 Subject: gnu: Add rust-actix-utils-1. * gnu/packages/crates-io.scm (rust-actix-utils-1): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 38de91dd70..c87dde302f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -364,6 +364,32 @@ asynchronous request/response operations.") the Actix ecosystem.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-utils-1 + (package + (inherit rust-actix-utils-2) + (name "rust-actix-utils") + (version "1.0.6") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-utils" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0kkz2hfz8r2k1gxcjk2qq1h1qxlb487g023q4v1dw6ph3dizby7w")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-either" ,rust-either-1) + ("rust-futures" ,rust-futures-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-slab" ,rust-slab-0.4)))))) + (define-public rust-addr2line-0.11 (package (name "rust-addr2line") -- cgit v1.2.3 From d1a6c1a748fd18842f045d35d3e150732cbea3bc Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 21:38:36 +0100 Subject: gnu: Add rust-actix-tls-1. * gnu/packages/crates-io.scm (rust-actix-tls-1): New variable. --- gnu/packages/crates-io.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c87dde302f..792acd52a1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -331,6 +331,44 @@ asynchronous request/response operations.") (description "This package provides Actix thread pool for sync code.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-tls-1 + (package + (name "rust-actix-tls") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-tls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1a4m96jz6vzmknpk5m803c337c6dillnqq4w71nrlphhmzxb9rd4")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-utils" ,rust-actix-utils-1) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-either" ,rust-either-1) + ("rust-futures" ,rust-futures-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio-openssl" ,rust-tokio-openssl-0.4) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.12) + ("rust-tokio-tls" ,rust-tokio-tls-0.3) + ("rust-webpki" ,rust-webpki-0.21) + ("rust-webpki-roots" ,rust-webpki-roots-0.17)) + #:cargo-development-inputs + (("rust-actix-testing" ,rust-actix-testing-1)))) + (home-page "https://actix.rs") + (synopsis "TLS acceptor services for Actix ecosystem") + (description + "This package provides TLS acceptor services for Actix ecosystem.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-utils-2 (package (name "rust-actix-utils") -- cgit v1.2.3 From c6cdfabe3d32cfa2a9a1e06d348c1e4b6176c224 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 21:41:52 +0100 Subject: gnu: Add rust-trust-dns-proto-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-proto-0.18): New variable. --- gnu/packages/crates-io.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 792acd52a1..a0660b977e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36960,6 +36960,41 @@ extension for the Trust-DNS client to use tokio-openssl for TLS.") foundational DNS protocol library for all Trust-DNS projects.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-proto-0.18 + (package + (inherit rust-trust-dns-proto-0.19) + (name "rust-trust-dns-proto") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-proto" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1vmhw7vdaa6b7wfv438f272ijjl2qlpcp6b1myvif4iay8pp4fi5")))) + (arguments + `(#:cargo-inputs + (("rust-async-trait" ,rust-async-trait-0.1) + ("rust-data-encoding" ,rust-data-encoding-2) + ("rust-enum-as-inner" ,rust-enum-as-inner-0.3) + ("rust-failure" ,rust-failure-0.1) + ("rust-futures" ,rust-futures-0.3) + ("rust-idna" ,rust-idna-0.2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-rand" ,rust-rand-0.7) + ("rust-ring" ,rust-ring-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-smallvec" ,rust-smallvec-1) + ("rust-socket2" ,rust-socket2-0.3) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-url" ,rust-url-2)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.7) + ("rust-futures" ,rust-futures-0.3) + ("rust-tokio" ,rust-tokio-0.2)))))) + (define-public rust-trust-dns-proto-0.7 (package (inherit rust-trust-dns-proto-0.19) -- cgit v1.2.3 From 98c4ebe53213d69192f8b2ec1fc9d7125f0062c1 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 21:51:11 +0100 Subject: gnu: Add rust-trust-dns-openssl-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-openssl-0.18): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index a0660b977e..7023815800 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36893,6 +36893,29 @@ extension for the Trust-DNS client to use native-tls for TLS.") extension for the Trust-DNS client to use tokio-openssl for TLS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-openssl-0.18 + (package + (inherit rust-trust-dns-openssl-0.19) + (name "rust-trust-dns-openssl") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-openssl" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1870s27ifsdh9plgcwwbxzvlw17r3dn9v6s0zfryf6kfp9hzpfz2")))) + (arguments + `(#:cargo-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-openssl" ,rust-tokio-openssl-0.4) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18)) + #:cargo-development-inputs + (("rust-openssl" ,rust-openssl-0.10) + ("rust-tokio" ,rust-tokio-0.2)))))) + (define-public rust-trust-dns-openssl-0.6 (package (inherit rust-trust-dns-openssl-0.19) -- cgit v1.2.3 From 2ff80a952e2115f24ca88d07fdb851216dd29180 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 22:01:12 +0100 Subject: gnu: Add rust-trust-dns-native-tls-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-native-tls-0.18): New variable. --- gnu/packages/crates-io.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7023815800..23e95f18df 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36837,6 +36837,28 @@ extension for the Trust-DNS client to use DNS over HTTPS.") extension for the Trust-DNS client to use native-tls for TLS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-native-tls-0.18 + (package + (inherit rust-trust-dns-native-tls-0.19) + (name "rust-trust-dns-native-tls") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-native-tls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0rcg018vdd5chd4hcmjp753qjlf4k311nmrxa5ay2hxjllzmqd1y")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;missing files + #:cargo-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-native-tls" ,rust-native-tls-0.2) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-tls" ,rust-tokio-tls-0.3) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18)))))) + (define-public rust-trust-dns-native-tls-0.6 (package (inherit rust-trust-dns-native-tls-0.19) -- cgit v1.2.3 From 0d3be912093648721873c371574a6aae4190b1bd Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 22:26:19 +0100 Subject: gnu: Add rust-trust-dns-rustls-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-rustls-0.18): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 23e95f18df..1fbf5d59d9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -37197,6 +37197,36 @@ other queries.") extension for the Trust-DNS client to use rustls for TLS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-rustls-0.18 + (package + (inherit rust-trust-dns-rustls-0.19) + (name "rust-trust-dns-rustls") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-rustls" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "19vhb0xsyr0wy4p0liwhv4rqmwv6szfmmid6439gq7wah1x1hzp4")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;missing file + #:cargo-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.12) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18) + ("rust-webpki" ,rust-webpki-0.21)) + #:cargo-development-inputs + (("rust-openssl" ,rust-openssl-0.10)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))))) + (define-public rust-trust-dns-rustls-0.6 (package (inherit rust-trust-dns-rustls-0.19) -- cgit v1.2.3 From eba03b51b9be745c5d9af5eb089e12ca16acc329 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 22:26:41 +0100 Subject: gnu: Add rust-trust-dns-https-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-https-0.18): New variable. --- gnu/packages/crates-io.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 1fbf5d59d9..20e29ec1c5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -36770,6 +36770,40 @@ application authors using tracing to instrument their applications.") extension for the Trust-DNS client to use DNS over HTTPS.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-https-0.18 + (package + (inherit rust-trust-dns-https-0.19) + (name "rust-trust-dns-https") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-https" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "03dapd5larsjlpk6mr4xnm2sb0h7l6dg988wjnaxd8zfi5swq5nl")))) + (arguments + `(#:tests? #false ;network unreachable + #:cargo-inputs + (("rust-bytes" ,rust-bytes-0.5) + ("rust-data-encoding" ,rust-data-encoding-2) + ("rust-failure" ,rust-failure-0.1) + ("rust-futures" ,rust-futures-0.3) + ("rust-h2" ,rust-h2-0.2) + ("rust-http" ,rust-http-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.12) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18) + ("rust-trust-dns-rustls" ,rust-trust-dns-rustls-0.18) + ("rust-typed-headers" ,rust-typed-headers-0.2) + ("rust-webpki" ,rust-webpki-0.21) + ("rust-webpki-roots" ,rust-webpki-roots-0.18)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.7) + ("rust-futures" ,rust-futures-0.3)))))) + (define-public rust-trust-dns-https-0.3 (package (inherit rust-trust-dns-https-0.19) -- cgit v1.2.3 From 0cc9efb0520d5db15fc0b2ab757bc814f2c579c2 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 22:29:04 +0100 Subject: gnu: Add rust-trust-dns-resolver-0.18. * gnu/packages/crates-io.scm (rust-trust-dns-resolver-0.18): New variable. --- gnu/packages/crates-io.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 20e29ec1c5..0eccda1ae3 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -37166,6 +37166,44 @@ and AsyncResolver for supported resolution types. The Client can be used for other queries.") (license (list license:expat license:asl2.0)))) +(define-public rust-trust-dns-resolver-0.18 + (package + (inherit rust-trust-dns-resolver-0.19) + (name "rust-trust-dns-resolver") + (version "0.18.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "trust-dns-resolver" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0cldg6y937il4kjk7rirgfhmk0chz41w7qys9h96skaznh4dzmvj")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;network unreachable + #:cargo-inputs + (("rust-cfg-if" ,rust-cfg-if-0.1) + ("rust-failure" ,rust-failure-0.1) + ("rust-futures" ,rust-futures-0.3) + ("rust-ipconfig" ,rust-ipconfig-0.2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-lru-cache" ,rust-lru-cache-0.1) + ("rust-resolv-conf" ,rust-resolv-conf-0.6) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-smallvec" ,rust-smallvec-1) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-trust-dns-https" ,rust-trust-dns-https-0.18) + ("rust-trust-dns-native-tls" ,rust-trust-dns-native-tls-0.18) + ("rust-trust-dns-openssl" ,rust-trust-dns-openssl-0.18) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18) + ("rust-trust-dns-rustls" ,rust-trust-dns-rustls-0.18) + ("rust-webpki-roots" ,rust-webpki-roots-0.18)) + #:cargo-development-inputs + (("rust-env-logger" ,rust-env-logger-0.7) + ("rust-futures" ,rust-futures-0.3)))))) + (define-public rust-trust-dns-resolver-0.11 (package (inherit rust-trust-dns-resolver-0.19) -- cgit v1.2.3 From 4d5ac43b89594fe5673cc539f251e9a1927a8563 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 22 Dec 2020 22:44:18 +0100 Subject: gnu: rust-trust-dns-rustls-0.19: Fix build. * gnu/packages/crates-io.scm (rust-trust-dns-rustls-0.19)[arguments]: Disable tests. [native-inputs]: Add pkg-config. [inputs]: Add openssl. * gnu/packages/crates-io.scm (rust-trust-dns-rustls-0.18)[native-inputs, inputs]: Remove, since they are now inherited. --- gnu/packages/crates-io.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0eccda1ae3..0879704a3e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -37253,7 +37253,8 @@ other queries.") "1hj4fx2x4ncj7v8pf6bbn7634zq76hjigm1s2h6b6yjzzmz4yprn")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:tests? #false ;missing file + #:cargo-inputs (("rust-futures" ,rust-futures-0.3) ("rust-log" ,rust-log-0.4) ("rust-rustls" ,rust-rustls-0.17) @@ -37263,6 +37264,10 @@ other queries.") ("rust-webpki" ,rust-webpki-0.21)) #:cargo-development-inputs (("rust-openssl" ,rust-openssl-0.10)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("openssl" ,openssl))) (home-page "http://www.trust-dns.org/index.html") (synopsis "rustls extension for the Trust-DNS client") (description "Trust-DNS is a safe and secure DNS library. This is an @@ -37293,11 +37298,7 @@ extension for the Trust-DNS client to use rustls for TLS.") ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18) ("rust-webpki" ,rust-webpki-0.21)) #:cargo-development-inputs - (("rust-openssl" ,rust-openssl-0.10)))) - (native-inputs - `(("pkg-config" ,pkg-config))) - (inputs - `(("openssl" ,openssl))))) + (("rust-openssl" ,rust-openssl-0.10)))))) (define-public rust-trust-dns-rustls-0.6 (package -- cgit v1.2.3 From 7d00f7d79d85258c1440317adf22df6f81e9a75a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 23 Dec 2020 11:01:37 +0100 Subject: gnu: Add rust-actix-connect-1. * gnu/packages/crates-io.scm (rust-actix-connect-1): New variable. --- gnu/packages/crates-io.scm | 50 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 0879704a3e..9874ecefd4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -141,6 +141,56 @@ protocols.") ("rust-tokio" ,rust-tokio-0.2) ("rust-tokio-util" ,rust-tokio-util-0.2)))))) +(define-public rust-actix-connect-1 + (package + (name "rust-actix-connect") + (version "1.0.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-connect" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0v77m394gzbrrzg12xkqgli11vwhig0zcxy3yhmq1s91j9bcjp69")))) + (build-system cargo-build-system) + (arguments + ;; XXX: The crate fails to't build with: "error[E0432]: unresolved import + ;; `trust_dns_resolver::Background`". I assume it really expects + ;; trust-dns-resolver at version 0.18-alpha.2, which we do not provide. + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-utils" ,rust-actix-utils-1) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-either" ,rust-either-1) + ("rust-futures" ,rust-futures-0.3) + ("rust-http" ,rust-http-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-tokio-openssl" ,rust-tokio-openssl-0.4) + ("rust-tokio-rustls" ,rust-tokio-rustls-0.12) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.18) + ("rust-trust-dns-resolver" ,rust-trust-dns-resolver-0.18) + ("rust-webpki" ,rust-webpki-0.21)) + #:cargo-development-inputs + (("rust-actix-testing" ,rust-actix-testing-1)) + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-version-requirements + (lambda _ + (substitute* "Cargo.toml" + (("0.18.0-alpha.2") + ,(package-version rust-trust-dns-proto-0.18))) + #t))))) + (home-page "https://actix.rs") + (synopsis "TCP connector service for Actix ecosystem") + (description + "This package provides a TCP connector service for Actix ecosystem.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-macros-0.1 (package (name "rust-actix-macros") -- cgit v1.2.3 From 7370231e248922141585fb57ad9edaa92cf1d72e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 10:21:40 +0100 Subject: gnu: Add rust-actix-derive-0.5. * gnu/packages/crates-io.scm (rust-actix-derive-0.5): New variable. --- gnu/packages/crates-io.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9874ecefd4..222d2feb55 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -191,6 +191,33 @@ protocols.") "This package provides a TCP connector service for Actix ecosystem.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-derive-0.5 + (package + (name "rust-actix-derive") + (version "0.5.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-derive" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0k1kg4gkp2jhi5fgdfd0cq2qfbyy3gfgwqjrvzq1hzrjmynwwnmr")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #true ;bootsrapping issues with rust-actix + #:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + ;; #:cargo-development-inputs + ;; (("rust-actix" ,rust-actix-0.8)) + )) + (home-page "https://github.com/actix/actix-derive/") + (synopsis "Proc macros for Actix Rust actor framework") + (description + "This package provides proc macros for the Rust actor framework Actix.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-macros-0.1 (package (name "rust-actix-macros") -- cgit v1.2.3 From c859c76e473bdfc68a5a7139906da4f763219d81 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 10:53:56 +0100 Subject: gnu: Add rust-actix-0.10. * gnu/packages/crates-io.scm (rust-actix-0.10): New variable. --- gnu/packages/crates-io.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 222d2feb55..c00c0a2ed5 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -89,6 +89,43 @@ library in Rust.") (license license:expat))) +(define-public rust-actix-0.10 + (package + (name "rust-actix") + (version "0.10.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0q6cd08d0xikilj9l3gfsyhva5b91y55lfxy7yd7w7ivizw43qhv")))) + (build-system cargo-build-system) + (arguments + `(#:tests? #false ;doc test fails + #:cargo-inputs + (("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-derive" ,rust-actix-derive-0.5) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.4) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-parking-lot" ,rust-parking-lot-0.11) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-smallvec" ,rust-smallvec-1) + ("rust-tokio" ,rust-tokio-0.2) + ("rust-tokio-util" ,rust-tokio-util-0.3) + ("rust-trust-dns-proto" ,rust-trust-dns-proto-0.19) + ("rust-trust-dns-resolver" ,rust-trust-dns-resolver-0.19)))) + (home-page "https://actix.rs") + (synopsis "Actor framework for Rust") + (description "This package provides Actix actor framework for Rust.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-codec-0.3 (package (name "rust-actix-codec") -- cgit v1.2.3 From 03487c3595f2ec95f0a486a82933a007cfa6a7d8 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 11:43:48 +0100 Subject: gnu: Add rust-actix-web-2. * gnu/packages/crates-io.scm (rust-actix-http-1): (rust-actix-http-test-1): (rust-actix-web-2): (rust-actix-web-codegen-0.2): (rust-awc-1): New variable. --- gnu/packages/crates-io.scm | 238 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 238 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c00c0a2ed5..95f0a725d6 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -255,6 +255,120 @@ protocols.") "This package provides proc macros for the Rust actor framework Actix.") (license (list license:expat license:asl2.0)))) +(define-public rust-actix-http-1 + (package + (name "rust-actix-http") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-http" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "06chrs9asbxmxzgiw5sw7ky97yrin9g88nmd6w407a6y9z668rn1")))) + (build-system cargo-build-system) + ;; XXX: The crate fails to't build with with the same error as + ;; rust-actix-connect. Skip build for now. + (arguments + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-connect" ,rust-actix-connect-1) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-threadpool" ,rust-actix-threadpool-0.3) + ("rust-actix-tls" ,rust-actix-tls-1) + ("rust-actix-utils" ,rust-actix-utils-1) + ("rust-base64" ,rust-base64-0.11) + ("rust-bitflags" ,rust-bitflags-1) + ("rust-brotli2" ,rust-brotli2-0.3) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-copyless" ,rust-copyless-0.1) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-either" ,rust-either-1) + ("rust-encoding-rs" ,rust-encoding-rs-0.8) + ("rust-failure" ,rust-failure-0.1) + ("rust-flate2" ,rust-flate2-1) + ("rust-futures-channel" ,rust-futures-channel-0.3) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-fxhash" ,rust-fxhash-0.2) + ("rust-h2" ,rust-h2-0.2) + ("rust-http" ,rust-http-0.2) + ("rust-httparse" ,rust-httparse-1) + ("rust-indexmap" ,rust-indexmap-1) + ("rust-language-tags" ,rust-language-tags-0.2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-log" ,rust-log-0.4) + ("rust-mime" ,rust-mime-0.3) + ("rust-percent-encoding" ,rust-percent-encoding-2) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-rand" ,rust-rand-0.7) + ("rust-regex" ,rust-regex-1) + ("rust-ring" ,rust-ring-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.6) + ("rust-sha1" ,rust-sha1-0.6) + ("rust-slab" ,rust-slab-0.4) + ("rust-time" ,rust-time-0.1)) + #:cargo-development-inputs + (("rust-actix-http-test" ,rust-actix-http-test-1)))) + (home-page "https://actix.rs") + (synopsis "HTTP primitives for the Actix ecosystem") + (description + "This package provides HTTP primitives for the Actix ecosystem.") + (license (list license:expat license:asl2.0)))) + +(define-public rust-actix-http-test-1 + (package + (name "rust-actix-http-test") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-http-test" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "06z6iy9ffsjcw3g8zwwghky5zpyg7c1z823x35lgc4y1yjzxfizq")))) + (build-system cargo-build-system) + (arguments + ;; XXX: The crate fails to't build with with the same error as + ;; rust-actix-connect. Skip build for now. + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-connect" ,rust-actix-connect-1) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-server" ,rust-actix-server-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-testing" ,rust-actix-testing-1) + ("rust-actix-utils" ,rust-actix-utils-1) + ("rust-awc" ,rust-awc-1) + ("rust-base64" ,rust-base64-0.11) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-env-logger" ,rust-env-logger-0.6) + ("rust-futures" ,rust-futures-0.3) + ("rust-http" ,rust-http-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-net2" ,rust-net2-0.2) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.6) + ("rust-sha1" ,rust-sha1-0.6) + ("rust-slab" ,rust-slab-0.4) + ("rust-time" ,rust-time-0.1)) + #:cargo-development-inputs + (("rust-actix-http" ,rust-actix-http-1)))) + (home-page "https://actix.rs") + (synopsis "Helpers for Actix applications to use during testing") + (description + "This package provides various helpers for Actix applications to use +during testing.") + (license (list license:expat license:asl2.0)))) + (define-public rust-actix-macros-0.1 (package (name "rust-actix-macros") @@ -542,6 +656,85 @@ the Actix ecosystem.") ("rust-pin-project" ,rust-pin-project-0.4) ("rust-slab" ,rust-slab-0.4)))))) +(define-public rust-actix-web-2 + (package + (name "rust-actix-web") + (version "2.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-web" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0dgnn7xiw2yhvrx7l7b57gwra7yfqawka5xz1lpq4h0h8qifhn1i")))) + (build-system cargo-build-system) + (arguments + ;; XXX: The crate fails to't build with with the same error as + ;; rust-actix-connect. Skip build for now. + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-http" ,rust-actix-http-1) + ("rust-actix-macros" ,rust-actix-macros-0.1) + ("rust-actix-router" ,rust-actix-router-0.2) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-server" ,rust-actix-server-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-actix-testing" ,rust-actix-testing-1) + ("rust-actix-threadpool" ,rust-actix-threadpool-0.3) + ("rust-actix-tls" ,rust-actix-tls-1) + ("rust-actix-utils" ,rust-actix-utils-1) + ("rust-actix-web-codegen" ,rust-actix-web-codegen-0.2) + ("rust-awc" ,rust-awc-1) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-encoding-rs" ,rust-encoding-rs-0.8) + ("rust-futures" ,rust-futures-0.3) + ("rust-fxhash" ,rust-fxhash-0.2) + ("rust-log" ,rust-log-0.4) + ("rust-mime" ,rust-mime-0.3) + ("rust-net2" ,rust-net2-0.2) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-pin-project" ,rust-pin-project-0.4) + ("rust-regex" ,rust-regex-1) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.6) + ("rust-time" ,rust-time-0.1) + ("rust-url" ,rust-url-2)))) + (home-page "https://actix.rs") + (synopsis "Powerful, pragmatic, and fast web framework for Rust") + (description + "Actix Web is a powerful, pragmatic, and fast web framework for +Rust.") + (license (list license:expat license:asl2.0)))) + +(define-public rust-actix-web-codegen-0.2 + (package + (name "rust-actix-web-codegen") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "actix-web-codegen" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0rjpzwsm51nfjqsz269jwbkiic9d454bnsk9ng882wp0rdsz86x7")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1) + ("rust-syn" ,rust-syn-1)) + #:cargo-development-inputs + (("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-web" ,rust-actix-web-2)))) + (home-page "https://actix.rs") + (synopsis "Actix web proc macros") + (description "This package provides Actix web proc macros.") + (license (list license:expat license:asl2.0)))) + (define-public rust-addr2line-0.11 (package (name "rust-addr2line") @@ -2489,6 +2682,51 @@ in Rust.") ("rust-serde-json" ,rust-serde-json-1) ("rust-streaming-stats" ,rust-streaming-stats-0.2)))))) +(define-public rust-awc-1 + (package + (name "rust-awc") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "awc" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1idacmq7n3irmdjkbxc5kdwspxk9w1gip94pcmfk7wky3m6isq6p")))) + (build-system cargo-build-system) + ;; XXX: The crate fails to't build with with the same error as + ;; rust-actix-connect. Skip build for now. + (arguments + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-codec" ,rust-actix-codec-0.2) + ("rust-actix-http" ,rust-actix-http-1) + ("rust-actix-rt" ,rust-actix-rt-1) + ("rust-actix-service" ,rust-actix-service-1) + ("rust-base64" ,rust-base64-0.11) + ("rust-bytes" ,rust-bytes-0.5) + ("rust-derive-more" ,rust-derive-more-0.99) + ("rust-futures-core" ,rust-futures-core-0.3) + ("rust-log" ,rust-log-0.4) + ("rust-mime" ,rust-mime-0.3) + ("rust-openssl" ,rust-openssl-0.10) + ("rust-percent-encoding" ,rust-percent-encoding-2) + ("rust-rand" ,rust-rand-0.7) + ("rust-rustls" ,rust-rustls-0.16) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.6)) + #:cargo-development-inputs + (("rust-actix-http-test" ,rust-actix-http-test-1) + ("rust-actix-web" ,rust-actix-web-2) + ("rust-brotli" ,rust-brotli-3)))) + (home-page "https://actix.rs") + (synopsis "Async HTTP and WebSocket client library") + (description + "This package provides async HTTP and WebSocket client library +built on the Actix ecosystem.") + (license (list license:expat license:asl2.0)))) + (define-public rust-az-1 (package (name "rust-az") -- cgit v1.2.3 From c3af32acb9b2febcf8a04fa2b5d1204f37abe594 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 11:50:06 +0100 Subject: gnu: Add rust-infer-0.2. * gnu/packages/crates-io.scm (rust-infer-0.2): New variable. --- gnu/packages/crates-io.scm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 95f0a725d6..17c96b9515 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -15503,6 +15503,26 @@ or numerical index. A corresponding hash set type is also provided.") Rust.") (license license:expat))) +(define-public rust-infer-0.2 + (package + (name "rust-infer") + (version "0.2.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "infer" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1b4ziqcv0d1wga5yfqf620dkgzijsdw3ylnzq61bfaxla2d85sb4")))) + (build-system cargo-build-system) + (arguments `(#:tests? #false)) ;missing files + (home-page "https://github.com/bojand/infer") + (synopsis "Infer file types based on its magic number signature") + (description + "This crate infers a file types based on its magic number +signature.") + (license license:expat))) + (define-public rust-inflate-0.4 (package (name "rust-inflate") -- cgit v1.2.3 From f78b1a62d218d09e90a8da3e141a05bb80ea47fe Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 11:50:52 +0100 Subject: gnu: rust-csv-1.1: Update to 1.1.5. * gnu/packages/crates-io.scm (rust-csv-1.1): Update to 1.1.5. --- gnu/packages/crates-io.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 17c96b9515..38ccb44d4b 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7729,7 +7729,7 @@ reallocations.") (define-public rust-csv-1.1 (package (name "rust-csv") - (version "1.1.3") + (version "1.1.5") (source (origin (method url-fetch) @@ -7738,7 +7738,7 @@ reallocations.") (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0yd2z55m2pg4al4yng4nl2y7c9dw2v7yhg5ynihxyrmmd9zzxbq0")))) + "15wydz6klf1shh1ac5n6rsihc4xrz1lzi8vjmhava94v54rqdmgr")))) (build-system cargo-build-system) (arguments `(#:skip-build? #t -- cgit v1.2.3 From 6e83fcd18630bd435c98fd1797a55d3849fda6ec Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 11:54:43 +0100 Subject: gnu: rust-csv: Do not skip build. * gnu/packages/crates-io.scm (rust-csv-1.1)[arguments]: Do not skip build. --- gnu/packages/crates-io.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 38ccb44d4b..626ce3e9c1 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7741,8 +7741,7 @@ reallocations.") "15wydz6klf1shh1ac5n6rsihc4xrz1lzi8vjmhava94v54rqdmgr")))) (build-system cargo-build-system) (arguments - `(#:skip-build? #t - #:cargo-inputs + `(#:cargo-inputs (("rust-bstr" ,rust-bstr-0.2) ("rust-csv-core" ,rust-csv-core-0.1) ("rust-itoa" ,rust-itoa-0.4) -- cgit v1.2.3 From 848cfe93d1578edf5ae5aa9fca0dbc71eb561bd3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 11:56:34 +0100 Subject: gnu: Add rust-serde-qs-0.7. * gnu/packages/crates-io.scm (rust-serde-qs-0.7): New variable. --- gnu/packages/crates-io.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 626ce3e9c1..08e10a2418 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -30651,6 +30651,41 @@ for the serde framework.") "Macros to auto-generate implementations for the serde framework.") (license (list license:expat license:asl2.0)))) +(define-public rust-serde-qs-0.7 + (package + (name "rust-serde-qs") + (version "0.7.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "serde_qs" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1jz6gpr02d393f8cwdxbgfl3jhx5svr1z5ilxhdh16slqvijvy2s")))) + (build-system cargo-build-system) + (arguments + ;; XXX: The crate fails to't build with with the same error as + ;; rust-actix-connect. Skip build for now. + `(#:skip-build? #true + #:cargo-inputs + (("rust-actix-web" ,rust-actix-web-2) + ("rust-data-encoding" ,rust-data-encoding-2) + ("rust-futures" ,rust-futures-0.3) + ("rust-percent-encoding" ,rust-percent-encoding-2) + ("rust-serde" ,rust-serde-1) + ("rust-thiserror" ,rust-thiserror-1)) + #:cargo-development-inputs + (("rust-csv" ,rust-csv-1.1) + ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.7)))) + (home-page "https://github.com/samscott89/serde_qs") + (synopsis "Querystrings for Serde") + (description + "This crate is a Rust library for serialising to and deserialising from +querystrings. This crate is designed to extend @code{serde_urlencoded} when +using nested parameters, similar to those used by @code{qs} for Node, and +commonly used by Ruby on Rails via Rack.") + (license (list license:expat license:asl2.0)))) + (define-public rust-serde-stacker-0.1 (package (name "rust-serde-stacker") -- cgit v1.2.3 From ddd9471c23d8c0d8f74eb95a21f97233a4262ab5 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 12:09:02 +0100 Subject: gnu: Add rust-simple-mutex-1. * gnu/packages/crates-io.scm (rust-simple-mutex-1): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 08e10a2418..d5512ea731 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31750,6 +31750,32 @@ CPUs, as well as raw interfaces to platform-specific instructions. "This package provides helpers to write more compact simd code.") (license license:expat))) +(define-public rust-simple-mutex-1 + (package + (name "rust-simple-mutex") + (version "1.1.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "simple-mutex" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1mnwlgjajqmxjfgsdcr9imf23yg1zblny95zrvcflvbgzbmbpaiq")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-event-listener" ,rust-event-listener-2)) + #:cargo-development-inputs + (("rust-parking-lot" ,rust-parking-lot-0.10)))) + (home-page "https://github.com/stjepang/simple-mutex") + (synopsis + "Mutex more efficient than @code{std} and simpler than +@code{parking_lot}") + (description + "This package provides a mutex more efficient than @code{std} and +simpler than @code{parking_lot}.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-siphasher-0.3 (package (name "rust-siphasher") -- cgit v1.2.3 From 29d8b1f4b26db3b3560de2e6ec4efd7c39646366 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 12:11:56 +0100 Subject: gnu: Add rust-async-dup-1. * gnu/packages/crates-io.scm (rust-async-dup-1): New variable. --- gnu/packages/crates-io.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d5512ea731..6ed63770a7 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1991,6 +1991,34 @@ Rust.") and Rust's modern asynchronous IO types.") (license (list license:expat license:asl2.0)))) +(define-public rust-async-dup-1 + (package + (name "rust-async-dup") + (version "1.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "async-dup" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0z3grxarv9wpck6jm31qayib9barf12a47gvii9934n0ilms29vl")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-futures-io" ,rust-futures-io-0.3) + ("rust-simple-mutex" ,rust-simple-mutex-1)) + #:cargo-development-inputs + (("rust-futures" ,rust-futures-0.3) + ("rust-smol" ,rust-smol-0.1)))) + (home-page "https://github.com/stjepang/async-dup") + (synopsis "Duplicate an async I/O handle") + (description + "This crate provides two tools, Arc and Mutex. Arc implements +AsyncRead, AsyncWrite, and AsyncSeek if a reference to the inner type +does. A reference to Mutex implements AsyncRead, AsyncWrite, and +AsyncSeek if the inner type does.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-async-executor-1 (package (name "rust-async-executor") -- cgit v1.2.3 From 3e5c122a0462429e4616b1d38b41b1ace4e07a7c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Thu, 24 Dec 2020 12:13:23 +0100 Subject: gnu: Add rust-byte-pool-0.2. * gnu/packages/crates-io.scm (rust-byte-pool-0.2): New variable. --- gnu/packages/crates-io.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 6ed63770a7..9b972c3a81 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -4471,6 +4471,29 @@ constants from build.rs or a script.") (("rust-criterion" ,rust-criterion-0.2) ("rust-quickcheck" ,rust-quickcheck-0.8)))))) +(define-public rust-byte-pool-0.2 + (package + (name "rust-byte-pool") + (version "0.2.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "byte-pool" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0yh96ral0pni02bzm3fhvicp1ixz1hz3c5m03hsyq66mk61fjf0y")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs + (("rust-crossbeam-queue" ,rust-crossbeam-queue-0.2) + ("rust-stable-deref-trait" ,rust-stable-deref-trait-1)))) + (home-page "https://crates.io/crates/byte-pool") + (synopsis "Pool of byte slices, for efficient memory usage") + (description + "This package provides a pool of byte slices, for efficient +memory usage.") + (license (list license:asl2.0 license:expat)))) + (define-public rust-byte-tools-0.3 (package (name "rust-byte-tools") -- cgit v1.2.3 From 87c670ae638b1cfe142242fd0a64697753162962 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 30 Dec 2020 19:41:17 +0100 Subject: gnu: Add rust-portpicker-0.1. * gnu/packages/crates-io.scm (rust-portpicker-0.1): New variable. --- gnu/packages/crates-io.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 9b972c3a81..47f83aa43d 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24328,6 +24328,27 @@ for constructing a Message Authentication Code (MAC).") overloading without macros in Rust.") (license license:expat))) +(define-public rust-portpicker-0.1 + (package + (name "rust-portpicker") + (version "0.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "portpicker" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1fgb5pdayxy5nlx1lh60r7gx7wx45zza802w8hwhkq3gq42psjav")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-inputs (("rust-rand" ,rust-rand-0.6)))) + (home-page "https://github.com/Dentosal/portpicker-rs") + (synopsis "Pick a free unused port") + (description + "This crate provides picks a free port, that is unused on both TCP and +UDP.") + (license license:unlicense))) + (define-public rust-ppv-lite86-0.2 (package (name "rust-ppv-lite86") -- cgit v1.2.3 From ff1a9f0d17e966746ab84ebf26e1f7e196a2bf12 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 6 Jan 2021 18:34:22 +0100 Subject: gnu: rust-csv-1: Remove minor version from name. * gnu/packages/crates-io.scm (rust-csv-1): Remove minor version from name. (rust-aho-corasick-0.6): (rust-criterion-0.3): (rust-criterion-0.2): (rust-csv-0.14): (rust-prettytable-rs-0.8): (rust-rusqlite-0.24): (rust-rusqlite-0.23): (rust-serde-qs-0.7): (rust-x86-0.33): Apply removal. --- gnu/packages/crates-io.scm | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 47f83aa43d..57556f773a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1142,7 +1142,7 @@ using AES-NI for high performance.") `(#:cargo-inputs (("rust-memchr" ,rust-memchr-2)) #:cargo-development-inputs - (("rust-csv" ,rust-csv-1.1) + (("rust-csv" ,rust-csv-1) ("rust-docopt" ,rust-docopt-1.1) ("rust-memmap" ,rust-memmap-0.6) ("rust-quickcheck" ,rust-quickcheck-0.7) @@ -7047,7 +7047,7 @@ to @code{is_x86_feature_detected}.") ("rust-cast" ,rust-cast-0.2) ("rust-clap" ,rust-clap-2) ("rust-criterion-plot" ,rust-criterion-plot-0.4) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-itertools" ,rust-itertools-0.9) ("rust-lazy-static" ,rust-lazy-static-1) ("rust-num-traits" ,rust-num-traits-0.2) @@ -7092,7 +7092,7 @@ to @code{is_x86_feature_detected}.") ("rust-cast" ,rust-cast-0.2) ("rust-clap" ,rust-clap-2) ("rust-criterion-plot" ,rust-criterion-plot-0.3) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-itertools" ,rust-itertools-0.8) ("rust-lazy-static" ,rust-lazy-static-1) ("rust-libc" ,rust-libc-0.2) @@ -7777,7 +7777,7 @@ reallocations.") ("rust-quote" ,rust-quote-1) ("rust-syn" ,rust-syn-1)))))) -(define-public rust-csv-1.1 +(define-public rust-csv-1 (package (name "rust-csv") (version "1.1.5") @@ -7808,7 +7808,7 @@ reallocations.") (define-public rust-csv-0.14 (package - (inherit rust-csv-1.1) + (inherit rust-csv-1) (name "rust-csv") (version "0.14.7") (source @@ -24680,7 +24680,7 @@ replacements, adding colorful diffs.") (arguments `(#:cargo-inputs (("rust-atty" ,rust-atty-0.2) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-encode-unicode" ,rust-encode-unicode-0.3) ("rust-lazy-static" ,rust-lazy-static-1) ("rust-term" ,rust-term-0.5) @@ -27824,7 +27824,7 @@ console applications.") (("rust-bitflags" ,rust-bitflags-1) ("rust-byteorder" ,rust-byteorder-1) ("rust-chrono" ,rust-chrono-0.4) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-fallible-iterator" ,rust-fallible-iterator-0.2) ("rust-fallible-streaming-iterator" ,rust-fallible-streaming-iterator-0.1) @@ -27877,7 +27877,7 @@ console applications.") (("rust-bitflags" ,rust-bitflags-1) ("rust-byteorder" ,rust-byteorder-1) ("rust-chrono" ,rust-chrono-0.4) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-fallible-iterator" ,rust-fallible-iterator-0.2) ("rust-fallible-streaming-iterator" ,rust-fallible-streaming-iterator-0.1) @@ -30747,7 +30747,7 @@ for the serde framework.") ("rust-serde" ,rust-serde-1) ("rust-thiserror" ,rust-thiserror-1)) #:cargo-development-inputs - (("rust-csv" ,rust-csv-1.1) + (("rust-csv" ,rust-csv-1) ("rust-serde-urlencoded" ,rust-serde-urlencoded-0.7)))) (home-page "https://github.com/samscott89/serde_qs") (synopsis "Querystrings for Serde") @@ -40618,7 +40618,7 @@ API.") #:cargo-inputs (("rust-bit-field" ,rust-bit-field-0.10) ("rust-bitflags" ,rust-bitflags-1) - ("rust-csv" ,rust-csv-1.1) + ("rust-csv" ,rust-csv-1) ("rust-phf" ,rust-phf-0.7) ("rust-phf-codegen" ,rust-phf-codegen-0.7) ("rust-raw-cpuid" ,rust-raw-cpuid-8) -- cgit v1.2.3 From 3d3185b54448cb44fffc1badc8c1cf51bb76585d Mon Sep 17 00:00:00 2001 From: Brice Waegeneire Date: Sat, 4 Jul 2020 20:54:29 +0200 Subject: services: kernel-module-loader: Return a single 'shepherd-service'. * gnu/services/linux.scm (kernel-module-loader-shepherd-service): Return a 'shepherd-service' instead of a list of it. (kernel-module-loader-service-type): Adjust it. Signed-off-by: Danny Milosavljevic --- gnu/services/linux.scm | 59 +++++++++++++++++++++++++------------------------- 1 file changed, 29 insertions(+), 30 deletions(-) diff --git a/gnu/services/linux.scm b/gnu/services/linux.scm index 72c7779596..1046a7e0c2 100644 --- a/gnu/services/linux.scm +++ b/gnu/services/linux.scm @@ -147,35 +147,34 @@ representation." (define kernel-module-loader-shepherd-service (match-lambda ((and (? list? kernel-modules) ((? string?) ...)) - (list - (shepherd-service - (documentation "Load kernel modules.") - (provision '(kernel-module-loader)) - (requirement '(file-systems)) - (one-shot? #t) - (modules `((srfi srfi-1) - (srfi srfi-34) - (srfi srfi-35) - (rnrs io ports) - ,@%default-modules)) - (start - #~(lambda _ - (cond - ((null? '#$kernel-modules) #t) - ((file-exists? "/proc/sys/kernel/modprobe") - (let ((modprobe (call-with-input-file - "/proc/sys/kernel/modprobe" get-line))) - (guard (c ((message-condition? c) - (format (current-error-port) "~a~%" - (condition-message c)) - #f)) - (every (lambda (module) - (invoke/quiet modprobe "--" module)) - '#$kernel-modules)))) - (else - (format (current-error-port) "error: ~a~%" - "Kernel is missing loadable module support.") - #f))))))))) + (shepherd-service + (documentation "Load kernel modules.") + (provision '(kernel-module-loader)) + (requirement '(file-systems)) + (one-shot? #t) + (modules `((srfi srfi-1) + (srfi srfi-34) + (srfi srfi-35) + (rnrs io ports) + ,@%default-modules)) + (start + #~(lambda _ + (cond + ((null? '#$kernel-modules) #t) + ((file-exists? "/proc/sys/kernel/modprobe") + (let ((modprobe (call-with-input-file + "/proc/sys/kernel/modprobe" get-line))) + (guard (c ((message-condition? c) + (format (current-error-port) "~a~%" + (condition-message c)) + #f)) + (every (lambda (module) + (invoke/quiet modprobe "--" module)) + '#$kernel-modules)))) + (else + (format (current-error-port) "error: ~a~%" + "Kernel is missing loadable module support.") + #f)))))))) (define kernel-module-loader-service-type (service-type @@ -183,7 +182,7 @@ representation." (description "Load kernel modules.") (extensions (list (service-extension shepherd-root-service-type - kernel-module-loader-shepherd-service))) + (compose list kernel-module-loader-shepherd-service)))) (compose concatenate) (extend append) (default-value '()))) -- cgit v1.2.3 From 4e2a7cc12fe578f2631ee2f4f40e402e9eaa58f7 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 21:22:55 +0200 Subject: gnu: python-curtsies: Update to 0.3.4. * gnu/packages/terminals.scm (python-curtsies): Update to 0.3.4. [home-page]: Update to new home-page. (python2-curtsies): Remove variable. --- gnu/packages/terminals.scm | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index b313c806cb..74e1937bbc 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2016 Mckinley Olsen ;;; Copyright © 2016, 2017, 2019 Alex Griffin ;;; Copyright © 2016 David Craven @@ -932,14 +932,14 @@ than a terminal.") (define-public python-curtsies (package (name "python-curtsies") - (version "0.2.11") + (version "0.3.4") (source (origin (method url-fetch) (uri (pypi-uri "curtsies" version)) (sha256 (base32 - "1vljmw3sy6lrqahhpyg4gk13mzcx3mwhvg8s41698ms3cpgkjipc")))) + "019bpf5wmng4f6ic2ykg893ypfihpfvzi6dhblcagfwbincl79ac")))) (build-system python-build-system) (arguments `(#:phases @@ -954,7 +954,7 @@ than a terminal.") `(("python-mock" ,python-mock) ("python-pyte" ,python-pyte) ("python-nose" ,python-nose))) - (home-page "https://github.com/thomasballinger/curtsies") + (home-page "https://github.com/bpython/curtsies") (synopsis "Library for curses-like terminal interaction with colored strings") (description "Curtsies is a Python library for interacting with the @@ -962,9 +962,6 @@ terminal. It features string-like objects which carry formatting information, per-line fullscreen terminal rendering, and keyboard input event reporting.") (license license:expat))) -(define-public python2-curtsies - (package-with-python2 python-curtsies)) - (define-public tmate (package (name "tmate") -- cgit v1.2.3 From 1379bb2009ec8be14c722b296b78ed79ce241e19 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 6 Jan 2021 21:31:45 +0200 Subject: gnu: bpython: Update to 0.20.1. * gnu/packages/python-xyz.scm (bpython): Update to 0.20.1. [propagated-inputs]: Remove python-babel. Add python-wcwidth, python-watchdog, python-jedi. --- gnu/packages/python-xyz.scm | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index ab10668a01..23e43b7e75 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2015, 2016, 2017, 2019 Leo Famulari ;;; Copyright © 2015, 2017 Ben Woodcroft ;;; Copyright © 2015, 2016 Erik Edrosa -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2015, 2017, 2020 Kyle Meyer ;;; Copyright © 2015, 2016 Chris Marusich ;;; Copyright © 2016 Danny Milosavljevic @@ -18236,13 +18236,13 @@ Included are implementations of: (define-public bpython (package (name "bpython") - (version "0.18") + (version "0.20.1") (source (origin (method url-fetch) (uri (pypi-uri "bpython" version)) (sha256 - (base32 "1hl6frgvr2lqaxqczl8amg9xih32b3gzv429vs0qrjb8wpdj1k2n")))) + (base32 "00vmkkc79mlnkyvwww1cr7bpwmf4p61704dhayz6kd0kc203hxvf")))) (build-system python-build-system) (arguments `(#:phases @@ -18265,11 +18265,14 @@ Included are implementations of: (propagated-inputs `(("python-pygments" ,python-pygments) ("python-requests" ,python-requests) - ("python-babel" ,python-babel) ; optional, for internationalization - ("python-curtsies" ,python-curtsies) ; >= 0.1.18 + ("python-curtsies" ,python-curtsies) ("python-greenlet" ,python-greenlet) + ("python-six" ,python-six) + ("python-wcwidth" ,python-wcwidth) + ;; optional dependencies ("python-urwid" ,python-urwid) ; for bpython-urwid only - ("python-six" ,python-six))) + ("python-watchdog" ,python-watchdog) + ("python-jedi" ,python-jedi))) (native-inputs `(("python-sphinx" ,python-sphinx) ("python-mock" ,python-mock))) -- cgit v1.2.3 From 4c697270669a6ee74d684ca1b4a30aa0dec74704 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 6 Jan 2021 10:03:23 +0100 Subject: gnu: guix: Set GUIX_EXTENSIONS_PATH. * gnu/packages/package-management.scm (guix)[native-search-paths]: Add specification for GUIX_EXTENSIONS_PATH. --- gnu/packages/package-management.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index b731df412e..d07df4eeee 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -418,6 +418,10 @@ $(prefix)/etc/init.d\n"))) ("guile-git" ,guile-git) ("guile-zlib" ,guile-zlib) ("guile-lzlib" ,guile-lzlib))) + (native-search-paths + (list (search-path-specification + (variable "GUIX_EXTENSIONS_PATH") + (files '("share/guix/extensions"))))) (home-page "https://www.gnu.org/software/guix/") (synopsis "Functional package manager for installed software packages and versions") -- cgit v1.2.3 From db42ee65bd657bae9b1a598cbdbe86079dc85f81 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 6 Jan 2021 22:13:50 +0100 Subject: gnu: rust-assert-json-diff-1: Fix syntax error. * gnu/packages/crates-io.scm (rust-assert-json-diff-1)[description]: Fix Texinfo syntax error. --- gnu/packages/crates-io.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 57556f773a..e3571ab595 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -1845,7 +1845,7 @@ standard library.") (description "This crate includes macros for comparing two serializable values by diffing their JSON representations. It is designed to give much -more helpful error messages than the standard @code{assert_eq!. It +more helpful error messages than the standard @code{assert_eq!}. It basically does a diff of the two objects and tells you the exact differences. This is useful when asserting that two large JSON objects are the same.") -- cgit v1.2.3 From 8d766132cf7b14efff40c490170eb5df1e632c3c Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Mon, 4 Jan 2021 15:49:31 +0100 Subject: gnu: guile-curl: Update to 0.7. * gnu/packages/curl.scm (guile-curl): Update to 0.7. [#:modules, #:imported-modules]: Load guile-build-system for target-guile-effective-version. [#:configure-flags]: Use target-guile-effective-version. [#:phases]: Add 'patch-undefined-references. Use target-guile-effective-version. [inputs]: Use guile-3.0. --- gnu/packages/curl.scm | 59 ++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 42 insertions(+), 17 deletions(-) diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index 06f0c8ba5b..34fc627a65 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -243,43 +243,68 @@ not offer a replacement for libcurl.") (define-public guile-curl (package (name "guile-curl") - (version "0.6") + (version "0.7") (source (origin (method url-fetch) (uri (string-append "http://www.lonelycactus.com/tarball/" "guile_curl-" version ".tar.gz")) (sha256 (base32 - "1pxdhnk288ky6gkpad8i60m0p6404rdvls43lr1b5d3csrklyc70")))) + "1zk0ijx6bj212k0j0ma84cpvpvn0x6raaxnby3wdx3w4wnhnscn7")))) (build-system gnu-build-system) (arguments - `(#:configure-flags (list (string-append + `(#:modules (((guix build guile-build-system) + #:select (target-guile-effective-version)) + ,@%gnu-build-system-modules) + #:imported-modules ((guix build guile-build-system) + ,@%gnu-build-system-modules) + #:configure-flags (list (string-append "--with-guilesitedir=" (assoc-ref %outputs "out") - "/share/guile/site/2.2") + "/share/guile/site/" + (target-guile-effective-version + (assoc-ref %build-inputs "guile"))) (string-append "-with-guileextensiondir=" (assoc-ref %outputs "out") - "/lib/guile/2.2/extensions")) + "/lib/guile/" + (target-guile-effective-version + (assoc-ref %build-inputs "guile")) + "/extensions")) #:phases (modify-phases %standard-phases + (add-after 'unpack 'patch-undefined-references + (lambda* _ + (substitute* "src/curl.scm" + ;; The following #defines are missing from our curl package + ;; and therefore result in the evaluation of undefined symbols. + ((",CURLOPT_HAPROXYPROTOCOL") "#f") + ((",CURLOPT_DISALLOW_USERNAME_IN_URL") "#f") + ((",CURLOPT_TIMEVALUE_LARGE") "#f") + ((",CURLOPT_DNS_SHUFFLE_ADDRESSES") "#f") + ((",CURLOPT_HAPPY_EYEBALLS_TIMEOUT_MS") "#f")))) (add-after 'install 'patch-extension-path (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (curl.scm (string-append - out "/share/guile/site/2.2/curl.scm")) - (curl.go (string-append - out "/lib/guile/2.2/site-ccache/curl.go")) - (ext (string-append out "/lib/guile/2.2/" - "extensions/libguile-curl"))) - (substitute* curl.scm (("libguile-curl") ext)) - ;; The build system does not actually compile the Scheme module. - ;; So we can compile it and put it in the right place in one go. - (invoke "guild" "compile" curl.scm "-o" curl.go))))))) + (let* ((out (assoc-ref outputs "out")) + (curl.scm (string-append + out "/share/guile/site/" + (target-guile-effective-version) + "/curl.scm")) + (curl.go (string-append + out "/lib/guile/" + (target-guile-effective-version) + "/site-ccache/curl.go")) + (ext (string-append out "/lib/guile/" + (target-guile-effective-version) + "/extensions/libguile-curl"))) + (substitute* curl.scm (("libguile-curl") ext)) + ;; The build system does not actually compile the Scheme module. + ;; So we can compile it and put it in the right place in one go. + (invoke "guild" "compile" curl.scm "-o" curl.go))))))) (native-inputs `(("pkg-config" ,pkg-config))) (inputs `(("curl" ,curl) - ("guile" ,guile-2.2))) + ("guile" ,guile-3.0))) (home-page "http://www.lonelycactus.com/guile-curl.html") (synopsis "Curl bindings for Guile") (description "@code{guile-curl} is a project that has procedures that allow -- cgit v1.2.3 From cdad0a2f6b77088dd9c88d6765ae6839c8aeae24 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Mon, 4 Jan 2021 16:05:14 +0100 Subject: gnu: Add guile2.2-curl. * gnu/packages/curl.scm (guile2.2-curl): New variable. --- gnu/packages/curl.scm | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index 34fc627a65..3ceae4718a 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -312,6 +312,14 @@ Guile to do client-side URL transfers, like requesting documents from HTTP or FTP servers. It is based on the curl library.") (license license:gpl3+))) +(define-public guile2.2-curl + (package + (inherit guile-curl) + (name "guile2.2-curl") + (inputs + `(("curl" ,curl) + ("guile" ,guile-2.2))))) + (define-public curlpp (package (name "curlpp") -- cgit v1.2.3 From e57b978fc0a6b6298b96c68de4769655d793c7b9 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 6 Jan 2021 22:46:12 +0100 Subject: gnu: guix: Update to 1.2.0-9.db42ee6. * gnu/packages/package-management.scm (guix): Update to 1.2.0-9.db42ee6. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index d07df4eeee..7441db0179 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -132,8 +132,8 @@ ;; Note: the 'update-guix-package.scm' script expects this definition to ;; start precisely like this. (let ((version "1.2.0") - (commit "7624ebbae33cf49dded5e9032ed426781c9554f6") - (revision 8)) + (commit "db42ee65bd657bae9b1a598cbdbe86079dc85f81") + (revision 9)) (package (name "guix") @@ -149,7 +149,7 @@ (commit commit))) (sha256 (base32 - "0dd28df278fzlwxk1c0n86q98q8q8cj6g87as8v4rymyprf4gyjc")) + "1kizkw6cxh6mhc8kal2fglnhyp1i668b4ilqbxq72slbmf9jr9jl")) (file-name (string-append "guix-" version "-checkout")))) (build-system gnu-build-system) (arguments -- cgit v1.2.3 From 8d3184c5bcf1a590f59a701f0484ab5cec673188 Mon Sep 17 00:00:00 2001 From: raid5atemyhomework Date: Tue, 5 Jan 2021 20:00:50 +0800 Subject: gnu: zfs: Fix build. * gnu/packages/file-systems.scm (zfs)[inputs]: Correct "util-linux" input; add "util-linux:lib" input. Signed-off-by: Danny Milosavljevic --- gnu/packages/file-systems.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/file-systems.scm b/gnu/packages/file-systems.scm index 895ad069c5..2c5ad95d63 100644 --- a/gnu/packages/file-systems.scm +++ b/gnu/packages/file-systems.scm @@ -6,6 +6,7 @@ ;;; Copyright © 2019, 2020 Efraim Flashner ;;; Copyright © 2020 Raghav Gururajan ;;; Copyright © 2020 Morgan Smith +;;; Copyright © 2021 raid5atemyhoemwork ;;; ;;; This file is part of GNU Guix. ;;; @@ -944,7 +945,8 @@ APFS.") ("openssl" ,openssl) ("python" ,python) ("python-cffi" ,python-cffi) - ("util-linux" ,util-linux "lib") + ("util-linux" ,util-linux) + ("util-linux:lib" ,util-linux "lib") ("zlib" ,zlib))) (home-page "https://zfsonlinux.org/") (synopsis "Native ZFS on Linux") -- cgit v1.2.3 From b793718cb482a2d2c9fb3de1c90baaf388a0eef5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Wed, 6 Jan 2021 18:22:21 +0100 Subject: import: elpa: Updater gracefully handles missing upstream data. Fixes a crash with: guix refresh emacs-exwm-no-x-toolkit * guix/import/elpa.scm (latest-release): Return #f when 'elpa-package-info' returns #f. --- guix/import/elpa.scm | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/guix/import/elpa.scm b/guix/import/elpa.scm index 1d586acab6..c0dc5acf51 100644 --- a/guix/import/elpa.scm +++ b/guix/import/elpa.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 Federico Beffa -;;; Copyright © 2015, 2016, 2017, 2018, 2020 Ludovic Courtès +;;; Copyright © 2015, 2016, 2017, 2018, 2020, 2021 Ludovic Courtès ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2020 Martin Becze ;;; Copyright © 2020 Ricardo Wurmus @@ -419,19 +419,24 @@ type ''." (string-drop (package-name package) 6) (package-name package))) - (let* ((repo 'gnu) - (info (elpa-package-info name repo)) - (version (match info - ((name raw-version . _) - (elpa-version->string raw-version)))) - (url (match info - ((_ raw-version reqs synopsis kind . rest) - (package-source-url kind name version repo))))) - (upstream-source - (package (package-name package)) - (version version) - (urls (list url)) - (signature-urls (list (string-append url ".sig")))))) + (define repo 'gnu) + + (match (elpa-package-info name repo) + (#f + ;; No info, perhaps because PACKAGE is not truly an ELPA package. + #f) + (info + (let* ((version (match info + ((name raw-version . _) + (elpa-version->string raw-version)))) + (url (match info + ((_ raw-version reqs synopsis kind . rest) + (package-source-url kind name version repo))))) + (upstream-source + (package (package-name package)) + (version version) + (urls (list url)) + (signature-urls (list (string-append url ".sig")))))))) (define package-from-gnu.org? (url-predicate (lambda (url) -- cgit v1.2.3 From 069bb95ab23345ff51ba96b207a262fb553e6126 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Wed, 6 Jan 2021 18:37:52 +0100 Subject: upstream: Make the 'updaters' parameter optional. * guix/upstream.scm (lookup-updater, package-latest-release) (package-latest-release*, package-update): Make 'updaters' an optional parameter. * guix/lint.scm (check-for-updates): Remove second argument to 'package-latest-release*'. --- guix/lint.scm | 4 ++-- guix/upstream.scm | 16 +++++++++++----- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/guix/lint.scm b/guix/lint.scm index be6bb4eb01..311bc94cc3 100644 --- a/guix/lint.scm +++ b/guix/lint.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014 Cyril Roelandt ;;; Copyright © 2014, 2015 Eric Bavier -;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2015, 2016 Mathieu Lirzin ;;; Copyright © 2016 Danny Milosavljevic ;;; Copyright © 2016 Hartmut Goebel @@ -1183,7 +1183,7 @@ vulnerability records for PACKAGE by calling PACKAGE-VULNERABILITIES." (format #f (G_ "while retrieving upstream info for '~a'") (package-name package)) #f - (package-latest-release* package (force %updaters))) + (package-latest-release* package)) ((? upstream-source? source) (if (version>? (upstream-source-version source) (package-version package)) diff --git a/guix/upstream.scm b/guix/upstream.scm index 6584d5e4c4..a8ed1d81cd 100644 --- a/guix/upstream.scm +++ b/guix/upstream.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2015 Alex Kost ;;; Copyright © 2019 Ricardo Wurmus ;;; @@ -248,7 +248,8 @@ correspond to the same version." '() (importer-modules)))) -(define (lookup-updater package updaters) +(define* (lookup-updater package + #:optional (updaters (force %updaters))) "Return an updater among UPDATERS that matches PACKAGE, or #f if none of them matches." (find (match-lambda @@ -256,7 +257,9 @@ them matches." (pred package))) updaters)) -(define (package-latest-release package updaters) +(define* (package-latest-release package + #:optional + (updaters (force %updaters))) "Return an upstream source to update PACKAGE, a object, or #f if none of UPDATERS matches PACKAGE. It is the caller's responsibility to ensure that the returned source is newer than the current one." @@ -265,7 +268,9 @@ that the returned source is newer than the current one." ((upstream-updater-latest updater) package)) (_ #f))) -(define (package-latest-release* package updaters) +(define* (package-latest-release* package + #:optional + (updaters (force %updaters))) "Like 'package-latest-release', but ensure that the return source is newer than that of PACKAGE." (match (package-latest-release package updaters) @@ -402,7 +407,8 @@ SOURCE, an ." ;; Mapping of origin methods to source update procedures. `((,url-fetch . ,package-update/url-fetch))) -(define* (package-update store package updaters +(define* (package-update store package + #:optional (updaters (force %updaters)) #:key (key-download 'interactive)) "Return the new version, the file name of the new version tarball, and input changes for PACKAGE; return #f (three values) when PACKAGE is up-to-date. -- cgit v1.2.3 From c356c751e2e21d7cbe88eb0563961f0c00a364fb Mon Sep 17 00:00:00 2001 From: Vincent Legoll Date: Tue, 5 Jan 2021 09:32:21 +0100 Subject: gnu: slurm: Add old 20.02 version back. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/parallel.scm (slurm-20.02): New variable. Signed-off-by: Ludovic Courtès --- gnu/packages/parallel.scm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/gnu/packages/parallel.scm b/gnu/packages/parallel.scm index 4bece3be26..fde19ced92 100644 --- a/gnu/packages/parallel.scm +++ b/gnu/packages/parallel.scm @@ -195,6 +195,21 @@ by managing a queue of pending work.") ;; . Thus, keep older ;; releases here. See also . +(define-public slurm-20.02 + (package + (inherit slurm) + (version "20.02.6-1") + (source (origin + (inherit (package-source slurm)) + (method url-fetch) + (uri (string-append + "https://download.schedmd.com/slurm/slurm-" + version ".tar.bz2")) + (sha256 + (base32 + "0qj4blfymrd2ry2qmb58l3jbr4jwygc3adcfw7my27rippcijlyc")))))) + + (define-public slurm-19.05 (package (inherit slurm) -- cgit v1.2.3 From d5909136b8ea2fa7cd609c07a81f92bd37b6819f Mon Sep 17 00:00:00 2001 From: Maxime Devos Date: Mon, 4 Jan 2021 19:44:45 +0100 Subject: gnu: texmacs: Install desktop file. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/text-editors.scm (texmacs)[arguments]: Add ‘install-desktop-file’ phase. Signed-off-by: Ludovic Courtès --- gnu/packages/text-editors.scm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gnu/packages/text-editors.scm b/gnu/packages/text-editors.scm index 749b93e29f..81915ca52b 100644 --- a/gnu/packages/text-editors.scm +++ b/gnu/packages/text-editors.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2020 Tom Zander ;;; Copyright © 2020 Mark Meyer +;;; Copyright © 2020 Maxime Devos ;;; ;;; This file is part of GNU Guix. ;;; @@ -788,6 +789,14 @@ editors.") (("/usr/share") (string-append out "/share"))) #t))) + (add-after 'install 'install-desktop-file + (lambda* (#:key outputs #:allow-other-keys) + ;; Install desktop file. + (let* ((out (assoc-ref outputs "out")) + (apps (string-append out "/share/applications")) + (source "TeXmacs/misc/mime/texmacs.desktop")) + (install-file source apps) + #t))) (add-before 'configure 'gzip-flags (lambda _ (substitute* "Makefile.in" -- cgit v1.2.3 From 5babdbdd4a2a80a81e0b41c5c3b5b8ccd24652ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= Date: Thu, 7 Jan 2021 19:18:23 +0800 Subject: gnu: wlroots: Propagate wayland-protocols. It's listed in the 'Requires.private' field of wlroots.pc. * gnu/packages/wm.scm (wlroots) [native-inputs]: Move wayland-protocols ... [propagated-inputs]: ... to here. --- gnu/packages/wm.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index fbbb975a58..9b178ae98d 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -1378,12 +1378,12 @@ functionality to display information about the most commonly used services.") ("mesa" ,mesa) ("pixman" ,pixman) ("wayland" ,wayland) + ("wayland-protocols" ,wayland-protocols) ("xcb-util-errors" ,xcb-util-errors) ("xcb-util-wm" ,xcb-util-wm) ("xorg-server-xwayland" ,xorg-server-xwayland))) (native-inputs - `(("pkg-config" ,pkg-config) - ("wayland-protocols" ,wayland-protocols))) + `(("pkg-config" ,pkg-config))) (home-page "https://github.com/swaywm/wlroots") (synopsis "Pluggable, composable, unopinionated modules for building a Wayland compositor") -- cgit v1.2.3 From 106c663dd82ef4d9c34b326f755919f0bd5b889e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= Date: Thu, 7 Jan 2021 19:22:53 +0800 Subject: gnu: Add cagebreak. * gnu/packages/wm.scm (cagebreak): New variable. --- gnu/packages/wm.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index 9b178ae98d..e1359c8539 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -2279,3 +2279,32 @@ start-up.") (description "XNotify receives a notification specification in stdin and shows a notification for the user on the screen.") (license license:expat))) + +(define-public cagebreak + (package + (name "cagebreak") + (version "1.4.4") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/project-repo/cagebreak") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0mnxs1m7jrqdl0asx39nxfzvkp7d4jqpdchi63w2yd1igpj2frb2")))) + (build-system meson-build-system) + (arguments '(#:configure-flags '("-Dxwayland=true"))) + (native-inputs + `(("pandoc" ,pandoc) + ("pkg-config" ,pkg-config))) + (inputs + `(("pango" ,pango) + ("wlroots" ,wlroots))) + (home-page "https://github.com/project-repo/cagebreak") + (synopsis "Tiling wayland compositor inspired by ratpoison") + (description + "@command{cagebreak} is a slim, keyboard-controlled, tiling compositor +for wayland conceptually based on the X11 window manager +@command{ratpoison}.") + (license license:expat))) -- cgit v1.2.3 From 0d3f2716a8b8b64fc4126e1f3e987e05cb9f6bac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?= Date: Wed, 4 Nov 2020 15:48:45 +0100 Subject: gnu: base: Add keywords to make-glibc-utf8-locales. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/base.scm (make-glibc-utf8-locales): Add keyword parameters locales and name with the old values as default. [name]: Use name parameter. [arguments]: Use locales parameter. Co-authored-by: Efraim Flashner Co-authored-by: Ludovic Courtès --- gnu/packages/base.scm | 31 +++++++++++++++++++++++-------- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm index 47fca7c494..b8301828cc 100644 --- a/gnu/packages/base.scm +++ b/gnu/packages/base.scm @@ -52,13 +52,16 @@ #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages gettext) + #:use-module (guix i18n) #:use-module (guix utils) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) + #:use-module (ice-9 format) #:use-module (ice-9 match) + #:use-module (ice-9 optargs) #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) #:export (glibc @@ -1106,9 +1109,16 @@ to the @code{share/locale} sub-directory of this package.") ,(version-major+minor (package-version glibc))))))))))) -(define-public (make-glibc-utf8-locales glibc) +(define %default-utf8-locales + ;; These are the locales commonly used for tests---e.g., in Guile's i18n + ;; tests. + '("de_DE" "el_GR" "en_US" "fr_FR" "tr_TR")) +(define*-public (make-glibc-utf8-locales glibc #:key + (locales %default-utf8-locales) + (name "glibc-utf8-locales")) + (define default-locales? (equal? locales %default-utf8-locales)) (package - (name "glibc-utf8-locales") + (name name) (version (package-version glibc)) (source #f) (build-system trivial-build-system) @@ -1142,17 +1152,22 @@ to the @code{share/locale} sub-directory of this package.") (symlink (string-append locale ".utf8") (string-append localedir "/" locale ".UTF-8"))) - - ;; These are the locales commonly used for - ;; tests---e.g., in Guile's i18n tests. - '("de_DE" "el_GR" "en_US" "fr_FR" "tr_TR")) + ',locales) #t)))) (native-inputs `(("glibc" ,glibc) ("gzip" ,gzip))) - (synopsis "Small sample of UTF-8 locales") + (synopsis (if default-locales? + (P_ "Small sample of UTF-8 locales") + (P_ "Customized sample of UTF-8 locales"))) (description - "This package provides a small sample of UTF-8 locales mostly useful in + (if default-locales? + (P_ "This package provides a small sample of UTF-8 locales mostly useful in test environments.") + (format #f (P_ "This package provides the following UTF-8 locales: +@itemize +~{@item ~a~%~} +@end itemize~%") + locales))) (home-page (package-home-page glibc)) (license (package-license glibc)))) -- cgit v1.2.3 From b509a071943d73f832a93af51d344785f49c5e8f Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 12:31:41 +0100 Subject: gnu: Add duktape. * gnu/packages/javascript.scm (duktape): New variable. --- gnu/packages/javascript.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm index 7bb2629a1e..8434836c6f 100644 --- a/gnu/packages/javascript.scm +++ b/gnu/packages/javascript.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2018 Nicolas Goaziou +;;; Copyright © 2021 Pierre Neidhardt ;;; ;;; This file is part of GNU Guix. ;;; @@ -623,3 +624,31 @@ Javascript sources to executables with no external dependency. It includes a command line interpreter with contextual colorization implemented in Javascript and a small built-in standard library with C library wrappers.") (license license:expat))) + +(define-public duktape + (package + (name "duktape") + (version "2.6.0") + (source (origin + (method url-fetch) + (uri (string-append "https://duktape.org/duktape-" + version ".tar.xz")) + (sha256 + (base32 + "19szwxzvl2g65fw95ggvb8h0ma5bd9vvnnccn59hwnc4dida1x4n")))) + (build-system gnu-build-system) + (arguments + '(#:tests? #f ; No tests. + #:make-flags (list "-f" "Makefile.sharedlibrary" + (string-append "INSTALL_PREFIX=" %output)) + #:phases + (modify-phases %standard-phases + (delete 'configure)))) + (home-page "https://duktape.org/") + (synopsis "Small embeddable Javascript engine") + (description "Duktape is an embeddable Javascript engine, with a focus on +portability and compact footprint. Duktape is easy to integrate into a C/C++ +project: add @file{duktape.c}, @file{duktape.h}, and @file{duk_config.h} to +your build, and use the Duktape API to call ECMAScript functions from C code +and vice versa.") + (license license:expat))) -- cgit v1.2.3 From f2089be3d179afc9b33ca62085c7a0566af7715e Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 14:19:44 +0100 Subject: gnu: json-modern-cxx: Install json_fwd.hpp header. * gnu/packages/cpp.scm (json-modern-cxx)[arguments]: Set JSON_MultipleHeaders=ON to install optional header. --- gnu/packages/cpp.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/cpp.scm b/gnu/packages/cpp.scm index 00e006928e..45d3faeafb 100644 --- a/gnu/packages/cpp.scm +++ b/gnu/packages/cpp.scm @@ -334,7 +334,8 @@ as ordering relation.") (build-system cmake-build-system) (arguments '(#:configure-flags - (list (string-append "-DJSON_TestDataDirectory=" + (list "-DJSON_MultipleHeaders=ON" ; For json_fwd.hpp. + (string-append "-DJSON_TestDataDirectory=" (assoc-ref %build-inputs "json_test_data"))) #:phases (modify-phases %standard-phases ;; XXX: When tests are enabled, the install phase will cause -- cgit v1.2.3 From ca3d1391c6478ae841e7a876f95f7d1c1225d7ae Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 12:31:54 +0100 Subject: gnu: openrct2-objects: Update to 1.0.20. * gnu/packages/games.scm (openrct2-objects): Update to 1.0.20. --- gnu/packages/games.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index a0390c6937..79e87c6ecd 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -4218,7 +4218,7 @@ Transport Tycoon Deluxe.") (define openrct2-objects (package (name "openrct2-objects") - (version "1.0.9") + (version "1.0.20") (source (origin (method url-fetch) @@ -4226,7 +4226,7 @@ Transport Tycoon Deluxe.") version "/objects.zip")) (file-name (string-append name "-" version ".zip")) (sha256 - (base32 "02apb8h553m7d6jvysgb1zahvxc1yzyygfca2iclb21b3fhpsas4")))) + (base32 "1q7a38kcwrfijav6app1gf253yfv8b0rljbkah8040y6i7snw9mw")))) (build-system trivial-build-system) (native-inputs `(("bash" ,bash) -- cgit v1.2.3 From cf7035dea00c7c1b7238bc8ff3f7b69cf892e3f9 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 14:20:51 +0100 Subject: gnu: openrct2: Update to 0.3.2. * gnu/packages/games.scm (openrct2): Update to 0.3.2. --- gnu/packages/games.scm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 79e87c6ecd..855f95c9eb 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -98,6 +98,7 @@ #:use-module (gnu packages check) #:use-module (gnu packages cmake) #:use-module (gnu packages compression) + #:use-module (gnu packages cpp) #:use-module (gnu packages curl) #:use-module (gnu packages crypto) #:use-module (gnu packages cyrus-sasl) @@ -133,6 +134,7 @@ #:use-module (gnu packages icu4c) #:use-module (gnu packages image) #:use-module (gnu packages imagemagick) + #:use-module (gnu packages javascript) #:use-module (gnu packages kde) #:use-module (gnu packages kde-frameworks) #:use-module (gnu packages less) @@ -4258,7 +4260,7 @@ Transport Tycoon Deluxe.") (define-public openrct2 (package (name "openrct2") - (version "0.2.6") + (version "0.3.2") (source (origin (method git-fetch) @@ -4267,7 +4269,7 @@ Transport Tycoon Deluxe.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1vikbkg3wh5ngzdfilb6irbh6nqinf138qpdz8wz9izlvl8s36k4")))) + (base32 "1fd32wniiy6qz2046ppqfj2sb3rf2qf086rf9v1bdhyj254d0b1z")))) (build-system cmake-build-system) (arguments `(#:configure-flags (list "-DDOWNLOAD_OBJECTS=OFF" @@ -4296,6 +4298,7 @@ Transport Tycoon Deluxe.") (("-Werror") "")) #t))))) (inputs `(("curl" ,curl) + ("duktape" ,duktape) ("fontconfig" ,fontconfig) ("freetype" ,freetype) ("icu4c" ,icu4c) @@ -4303,6 +4306,7 @@ Transport Tycoon Deluxe.") ("libpng" ,libpng) ("libzip" ,libzip) ("mesa" ,mesa) + ("nlohmann-json-cpp" ,nlohmann-json-cpp) ("openrct2-objects" ,openrct2-objects) ("openrct2-title-sequences" ,openrct2-title-sequences) ("openssl" ,openssl) -- cgit v1.2.3 From fc62833b7f394ece1d7867189cd46b5944fa3535 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 16:35:59 +0100 Subject: gnu: emacs-sly-stepper: Update to 20200106. * gnu/packages/emacs-xyz.scm (emacs-sly-stepper): Update to 20200106. [arguments]: Remove convoluted part of the workaround to load agnostic-lizard now that upstream has cleaned up the code. --- gnu/packages/emacs-xyz.scm | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 689d3dd54b..0923598156 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9736,7 +9736,7 @@ inside the source file.") (license license:gpl3+)))) (define-public emacs-sly-stepper - (let ((commit "cd7fd00f9a701246e2a9ba8c37166dcae2fde04e")) + (let ((commit "ec3c0a7f3c8b82926882e5fcfdacf67b86d989f8")) (package (name "emacs-sly-stepper") (version (git-version "0.0.0" "1" commit)) @@ -9750,7 +9750,7 @@ inside the source file.") (file-name (git-file-name name version)) (sha256 (base32 - "09ll9dv8fd5dgnki82hcd48nm4qdzzn8wpva0zzr69zkjwzf9v25")))) + "1hxniaxifdw3m4y4yssgy22xcmmf558wx7rpz66wy5hwybjslf7b")))) (build-system emacs-build-system) (inputs `(("cl-agnostic-lizard" ,cl-agnostic-lizard))) @@ -9780,18 +9780,11 @@ inside the source file.") "/share/common-lisp/systems/agnostic-lizard.asd"))) ;; agnostic-lizard is found at runtime. (substitute* file - (("\\(funcall \\(read-from-string \"asdf:load-system\"\\)") + (("\\(require :asdf\\)") (string-append - "(funcall (read-from-string \"asdf:load-asd\") \"" - asd - "\")\n (funcall (read-from-string \"asdf:load-system\")")) - ;; Upstream mistakenly requires Quicklisp. See - ;; https://github.com/joaotavora/sly-stepper/issues/2. - (("\\(funcall \\(read-from-string \"ql:quickload\"\\)") - (string-append - "(ignore-errors (funcall (read-from-string \"ql:quickload\") " - ":agnostic-lizard))")) - ((" :agnostic-lizard\\)") "")))))))) + "(require :asdf)\n" + " (funcall (read-from-string \"asdf:load-asd\")\n" + " \"" asd "\")\n"))))))))) (synopsis "Portable Common Lisp stepper interface for Emacs") (description "This package features a new, portable, visual stepping facility for -- cgit v1.2.3 From e77bb9b54be1c1fa1415393d1fbd2ac2aeef43f7 Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 16:37:04 +0100 Subject: gnu: emacs-sly: Correct version number to 1.0.43. * gnu/packages/emacs-xyz.scm (emacs-sly): Set version to 1.0.43 (upstream did not push a Git tag). --- gnu/packages/emacs-xyz.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 0923598156..962744263a 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9534,7 +9534,7 @@ CIDER).") ;; https://github.com/joaotavora/sly/issues/394. (package (name "emacs-sly") - (version (git-version "1.0.42" "1" commit)) + (version (git-version "1.0.43" "1" commit)) (source (origin (method git-fetch) -- cgit v1.2.3 From e53dcaefa3e78d1bb57fba9265dbc85e4c48225d Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Thu, 7 Jan 2021 16:37:50 +0100 Subject: gnu: sbcl-slynk: Update to 1.0.43. * gnu/packages/lisp-xyz.scm (sbcl-slynk): Update to 1.0.43. We still use git-version because upstream did not push a Git tag. --- gnu/packages/lisp-xyz.scm | 139 +++++++++++++++++++++++----------------------- 1 file changed, 70 insertions(+), 69 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index c3205ad904..6d87329c16 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -782,79 +782,80 @@ antialiased TrueType font rendering using CLX and XRender extension.") (sbcl-package->ecl-package sbcl-clx-truetype)) (define-public sbcl-slynk - (package - (name "sbcl-slynk") - (version "1.0.42") - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/joaotavora/sly") - (commit version))) - (sha256 - (base32 "10l867c4hgcpiajcfkz9g9vabp7y4bcgy51la6n9pqxrlg1fs455")) - (file-name (git-file-name "slynk" version)) - (modules '((guix build utils) - (ice-9 ftw))) - (snippet - '(begin - ;; Move the contribs into the main source directory for easier - ;; access - (substitute* "slynk/slynk.asd" - (("\\.\\./contrib") - "contrib")) - (rename-file "contrib" "slynk/contrib") - ;; Move slynk's contents into the base directory for easier - ;; access - (for-each (lambda (file) - (unless (string-prefix? "." file) - (rename-file (string-append "slynk/" file) - (string-append "./" (basename file))))) - (scandir "slynk")) - #t)))) - (build-system asdf-build-system/sbcl) - (outputs '("out" "image")) - (arguments - `(#:tests? #f ; No test suite - #:asd-systems '("slynk" - "slynk/arglists" - "slynk/fancy-inspector" - "slynk/package-fu" - "slynk/mrepl" - "slynk/trace-dialog" - "slynk/profiler" - "slynk/stickers" - "slynk/indentation" - "slynk/retro") - #:phases - (modify-phases %standard-phases - (add-after 'create-asdf-configuration 'build-image - (lambda* (#:key outputs #:allow-other-keys) - (build-image (string-append - (assoc-ref %outputs "image") - "/bin/slynk") - %outputs - #:dependencies '("slynk" - "slynk/arglists" - "slynk/fancy-inspector" - "slynk/package-fu" - "slynk/mrepl" - "slynk/trace-dialog" - "slynk/profiler" - "slynk/stickers" - "slynk/indentation" - "slynk/retro")) - #t))))) - (synopsis "Common Lisp IDE for Emacs") - (description "SLY is a fork of SLIME, an IDE backend for Common Lisp. + (let ((commit "dffdf3caa12e964127d6eb45ba92ac0442cc5a48")) + (package + (name "sbcl-slynk") + (version (git-version "1.0.43" "1" commit)) + (source + (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/joaotavora/sly") + (commit commit))) + (sha256 + (base32 "0vv185gz3rkfng5y79dijfnc11p92qdz2kdza05avjbpqfs6l0zn")) + (file-name (git-file-name "slynk" version)) + (modules '((guix build utils) + (ice-9 ftw))) + (snippet + '(begin + ;; Move the contribs into the main source directory for easier + ;; access + (substitute* "slynk/slynk.asd" + (("\\.\\./contrib") + "contrib")) + (rename-file "contrib" "slynk/contrib") + ;; Move slynk's contents into the base directory for easier + ;; access + (for-each (lambda (file) + (unless (string-prefix? "." file) + (rename-file (string-append "slynk/" file) + (string-append "./" (basename file))))) + (scandir "slynk")) + #t)))) + (build-system asdf-build-system/sbcl) + (outputs '("out" "image")) + (arguments + `(#:tests? #f ; No test suite + #:asd-systems '("slynk" + "slynk/arglists" + "slynk/fancy-inspector" + "slynk/package-fu" + "slynk/mrepl" + "slynk/trace-dialog" + "slynk/profiler" + "slynk/stickers" + "slynk/indentation" + "slynk/retro") + #:phases + (modify-phases %standard-phases + (add-after 'create-asdf-configuration 'build-image + (lambda* (#:key outputs #:allow-other-keys) + (build-image (string-append + (assoc-ref %outputs "image") + "/bin/slynk") + %outputs + #:dependencies '("slynk" + "slynk/arglists" + "slynk/fancy-inspector" + "slynk/package-fu" + "slynk/mrepl" + "slynk/trace-dialog" + "slynk/profiler" + "slynk/stickers" + "slynk/indentation" + "slynk/retro")) + #t))))) + (synopsis "Common Lisp IDE for Emacs") + (description "SLY is a fork of SLIME, an IDE backend for Common Lisp. It also features a completely redesigned REPL based on Emacs's own full-featured @code{comint-mode}, live code annotations, and a consistent interactive button interface. Everything can be copied to the REPL. One can create multiple inspectors with independent history.") - (home-page "https://github.com/joaotavora/sly") - (license license:public-domain) - (properties `((cl-source-variant . ,(delay cl-slynk)))))) + (home-page "https://github.com/joaotavora/sly") + (license license:public-domain) + (properties `((cl-source-variant . ,(delay cl-slynk))))))) (define-public cl-slynk (sbcl-package->cl-source-package sbcl-slynk)) -- cgit v1.2.3 From d033540e6c113323089403a26e39f9a288c9c857 Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Thu, 7 Jan 2021 17:18:05 +0100 Subject: gnu: php: Update to 7.4.14. * gnu/packages/php.scm (php): Update to 7.4.14. --- gnu/packages/php.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/php.scm b/gnu/packages/php.scm index 5a56b59548..ef2618083f 100644 --- a/gnu/packages/php.scm +++ b/gnu/packages/php.scm @@ -60,7 +60,7 @@ (define-public php (package (name "php") - (version "7.4.13") + (version "7.4.14") (home-page "https://secure.php.net/") (source (origin (method url-fetch) @@ -68,7 +68,7 @@ "php-" version ".tar.xz")) (sha256 (base32 - "1x402vsg3zq8mbar2fwln85vmvdvmrxm8q4ma8333hms78z31bdf")) + "11i8w12kyz2lx3fs4vv4l6ccca1znmmdf7dv3mn01ngwd5ww7wzr")) (modules '((guix build utils))) (snippet '(with-directory-excursion "ext" -- cgit v1.2.3 From a0f019b81f9e58bc1290a0d7426cc9558fbed568 Mon Sep 17 00:00:00 2001 From: Simon Tournier Date: Thu, 7 Jan 2021 18:08:47 +0100 Subject: ui: Fix order of match clauses. Fixes . This is a follow-up to commit cf289d7cfa34315bf13b3114b9a5bf3d3c05ebea. * guix/ui.scm (run-guix-command): Match for #false first. Signed-off-by: Ricardo Wurmus --- guix/ui.scm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/guix/ui.scm b/guix/ui.scm index 7f52518023..bd504c68da 100644 --- a/guix/ui.scm +++ b/guix/ui.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2018 Ricardo Wurmus ;;; Copyright © 2019 Chris Marusich ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice -;;; Copyright © 2019 Simon Tournier +;;; Copyright © 2019, 2021 Simon Tournier ;;; Copyright © 2020 Arun Isaac ;;; Copyright © 2020 Maxim Cournoyer ;;; @@ -2133,11 +2133,11 @@ found." (lambda () (match (search-path (extension-directories) (format #f "~a.scm" command)) + (#f + (throw 'misc-error)) (file - (load file) - (resolve-interface `(guix extensions ,command))) - (_ - (throw 'misc-error)))) + (load file) + (resolve-interface `(guix extensions ,command))))) (lambda _ (format (current-error-port) (G_ "guix: ~a: command not found~%") command) -- cgit v1.2.3 From ec732a46febd5dee0e4d116caed7b259f882f7c7 Mon Sep 17 00:00:00 2001 From: Evgeny Pisemsky Date: Tue, 5 Jan 2021 05:30:00 +0300 Subject: gnu: Add screentest. * gnu/packages/hardware.scm (screentest): New variable. Signed-off-by: Mathieu Othacehe --- gnu/packages/hardware.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm index d130ebd48b..3da6759472 100644 --- a/gnu/packages/hardware.scm +++ b/gnu/packages/hardware.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2020 Brice Waegeneire +;;; Copyright © 2021 Evgeny Pisemsky ;;; ;;; This file is part of GNU Guix. ;;; @@ -29,6 +30,7 @@ #:use-module (gnu packages documentation) #:use-module (gnu packages gcc) #:use-module (gnu packages glib) + #:use-module (gnu packages gtk) #:use-module (gnu packages libusb) #:use-module (gnu packages linux) #:use-module (gnu packages ncurses) @@ -465,3 +467,34 @@ authorization policies (what kind of USB devices are authorized) as well as method of use policies (how a USB device may interact with the system). Simply put, it is a USB device whitelisting tool.") (license license:gpl2))) + +(define-public screentest + (package + (name "screentest") + (version "2.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/TobiX/screentest") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0gv3xj9sbk1wsyijfw9xjnvy8pg7j4arjnma2r2kfi18qy32wd30")))) + (build-system gnu-build-system) + (inputs + `(("glib" ,glib) + ("gtk+" ,gtk+-2))) + (native-inputs + `(("autoconf" ,autoconf) + ("intltool" ,intltool) + ("libtool" ,libtool) + ("glib" ,glib "bin") + ("automake" ,automake) + ("pkg-config" ,pkg-config))) + (synopsis "Simple screen testing tool") + (description "This is a program for testing the quality of CRT/LCD +screens. It displays various patterns and allows you to estimate the quality +of your CRT/LCD monitor.") + (home-page "https://github.com/TobiX/screentest") + (license license:gpl2))) -- cgit v1.2.3 From 999279f061e93a3e233cdfd1d4ad5e26cd0046ab Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sat, 2 Jan 2021 18:45:14 +0100 Subject: gnu: delft-icon-theme: Update to 1.14. * gnu/packages/gnome-xyz.scm (delft-icon-theme): Update to 1.14. --- gnu/packages/gnome-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 10df9bc366..e036e5a443 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -96,7 +96,7 @@ like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") (define-public delft-icon-theme (package (name "delft-icon-theme") - (version "1.12") + (version "1.14") (source (origin (method git-fetch) @@ -105,7 +105,7 @@ like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") (commit (string-append "v" version)))) (sha256 (base32 - "1r6b6jf793jxz15ljniwbqy3vcvsl2712qiigfrfrm46fdxlshjd")) + "1iw85cxx9lv7irs28qi3815dk9f9vldv2j7jf1x5l1dqzwaxgwpb")) (file-name (git-file-name name version)))) (build-system copy-build-system) (arguments -- cgit v1.2.3 From 51d3c8450232fdb0d703c532b35f540696551977 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sat, 2 Jan 2021 19:53:17 +0100 Subject: gnu: matcha-theme: Update to 2021-01-01. * gnu/packages/gnome-xyz.scm (matcha-theme): Update to 2021-01-01. --- gnu/packages/gnome-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index e036e5a443..950a876407 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -50,7 +50,7 @@ (define-public matcha-theme (package (name "matcha-theme") - (version "2020-05-09") + (version "2021-01-01") (source (origin (method git-fetch) @@ -61,7 +61,7 @@ (file-name (git-file-name name version)) (sha256 (base32 - "0fp3ijynyvncy2byjjyba573p81x2pl2hdzv17mg40r8d5mjlkww")))) + "1pa6ra87wlq0gwz4n03l6xv0pxiamr5dygycvppms8v6xyc2aa0r")))) (build-system trivial-build-system) (arguments '(#:modules ((guix build utils)) -- cgit v1.2.3 From 67b1ef5f65f4aeb302c5ec34890111c076b4e524 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sat, 2 Jan 2021 23:44:52 +0100 Subject: gnu: greybird-gtk-theme: Update to 3.22.13. * gnu/packages/gnome-xyz.scm (greybird-gtk-theme): Update to 3.22.13. --- gnu/packages/gnome-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 950a876407..c97405104e 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -521,7 +521,7 @@ notebooks and tiling window managers.") (define-public greybird-gtk-theme (package (name "greybird-gtk-theme") - (version "3.22.12") + (version "3.22.13") (source (origin (method git-fetch) (uri @@ -531,7 +531,7 @@ notebooks and tiling window managers.") (file-name (git-file-name name version)) (sha256 (base32 - "1j66ddvl3pmwh2v8ajm8r5g5nbsr7r262ff1qn2nf3i0gy8b3lq8")))) + "154qawiga792iimkpk3a6q8f4gm4r158wmsagkbqqbhj33kxgxhg")))) (build-system meson-build-system) (native-inputs `(("gtk+" ,gtk+) -- cgit v1.2.3 From 0759cde4fe97b7dc467ea7ce7b121a9a0e44a78a Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sat, 2 Jan 2021 23:45:06 +0100 Subject: gnu: papirus-icon-theme: Update to 20210101. * gnu/packages/gnome-xyz.scm (papirus-icon-theme): Update to 20210101. Also use upstream versioning. --- gnu/packages/gnome-xyz.scm | 43 ++++++++++++++++++++----------------------- 1 file changed, 20 insertions(+), 23 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index c97405104e..96e109ba59 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -585,23 +585,20 @@ dark elements. It supports GNOME, Unity, Xfce, and Openbox.") (deprecated-package "numix-theme" numix-gtk-theme)) (define-public papirus-icon-theme - (let ((version "0.0.0") ;; The package does not use semver - (revision "2") - (tag "20200602")) - (package - (name "papirus-icon-theme") - (version (git-version version revision tag)) - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/PapirusDevelopmentTeam/papirus-icon-theme") - (commit tag))) - (sha256 - (base32 - "0yv19kl8jr2jmh9018b1qmnq68alw84vrmb35jm462qd3qzzdgah")) - (file-name (git-file-name name version)))) - (build-system gnu-build-system) + (package + (name "papirus-icon-theme") + (version "20210101") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/PapirusDevelopmentTeam/papirus-icon-theme") + (commit version))) + (sha256 + (base32 + "0w6qg3zjhfvjg1gg5inranf8ianb4mrp0jm9qgi6hg87ig1rashs")) + (file-name (git-file-name name version)))) + (build-system gnu-build-system) (arguments '(#:tests? #f #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) @@ -610,13 +607,13 @@ dark elements. It supports GNOME, Unity, Xfce, and Openbox.") (delete 'bootstrap) (delete 'configure) (delete 'build)))) - (native-inputs - `(("gtk+:bin" ,gtk+ "bin"))) - (home-page "https://git.io/papirus-icon-theme") - (synopsis "Fork of Paper icon theme with a lot of new icons and a few extras") - (description "Papirus is a fork of the icon theme Paper with a lot of new icons + (native-inputs + `(("gtk+:bin" ,gtk+ "bin"))) + (home-page "https://git.io/papirus-icon-theme") + (synopsis "Fork of Paper icon theme with a lot of new icons and a few extras") + (description "Papirus is a fork of the icon theme Paper with a lot of new icons and a few extra features.") - (license license:gpl3)))) + (license license:gpl3))) (define-public vala-language-server (package -- cgit v1.2.3 From 364bc7a01b2fe41410c684b1f3c8c825085d7d1f Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sat, 2 Jan 2021 23:56:30 +0100 Subject: gnu: arc-theme: Move to gnome-xyz. * gnu/packages/gnome.scm (arc-theme): Move from here... * gnu/packages/gnome-xyz.scm (arc-theme): ... to here. --- gnu/packages/gnome-xyz.scm | 47 ++++++++++++++++++++++++++++++++++++++++++++++ gnu/packages/gnome.scm | 44 ------------------------------------------- 2 files changed, 47 insertions(+), 44 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 96e109ba59..4539cddbfb 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -33,12 +33,15 @@ #:use-module (guix git-download) #:use-module (guix packages) #:use-module ((guix licenses) #:prefix license:) + #:use-module (gnu packages autotools) #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages gtk) + #:use-module (gnu packages inkscape) + #:use-module (gnu packages image) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python-xyz) #:use-module (gnu packages ssh) @@ -518,6 +521,50 @@ scrollable tiling of windows and per monitor workspaces. It's inspired by paper notebooks and tiling window managers.") (license license:gpl3))) +(define-public arc-theme + (package + (name "arc-theme") + (version "20201013") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/jnsh/arc-theme") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1x2l1mwjx68dwf3jb1i90c1q8nqsl1wf2zggcn8im6590k5yv39s")))) + (build-system gnu-build-system) + (arguments + '(#:configure-flags + (list "--disable-cinnamon") + #:phases + (modify-phases %standard-phases + ;; autogen.sh calls configure at the end of the script. + (replace 'bootstrap + (lambda _ (invoke "autoreconf" "-vfi"))) + (add-before 'build 'set-home ;placate Inkscape + (lambda _ + (setenv "HOME" (getcwd)) + #t))))) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake) + ("glib" ,glib "bin") ; for glib-compile-resources + ("gnome-shell" ,gnome-shell) + ("gtk+" ,gtk+) + ("inkscape" ,inkscape) + ("optipng" ,optipng) + ("pkg-config" ,pkg-config) + ("sassc" ,sassc/libsass-3.5))) + (synopsis "A flat GTK+ theme with transparent elements") + (description "Arc is a flat theme with transparent elements for GTK 3, GTK +2, and GNOME Shell which supports GTK 3 and GTK 2 based desktop environments +like GNOME, Unity, Budgie, Pantheon, XFCE, Mate, etc.") + (home-page "https://github.com/horst3180/arc-theme") + ;; No "or later" language found. + (license license:gpl3+))) + (define-public greybird-gtk-theme (package (name "greybird-gtk-theme") diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index f0d94ab1fe..b499684aee 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -9570,50 +9570,6 @@ functionality and behavior.") (home-page "https://extensions.gnome.org/") (license license:gpl3+))) -(define-public arc-theme - (package - (name "arc-theme") - (version "20201013") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/jnsh/arc-theme") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1x2l1mwjx68dwf3jb1i90c1q8nqsl1wf2zggcn8im6590k5yv39s")))) - (build-system gnu-build-system) - (arguments - '(#:configure-flags - (list "--disable-cinnamon") - #:phases - (modify-phases %standard-phases - ;; autogen.sh calls configure at the end of the script. - (replace 'bootstrap - (lambda _ (invoke "autoreconf" "-vfi"))) - (add-before 'build 'set-home ;placate Inkscape - (lambda _ - (setenv "HOME" (getcwd)) - #t))))) - (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("glib" ,glib "bin") ; for glib-compile-resources - ("gnome-shell" ,gnome-shell) - ("gtk+" ,gtk+) - ("inkscape" ,inkscape) - ("optipng" ,optipng) - ("pkg-config" ,pkg-config) - ("sassc" ,sassc/libsass-3.5))) - (synopsis "A flat GTK+ theme with transparent elements") - (description "Arc is a flat theme with transparent elements for GTK 3, GTK -2, and GNOME Shell which supports GTK 3 and GTK 2 based desktop environments -like GNOME, Unity, Budgie, Pantheon, XFCE, Mate, etc.") - (home-page "https://github.com/horst3180/arc-theme") - ;; No "or later" language found. - (license license:gpl3+))) - (define-public faba-icon-theme (package (name "faba-icon-theme") -- cgit v1.2.3 From 7ae52dd04f67a215be6d5bfc3135a3baad0a7c13 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 00:01:13 +0100 Subject: gnu: arc-icon-theme: Move to gnome-xyz. * gnu/packages/gnome.scm (arc-icon-theme): Move from here... * gnu/packages/gnome-xyz.scm (arc-icon-theme): ... to here. --- gnu/packages/gnome-xyz.scm | 35 +++++++++++++++++++++++++++++++++++ gnu/packages/gnome.scm | 35 ----------------------------------- 2 files changed, 35 insertions(+), 35 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 4539cddbfb..0477ccfbaf 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -96,6 +96,41 @@ like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") (home-page "https://github.com/vinceliuice/matcha") (license license:gpl3+))) +(define-public arc-icon-theme + (package + (name "arc-icon-theme") + (version "20161122") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/horst3180/arc-icon-theme") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1ch3hp08qri93510hypzz6m2x4xgg2h15wvnhjwh1x1s1b7jvxjd")))) + (build-system gnu-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'disable-configure-during-bootstrap + (lambda _ + (substitute* "autogen.sh" + (("^\"\\$srcdir/configure\".*") "")) + #t))))) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake))) + ;; When Arc is missing an icon, it looks in the Moka icon theme for it. + (propagated-inputs + `(("moka-icon-theme" ,moka-icon-theme))) + (synopsis "Arc icon theme") + (description "The Arc icon theme provides a set of icons matching the +style of the Arc GTK theme. Icons missing from the Arc theme are provided by +the Moka icon theme.") + (home-page "https://github.com/horst3180/arc-icon-theme") + (license license:gpl3+))) + (define-public delft-icon-theme (package (name "delft-icon-theme") diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index b499684aee..3372a6f0dd 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -9626,41 +9626,6 @@ simple and consistent.") (license (list license:gpl3+ license:cc-by-sa4.0)))) -(define-public arc-icon-theme - (package - (name "arc-icon-theme") - (version "20161122") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/horst3180/arc-icon-theme") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 "1ch3hp08qri93510hypzz6m2x4xgg2h15wvnhjwh1x1s1b7jvxjd")))) - (build-system gnu-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'disable-configure-during-bootstrap - (lambda _ - (substitute* "autogen.sh" - (("^\"\\$srcdir/configure\".*") "")) - #t))))) - (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake))) - ;; When Arc is missing an icon, it looks in the Moka icon theme for it. - (propagated-inputs - `(("moka-icon-theme" ,moka-icon-theme))) - (synopsis "Arc icon theme") - (description "The Arc icon theme provides a set of icons matching the -style of the Arc GTK theme. Icons missing from the Arc theme are provided by -the Moka icon theme.") - (home-page "https://github.com/horst3180/arc-icon-theme") - (license license:gpl3+))) - (define-public folks (package (name "folks") -- cgit v1.2.3 From 43c8b56f72e03ec041238283d05b8d533bc40723 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 00:11:53 +0100 Subject: gnu: Move faba-icon-theme and moka-icon-theme to gnome-xyz.scm They need to be moved together, as the latter inherits the former. * gnu/packages/gnome.scm (faba-icon-theme, moka-icon-theme): Move from here... * gnu/packages/gnome-xyz.scm (faba-icon-theme, moka-icon-theme): ... to here. --- gnu/packages/gnome-xyz.scm | 56 ++++++++++++++++++++++++++++++++++++++++++++++ gnu/packages/gnome.scm | 56 ---------------------------------------------- 2 files changed, 56 insertions(+), 56 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 0477ccfbaf..0c76c6320d 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -164,6 +164,62 @@ which haven't been updated for some years. The new app icons are ported from the Obsidian icon theme.") (license license:gpl3))) +(define-public faba-icon-theme + (package + (name "faba-icon-theme") + (version "4.3") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/snwh/faba-icon-theme") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0xh6ppr73p76z60ym49b4d0liwdc96w41cc5p07d48hxjsa6qd6n")))) + (build-system meson-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-before 'configure 'disable-post-install + (lambda _ + (substitute* "meson.build" + (("meson.add_install_script.*") ""))))))) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake))) + (synopsis "Faba icon theme") + (description + "Faba is a minimal icon set used as a basis for other themes such as +Moka") + (home-page "https://snwh.org/moka") + (license (list license:lgpl3+ + license:cc-by-sa4.0)))) + +(define-public moka-icon-theme + (package + (inherit faba-icon-theme) + (name "moka-icon-theme") + (version "5.4.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/snwh/moka-icon-theme") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "015l02im4mha5z91dbchxf6xkp66d346bg3xskwg0rh3lglhjsrd")))) + (propagated-inputs + ;; Moka is based on Faba by using it as a fallback icon set instead of + ;; bundling it, so we need to add it as a propagated input. + `(("faba-icon-theme" ,faba-icon-theme))) + (synopsis "Moka icon theme") + (description "Moka is a stylized desktop icon set, designed to be clear, +simple and consistent.") + (license (list license:gpl3+ + license:cc-by-sa4.0)))) + (define-public gnome-shell-extension-appindicator (package (name "gnome-shell-extension-appindicator") diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 3372a6f0dd..60fde4fabb 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -9570,62 +9570,6 @@ functionality and behavior.") (home-page "https://extensions.gnome.org/") (license license:gpl3+))) -(define-public faba-icon-theme - (package - (name "faba-icon-theme") - (version "4.3") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/snwh/faba-icon-theme") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 "0xh6ppr73p76z60ym49b4d0liwdc96w41cc5p07d48hxjsa6qd6n")))) - (build-system meson-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'configure 'disable-post-install - (lambda _ - (substitute* "meson.build" - (("meson.add_install_script.*") ""))))))) - (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake))) - (synopsis "Faba icon theme") - (description - "Faba is a minimal icon set used as a basis for other themes such as -Moka") - (home-page "https://snwh.org/moka") - (license (list license:lgpl3+ - license:cc-by-sa4.0)))) - -(define-public moka-icon-theme - (package - (inherit faba-icon-theme) - (name "moka-icon-theme") - (version "5.4.0") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/snwh/moka-icon-theme") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 "015l02im4mha5z91dbchxf6xkp66d346bg3xskwg0rh3lglhjsrd")))) - (propagated-inputs - ;; Moka is based on Faba by using it as a fallback icon set instead of - ;; bundling it, so we need to add it as a propagated input. - `(("faba-icon-theme" ,faba-icon-theme))) - (synopsis "Moka icon theme") - (description "Moka is a stylized desktop icon set, designed to be clear, -simple and consistent.") - (license (list license:gpl3+ - license:cc-by-sa4.0)))) - (define-public folks (package (name "folks") -- cgit v1.2.3 From 579a5eff08e62b33ade5b57b4098b735a7860583 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 00:16:38 +0100 Subject: gnu: gnome-xyz.scm: Reorder packages. Make it so that icon themes, shell extensions and GTK themes are grouped in that order. * gnu/packages/gnome-xyz.scm (matcha-theme): Move before numix-gtk-theme. (papirus-icon-theme): Move after moka-icon-theme. --- gnu/packages/gnome-xyz.scm | 154 ++++++++++++++++++++++----------------------- 1 file changed, 77 insertions(+), 77 deletions(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 0c76c6320d..a0e31bc15c 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -50,52 +50,6 @@ #:use-module (gnu packages web) #:use-module (gnu packages xml)) -(define-public matcha-theme - (package - (name "matcha-theme") - (version "2021-01-01") - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://github.com/vinceliuice/Matcha-gtk-theme") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1pa6ra87wlq0gwz4n03l6xv0pxiamr5dygycvppms8v6xyc2aa0r")))) - (build-system trivial-build-system) - (arguments - '(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let* ((out (assoc-ref %outputs "out")) - (source (assoc-ref %build-inputs "source")) - (bash (assoc-ref %build-inputs "bash")) - (coreutils (assoc-ref %build-inputs "coreutils")) - (themesdir (string-append out "/share/themes"))) - (setenv "PATH" - (string-append coreutils "/bin:" - (string-append bash "/bin:"))) - (copy-recursively source (getcwd)) - (patch-shebang "install.sh") - (mkdir-p themesdir) - (invoke "./install.sh" "-d" themesdir) - #t)))) - (inputs - `(("gtk-engines" ,gtk-engines))) - (native-inputs - `(("bash" ,bash) - ("coreutils" ,coreutils))) - (synopsis "Flat design theme for GTK 3, GTK 2 and GNOME-Shell") - (description "Matcha is a flat Design theme for GTK 3, GTK 2 and -Gnome-Shell which supports GTK 3 and GTK 2 based desktop environments -like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") - (home-page "https://github.com/vinceliuice/matcha") - (license license:gpl3+))) - (define-public arc-icon-theme (package (name "arc-icon-theme") @@ -220,6 +174,37 @@ simple and consistent.") (license (list license:gpl3+ license:cc-by-sa4.0)))) +(define-public papirus-icon-theme + (package + (name "papirus-icon-theme") + (version "20210101") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/PapirusDevelopmentTeam/papirus-icon-theme") + (commit version))) + (sha256 + (base32 + "0w6qg3zjhfvjg1gg5inranf8ianb4mrp0jm9qgi6hg87ig1rashs")) + (file-name (git-file-name name version)))) + (build-system gnu-build-system) + (arguments + '(#:tests? #f + #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) + #:phases + (modify-phases %standard-phases + (delete 'bootstrap) + (delete 'configure) + (delete 'build)))) + (native-inputs + `(("gtk+:bin" ,gtk+ "bin"))) + (home-page "https://git.io/papirus-icon-theme") + (synopsis "Fork of Paper icon theme with a lot of new icons and a few extras") + (description "Papirus is a fork of the icon theme Paper with a lot of new icons +and a few extra features.") + (license license:gpl3))) + (define-public gnome-shell-extension-appindicator (package (name "gnome-shell-extension-appindicator") @@ -684,6 +669,52 @@ like GNOME, Unity, Budgie, Pantheon, XFCE, Mate, etc.") Shimmer Project. It supports GNOME, Unity, and Xfce.") (license (list license:gpl2+ license:cc-by-sa3.0)))) +(define-public matcha-theme + (package + (name "matcha-theme") + (version "2021-01-01") + (source + (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/vinceliuice/Matcha-gtk-theme") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1pa6ra87wlq0gwz4n03l6xv0pxiamr5dygycvppms8v6xyc2aa0r")))) + (build-system trivial-build-system) + (arguments + '(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (let* ((out (assoc-ref %outputs "out")) + (source (assoc-ref %build-inputs "source")) + (bash (assoc-ref %build-inputs "bash")) + (coreutils (assoc-ref %build-inputs "coreutils")) + (themesdir (string-append out "/share/themes"))) + (setenv "PATH" + (string-append coreutils "/bin:" + (string-append bash "/bin:"))) + (copy-recursively source (getcwd)) + (patch-shebang "install.sh") + (mkdir-p themesdir) + (invoke "./install.sh" "-d" themesdir) + #t)))) + (inputs + `(("gtk-engines" ,gtk-engines))) + (native-inputs + `(("bash" ,bash) + ("coreutils" ,coreutils))) + (synopsis "Flat design theme for GTK 3, GTK 2 and GNOME-Shell") + (description "Matcha is a flat Design theme for GTK 3, GTK 2 and +Gnome-Shell which supports GTK 3 and GTK 2 based desktop environments +like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") + (home-page "https://github.com/vinceliuice/matcha") + (license license:gpl3+))) + (define-public numix-gtk-theme (package (name "numix-gtk-theme") @@ -722,37 +753,6 @@ dark elements. It supports GNOME, Unity, Xfce, and Openbox.") (define-public numix-theme (deprecated-package "numix-theme" numix-gtk-theme)) -(define-public papirus-icon-theme - (package - (name "papirus-icon-theme") - (version "20210101") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/PapirusDevelopmentTeam/papirus-icon-theme") - (commit version))) - (sha256 - (base32 - "0w6qg3zjhfvjg1gg5inranf8ianb4mrp0jm9qgi6hg87ig1rashs")) - (file-name (git-file-name name version)))) - (build-system gnu-build-system) - (arguments - '(#:tests? #f - #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) - #:phases - (modify-phases %standard-phases - (delete 'bootstrap) - (delete 'configure) - (delete 'build)))) - (native-inputs - `(("gtk+:bin" ,gtk+ "bin"))) - (home-page "https://git.io/papirus-icon-theme") - (synopsis "Fork of Paper icon theme with a lot of new icons and a few extras") - (description "Papirus is a fork of the icon theme Paper with a lot of new icons -and a few extra features.") - (license license:gpl3))) - (define-public vala-language-server (package (name "vala-language-server") -- cgit v1.2.3 From a72414832bd70a8312124874a3e6d6b91050aa96 Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 00:29:22 +0100 Subject: gnu: Add materia-theme. * gnu/packages/gnome-xyz.scm (materia-theme): New variable. --- gnu/packages/gnome-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index a0e31bc15c..be053ff511 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -715,6 +715,32 @@ like Gnome, Unity, Budgie, Pantheon, XFCE, Mate and others.") (home-page "https://github.com/vinceliuice/matcha") (license license:gpl3+))) +(define-public materia-theme + (package + (name "materia-theme") + (version "20200916") + (source + (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/nana-4/materia-theme") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0qaxxafsn5zd2ysgr0jyv5j73360mfdmxyd55askswlsfphssn74")))) + (build-system meson-build-system) + (native-inputs + `(("gtk+" ,gtk+) + ("sassc" ,sassc))) + (home-page "https://github.com/nana-4/materia-theme") + (synopsis "Material Design theme for a wide range of environments") + (description "Materia is a Material Design theme for GNOME/GTK based +desktop environments. It supports GTK 2, GTK 3, GNOME Shell, Budgie, +Cinnamon, MATE, Unity, Xfce, LightDM, GDM, Chrome theme, etc.") + (license license:gpl2+))) + (define-public numix-gtk-theme (package (name "numix-gtk-theme") -- cgit v1.2.3 From 4765cf4d24ea153127a9758a02141ac0bc5cfffe Mon Sep 17 00:00:00 2001 From: Leo Prikler Date: Sun, 3 Jan 2021 00:31:14 +0100 Subject: gnu: Update copyright line. * gnu/packages/gnome-xyz.scm: Bump year in copyright line. --- gnu/packages/gnome-xyz.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index be053ff511..1204dcee90 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2019, 2020 Leo Prikler +;;; Copyright © 2019, 2020, 2021 Leo Prikler ;;; Copyright © 2019 Alexandros Theodotou ;;; Copyright © 2019 Giacomo Leidi ;;; Copyright © 2020 Alex Griffin -- cgit v1.2.3 From b17b54113a0952b7c66653169161069a894dc9b4 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 7 Jan 2021 21:43:23 +0200 Subject: gnu: vtk: Remove some vendored libraries. * gnu/packages/image-processing.scm (vtk)[source]: Add snippet to remove some vendored sources. --- gnu/packages/image-processing.scm | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index 388e91d31a..613d55beaa 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2018 Björn Höfling ;;; Copyright © 2018 Lprndn -;;; Copyright © 2019 Efraim Flashner +;;; Copyright © 2019, 2021 Efraim Flashner ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2020 Vinicius Monego ;;; Copyright © 2020 Pierre Neidhardt @@ -252,7 +252,17 @@ many popular formats.") "/VTK-" version ".tar.gz")) (sha256 (base32 - "1fspgp8k0myr6p2a6wkc21ldcswb4bvmb484m12mxgk1a9vxrhrl")))) + "1fspgp8k0myr6p2a6wkc21ldcswb4bvmb484m12mxgk1a9vxrhrl")) + (modules '((guix build utils))) + (snippet + '(begin + (for-each + (lambda (dir) + (delete-file-recursively + (string-append "ThirdParty/" dir "/vtk" dir))) + '("expat" "freetype" "hdf5" "jpeg" "jsoncpp" "libxml2" + "png" "tiff" "zlib")) + #t)))) (build-system cmake-build-system) (arguments '(#:build-type "Release" ;Build without '-g' to save space. -- cgit v1.2.3 From fac4e4aee51c85b9e2058071c4970217769d1f01 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 7 Jan 2021 21:45:04 +0200 Subject: gnu: vtk: Sort inputs alphabetically. * gnu/packages/image-processing.scm (vtk)[inputs]: Sort alphabetically. --- gnu/packages/image-processing.scm | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index 613d55beaa..cf84bfb4aa 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -279,21 +279,21 @@ many popular formats.") "-DVTK_USE_SYSTEM_ZLIB:BOOL=TRUE") #:tests? #f)) ;XXX: no "test" target (inputs - `(("libXt" ,libxt) - ("xorgproto" ,xorgproto) - ("libX11" ,libx11) - ("libxml2" ,libxml2) - ("mesa" ,mesa) - ("glu" ,glu) - ("expat" ,expat) + `(("expat" ,expat) ("freetype" ,freetype) + ("glu" ,glu) ("hdf5" ,hdf5) ("jpeg" ,libjpeg-turbo) ("jsoncpp" ,jsoncpp) ("libogg" ,libogg) ("libtheora" ,libtheora) + ("libX11" ,libx11) + ("libxml2" ,libxml2) + ("libXt" ,libxt) + ("mesa" ,mesa) ("png" ,libpng) ("tiff" ,libtiff) + ("xorgproto" ,xorgproto) ("zlib" ,zlib))) (home-page "https://vtk.org/") (synopsis "Libraries for 3D computer graphics") -- cgit v1.2.3 From a675c01ffeb416b82d8e1e7aba1a8fd557cb9fa2 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 7 Jan 2021 22:28:21 +0200 Subject: gnu: vtk: Use more system libraries. * gnu/packages/image-processing.scm (vtk)[source]: Remove more bundled sources in snippet. [arguments]: Add to configure-flags to use more system libraries. [inputs]: Remove libogg. Add double-conversion, eigen, gl2ps, glew, lz4, netcdf, proj.4 and sqlite. --- gnu/packages/image-processing.scm | 38 ++++++++++++++++++++++++++++++-------- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index cf84bfb4aa..c3ea8491d9 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -70,6 +70,7 @@ #:use-module (gnu packages python-xyz) #:use-module (gnu packages qt) #:use-module (gnu packages serialization) + #:use-module (gnu packages sqlite) #:use-module (gnu packages tbb) #:use-module (gnu packages tls) #:use-module (gnu packages version-control) @@ -260,38 +261,59 @@ many popular formats.") (lambda (dir) (delete-file-recursively (string-append "ThirdParty/" dir "/vtk" dir))) - '("expat" "freetype" "hdf5" "jpeg" "jsoncpp" "libxml2" - "png" "tiff" "zlib")) + ;; ogg, pugixml depended upon unconditionally + '("doubleconversion" "eigen" "expat" "freetype" "gl2ps" + "glew" "hdf5" "jpeg" "jsoncpp" "libproj" "libxml2" "lz4" + "netcdf" "png" "sqlite" "theora" "tiff" "zlib")) #t)))) (build-system cmake-build-system) (arguments '(#:build-type "Release" ;Build without '-g' to save space. - ;; -DVTK_USE_SYSTEM_NETCDF:BOOL=TRUE requires netcdf_cxx - #:configure-flags '("-DVTK_USE_SYSTEM_EXPAT:BOOL=TRUE" + #:configure-flags '(;"-DBUILD_TESTING:BOOL=TRUE" + ;"-DVTK_MODULE_USE_EXTERNAL_vtkogg:BOOL=TRUE" ; not honored + "-DVTK_USE_SYSTEM_DOUBLECONVERSION:BOOL=TRUE" + "-DVTK_USE_SYSTEM_EIGEN:BOOL=TRUE" + "-DVTK_USE_SYSTEM_EXPAT:BOOL=TRUE" "-DVTK_USE_SYSTEM_FREETYPE:BOOL=TRUE" + "-DVTK_USE_SYSTEM_GL2PS:BOOL=TRUE" + "-DVTK_USE_SYSTEM_GLEW:BOOL=TRUE" "-DVTK_USE_SYSTEM_HDF5:BOOL=TRUE" "-DVTK_USE_SYSTEM_JPEG:BOOL=TRUE" "-DVTK_USE_SYSTEM_JSONCPP:BOOL=TRUE" + "-DVTK_USE_SYSTEM_LIBPROJ:BOOL=TRUE" "-DVTK_USE_SYSTEM_LIBXML2:BOOL=TRUE" - "-DVTK_USE_SYSTEM_OGGTHEORA:BOOL=TRUE" + "-DVTK_USE_SYSTEM_LZ4:BOOL=TRUE" + "-DVTK_USE_SYSTEM_NETCDF:BOOL=TRUE" "-DVTK_USE_SYSTEM_PNG:BOOL=TRUE" + ;"-DVTK_USE_SYSTEM_PUGIXML:BOOL=TRUE" ; breaks IO/CityGML + "-DVTK_USE_SYSTEM_SQLITE:BOOL=TRUE" + "-DVTK_USE_SYSTEM_THEORA:BOOL=TRUE" "-DVTK_USE_SYSTEM_TIFF:BOOL=TRUE" "-DVTK_USE_SYSTEM_ZLIB:BOOL=TRUE") - #:tests? #f)) ;XXX: no "test" target + #:tests? #f)) ;XXX: test data not included (inputs - `(("expat" ,expat) + `(("double-conversion" ,double-conversion) + ("eigen" ,eigen) + ("expat" ,expat) ("freetype" ,freetype) + ("gl2ps" ,gl2ps) + ("glew" ,glew) ("glu" ,glu) ("hdf5" ,hdf5) ("jpeg" ,libjpeg-turbo) ("jsoncpp" ,jsoncpp) - ("libogg" ,libogg) + ;("libogg" ,libogg) ("libtheora" ,libtheora) ("libX11" ,libx11) ("libxml2" ,libxml2) ("libXt" ,libxt) + ("lz4" ,lz4) ("mesa" ,mesa) + ("netcdf" ,netcdf) ("png" ,libpng) + ("proj" ,proj.4) + ;("pugixml" ,pugixml) + ("sqlite" ,sqlite) ("tiff" ,libtiff) ("xorgproto" ,xorgproto) ("zlib" ,zlib))) -- cgit v1.2.3 From 84ea98d6114a040b0da3bbd0f808ea44dc71942f Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 01:36:01 +0100 Subject: gnu: ngircd: Update to 26.1. * gnu/packages/messaging.scm (ngircd): Update to 26.1. --- gnu/packages/messaging.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 89d7b8ca83..c585326124 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2016, 2017, 2018, 2019 Clément Lassieur ;;; Copyright © 2017 Mekeor Melire ;;; Copyright © 2017, 2018, 2020 Arun Isaac -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Theodoros Foradis ;;; Copyright © 2017, 2018, 2019 Rutger Helling ;;; Copyright © 2018 Leo Famulari @@ -659,14 +659,14 @@ dictionaries. HexChat can be extended with multiple addons.") (define-public ngircd (package (name "ngircd") - (version "26") + (version "26.1") (source (origin (method url-fetch) (uri (string-append "https://arthur.barton.de/pub/ngircd/ngircd-" version ".tar.xz")) (sha256 (base32 - "1ijmv18fa648y7apxb9vp4j9iq6fxq850kz5v36rysaq614cdp2n")) + "0m32v0c7mq96rshws4h6d0pi4bm0hynfzx3x01mgrxh9c396zham")) (patches (search-patches "ngircd-handle-zombies.patch")))) (build-system gnu-build-system) ;; Needed for the test suite. -- cgit v1.2.3 From 91d2e6f9bad99e082724e525402e1bf6d260d218 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 01:52:32 +0100 Subject: gnu: gtkwave: Update to 3.3.108. * gnu/packages/fpga.scm (gtkwave): Update to 3.3.108. --- gnu/packages/fpga.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/fpga.scm b/gnu/packages/fpga.scm index 96c37791f6..96ba0026f9 100644 --- a/gnu/packages/fpga.scm +++ b/gnu/packages/fpga.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016 Danny Milosavljevic ;;; Copyright © 2016, 2017 Theodoros Foradis -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2019 Amin Bandali ;;; Copyright © 2020 Vinicius Monego ;;; @@ -348,7 +348,7 @@ FOSS FPGA place and route tool.") (define-public gtkwave (package (name "gtkwave") - (version "3.3.107") + (version "3.3.108") (source (origin (method url-fetch) @@ -358,7 +358,7 @@ FOSS FPGA place and route tool.") (string-append "http://gtkwave.sourceforge.net/" "gtkwave-" version ".tar.gz"))) (sha256 - (base32 "1ibnhn7w1awalsbndbb5nilbmih3i3dwfry95mq5sn221l5n7zj8")))) + (base32 "0fzbap72zm4ka6n85j0873fpaarrx199ay0kjw1avrs20hs4gr7c")))) (build-system gnu-build-system) (native-inputs `(("gperf" ,gperf) -- cgit v1.2.3 From 4203024e65925f322860d08cd6870ecf8203aba2 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 01:53:43 +0100 Subject: gnu: perl-test-file: Update to 1.444. * gnu/packages/perl-check.scm (perl-test-file): Update to 1.444. --- gnu/packages/perl-check.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/perl-check.scm b/gnu/packages/perl-check.scm index cc7736ce18..ad8b166bd9 100644 --- a/gnu/packages/perl-check.scm +++ b/gnu/packages/perl-check.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2017 Leo Famulari ;;; Copyright © 2017 Christopher Baines ;;; Copyright © 2017 Petter -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2018 Pierre Neidhardt ;;; Copyright © 2018 Kei Kebreau @@ -587,7 +587,7 @@ testing exception-throwing code with about the same amount of typing.") (define-public perl-test-file (package (name "perl-test-file") - (version "1.443") + (version "1.444") (source (origin (method url-fetch) @@ -596,8 +596,7 @@ testing exception-throwing code with about the same amount of typing.") version ".tar.gz")) (sha256 - (base32 - "1mdwb3x8d4l24wsymamsnq2c73a637v4q5kmb5xqqz31iymsdd31")))) + (base32 "0195dnvwxxphwbglw6cjid3j7kq15xg46lr7r4468idvadyal6c7")))) (build-system perl-build-system) (native-inputs `(("perl-test-utf8" ,perl-test-utf8))) -- cgit v1.2.3 From d17e6f2b6b7f9287d1c17d3315efb050e090f68b Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 20:58:14 +0100 Subject: gnu: youtube-viewer: Update to 3.8.1. * gnu/packages/video.scm (youtube-viewer): Update to 3.8.1. --- gnu/packages/video.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 2b1b111e97..c92022e7ec 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -15,7 +15,7 @@ ;;; Copyright © 2016, 2018, 2019, 2020 Eric Bavier ;;; Copyright © 2016 Jan Nieuwenhuizen ;;; Copyright © 2017 Feng Shu -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 201–72021 Tobias Geerinckx-Rice ;;; Copyright © 2017 Chris Marusich ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017 Ethan R. Jones @@ -2418,7 +2418,7 @@ audio, images) from the Web. It can use either mpv or vlc for playback.") (define-public youtube-viewer (package (name "youtube-viewer") - (version "3.8.0") + (version "3.8.1") (source (origin (method git-fetch) (uri (git-reference @@ -2427,7 +2427,7 @@ audio, images) from the Web. It can use either mpv or vlc for playback.") (file-name (git-file-name name version)) (sha256 (base32 - "16gskhzkvgzhfb89zqfmvz7kmhjsyc38f2dl86ksal4p69kn8j3g")))) + "0xdybiihd66b79rbsawjhxs9snm78gld5ziz3gnp8vdcw0bshwz7")))) (build-system perl-build-system) (native-inputs `(("perl-module-build" ,perl-module-build))) -- cgit v1.2.3 From b974e34c178e0437efdc0569d822fec2fca4c55d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 21:08:51 +0100 Subject: gnu: starfighter: Update to 2.4. * gnu/packages/games.scm (starfighter): Update to 2.4. --- gnu/packages/games.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 855f95c9eb..2208ca4113 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -24,7 +24,7 @@ ;;; Copyright © 2016 Steve Webber ;;; Copyright © 2017 Adonay "adfeno" Felipe Nogueira ;;; Copyright © 2017, 2018, 2020 Arun Isaac -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2019 nee ;;; Copyright © 2017 Clément Lassieur ;;; Copyright © 2017, 2019, 2020 Marius Bakke @@ -4942,7 +4942,7 @@ of war. Widelands also offers an Artificial Intelligence to challenge you.") (define-public starfighter (package (name "starfighter") - (version "2.3.3") + (version "2.4") (source (origin (method url-fetch) (uri (string-append @@ -4951,7 +4951,7 @@ of war. Widelands also offers an Artificial Intelligence to challenge you.") version "-src.tar.gz")) (sha256 (base32 - "0jz2lgvmp299nks6ajg2yxbx4xcaxlc4cpfr61861p7m7z2nv84y")))) + "0ips79j3sdy8wa64jqka0skbbqkzqiln9bbiiilh4z717q7vz9r5")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) -- cgit v1.2.3 From b6c42727b6d583977a0e3d8c66eb0755e19bb12c Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 21:13:28 +0100 Subject: gnu: system-config-printer: Update to 1.5.14. * gnu/packages/gnome.scm (system-config-printer): Update to 1.5.14. --- gnu/packages/gnome.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 60fde4fabb..3167b69f37 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -2841,7 +2841,7 @@ database is translated at Transifex.") (define-public system-config-printer (package (name "system-config-printer") - (version "1.5.13") + (version "1.5.14") (source (origin (method url-fetch) @@ -2850,7 +2850,7 @@ database is translated at Transifex.") "download/v" version "/system-config-printer-" version ".tar.xz")) (sha256 - (base32 "18dqvi1s971lggkw6pv1sqxixlpg5a8rppzc1pxbanxa91jg18zf")))) + (base32 "1l79lj44kl079sk308m42x3py1yvcxk5x5bs2vqfmqv26zm8qyqf")))) (build-system glib-or-gtk-build-system) (arguments `(#:imported-modules ((guix build python-build-system) -- cgit v1.2.3 From df0447be61c0f8c463aeb46369fe67aeb9e914dd Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Thu, 7 Jan 2021 21:40:32 +0100 Subject: gnu: obs: Update to 26.1.1. * gnu/packages/video.scm (obs): Update to 26.1.1. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index c92022e7ec..1f68208021 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -3078,7 +3078,7 @@ be used for realtime video capture via Linux-specific APIs.") (define-public obs (package (name "obs") - (version "26.1.0") + (version "26.1.1") (source (origin (method git-fetch) (uri (git-reference @@ -3087,7 +3087,7 @@ be used for realtime video capture via Linux-specific APIs.") (file-name (git-file-name name version)) (sha256 (base32 - "0p8wdzm9imn3s17arr206sz92g4pkacfcpfbwvhvgkrrs4w000bx")))) + "18b40ayww5isjqnjz63l05fi5xwzrcc64jvwxwq8nqsydn0b14ng")))) (build-system cmake-build-system) (arguments `(#:configure-flags -- cgit v1.2.3 From 82a98146ef7707769b3b57aa24b969bd120c751d Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 6 Jan 2021 13:12:00 -0500 Subject: gnu: linux-libre: Update to 5.10.5. * gnu/packages/linux.scm (linux-libre-5.10-version): Update to 5.10.5. (linux-libre-5.10-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index b5df847a53..869288fbe8 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -353,7 +353,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.10-version "5.10.4") +(define-public linux-libre-5.10-version "5.10.5") (define deblob-scripts-5.10 (linux-libre-deblob-scripts linux-libre-5.10-version @@ -361,7 +361,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0hh27ccqimagr3aij7ygwikxw66y63sqwd0xlf49bhpjd090r9a7"))) (define-public linux-libre-5.10-pristine-source (let ((version linux-libre-5.10-version) - (hash (base32 "1v2nbpp21c3fkw23dgrrfznnnlvi0538kj8wrlb2m6g94rn3jklh"))) + (hash (base32 "1x1fc4cywqnjm514q376d5540zsxmqv95n0lykaphz8qdbhsk49r"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.10))) -- cgit v1.2.3 From bf83d3aae10a02b95d818118c383a87b4478fb9a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 6 Jan 2021 13:12:30 -0500 Subject: gnu: linux-libre 5.4: Update to 5.4.87. * gnu/packages/linux.scm (linux-libre-5.4-version): Update to 5.4.87. (linux-libre-5.4-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 869288fbe8..8d5598598f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -369,7 +369,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; -(define-public linux-libre-5.4-version "5.4.86") +(define-public linux-libre-5.4-version "5.4.87") (define deblob-scripts-5.4 (linux-libre-deblob-scripts linux-libre-5.4-version @@ -377,7 +377,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1xghbbnaisjd0k1klbyn1p7r6r4x5a1bpmkm56a3gh2zvw4s7mj8"))) (define-public linux-libre-5.4-pristine-source (let ((version linux-libre-5.4-version) - (hash (base32 "12qf7gza94s4f7smi3dk6i6hqcz0fbc64ghapan57fgpdvybadpb"))) + (hash (base32 "0cawb7md97i0hz83hf7l4ihn9lyrg8q64j8jam8n9fw45qzfjd3a"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.4))) -- cgit v1.2.3 From efa773f94a18b40f2c63795f364ae87dade76f60 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 6 Jan 2021 13:12:53 -0500 Subject: gnu: linux-libre 4.19: Update to 4.19.165. * gnu/packages/linux.scm (linux-libre-4.19-version): Update to 4.19.165. (linux-libre-4.19-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 8d5598598f..8317723bbf 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -382,7 +382,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.4))) -(define-public linux-libre-4.19-version "4.19.164") +(define-public linux-libre-4.19-version "4.19.165") (define deblob-scripts-4.19 (linux-libre-deblob-scripts linux-libre-4.19-version @@ -390,7 +390,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1jiaw0as1ippkrjdpd52657w5mz9qczg3y2hlra7m9k0xawwiqlf"))) (define-public linux-libre-4.19-pristine-source (let ((version linux-libre-4.19-version) - (hash (base32 "1amafhydq934a04pizc5w4h4y4ny982zn33yrz7q0h2d6sskmyp5"))) + (hash (base32 "1l72wka1dli0jdb91sx4zr13vy0q5l6p37fh6hf093gjn14mdh51"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.19))) -- cgit v1.2.3 From cb09ac57b4ba1a3ebc641914c6c91a1054088a21 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:44:20 +0100 Subject: gnu: Add rust-cipher-0.2. * gnu/packages/crates-io.scm (rust-cipher-0.2): New variable. --- gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index e3571ab595..f379c375de 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5543,6 +5543,32 @@ chain, the first matching branch is the item that gets emitted.") (description "This package provides Rust bindings for libclang.") (license license:asl2.0))) +(define-public rust-cipher-0.2 + (package + (name "rust-cipher") + (version "0.2.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "cipher" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "00b8imbmdg7zdrbaczlivmdfdy09xldg95wl4iijl15xgjcfgy0j")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-blobby" ,rust-blobby-0.3) + ("rust-generic-array" ,rust-generic-array-0.14)))) + (home-page "https://docs.rs/cipher/") + (synopsis "Traits for describing block ciphers and stream ciphers") + (description "This package provides traits which define the functionality +of block ciphers and stream ciphers. See RustCrypto/block-ciphers and +RustCrypto/stream-ciphers for algorithm implementations which use these +traits.") + (license (list license:expat license:asl2.0)))) + (define-public rust-clang-sys-0.29 (package (inherit rust-clang-sys-1) -- cgit v1.2.3 From cecd572bd7027791cdb56c42b3657ea842cf5221 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:49:08 +0100 Subject: gnu: Add rust-cmac-0.5. * gnu/packages/crates-io.scm (rust-cmac-0.5): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index f379c375de..721ad88419 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5863,6 +5863,31 @@ contains all syscalls and related types.") license:asl2.0 license:zlib)))) +(define-public rust-cmac-0.5 + (package + (name "rust-cmac") + (version "0.5.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "cmac" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0wj2kd4lb5hb7dvxfad4hi8gklmbq8vvvcnzmmqgxr94fx7xxm3k")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-crypto-mac" ,rust-crypto-mac-0.10) + ("rust-dbl" ,rust-dbl-0.3)))) + (home-page "https://docs.rs/cmac/") + (synopsis "Generic implementation of Cipher-based Message Authentication +Code") + (description "This package provides a pure Rust implementation of the +Cipher-based Message Authentication Code (CMAC).") + (license (list license:expat license:asl2.0)))) ; at your choice + (define-public rust-cmake-0.1 (package (name "rust-cmake") -- cgit v1.2.3 From 91f05b1bc48506a7ba43271575d869d915bbea37 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:50:13 +0100 Subject: gnu: Add rust-ctr-0.6. * gnu/packages/crates-io.scm (rust-ctr-0.6): New variable. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 721ad88419..711b482b3f 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7983,6 +7983,31 @@ Transparency logs for use with sct crate.") "This package provides an @code{__attribute__((constructor))} for Rust.") (license (list license:asl2.0 license:expat)))) +(define-public rust-ctr-0.6 + (package + (name "rust-ctr") + (version "0.6.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "ctr" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0zvyf13675hrlc37myj97k5ng7m1mj3d9p4ic4yvyhvl9zak0jpv")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-cipher" ,rust-cipher-0.2)))) + (home-page "https://docs.rs/ctr/") + (synopsis "CTR block mode of operation") + (description "This package provides a generic implementations of CTR mode +for block ciphers. + +Mode functionality is accessed using traits from re-exported cipher crate.") + (license (list license:expat license:asl2.0)))) + (define-public rust-ctrlc-3.1 (package (name "rust-ctrlc") -- cgit v1.2.3 From 7ce8284fbcbea202921e751405f7cab621c597fc Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:56:14 +0100 Subject: gnu: Add rust-dbl-0.3. * gnu/packages/crates-io.scm (rust-dbl-0.3): New varible. --- gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 711b482b3f..d961e06966 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -8553,6 +8553,31 @@ hexadecimal, base32, and base64.") and arithmetic.") (license license:expat))) +(define-public rust-dbl-0.3 + (package + (name "rust-dbl") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "dbl" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "1pihf6zrzncbs3lsyqkzxxxqmjf8rfpwvs1sg8nmz8cv7df18d97")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-generic-array" ,rust-generic-array-0.14)))) + (home-page "https://docs.rs/dbl") + (synopsis "Double operation in Galois Field") + (description + "This package provides double and inverse double over Galois Field - +GF(2^n). This trait is implemented for 64, 128 and 256 bit block +sizes. Big-endian order is used. WARNING: Block must be aligned!") + (license (list license:expat license:asl2.0)))) + (define-public rust-decimal-2.0 (package (name "rust-decimal") -- cgit v1.2.3 From 7079060cb08a3d9827d064057d6c36cc37e5996c Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:57:16 +0100 Subject: gnu: Add rust-eax-0.3. * gnu/packages/crates-io.scm (rust-eax-0.3): New variable. --- gnu/packages/crates-io.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d961e06966..40fa3266c4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -9945,6 +9945,37 @@ waiting for them to complete. Threads are allowed to borrow local variables from the main thread.") (license (list license:asl2.0 license:expat)))) +(define-public rust-eax-0.3 + (package + (name "rust-eax") + (version "0.3.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "eax" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "0vmpbqncpbj2ldm3fhfz87ija1sk4zk9vad91yd2jjsrbrx6xxz1")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-aead" ,rust-aead-0.3) + ("rust-cipher" ,rust-cipher-0.2) + ("rust-cmac" ,rust-cmac-0.5) + ("rust-ctr" ,rust-ctr-0.6) + ("rust-subtle" ,rust-subtle-2)))) + (home-page "https://docs.rs/eax/") + (synopsis "Pure Rust implementation of the EAX Authenticated Encryption +with Associated Data (AEAD)") + (description "This package provides a pure Rust implementation of the EAX +Authenticated Encryption with Associated Data (AEAD) Cipher with optional +architecture-specific hardware acceleration. This scheme is only based on a +block cipher. It uses counter mode (CTR) for encryption and CBC mode for +generating a OMAC/CMAC/CBCMAC (all names for the same thing).") + (license (list license:asl2.0 license:expat)))) ; at your choice + (define-public rust-ed25519-1 (package (name "rust-ed25519") -- cgit v1.2.3 From 5fb1ad6e5751ea6b1264ddfd54c385c391745e7e Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:58:07 +0100 Subject: gnu: Add rust-sha1collisiondetection-0.2. * gnu/packages/crates-io.scm (rust-sha1collisiondetection-0.2): New variable. --- gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 40fa3266c4..2091ed7d12 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -31482,6 +31482,36 @@ functionality and without weak references.") "Assembly implementation of SHA-1 compression function.") (license license:expat))) +(define-public rust-sha1collisiondetection-0.2 + (package + (name "rust-sha1collisiondetection") + (version "0.2.3") + (source + (origin + (method url-fetch) + (uri (crate-uri "sha1collisiondetection" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "10nh7s3d02136kkz93pxyfv628ls5xz8ndg27pkb6na0ghccz9np")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t + #:cargo-inputs + (("rust-digest" ,rust-digest-0.9) + ("rust-generic-array" ,rust-generic-array-0.14) + ("rust-libc" ,rust-libc-0.2) + ("rust-sha-1" ,rust-sha-1-0.9) + ("rust-structopt" ,rust-structopt-0.3)))) + (home-page "https://docs.rs/sha1collisiondetection") + (synopsis "SHA-1 hash function with collision detection and mitigation") + (description + "This package implementation of the SHA-1 cryptographic hash algorithm. + +This is a port of Marc Stevens' sha1collisiondetection algorithm to Rust. The +code is translated from C to Rust using c2rust.") + (license license:expat))) + (define-public rust-sha2-0.9 (package (name "rust-sha2") -- cgit v1.2.3 From 4c640083f59aa14135c781a9c62a2a144fc42da5 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:58:52 +0100 Subject: gnu: Add rust-crypto-mac-0.10. * gnu/packages/crates-io.scm (rust-crypto-mac-0.10): New variable. (rust-crypto-mac-0.8) Inherit from rust-crypto-mac-0.10. --- gnu/packages/crates-io.scm | 37 +++++++++++++++++++++++++++++-------- 1 file changed, 29 insertions(+), 8 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 2091ed7d12..30f2657af9 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -7588,10 +7588,10 @@ manipulating terminals.") around common WinAPI calls.") (license license:expat))) -(define-public rust-crypto-mac-0.8 +(define-public rust-crypto-mac-0.10 (package (name "rust-crypto-mac") - (version "0.8.0") + (version "0.10.0") (source (origin (method url-fetch) @@ -7599,20 +7599,41 @@ around common WinAPI calls.") (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 - "1axfs4zmy74rn9666p92j7nmcv11zdp2d51yrppc2dv26cqa715m")))) + (base32 "19iyh7h9qaqrv29dhbd31rm6pq023ry78nw7jwr3qjy3l22zsms8")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs - (("rust-blobby" ,rust-blobby-0.1) - ("rust-generic-array" ,rust-generic-array-0.14) - ("rust-subtle" ,rust-subtle-2)))) + `(#:skip-build? #t + #:cargo-inputs + (("rust-blobby" ,rust-blobby-0.3) + ("rust-cipher" ,rust-cipher-0.2) + ("rust-generic-array" ,rust-generic-array-0.14) + ("rust-subtle" ,rust-subtle-2)))) (home-page "https://github.com/RustCrypto/traits") (synopsis "Trait for Message Authentication Code (MAC) algorithms") (description "This package provides trait for @dfn{Message Authentication Code} (MAC) algorithms.") (license (list license:expat license:asl2.0)))) +(define-public rust-crypto-mac-0.8 + (package + (inherit rust-crypto-mac-0.10) + (name "rust-crypto-mac") + (version "0.8.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "crypto-mac" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1rbrq6qy9dl0pj4ym2zy33miaaa8vpzdss60p9bdb58xy46l0d24")))) + (arguments + `(#:cargo-inputs + (("rust-blobby" ,rust-blobby-0.1) + ("rust-generic-array" ,rust-generic-array-0.14) + ("rust-subtle" ,rust-subtle-2)))))) + (define-public rust-crypto-mac-0.7 (package (inherit rust-crypto-mac-0.8) -- cgit v1.2.3 From beb03faee7dfe38281474f3347c25633e30a8cc2 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:07:58 +0100 Subject: gnu: Add rust-pin-utils-0.1. * gnu/packages/crates-io.scm (rust-pin-utils-0.1): New variable. --- gnu/packages/crates-io.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 30f2657af9..581b1e5260 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -24161,6 +24161,25 @@ written with declarative macros.") ("rust-static-assertions" ,rust-static-assertions-1) ("rust-trybuild" ,rust-trybuild-1)))))) +(define-public rust-pin-utils-0.1 + (package + (name "rust-pin-utils") + (version "0.1.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "pin-utils" version)) + (file-name + (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "117ir7vslsl2z1a7qzhws4pd01cg2d3338c47swjyvqv2n60v1wb")))) + (build-system cargo-build-system) + (arguments `(#:skip-build? #t)) + (home-page "https://docs.rs/pin-utils") + (synopsis "Utilities for pinning") + (description "This package provides utilities for pinning.") + (license (list license:expat license:asl2.0)))) + (define-public rust-pkg-config-0.3 (package (name "rust-pkg-config") -- cgit v1.2.3 From f1676daac75b91259a029dbf9c9baed69790a0a3 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:12:32 +0100 Subject: gnu: Replace rust-capnp-0.10 by rust-capnp-0.13. * gnu/packages/crates-io.scm (rust-capnp-0.10): Update to 0.13.6 and rename to rust-capnp-0.13. [arguments] Add skip-build. --- gnu/packages/crates-io.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 581b1e5260..fc6a8d8bf0 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5043,20 +5043,21 @@ directories and @code{CACHEDIR.TAG} files.") "This package provides a callback-based event loop") (license license:expat))) -(define-public rust-capnp-0.10 +(define-public rust-capnp-0.13 (package (name "rust-capnp") - (version "0.10.3") + (version "0.13.6") (source (origin (method url-fetch) (uri (crate-uri "capnp" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "17hsnmlcrzksjjpwpz51y8g36xzq8042i2cwns0lsg7rixfw2rxq")))) + (base32 "1bx2pj0ysmyd1ryd5s43m3c7n5k067x1aciqiiyg4kjswlcs6xjf")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs + `(#:skip-build? #t + #:cargo-inputs (("rust-futures" ,rust-futures-0.1) ("rust-quickcheck" ,rust-quickcheck-0.2)) #:cargo-development-inputs -- cgit v1.2.3 From d6e63eb48b0b327c4e77a539e886d8707aaf916c Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:36:10 +0100 Subject: gnu: Replace rust-capnp-futures-0.10 by rust-capnp-futures-0.13. * gnu/packages/crates-io.scm (rust-capnp-futures-0.10): Update to 0.13.2 and rename to (rust-capnp-futures-0.13). [arguments] Add skip-build. {cargo-inputs}: Update rust-capnp to rust-capnp-0.13. --- gnu/packages/crates-io.scm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index fc6a8d8bf0..7793e50bd4 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5068,24 +5068,25 @@ directories and @code{CACHEDIR.TAG} files.") encoding.") (license license:expat))) -(define-public rust-capnp-futures-0.10 +(define-public rust-capnp-futures-0.13 (package (name "rust-capnp-futures") - (version "0.10.1") + (version "0.13.2") (source (origin (method url-fetch) (uri (crate-uri "capnp-futures" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0qdiqkp9mh4acpa0dqhpzv2gwf949rj3m85mgwl1rih6gvgbh1zs")))) + (base32 "18q93ncbfcnjq7zhvy9idnifypmi2qcp775q7454y3r4lvvdcyyw")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs - (("rust-capnp" ,rust-capnp-0.10) + `(#:skip-build? #t + #:cargo-inputs + (("rust-capnp" ,rust-capnp-0.13) ("rust-futures" ,rust-futures-0.1)) #:cargo-development-inputs - (("rust-capnp" ,rust-capnp-0.10) + (("rust-capnp" ,rust-capnp-0.13) ("rust-quickcheck" ,rust-quickcheck-0.2)))) (home-page "https://github.com/capnproto/capnproto-rust") (synopsis "Async serialization for Cap'n Proto messages") -- cgit v1.2.3 From d5653a37a24f832431ae4c42b09d2aa278851369 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:36:44 +0100 Subject: gnu: Replace rust-capnp-rpc-0.10 by rust-capnp-rpc-0.13. * gnu/packages/crates-io.scm (rust-capnp-rpc-0.10): Update to 0.13.1 and rename to rust-capnp-rpc-0.13. [arguments] Add skip-build. {cargo-inputs}: Update rust-capnp to rust-capnp-0.13. Update rust-capnp-futures to rust-capnp-futures-0.13. --- gnu/packages/crates-io.scm | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7793e50bd4..c46f51d950 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5094,27 +5094,28 @@ encoding.") messages.") (license license:expat))) -(define-public rust-capnp-rpc-0.10 +(define-public rust-capnp-rpc-0.13 (package (name "rust-capnp-rpc") - (version "0.10.0") + (version "0.13.1") (source (origin (method url-fetch) (uri (crate-uri "capnp-rpc" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1j6xg7yays1hlm1045wviyn1642yvvi2p4kba26yk07a0kafr3jn")))) + (base32 "17p0y0yk68pzsnpmaklhiqrrlrrv0ld8nhbg4qflmgibshi8b69p")))) (build-system cargo-build-system) (native-inputs `(("capnproto" ,capnproto))) (arguments - `(#:cargo-inputs - (("rust-capnp" ,rust-capnp-0.10) - ("rust-capnp-futures" ,rust-capnp-futures-0.10) + `(#:skip-build? #t + #:cargo-inputs + (("rust-capnp" ,rust-capnp-0.13) + ("rust-capnp-futures" ,rust-capnp-futures-0.13) ("rust-futures" ,rust-futures-0.1)) #:cargo-development-inputs - (("rust-capnpc" ,rust-capnpc-0.10)))) + (("rust-capnpc" ,rust-capnpc-0.13)))) (home-page "https://github.com/capnproto/capnproto-rust") (synopsis "Cap'n Proto remote procedure call protocol implementation") (description "This package provides an implementation of the Cap'n Proto -- cgit v1.2.3 From 2e4bfeb4fef46a0b74f5228bda67e0740c751dba Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:37:29 +0100 Subject: gnu: Replace rust-capnpc-0.10 by rust-capnpc-0.13. * gnu/packages/crates-io.scm (rust-capnpc-0.10): Update to 0.13.1 and rename to rust-capnpc-0.13. [arguments] Add skip-build. {cargo-inputs}: Update rust-capnp to rust-capnp-0.13. --- gnu/packages/crates-io.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index c46f51d950..7a8bd9e600 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -5122,20 +5122,21 @@ messages.") remote procedure call protocol") (license license:expat))) -(define-public rust-capnpc-0.10 +(define-public rust-capnpc-0.13 (package (name "rust-capnpc") - (version "0.10.2") + (version "0.13.1") (source (origin (method url-fetch) (uri (crate-uri "capnpc" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "1zxbmdkr0xfzkfq9p8zn7pp9jjq275qhr8fh9a0cc0ab37yfvbyj")))) + (base32 "1hbm5xqpam3f0ha5ds39wjmpqpzdalpbrls9wlp7m3slh3p5r1c1")))) (build-system cargo-build-system) (arguments - `(#:cargo-inputs (("rust-capnp" ,rust-capnp-0.10)))) + `(#:skip-build? #t + #:cargo-inputs (("rust-capnp" ,rust-capnp-0.13)))) (home-page "https://github.com/capnproto/capnproto-rust") (synopsis "Cap'n Proto code generation") (description "Cap'n Proto code generation") -- cgit v1.2.3 From fe9ed313ebf25da5013e7d3b5f60b0fb2a7aed31 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 18:59:34 +0100 Subject: gnu: Replace rust-win-crypto-ng-0.2 by rust-win-crypto-ng-0.4. * gnu/packages/crates-io.scm (rust-win-crypto-ng-0.2): Update to 0.4.0 and rename to (rust-win-crypto-ng-0.4). [arguments]{cargo-inouts}: Add rust-cipher. --- gnu/packages/crates-io.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index 7a8bd9e600..ee0163b3ad 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -40625,22 +40625,23 @@ color in a Windows console.") (license (list license:unlicense license:expat)))) -(define-public rust-win-crypto-ng-0.2 +(define-public rust-win-crypto-ng-0.4 (package (name "rust-win-crypto-ng") - (version "0.2.1") + (version "0.4.0") (source (origin (method url-fetch) (uri (crate-uri "win-crypto-ng" version)) (file-name (string-append name "-" version ".tar.gz")) (sha256 - (base32 "0ab0iwl4bmqvysypyn6xgax7rlh3w524jji2y1zfwfpdr7wwyv23")))) + (base32 "0v26ssjip8fdilj1j6csnvcny98gb90ra1qlnm2xwjlgivlr5kr4")))) (build-system cargo-build-system) (arguments `(#:skip-build? #t #:cargo-inputs - (("rust-doc-comment" ,rust-doc-comment-0.3) + (("rust-cipher" ,rust-cipher-0.2) + ("rust-doc-comment" ,rust-doc-comment-0.3) ("rust-rand-core" ,rust-rand-core-0.5) ("rust-winapi" ,rust-winapi-0.3) ("rust-zeroize" ,rust-zeroize-1)))) -- cgit v1.2.3 From e0158630d3355d27fc29bb2aba36967f5a313b95 Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:00:14 +0100 Subject: gnu: rust-socket2: Update to 0.3.19. * gnu/packages/crates-io.scm (rust-socket2): Update to 0.3.19. [arguments]{cargo-inputs}: Remove rust-redox-syscall. --- gnu/packages/crates-io.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index ee0163b3ad..d173a0607e 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -32407,21 +32407,20 @@ stack.") (define-public rust-socket2-0.3 (package (name "rust-socket2") - (version "0.3.18") + (version "0.3.19") (source (origin (method url-fetch) (uri (crate-uri "socket2" version)) (file-name (string-append name "-" version ".crate")) (sha256 - (base32 "0mqh39dkspcz3x11jhck9k2yrbx2krawn7xr3zva8n3lazyykq4p")))) + (base32 "0vldz14mxqxnjqb6an2pj7mgclv7nrk45cpscwq7g3fj2c0mfbhj")))) (build-system cargo-build-system) (arguments `(#:tests? #f ; tests require network access #:cargo-inputs (("rust-cfg-if" ,rust-cfg-if-1) ("rust-libc" ,rust-libc-0.2) - ("rust-redox-syscall" ,rust-redox-syscall-0.1) ("rust-winapi" ,rust-winapi-0.3)) #:cargo-development-inputs (("rust-tempdir" ,rust-tempdir-0.3)))) -- cgit v1.2.3 From a240686cc34454a3221c31f3c546985c2c90bf2c Mon Sep 17 00:00:00 2001 From: Hartmut Goebel Date: Wed, 16 Dec 2020 20:13:42 +0100 Subject: gnu: sequoia: Update to 1.0.0. * gnu/packages/sequoia.scm (sequoia): Update to 1.0.0. [arguments]{cargo-inputs}: Add rust-eax, rust-futures-util, rust-sha1collisiondetection, rust-socket2. Update rust-capnp, rust-capnp-rpc, rust-capnpc, rust-futures, rust-http,rust-hyper rust-hyper-tls, rust-tokio, rust-win-crypto-ng. --- gnu/packages/sequoia.scm | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/gnu/packages/sequoia.scm b/gnu/packages/sequoia.scm index f07416c315..ce3396a7c4 100644 --- a/gnu/packages/sequoia.scm +++ b/gnu/packages/sequoia.scm @@ -40,7 +40,7 @@ (define-public sequoia (package (name "sequoia") - (version "0.20.0") + (version "1.0.0") (source (origin (method git-fetch) @@ -48,7 +48,7 @@ (url "https://gitlab.com/sequoia-pgp/sequoia.git") (commit (string-append "v" version)))) (sha256 - (base32 "1c76sz4y0n4jhf1gq4b87v5c07i09mmd3i6sqki09bd96m3ldgkf")) + (base32 "0y80bl786m29ww3272qsl1ql0xc3pwd6iiqlkv3nmhnjsmygbn0d")) (file-name (git-file-name name version)))) (build-system cargo-build-system) (outputs '("out" "python")) @@ -75,9 +75,9 @@ ("rust-base64" ,rust-base64-0.13) ;;("rust-buffered-reader" included ("rust-bzip2" ,rust-bzip2-0.4) - ("rust-capnp" ,rust-capnp-0.10) - ("rust-capnp-rpc" ,rust-capnp-rpc-0.10) - ("rust-capnpc" ,rust-capnpc-0.10) + ("rust-capnp" ,rust-capnp-0.13) + ("rust-capnp-rpc" ,rust-capnp-rpc-0.13) + ("rust-capnpc" ,rust-capnpc-0.13) ("rust-chrono" ,rust-chrono-0.4) ;; for sqv, sop ("rust-clap" ,rust-clap-2) ;; for sqv ("rust-colored" ,rust-colored-1.9.1) @@ -86,14 +86,16 @@ ("rust-dirs" ,rust-dirs-2.0) ("rust-dyn-clone" ,rust-dyn-clone-1) ("rust-ed25519-dalek" ,rust-ed25519-dalek-1) + ("rust-eax" ,rust-eax-0.3) ;;("rust-failure" included ("rust-filetime" ,rust-filetime-0.2) ("rust-flate2" ,rust-flate2-1) ("rust-fs2" ,rust-fs2-0.4) - ("rust-futures" ,rust-futures-0.1) - ("rust-http" ,rust-http-0.1) - ("rust-hyper" ,rust-hyper-0.12) - ("rust-hyper-tls" ,rust-hyper-tls-0.3) + ("rust-futures" ,rust-futures-0.3) + ("rust-futures-util" ,rust-futures-util-0.3) + ("rust-http" ,rust-http-0.2) + ("rust-hyper" ,rust-hyper-0.13) + ("rust-hyper-tls" ,rust-hyper-tls-0.4) ("rust-idna" ,rust-idna-0.2) ("rust-itertools" ,rust-itertools-0.9) ;; for sq ("rust-lalrpop" ,rust-lalrpop-0.19) @@ -112,14 +114,16 @@ ("rust-rand" ,rust-rand-0.7) ("rust-regex" ,rust-regex-1) ("rust-rusqlite" ,rust-rusqlite-0.24) + ("rust-sha1collisiondetection" ,rust-sha1collisiondetection-0.2) + ("rust-socket2", rust-socket2-0.3) ("rust-structopt" ,rust-structopt-0.3) ;; for sop ("rust-tempfile" ,rust-tempfile-3) ;; for sq ("rust-thiserror" ,rust-thiserror-1) - ("rust-tokio" ,rust-tokio-0.1) + ("rust-tokio" ,rust-tokio-0.2) ("rust-tokio-core" ,rust-tokio-core-0.1) ("rust-unicode-normalization" ,rust-unicode-normalization-0.1) ("rust-url" ,rust-url-2) - ("rust-win-crypto-ng" ,rust-win-crypto-ng-0.2) + ("rust-win-crypto-ng" ,rust-win-crypto-ng-0.4) ("rust-winapi" ,rust-winapi-0.3) ("rust-zbase32" ,rust-zbase32-0.1)) #:cargo-development-inputs -- cgit v1.2.3 From b76ae073722910b1373301293f0acabd7c0833ee Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Fri, 8 Jan 2021 10:21:08 +0100 Subject: gnu: Add cl-dynamic-classes. * gnu/packages/lisp-xyz.scm (cl-dynamic-classes, ecl-dynamic-classes, sbcl-dynamic-classes): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 6d87329c16..02eb0fcb20 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -12872,3 +12872,36 @@ It aims to be implementation-agnostic and to climb the syntax trees.") (define-public ecl-agnostic-lizard (sbcl-package->ecl-package sbcl-agnostic-lizard)) + +(define-public sbcl-dynamic-classes + (package + (name "sbcl-dynamic-classes") + (version "1.0.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/gwkkwg/dynamic-classes") + (commit (string-append "version-" version)))) + (file-name (git-file-name "dynamic-classes" version)) + (sha256 + (base32 "1z3ag6w4ff0v6715xa9zhvwjqnp4i6zrjfmxdz8m115sklbwgm6c")))) + (build-system asdf-build-system/sbcl) + (inputs + `(("metatilities-base" ,sbcl-metatilities-base))) + (arguments + ;; NOTE: (Sharlatan-20210106222900+0000) Circular dependencies and failing + ;; test suites. lift-standard.config contains referances to deprecated + ;; functionality. + `(#:tests? #f)) + (home-page "https://common-lisp.net/project/dynamic-classes/") + (synopsis "Dynamic class definition for Common Lisp") + (description "Dynamic-Classes helps to ease the prototyping process by +bringing dynamism to class definition.") + (license license:expat))) + +(define-public ecl-dynamic-classes + (sbcl-package->ecl-package sbcl-dynamic-classes)) + +(define-public cl-dynamic-classes + (sbcl-package->cl-source-package sbcl-dynamic-classes)) -- cgit v1.2.3 From 375c44de40827a33369a93f5745f272e491f4150 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Fri, 8 Jan 2021 10:38:48 +0100 Subject: gnu: Add cl-markdown. * gnu/packages/lisp-xyz.scm (cl-markdown, ecl-cl-markdown, sbcl-cl-markdown): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 02eb0fcb20..52abef3d85 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -12905,3 +12905,43 @@ bringing dynamism to class definition.") (define-public cl-dynamic-classes (sbcl-package->cl-source-package sbcl-dynamic-classes)) + +(define-public sbcl-cl-markdown + ;; NOTE: (Sharlatan-20210106214629+0000) latest version tag + ;; "version-0.10.6_version-0.10.6" is failing to build due to missing system + ;; #:container-dynamic-classes + (package + (name "sbcl-cl-markdown") + (version "0.10.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/gwkkwg/cl-markdown") + (commit (string-append "version-" version)))) + (file-name (git-file-name "cl-markdown" version)) + (sha256 + (base32 "1wdjbdd1zyskxf7zlilcp6fmwkivybj0wjp64vvzb265d5xi7p8p")))) + (build-system asdf-build-system/sbcl) + (inputs + `(("anaphora" ,sbcl-anaphora) + ("cl-containers" ,sbcl-cl-containers) + ("cl-ppcre" ,sbcl-cl-ppcre) + ("dynamic-classes" ,sbcl-dynamic-classes) + ("metabang-bind" ,sbcl-metabang-bind) + ("metatilities-base" ,sbcl-metatilities-base))) + (arguments + ;; NOTE: (Sharlatan-20210107213629+0000) Tests depend on too many not + ;; available systems, which themself are abandoned. + `(#:tests? #f)) + (home-page "https://common-lisp.net/project/cl-markdown/") + (synopsis "Common Lisp rewrite of Markdown") + (description + "This is an implementation of a Markdown parser in Common Lisp.") + (license license:expat))) + +(define-public ecl-cl-markdown + (sbcl-package->ecl-package sbcl-cl-markdown)) + +(define-public cl-markdown + (sbcl-package->cl-source-package sbcl-cl-markdown)) -- cgit v1.2.3 From f4cc6787f51a387f258cc7bd81a1b19abac2b6da Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Fri, 8 Jan 2021 12:55:32 +0200 Subject: gnu: rust-pin-utils-0.1: Deduplicate duplicate definitions. * gnu/packages/crates-io.scm (rust-pin-utils-0.1): Combine duplicate definitions. --- gnu/packages/crates-io.scm | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm index d173a0607e..38d6fe806a 100644 --- a/gnu/packages/crates-io.scm +++ b/gnu/packages/crates-io.scm @@ -23999,25 +23999,6 @@ function data structures.") "This package provides bindings to the PicoHTTPParser.") (license license:expat))) -(define-public rust-pin-utils-0.1 - (package - (name "rust-pin-utils") - (version "0.1.0") - (source - (origin - (method url-fetch) - (uri (crate-uri "pin-utils" version)) - (file-name (string-append name "-" version ".crate")) - (sha256 - (base32 - "117ir7vslsl2z1a7qzhws4pd01cg2d3338c47swjyvqv2n60v1wb")))) - (build-system cargo-build-system) - (home-page "https://github.com/rust-lang-nursery/pin-utils") - (synopsis "Utilities for pinning") - (description "This crate provides utilities for pinning values on the stack.") - (license (list license:asl2.0 - license:expat)))) - (define-public rust-pin-project-1 (package (name "rust-pin-project") @@ -24178,10 +24159,9 @@ written with declarative macros.") (sha256 (base32 "117ir7vslsl2z1a7qzhws4pd01cg2d3338c47swjyvqv2n60v1wb")))) (build-system cargo-build-system) - (arguments `(#:skip-build? #t)) (home-page "https://docs.rs/pin-utils") (synopsis "Utilities for pinning") - (description "This package provides utilities for pinning.") + (description "This crate provides utilities for pinning values on the stack.") (license (list license:expat license:asl2.0)))) (define-public rust-pkg-config-0.3 -- cgit v1.2.3 From 0a40da604f8bae39d8624745d89966fc9edc8d1f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 8 Jan 2021 13:33:30 +0100 Subject: gnu: Add schmutz. * gnu/packages/guile-xyz.scm (schmutz): New variable. --- gnu/packages/guile-xyz.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 92aee2f2e9..c5eaa8a2ca 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -108,6 +108,7 @@ #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix hg-download) + #:use-module (guix build-system cmake) #:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system gnu) #:use-module (guix build-system guile) @@ -4427,3 +4428,31 @@ including parsing and code generation.") (description "Guile Shapefile is a Guile library for reading shapefiles.") (license license:expat))) + +(define-public schmutz + (let ((commit "add24588c59552537b8f1316df99a0cdd62c221e") + (revision "1")) + (package + (name "schmutz") + (version (git-version "0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/arximboldi/schmutz") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1z3n61sj62lnn15mandvyrpjzli07rp9r62ypvgg3a8bvh37yc89")))) + (build-system cmake-build-system) + (arguments `(#:tests? #f)) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("guile" ,guile-2.2))) + (home-page "https://github.com/arximboldi/schmutz") + (synopsis "Bind C++ code to Scheme") + (description "Schmutz is a header-only library to declare Scheme bindings +for C++ code using a simple embedded DSL. Think of it as @code{Boost.Python} +or @code{LuaBind} but for Scheme.") + (license license:boost1.0)))) -- cgit v1.2.3 From bd089edd1ae1d53dc83e90fbb3985a471e879679 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Fri, 8 Jan 2021 11:37:38 +0100 Subject: gnu: monero: Update to 0.17.1.9. * gnu/packages/finance.scm (monero): Update to 0.17.1.9. --- gnu/packages/finance.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index 326df299a2..c6fe6aaa67 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -11,7 +11,7 @@ ;;; Copyright © 2018 Adriano Peluso ;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou ;;; Copyright © 2018 Arun Isaac -;;; Copyright © 2019, 2020 Guillaume Le Vaillant +;;; Copyright © 2019, 2020, 2021 Guillaume Le Vaillant ;;; Copyright © 2019 Tanguy Le Carrour ;;; Copyright © 2019, 2020 Martin Becze ;;; Copyright © 2019 Sebastian Schott @@ -630,7 +630,7 @@ other machines/servers. Electroncash does not download the Bitcoin Cash blockch ;; the system's dynamically linked library. (package (name "monero") - (version "0.17.1.8") + (version "0.17.1.9") (source (origin (method git-fetch) @@ -650,7 +650,7 @@ other machines/servers. Electroncash does not download the Bitcoin Cash blockch "external/unbound")) #t)) (sha256 - (base32 "10blazbk1602slx3wrmw4jfgkdry55iclrhm5drdficc5v3h735g")))) + (base32 "0jqss4csvkcrhrmaa3vrnyv6yiwqpbfw7037clx9xcfm4qrrfiwy")))) (build-system cmake-build-system) (native-inputs `(("doxygen" ,doxygen) -- cgit v1.2.3 From 9524a2877b18b12fa71dceda4e22eb9d9032eb26 Mon Sep 17 00:00:00 2001 From: Guillaume Le Vaillant Date: Fri, 8 Jan 2021 13:35:32 +0100 Subject: gnu: monero-gui: Update to 0.17.1.9. * gnu/packages/finance.scm (monero-gui): Update to 0.17.1.9. [source]: Fetch submodules. Add snippet to remove embedded monero sources. --- gnu/packages/finance.scm | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index c6fe6aaa67..e7d58bbcc0 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -740,16 +740,24 @@ the Monero command line client and daemon.") (define-public monero-gui (package (name "monero-gui") - (version "0.17.1.8") + (version "0.17.1.9") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/monero-project/monero-gui") - (commit (string-append "v" version)))) + (commit (string-append "v" version)) + (recursive? #t))) (file-name (git-file-name name version)) + (modules '((guix build utils))) + (snippet + '(begin + ;; Delete bundled monero sources, we already have them. + ;; See the 'extract-monero-sources' phase. + (delete-file-recursively "monero") + #t)) (sha256 - (base32 "13cjrfdkr7c2ff8j2rg8hvhlc00af38vcs67wlx2109i2baq4pp3")))) + (base32 "0vpvpvsbbj547yir15g84qy9l9lwbip795zlliz79i7d66l23b1w")))) (build-system qt-build-system) (native-inputs `(,@(package-native-inputs monero) @@ -778,6 +786,7 @@ the Monero command line client and daemon.") ;; Some of the monero package source code is required ;; to build the GUI. (lambda* (#:key inputs #:allow-other-keys) + (mkdir-p "monero") (invoke "tar" "-xv" "--strip-components=1" "-C" "monero" "-f" (assoc-ref inputs "monero-source")))) -- cgit v1.2.3 From 55f71f0ef753971b44cd057008ba95f74950e9c6 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 8 Jan 2021 16:02:44 +0100 Subject: gnu: yoshimi: Update to 1.7.4. * gnu/packages/music.scm (yoshimi): Update to 1.7.4. --- gnu/packages/music.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index aba87ab6f2..e787d7ba36 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014, 2019 Eric Bavier -;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Ricardo Wurmus +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ricardo Wurmus ;;; Copyright © 2015 Paul van der Walt ;;; Copyright © 2016 Al McElrath ;;; Copyright © 2016, 2017, 2019 Efraim Flashner @@ -2653,7 +2653,7 @@ capabilities, custom envelopes, effects, etc.") (define-public yoshimi (package (name "yoshimi") - (version "1.7.3") + (version "1.7.4") (source (origin (method url-fetch) @@ -2661,7 +2661,7 @@ capabilities, custom envelopes, effects, etc.") (version-major+minor version) "/yoshimi-" version ".tar.bz2")) (sha256 - (base32 "1ixb2kqmfgm2lfjaj6z3h03c840hcfmca4h6pjnc4aln2mzm7fcw")))) + (base32 "0lxfqj4p4njww3n0wa6yfj38zfls16y3wszd47gvc5asmqyg5vjd")))) (build-system cmake-build-system) (arguments `(#:tests? #f ; there are no tests -- cgit v1.2.3 From bc8ea17b330deb65ab8031927833ca2f7a4e05f8 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 8 Jan 2021 16:02:54 +0100 Subject: gnu: Add liquidsfz. * gnu/packages/music.scm (liquidsfz): New variable. --- gnu/packages/music.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index e787d7ba36..fc6c29855d 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -4401,6 +4401,36 @@ melodies and beats and for mixing and arranging songs. LMMS includes instrument audio samples and various soft sythesizers. It can receive input from a MIDI keyboard.") (license license:gpl2+))) +(define-public liquidsfz + (package + (name "liquidsfz") + (version "0.2.2") + (source (origin + (method url-fetch) + (uri (string-append "https://space.twc.de/~stefan/liquidsfz/" + "liquidsfz-" version ".tar.bz2")) + (sha256 + (base32 + "011m839vjb8gmiv1vzc0d7xz2q2jiwk4v0j9paqyx3lm61czvy93")))) + (build-system gnu-build-system) + (arguments + `(#:configure-flags '("--enable-shared"))) + (native-inputs + `(("pkg-config" ,pkg-config) + ;; Fails with default gcc (#include not found). + ("gcc" ,gcc-9))) + (inputs + `(("jack" ,jack-2) + ("lv2" ,lv2) + ("readline" ,readline) + ("libsndfile" ,libsndfile))) + (home-page "https://github.com/swesterfeld/liquidsfz") + (synopsis "Sampler library") + (description "The main goal of liquidsfz is to provide an SFZ sampler +implementation library that is easy to integrate into other projects. A +standalone JACK client and an LV2 plugin is also available.") + (license license:lgpl2.1+))) + (define-public musescore (package (name "musescore") -- cgit v1.2.3 From 789dcf5bc43d970b1676e94239a34dfbf699490f Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Fri, 8 Jan 2021 18:13:56 +0100 Subject: gnu: emacs-emms: Fix vorbiscomment path. * gnu/packages/emacs-xyz.scm (emacs-emms)[arguments]: Replace call to "vorbiscomment" by its full store path. --- gnu/packages/emacs-xyz.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 962744263a..209a0da289 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -1720,7 +1720,9 @@ light user interface.") (string-append "\"" alsa "/bin/amixer\""))) (substitute* "emms-tag-editor.el" (("\"mid3v2\"") - (string-append "\"" mutagen "/bin/mid3v2\""))) + (string-append "\"" mutagen "/bin/mid3v2\"")) + (("\"vorbiscomment\"") + (string-append "\"" vorbis "/bin/vorbiscomment\""))) (substitute* "emms-info-exiftool.el" (("\"exiftool\"") (string-append "\"" exiftool "/bin/exiftool\""))) -- cgit v1.2.3 From ddb51f3e903ed53ce3c3a88e2af107360f2c51ac Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Fri, 8 Jan 2021 18:29:39 +0100 Subject: gnu: emacs-howm: Update to 1.4.7. * gnu/packages/emacs-xyz.scm (emacs-howm): Update to 1.4.7. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 209a0da289..08cbb70b0a 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -2155,14 +2155,14 @@ a set of simplified face specifications and a user-supplied color palette") (define-public emacs-howm (package (name "emacs-howm") - (version "1.4.6") + (version "1.4.7") (source (origin (method url-fetch) (uri (string-append "https://howm.sourceforge.jp/a/" "howm-" version ".tar.gz")) (sha256 - (base32 "17ihch1zbk08ih7gc232jlmbw7hax8ldb9glxp8d75k4asa98qh5")))) + (base32 "11k0dzwyn7ly34g0zcd6i0i8qwyv9di8m6fx805axrxykxb0qan2")))) (build-system gnu-build-system) (native-inputs `(("emacs" ,emacs-minimal))) -- cgit v1.2.3 From 069d2bf200d5dd2bda6c15e345001a9191abf733 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Fri, 8 Jan 2021 12:06:06 +0100 Subject: tests: Run 'tests/offload.scm' only when BUILD_DAEMON_OFFLOAD is true. Fixes: guix build -e '(@ (gnu packages package-management) guix-minimal)' * Makefile.am (SCM_TESTS): Move 'tests/offload.scm' within "if BUILD_DAEMON_OFFLOAD" conditional. --- Makefile.am | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index 51ff9c9ec9..99bdcfa346 100644 --- a/Makefile.am +++ b/Makefile.am @@ -462,7 +462,6 @@ SCM_TESTS = \ tests/monads.scm \ tests/nar.scm \ tests/networking.scm \ - tests/offload.scm \ tests/opam.scm \ tests/openpgp.scm \ tests/packages.scm \ @@ -499,6 +498,12 @@ SCM_TESTS = \ tests/uuid.scm \ tests/workers.scm +if BUILD_DAEMON_OFFLOAD +SCM_TESTS += tests/offload.scm +else +EXTRA_DIST += tests/offload.scm +endif + SH_TESTS = \ tests/guix-build.sh \ tests/guix-build-branch.sh \ -- cgit v1.2.3 From a687b995798d8416c53bc2441c2315925de93460 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Fri, 8 Jan 2021 17:57:13 +0100 Subject: gnu: guile: Update to 3.0.5. * gnu/packages/guile.scm (guile-3.0-latest): Update to 3.0.5. --- gnu/packages/guile.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm index 40e42e6f11..1c983e50eb 100644 --- a/gnu/packages/guile.scm +++ b/gnu/packages/guile.scm @@ -312,14 +312,14 @@ without requiring the source code to be rewritten.") ;; TODO: Make this 'guile-3.0' on the next rebuild cycle. (package (inherit guile-3.0) - (version "3.0.4") + (version "3.0.5") (source (origin (inherit (package-source guile-3.0)) (uri (string-append "mirror://gnu/guile/guile-" version ".tar.xz")) (sha256 (base32 - "0c8dkyvs6xbxp7rgnhkyakajzhakay7qn9kahj1mj49x5vf4fybb")))))) + "1wah6fq1h8vmbpdadjych1mq8hyqkd7p015cbxm14ri37l1gnxid")))))) (define-public guile-next (deprecated-package "guile-next" guile-3.0)) -- cgit v1.2.3 From 01fa1cd619cf6ae2971a3d63d5f29580bb3a64cb Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Fri, 8 Jan 2021 18:16:56 -0500 Subject: gnu: icecat: Update to 78.6.1-guix0-preview1 [fixes CVE-2020-16044]. * gnu/packages/gnuzilla.scm (%icecat-version, %icecat-build-id): Update. (icecat-source): Update gnuzilla commit, base version, and hashes. * gnu/packages/patches/icecat-makeicecat.patch: Adapt to new version. --- gnu/packages/gnuzilla.scm | 14 +++++++------- gnu/packages/patches/icecat-makeicecat.patch | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/gnu/packages/gnuzilla.scm b/gnu/packages/gnuzilla.scm index 0c432f5dc1..d3f9dc15b0 100644 --- a/gnu/packages/gnuzilla.scm +++ b/gnu/packages/gnuzilla.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2015 Andreas Enge ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès -;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Mark H Weaver +;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Mark H Weaver ;;; Copyright © 2015 Sou Bunnbu ;;; Copyright © 2016, 2017, 2018, 2019 Efraim Flashner ;;; Copyright © 2016 Alex Griffin @@ -694,8 +694,8 @@ from forcing GEXP-PROMISE." #:system system #:guile-for-build guile))) -(define %icecat-version "78.6.0-guix0-preview1") -(define %icecat-build-id "20201215000000") ;must be of the form YYYYMMDDhhmmss +(define %icecat-version "78.6.1-guix0-preview1") +(define %icecat-build-id "20210107000000") ;must be of the form YYYYMMDDhhmmss ;; 'icecat-source' is a "computed" origin that generates an IceCat tarball ;; from the corresponding upstream Firefox ESR tarball, using the 'makeicecat' @@ -717,11 +717,11 @@ from forcing GEXP-PROMISE." "firefox-" upstream-firefox-version ".source.tar.xz")) (sha256 (base32 - "0lyg65v380j8i2lrylwz8a5ya80822l8vcnlx3dfqpd3s6zzjsay")))) + "1kp75838a38x4h0w98qn01g9asn7jlgm64bz7n70353bnr6bf1qd")))) - (upstream-icecat-base-version "78.6.0") ; maybe older than base-version + (upstream-icecat-base-version "78.6.1") ; maybe older than base-version ;;(gnuzilla-commit (string-append "v" upstream-icecat-base-version)) - (gnuzilla-commit "a43514623e93d4f3fe6d61f5b2f82c5ef29bf518") + (gnuzilla-commit "10ca84bd9d255caeed506ef36bd3dbe2ad6375ab") (gnuzilla-source (origin (method git-fetch) @@ -733,7 +733,7 @@ from forcing GEXP-PROMISE." (string-take gnuzilla-commit 8))) (sha256 (base32 - "0d2hpk4x0hwflhilc3hyj6nl4pv2m53fcv3jc415ca01bigk6drp")))) + "07i3pfbzprnmzrilsh13jjrrk0jixpb9nrrqxzzdvzr2gz06vw29")))) ;; 'search-patch' returns either a valid file name or #f, so wrap it ;; in 'assume-valid-file-name' to avoid 'local-file' warnings. diff --git a/gnu/packages/patches/icecat-makeicecat.patch b/gnu/packages/patches/icecat-makeicecat.patch index 73e87b9612..3f16880260 100644 --- a/gnu/packages/patches/icecat-makeicecat.patch +++ b/gnu/packages/patches/icecat-makeicecat.patch @@ -25,7 +25,7 @@ index 8be2362..48716f2 100755 -wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz.asc -gpg --recv-keys --keyserver keyserver.ubuntu.com 14F26682D0916CDD81E37B6D61B7B526D98F0353 -gpg --verify firefox-${FFVERSION}esr.source.tar.xz.asc --echo -n 5e69f9bfd1a35decdae8d4b28da8100820e58b429f539fa9884802347631cf53 firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c - +-echo -n 0d07b74cb66b94018e3d7f11531f95c76a955e0016a3c401241d0d85062ae7ce firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c - - -echo Extracting Firefox tarball -tar -xf firefox-${FFVERSION}esr.source.tar.xz @@ -37,7 +37,7 @@ index 8be2362..48716f2 100755 +# wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz.asc +# gpg --recv-keys --keyserver keyserver.ubuntu.com 14F26682D0916CDD81E37B6D61B7B526D98F0353 +# gpg --verify firefox-${FFVERSION}esr.source.tar.xz.asc -+# echo -n 5e69f9bfd1a35decdae8d4b28da8100820e58b429f539fa9884802347631cf53 firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c - ++# echo -n 0d07b74cb66b94018e3d7f11531f95c76a955e0016a3c401241d0d85062ae7ce firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c - +# +# echo Extracting Firefox tarball +# tar -xf firefox-${FFVERSION}esr.source.tar.xz -- cgit v1.2.3 From bc66d351649f39b2dd2c00a664e47e54b1d161f4 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 9 Jan 2021 11:38:02 +0100 Subject: gnu: emacs-scheme-complete: Update to 0.9.9. * gnu/packages/emacs-xyz.scm (emacs-scheme-complete): Update to 0.9.9. * gnu/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch: Remove file. * gnu/local.mk: Update file. --- gnu/local.mk | 1 - gnu/packages/emacs-xyz.scm | 11 +++++------ .../patches/emacs-scheme-complete-scheme-r5rs-info.patch | 14 -------------- 3 files changed, 5 insertions(+), 21 deletions(-) delete mode 100644 gnu/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch diff --git a/gnu/local.mk b/gnu/local.mk index 1151d4642e..ec3d6137e7 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -958,7 +958,6 @@ dist_patch_DATA = \ %D%/packages/patches/emacs-highlight-stages-add-gexp.patch \ %D%/packages/patches/emacs-hyperbole-toggle-messaging.patch \ %D%/packages/patches/emacs-libgit-use-system-libgit2.patch \ - %D%/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch \ %D%/packages/patches/emacs-source-date-epoch.patch \ %D%/packages/patches/emacs-telega-patch-server-functions.patch \ %D%/packages/patches/emacs-telega-test-env.patch \ diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 08cbb70b0a..c86452fe2b 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -5722,10 +5722,12 @@ navigation to errors.") (license license:gpl3+))) (define-public emacs-scheme-complete - (let ((commit "9b5cf224bf2a5994bc6d5b152ff487517f1a9bb5")) + ;; Upstream does not provide tags. The commit below corresponds to the + ;; exact version update. Version is extracted from main file. + (let ((commit "5c0a16684a3be7021d67067b2955f1c3e17a320a")) (package (name "emacs-scheme-complete") - (version (string-append "20151223." (string-take commit 8))) + (version "0.9.9") (source (origin (method git-fetch) @@ -5734,10 +5736,7 @@ navigation to errors.") (commit commit))) (file-name (git-file-name name version)) (sha256 - (base32 - "141wn9l0m33w0g3dqmx8nxbfdny1r5xbr6ak61rsz21bk0qafs7x")) - (patches - (search-patches "emacs-scheme-complete-scheme-r5rs-info.patch")))) + (base32 "1smxr5bkzbfrjx21vhrj1wagmqx5yd92i997dbgs16iaqbzzr7cz")))) (build-system emacs-build-system) (home-page "https://github.com/ashinn/scheme-complete") (synopsis "Smart tab completion for Scheme in Emacs") diff --git a/gnu/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch b/gnu/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch deleted file mode 100644 index 6c49bdcdde..0000000000 --- a/gnu/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch +++ /dev/null @@ -1,14 +0,0 @@ -Fix completion for R5RS Scheme. -See https://github.com/ashinn/scheme-complete/issues/1 - ---- scheme-complete-master/scheme-complete.el.orig 2015-12-25 21:59:09.896909029 +0100 -+++ scheme-complete-master/scheme-complete.el 2015-12-25 21:59:17.924993998 +0100 -@@ -591,7 +591,7 @@ - '((exact->inexact (lambda (z) z)) - (inexact->exact (lambda (z) z))) - (mapcar #'(lambda (x) -- (list x (scheme-env-lookup *scheme-r7rs-info* x))) -+ (scheme-env-lookup *scheme-r7rs-info* x)) - *scheme-r5rs-bindings*)))) - *scheme-r5rs-info*) - -- cgit v1.2.3 From 0fab032ae3849a8827b4ccf40d7a8f70090b4255 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sat, 9 Jan 2021 11:06:55 +0000 Subject: gnu: guix-build-coordinator: Update to 0-15.b5d998c. * gnu/packages/package-management.scm (guix-build-coordinator): Update to 0-15.b5d998c. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 7441db0179..d12db70aca 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -1032,8 +1032,8 @@ environments.") (license (list license:gpl3+ license:agpl3+ license:silofl1.1)))) (define-public guix-build-coordinator - (let ((commit "5149e4f322f71d65851c899cc9b8ce4532ca65ee") - (revision "14")) + (let ((commit "b5d998c22f7d4db3e26166ada9489af363f2d47a") + (revision "15")) (package (name "guix-build-coordinator") (version (git-version "0" revision commit)) @@ -1044,7 +1044,7 @@ environments.") (commit commit))) (sha256 (base32 - "0ps8zppma9hvyikv9l0kl0k4p9cl499x4lb9vanj7zn99136sd3q")) + "1jfmwfx7cvfsvryc3w70nw6mixdamjymkqh40qkv99sspkd86dkr")) (file-name (string-append name "-" version "-checkout")))) (build-system gnu-build-system) (arguments -- cgit v1.2.3 From b4384e61165623b16b77b8cab16c81423c6853ed Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 13:47:06 -0500 Subject: gnu: ncmpcpp: Update to 0.9.1. * gnu/packages/mpd.scm (ncmpcpp): Update to 0.9.1. --- gnu/packages/mpd.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm index 4944c960a6..6066913f16 100644 --- a/gnu/packages/mpd.scm +++ b/gnu/packages/mpd.scm @@ -228,7 +228,7 @@ terminal using ncurses.") (define-public ncmpcpp (package (name "ncmpcpp") - (version "0.8.2") + (version "0.9.1") (source (origin (method url-fetch) (uri @@ -236,7 +236,7 @@ terminal using ncurses.") version ".tar.bz2")) (sha256 (base32 - "0m0mjb049sl62vx13h9waavysa30mk0rphacksnvf94n13la62v5")))) + "0x35nd4v31sma8fliqdbn1nxpjyi8hv472318sfb3xbmr4wlm0fb")))) (build-system gnu-build-system) (inputs `(("libmpdclient" ,libmpdclient) ("boost" ,boost) -- cgit v1.2.3 From 48632af5cc7c9c7307d72aced00b5731b4fc16a6 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 23:08:38 +0100 Subject: gnu: rspamd: Update to 2.7. * gnu/packages/mail.scm (rspamd): Update to 2.7. --- gnu/packages/mail.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 5bdb4152cb..043f5c5fec 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -4183,7 +4183,7 @@ based on asyncio.") (define-public rspamd (package (name "rspamd") - (version "2.6") + (version "2.7") (source (origin (method git-fetch) @@ -4191,7 +4191,7 @@ based on asyncio.") (url "https://github.com/rspamd/rspamd") (commit version))) (sha256 - (base32 "0vwa7k2s2bkfb8w78z5izkd6ywjbzqysb0grls898y549hm8ii70")) + (base32 "0fw6nbfc3xqapzq5nydakwgpw6cz6vb3qby2aqlr06lzf87d3hic")) (file-name (git-file-name name version)))) (build-system cmake-build-system) (arguments -- cgit v1.2.3 From 65ba20e57f52313a4b0261917b84dd7cf925cec7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:26:35 +0100 Subject: gnu: feh: Update to 3.6.2. * gnu/packages/image-viewers.scm (feh): Update to 3.6.2. --- gnu/packages/image-viewers.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/image-viewers.scm b/gnu/packages/image-viewers.scm index 0dae0a39f3..dfe29d413e 100644 --- a/gnu/packages/image-viewers.scm +++ b/gnu/packages/image-viewers.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2017 Nikita ;;; Copyright © 2017 Mathieu Othacehe ;;; Copyright © 2017 nee -;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2018–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018, 2019 Ricardo Wurmus ;;; Copyright © 2019 Nicolas Goaziou ;;; Copyright © 2019, 2020 Guy Fleury Iteriteka @@ -76,7 +76,7 @@ (define-public feh (package (name "feh") - (version "3.6.1") + (version "3.6.2") (home-page "https://feh.finalrewind.org/") (source (origin (method url-fetch) @@ -84,7 +84,7 @@ name "-" version ".tar.bz2")) (sha256 (base32 - "1a0ygdpyvpcsr0hdi9ai7ycbkgvacq8dpd8cacbppsds5k2xw7lv")))) + "0d66qz9h37pk8h10bc918hbv3j364vyni934rlw2j951s5wznj8n")))) (build-system gnu-build-system) (arguments '(#:phases (modify-phases %standard-phases (delete 'configure)) -- cgit v1.2.3 From a779aeda206f5815ac7d5bb822f0ca0481ec8784 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:28:28 +0100 Subject: gnu: tomb: Update to 2.9. * gnu/packages/crypto.scm (tomb): Update to 2.9. --- gnu/packages/crypto.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm index 6683f1cd78..19041c7cbe 100644 --- a/gnu/packages/crypto.scm +++ b/gnu/packages/crypto.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2015, 2017, 2018, 2019 Ricardo Wurmus ;;; Copyright © 2016, 2017, 2018, 2019 Leo Famulari ;;; Copyright © 2016 Lukas Gradl -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2016–2021 Tobias Geerinckx-Rice ;;; Copyright © 2016, 2017 Nikita ;;; Copyright © 2016, 2017, 2019, 2020 Eric Bavier ;;; Copyright © 2017 Pierre Langlois @@ -444,14 +444,14 @@ total number of shares generated.") (define-public tomb (package (name "tomb") - (version "2.8") + (version "2.9") (source (origin (method url-fetch) (uri (string-append "https://files.dyne.org/tomb/releases/" "Tomb-" version ".tar.gz")) (sha256 (base32 - "0bggzzqmpfiknr76lyl8iszybrcpyqlbgiqk47fxq08h2b5ln1ic")))) + "136nfnpaz29hngwwnzrmc858gpnvnb977gf4ldbpapw1h1k3r8mk")))) (build-system gnu-build-system) (native-inputs `(("sudo" ,sudo))) ;presence needed for 'check' phase (inputs -- cgit v1.2.3 From 341b2d3d36900fca6911c940ec0d08e6c8dcbad0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:29:14 +0100 Subject: gnu: plzip: Update to 1.9. * gnu/packages/compression.scm (plzip): Update to 1.9. --- gnu/packages/compression.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm index 7294a2eda6..1eab34a517 100644 --- a/gnu/packages/compression.scm +++ b/gnu/packages/compression.scm @@ -1843,14 +1843,14 @@ corrupted input.") (define-public plzip (package (name "plzip") - (version "1.8") + (version "1.9") (source (origin (method url-fetch) (uri (string-append "mirror://savannah/lzip/plzip/" "plzip-" version ".tar.gz")) (sha256 - (base32 "04indil809qgfmz776imb3dnhkysh7zk28jcv3mw0ahl2lyaxbzd")))) + (base32 "19zinpx7hssl6r3vilpvq2s7wha3545xan8b0vcvsxnyipdx3n0l")))) (build-system gnu-build-system) (inputs `(("lzlib" ,lzlib))) -- cgit v1.2.3 From 8b7e84b952eeb383d26426246f080d1a2f41864a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:48:47 +0100 Subject: gnu: okular: Update to 20.12.1. * gnu/packages/kde.scm (okular): Update to 20.12.1. --- gnu/packages/kde.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm index 12d54a0b5d..d2044cd2b6 100644 --- a/gnu/packages/kde.scm +++ b/gnu/packages/kde.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2016 David Craven ;;; Copyright © 2016, 2017 Thomas Danckaert ;;; Copyright © 2017, 2018 Mark Meyer -;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice +;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2018 Gábor Boskovits ;;; Copyright © 2019 Nicolas Goaziou ;;; Copyright © 2018, 2019, 2020 Hartmut Goebel @@ -848,14 +848,14 @@ Python, PHP, and Perl.") (define-public okular (package (name "okular") - (version "20.12.0") + (version "20.12.1") (source (origin (method url-fetch) (uri (string-append "mirror://kde/stable/release-service/" version "/src/" name "-" version ".tar.xz")) (sha256 - (base32 "1kib8zqfd9qgqn7bz88hay2j3kcvarnlfyr3a417pi6rvaam6b4p")))) + (base32 "0gpm7n47yijsjg4yba561j5pbvd98hgvr93w1kvzk851nb87m89c")))) (build-system qt-build-system) ;; The tests fail because they can't find the proper mimetype plugins: ;; "org.kde.okular.core: No plugin for mimetype '"image/jpeg"'." -- cgit v1.2.3 From d15c050116a4969c4714534c6f8880a2fb443045 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:48:59 +0100 Subject: gnu: lvm2: Update to 2.03.11. * gnu/packages/linux.scm (lvm2): Update to 2.03.11. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 8317723bbf..0698017993 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -3465,7 +3465,7 @@ devices that can inject events directly into the input subsystem.") (define-public lvm2 (package (name "lvm2") - (version "2.03.10") + (version "2.03.11") (source (origin (method url-fetch) (uri (list (string-append "https://sourceware.org/ftp/lvm2/LVM2." @@ -3474,7 +3474,7 @@ devices that can inject events directly into the input subsystem.") version ".tgz"))) (sha256 (base32 - "1l0fkn9abrgk5mfn6jfh9qhdr86b59l1c5pk6lp8jh0491d69las")) + "1m4xpda8vbyd89ca0w8nacvnl4j34yzsa625gn990fb5sh84ab44")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.2.3 From 5c149f41db8f11e577b7fe224d6c6cd76cbde858 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:49:11 +0100 Subject: gnu: yakuake: Update to 20.12.1. * gnu/packages/kde-systemtools.scm (yakuake): Update to 20.12.1. --- gnu/packages/kde-systemtools.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/kde-systemtools.scm b/gnu/packages/kde-systemtools.scm index f5d97dae27..b9c3865a93 100644 --- a/gnu/packages/kde-systemtools.scm +++ b/gnu/packages/kde-systemtools.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017, 2020 Hartmut Goebel +;;; Copyright © 2021 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -322,14 +323,14 @@ This package is part of the KDE administration module.") (define-public yakuake (package (name "yakuake") - (version "20.12.0") + (version "20.12.1") (source (origin (method url-fetch) (uri (string-append "mirror://kde/stable/release-service/" version "/src/yakuake-" version ".tar.xz")) (sha256 (base32 - "175vvkpkpbd7nm0lqjyiw27xmfdfcs9syvfngnjlndmlzwagk8d1")))) + "02pal9xx1wbpw7dimvs2aw1xnyjqlvbjlybkkfhf8x7c6m1r63aa")))) (build-system qt-build-system) (native-inputs `(("extra-cmake-modules" ,extra-cmake-modules))) -- cgit v1.2.3 From 64baf7fd618f4a5fa98ddf80fc934390bd03c5c7 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 9 Jan 2021 22:51:53 +0100 Subject: gnu: youtube-dl: Update to 2021.01.08. * gnu/packages/video.scm (youtube-dl): Update to 2021.01.08. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 1f68208021..b4a40f6ea6 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -2197,14 +2197,14 @@ To load this plugin, specify the following option when starting mpv: (define-public youtube-dl (package (name "youtube-dl") - (version "2021.01.03") + (version "2021.01.08") (source (origin (method url-fetch) (uri (string-append "https://youtube-dl.org/downloads/latest/" "youtube-dl-" version ".tar.gz")) (sha256 (base32 - "0qqixcr748nfhnihkjzayzdja26kgrsds45q5s8krmfm3b79ipli")) + "1k870v9xc7g16nvixa272sdjnmc7pl49ymmnn6rdz0mcj2548h3k")) (snippet '(begin ;; Delete the pre-generated files, except for the man page -- cgit v1.2.3 From 35e38c6cae2e5ab09d98691e572ad6065a522cd1 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:16:38 -0500 Subject: gnu: linux-libre: Update to 5.10.6. * gnu/packages/linux.scm (linux-libre-5.10-version): Update to 5.10.6. (linux-libre-5.10-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 0698017993..ee363b1818 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -353,7 +353,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.10-version "5.10.5") +(define-public linux-libre-5.10-version "5.10.6") (define deblob-scripts-5.10 (linux-libre-deblob-scripts linux-libre-5.10-version @@ -361,7 +361,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0hh27ccqimagr3aij7ygwikxw66y63sqwd0xlf49bhpjd090r9a7"))) (define-public linux-libre-5.10-pristine-source (let ((version linux-libre-5.10-version) - (hash (base32 "1x1fc4cywqnjm514q376d5540zsxmqv95n0lykaphz8qdbhsk49r"))) + (hash (base32 "02v91afra3pcwfws74wxdsm8pfc57vws659b7j6jmsxm3hnd0rvp"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.10))) -- cgit v1.2.3 From 28bf4f70b6b22e29383e0d7efd6d403bb8b79bae Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:17:36 -0500 Subject: gnu: linux-libre 5.4: Update to 5.4.88. * gnu/packages/linux.scm (linux-libre-5.4-version): Update to 5.4.88. (linux-libre-5.4-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index ee363b1818..3ce7b1842e 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -369,7 +369,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; -(define-public linux-libre-5.4-version "5.4.87") +(define-public linux-libre-5.4-version "5.4.88") (define deblob-scripts-5.4 (linux-libre-deblob-scripts linux-libre-5.4-version @@ -377,7 +377,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1xghbbnaisjd0k1klbyn1p7r6r4x5a1bpmkm56a3gh2zvw4s7mj8"))) (define-public linux-libre-5.4-pristine-source (let ((version linux-libre-5.4-version) - (hash (base32 "0cawb7md97i0hz83hf7l4ihn9lyrg8q64j8jam8n9fw45qzfjd3a"))) + (hash (base32 "1ci432xanm7glgg05012kh43pfi4k771kzih0816y5674v0hg02b"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.4))) -- cgit v1.2.3 From 97a60578a2395e016310c0dc12b6411e61740d27 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:18:44 -0500 Subject: gnu: linux-libre 4.19: Update to 4.19.166. * gnu/packages/linux.scm (linux-libre-4.19-version): Update to 4.19.166. (linux-libre-4.19-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 3ce7b1842e..e71ce1677c 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -382,7 +382,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-5.4))) -(define-public linux-libre-4.19-version "4.19.165") +(define-public linux-libre-4.19-version "4.19.166") (define deblob-scripts-4.19 (linux-libre-deblob-scripts linux-libre-4.19-version @@ -390,7 +390,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1jiaw0as1ippkrjdpd52657w5mz9qczg3y2hlra7m9k0xawwiqlf"))) (define-public linux-libre-4.19-pristine-source (let ((version linux-libre-4.19-version) - (hash (base32 "1l72wka1dli0jdb91sx4zr13vy0q5l6p37fh6hf093gjn14mdh51"))) + (hash (base32 "03l86ykdjs5wa0n4wknpgy9dv2r6l92qfsyak373jkhs684z53mr"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.19))) -- cgit v1.2.3 From 0ab8850b1647764c94bb98ef1ae0fc61b7893845 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:31:38 -0500 Subject: gnu: linux-libre 4.14: Update to 4.14.214. * gnu/packages/linux.scm (linux-libre-4.14-version): Update to 4.14.214. (linux-libre-4.14-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index e71ce1677c..48fa81e00f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -395,7 +395,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-4.19))) -(define-public linux-libre-4.14-version "4.14.213") +(define-public linux-libre-4.14-version "4.14.214") (define deblob-scripts-4.14 (linux-libre-deblob-scripts linux-libre-4.14-version @@ -403,7 +403,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "1qij18inijj6c3ma8hv98yjagnzxdxyn134da9fd23ky8q6hbvky"))) (define-public linux-libre-4.14-pristine-source (let ((version linux-libre-4.14-version) - (hash (base32 "079axkl14jp8lz30h21q4gmhmjw6zf5ycmxji65kgcgyg7dwwyzx"))) + (hash (base32 "07ir4yw7s5c6yb3gjbgjvcqqdgpbsjxrvapgh6zs22ffd8hrchpm"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.14))) -- cgit v1.2.3 From 3bef805e0558ebf1afed22fdce849f2ec26c7e2a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:32:30 -0500 Subject: gnu: linux-libre 4.9: Update to 4.9.250. * gnu/packages/linux.scm (linux-libre-4.9-version): Update to 4.9.250. (linux-libre-4.9-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 48fa81e00f..5197d5ba4c 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -408,7 +408,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-4.14))) -(define-public linux-libre-4.9-version "4.9.249") +(define-public linux-libre-4.9-version "4.9.250") (define deblob-scripts-4.9 (linux-libre-deblob-scripts linux-libre-4.9-version @@ -416,7 +416,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0fxajshb75siq39lj5h8xvhdj8lcmddkslwlyj65rhlwk6g2r4b2"))) (define-public linux-libre-4.9-pristine-source (let ((version linux-libre-4.9-version) - (hash (base32 "0kjcw0vgga9msgqnipgg028v3rcc5am2d094v3hqkkjvzyb8dwxi"))) + (hash (base32 "15vizxd2i2311skjank406ny3bc30c5rz2p9jvh5xz1yv12vzgcy"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.9))) -- cgit v1.2.3 From 9f829da86fceb78cc6fedfd30ee42071d3e402c4 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sat, 9 Jan 2021 20:38:16 -0500 Subject: gnu: linux-libre 4.4: Update to 4.4.250. * gnu/packages/linux.scm (linux-libre-4.4-version): Update to 4.4.250. (linux-libre-4.4-pristine-source): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 5197d5ba4c..46b86186e9 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -421,7 +421,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (%upstream-linux-source version hash) deblob-scripts-4.9))) -(define-public linux-libre-4.4-version "4.4.249") +(define-public linux-libre-4.4-version "4.4.250") (define deblob-scripts-4.4 (linux-libre-deblob-scripts linux-libre-4.4-version @@ -429,7 +429,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "0hhin1jpfkd6nwrb6xqxjzl3hdxy4pn8a15hy2d3d83yw6pflbsf"))) (define-public linux-libre-4.4-pristine-source (let ((version linux-libre-4.4-version) - (hash (base32 "04pb4vgia6zaindf6804gq9jn3mhmy01yijqmpi79sh9rlqzzh1i"))) + (hash (base32 "12m14j8654rawj2znkyhvcnwnf53x10zlghxd0mpl8dfzwvn2f5b"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-4.4))) -- cgit v1.2.3 From 4a0a4533920c11bf4ddb8c06bee3c2720fa811df Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 10 Jan 2021 09:47:38 +0200 Subject: gnu: vim: Skip terminal screen-dump tests. Even with careful substitutions these tests often break on other architectures anyway. * gnu/packages/vim.scm (vim)[arguments]: Adjust skip-or-fix-failing-tests to skip another terminal screen-dump test. --- gnu/packages/vim.scm | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm index da4404e23c..3e120fac17 100644 --- a/gnu/packages/vim.scm +++ b/gnu/packages/vim.scm @@ -126,25 +126,13 @@ ;; a difference being detected. Patching the expected result is ;; non-trivial due to the special format used, so skip the test. (substitute* "src/testdir/test_terminal.vim" + ((".*Test_open_term_from_cmd.*" line) + (string-append line "return\n")) ((".*Test_terminal_postponed_scrollback.*" line) (string-append line "return\n"))) (substitute* "src/testdir/test_popupwin.vim" ((".*Test_popup_drag_termwin.*" line) (string-append line "return\n"))) - - ;; This test compares output against a golden ‘…/|b|i|n|/|s|h…’ - ;; literal. We need to match that and substitute a similarly - ;; ‘spliced’ path to ‘sh’ in the store, truncated to the last - ;; 44 (spliced: 88) characters. - (let ((splice (lambda (s separator) - (string-join (map string (string->list s)) - separator)))) - (substitute* "src/testdir/dumps/Test_terminal_from_cmd.dump" - (((splice "/bin/sh" "\\|")) - (splice (string-take-right (which "sh") 44) "|")) - ;; Blindly fix some other differences based on error output. - (("^\\|!") "|<") - (("@37") ""))) #t)) (add-after 'install 'install-guix.vim (lambda* (#:key inputs outputs #:allow-other-keys) -- cgit v1.2.3 From df898f7206f3925cdc041a8578d9dbff2f0118f1 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Sat, 9 Jan 2021 13:38:54 +0000 Subject: gnu: Add cl-garbage-pools. * gnu/packages/lisp-xyz.scm (cl-garbage-pools, ecl-garbage-pools, sbcl-garbage-pools): New variables. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 52abef3d85..1cda7ff07f 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -6545,6 +6545,34 @@ trees to dispatch on string equality.") (define-public ecl-string-case (sbcl-package->ecl-package sbcl-string-case)) +(define-public sbcl-garbage-pools + (let ((commit "9a7cb7f48b04197c0495df3b6d2e8395ad13f790") + (revision "1")) + (package + (name "sbcl-garbage-pools") + (version (git-version "0.1.2" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/archimag/garbage-pools") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "04jqwr6j138him6wc4nrwjzm4lvyj5j31xqab02nkf8h9hmsf5v1")))) + (build-system asdf-build-system/sbcl) + (home-page "https://github.com/archimag/garbage-pools") + (synopsis "Resource management pools for Common Lisp") + (description "GARBAGE-POOLS is Common Lisp re-implementation of the APR +Pools for resource management.") + (license license:expat)))) + +(define-public ecl-garbage-pools + (sbcl-package->ecl-package sbcl-garbage-pools)) + +(define-public cl-garbage-pools + (sbcl-package->cl-source-package sbcl-garbage-pools)) + (define-public sbcl-global-vars (let ((commit "c749f32c9b606a1457daa47d59630708ac0c266e") (revision "0")) -- cgit v1.2.3 From 6c1982d41c381b0f7d21e804b4bd480363686bf6 Mon Sep 17 00:00:00 2001 From: Sharlatan Hellseher Date: Sun, 10 Jan 2021 01:08:32 +0000 Subject: gnu: sbcl-local-time: Update to 1.0.6-2.a177eb9. * gnu/packages/lisp-xyz.scm (sbcl-local-time): Update to 1.0.6-2.a177eb9. [inputs]: Remove sbcl-cl-fad. [arguments]: Activate tests. Signed-off-by: Guillaume Le Vaillant --- gnu/packages/lisp-xyz.scm | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 1cda7ff07f..f0881bdfb7 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -4311,8 +4311,8 @@ performance and simplicity in mind.") (sbcl-package->ecl-package sbcl-lack)) (define-public sbcl-local-time - (let ((commit "62792705245168d3fc2e04164b9a143477284142") - (revision "1")) + (let ((commit "a177eb911c0e8116e2bfceb79049265a884b701b") + (revision "2")) (package (name "sbcl-local-time") (version (git-version "1.0.6" revision commit)) @@ -4324,16 +4324,10 @@ performance and simplicity in mind.") (commit commit))) (file-name (git-file-name name version)) (sha256 - (base32 "1r5zq4l1lrgprdr2pw7wwry194yknnllyjf6lx7snypb3k4r3yir")))) + (base32 "0wld28xx20k0ysgg6akic5lg4vkjd0iyhv86m388xfrv8xh87wii")))) (build-system asdf-build-system/sbcl) - (arguments - ;; TODO: Component :STEFIL not found, required by # - '(#:tests? #f)) (native-inputs - `(("stefil" ,sbcl-hu.dwim.stefil))) - (inputs - `(("sbcl-cl-fad" ,sbcl-cl-fad))) + `(("hu.dwim.stefil" ,sbcl-hu.dwim.stefil))) (home-page "https://common-lisp.net/project/local-time/") (synopsis "Time manipulation library for Common Lisp") (description -- cgit v1.2.3 From fa05535f6e2d0767f3605336c8bfee62ec56ac36 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 10 Jan 2021 11:57:36 +0100 Subject: gnu: emacs-auctex: Update to 13.0.3. * gnu/packages/emacs-xyz.scm (emacs-auctex): Update to 13.0.3. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index c86452fe2b..4731ee8fd8 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -2071,14 +2071,14 @@ as a library for other Emacs packages.") (define-public emacs-auctex (package (name "emacs-auctex") - (version "13.0.1") + (version "13.0.3") (source (origin (method url-fetch) (uri (string-append "https://elpa.gnu.org/packages/" "auctex-" version ".tar")) (sha256 - (base32 "1y5q3phd0xr7342i757hr4hic8nad4kkdf1zk56mlj5snwr0g0w7")))) + (base32 "1ljpkr0z15fyh907jbgky238dvci5vqi3xhvslyhblhp8sg9cbsi")))) (build-system emacs-build-system) ;; We use 'emacs' because AUCTeX requires dbus at compile time ;; ('emacs-minimal' does not provide dbus). -- cgit v1.2.3 From 3dd93fcac400902b155ed71efba9b37517617c8c Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 10 Jan 2021 11:58:29 +0100 Subject: gnu: emacs-websocket: Update to 1.13. * gnu/packages/emacs-xyz.scm (emacs-websocket): Update to 1.13. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 4731ee8fd8..19e903bc20 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -13511,14 +13511,14 @@ database of references on life sciences.") (define-public emacs-websocket (package (name "emacs-websocket") - (version "1.12") + (version "1.13") (source (origin (method url-fetch) (uri (string-append "https://elpa.gnu.org/packages/" "websocket-" version ".tar")) (sha256 - (base32 "0ap4z80c6pzpb69wrx0hsvwzignxmd2b9xy974by9gf5xm2wpa8w")))) + (base32 "0jnarx53csmx5fivzp5vhvvj3m8s03zwc6hjl0spz5zb6icqclsa")))) (build-system emacs-build-system) (home-page "https://elpa.gnu.org/packages/websocket.html") (synopsis "Emacs WebSocket client and server") -- cgit v1.2.3 From 787570ea29354e975d91d3d115ce871467b0a353 Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Tue, 5 Jan 2021 20:08:04 -0300 Subject: gnu: emacs-fountain-mode: Update to 3.4.0. * gnu/packages/emacs-xyz.scm (emacs-fountain-mode): Update to 3.4.0. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 19e903bc20..34faec6b69 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -70,7 +70,7 @@ ;;; Copyright © 2020 Alberto Eleuterio Flores Guerrero ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2020 pinoaffe -;;; Copyright © 2020 Vinicius Monego +;;; Copyright © 2020, 2021 Vinicius Monego ;;; Copyright © 2020 Ryan Desfosses ;;; Copyright © 2020 Marcin Karpezo ;;; Copyright © 2020 Fredrik Salomonsson @@ -3317,7 +3317,7 @@ files and directories.") (define-public emacs-fountain-mode (package (name "emacs-fountain-mode") - (version "3.3.3") + (version "3.4.0") (source (origin (method git-fetch) @@ -3326,7 +3326,7 @@ files and directories.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "095nrkg2bap6rcg9hy3bh0nis4v2f8w8d9hnahkzsa3njlpqa4ka")))) + (base32 "161wn66gc2z7fd4f89827dpww6hjmnassbi15yis5rqbklj1h2z6")))) (build-system emacs-build-system) (home-page "https://github.com/rnkn/fountain-mode") (synopsis "Major mode for screenwriting in Fountain markup") -- cgit v1.2.3 From 9f48bb3f53e86710e5d534209cf3260b2e30e439 Mon Sep 17 00:00:00 2001 From: Michael Rohleder Date: Fri, 8 Jan 2021 20:11:18 +0100 Subject: gnu: emacs-calibredb: Update to 2.8.0. * gnu/packages/emacs-xyz.scm (emacs-calibredb): Update to 2.8.0. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 34faec6b69..25ec13dd20 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -62,7 +62,7 @@ ;;; Copyright © 2020 Evan Straw ;;; Copyright © 2020 Masaya Tojo ;;; Copyright © 2020 Martin Becze -;;; Copyright © 2020 Michael Rohleder +;;; Copyright © 2020, 2021 Michael Rohleder ;;; Copyright © 2020 Brice Waegeneire ;;; Copyright © 2020 6033fe7de85d <6033fe7de85d@airmail.cc> ;;; Copyright © 2020 John Soo @@ -22571,7 +22571,7 @@ through Dash docsets.") (define-public emacs-calibredb (package (name "emacs-calibredb") - (version "2.7.0") + (version "2.8.0") (source (origin (method git-fetch) @@ -22580,7 +22580,7 @@ through Dash docsets.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1w3kz9iny72gk54jdafz8sy5sv6hnpm3rw4fn1r8aznx4p00f9dy")))) + (base32 "19gc05k2p1l8wlkrqij9cw6d61hzknd6a9n64kzlpi87cpbav3lv")))) (build-system emacs-build-system) (propagated-inputs `(("emacs-dash" ,emacs-dash) -- cgit v1.2.3 From abcd2d242019f6707e4189d5b6ed27593e6d5f52 Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Thu, 7 Jan 2021 21:09:01 +0100 Subject: gnu: julius: Update to 1.6.0. * gnu/packages/games.scm (julius): Update to 1.6.0. Signed-off-by: Nicolas Goaziou --- gnu/packages/games.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 2208ca4113..d53583168e 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -1324,7 +1324,7 @@ automata. The following features are available: (define-public julius (package (name "julius") - (version "1.5.1") + (version "1.6.0") (source (origin (method git-fetch) @@ -1333,7 +1333,7 @@ automata. The following features are available: (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "10d6py1cmkq8lnb5h3w8rdpp4fmpd1wgqkgiabdghqxi7b2s0g4b")) + (base32 "0nfdn8n6ywhm69ckz9a1chl5xxiqyaj3l337wadsbppnpscjihrc")) ;; Remove unused bundled libraries. (modules '((guix build utils))) (snippet -- cgit v1.2.3 From 3af7dc15a6397c6c1b1712e6ff8994074f2919e4 Mon Sep 17 00:00:00 2001 From: raingloom Date: Wed, 6 Jan 2021 17:38:50 +0100 Subject: gnu: Updated liferea to 1.13.4. * gnu/packages/syndiction.scm (liferea): Updated to 1.13.4. [source]: Switched to git-download. [native-inputs]: Added autotools, automake, libtool. Signed-off-by: Nicolas Goaziou --- gnu/packages/syndication.scm | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/gnu/packages/syndication.scm b/gnu/packages/syndication.scm index 075fd7e3e6..efe231c92f 100644 --- a/gnu/packages/syndication.scm +++ b/gnu/packages/syndication.scm @@ -21,12 +21,15 @@ (define-module (gnu packages syndication) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix download) + #:use-module (guix git-download) #:use-module (guix packages) #:use-module (guix build-system cargo) #:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system gnu) #:use-module (guix build-system python) #:use-module (gnu packages) + #:use-module (gnu packages autotools) + #:use-module (gnu packages base) #:use-module (gnu packages check) #:use-module (gnu packages crates-io) #:use-module (gnu packages curl) @@ -181,15 +184,15 @@ file system, and many more features.") (define-public liferea (package (name "liferea") - (version "1.12.9") + (version "1.13.4") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/lwindolf/liferea/" - "releases/download/v" version "/liferea-" - version ".tar.bz2")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/lwindolf/liferea/") + (commit (string-append "v" version)))) (sha256 - (base32 "06ybr1wjlfir8iqjx6x0v1knd4b2hsy30qmkk4kssy6ky2ahc66q")))) + (base32 "1g9463bvswsm899j6dfhslcg6np70m5wq143mjicr24zy8d17bm7")))) (build-system glib-or-gtk-build-system) (arguments `(#:phases @@ -208,11 +211,15 @@ file system, and many more features.") `("PYTHONPATH" ":" prefix (,python-path)))) #t))))) (native-inputs - `(("gettext" ,gettext-minimal) + `(("autoconf" ,autoconf) + ("automake" ,automake) + ("gettext" ,gettext-minimal) ("glib:bin" ,glib "bin") ("gobject-introspection" ,gobject-introspection) ("intltool" ,intltool) - ("pkg-config" ,pkg-config))) + ("libtool" ,libtool) + ("pkg-config" ,pkg-config) + ("which" ,which))) (inputs `(("glib-networking" ,glib-networking) ("gnome-keyring" ,gnome-keyring) -- cgit v1.2.3 From 00fb6c91f44c38fc311021e99badd38ba6bcdc17 Mon Sep 17 00:00:00 2001 From: John Soo Date: Mon, 4 Jan 2021 13:47:23 -0800 Subject: gnu: emacs-eglot: Add missing dependency. * gnu/packages/emacs-xyz.scm (emacs-eglot): [propagated-inputs] Add emacs-project. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 25ec13dd20..4893a9c846 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -12550,7 +12550,8 @@ Emacs.") (base32 "1zvs144hxq2mmq1h0ynx9hy7yyccb46f3pjg9mgq8v9cw5y678vk")))) (build-system emacs-build-system) (propagated-inputs - `(("emacs-jsonrpc" ,emacs-jsonrpc))) + `(("emacs-jsonrpc" ,emacs-jsonrpc) + ("emacs-project" ,emacs-project))) (home-page "https://github.com/joaotavora/eglot") (synopsis "Client for Language Server Protocol (LSP) servers") (description -- cgit v1.2.3 From 71ebe52734d6e7cf1d31cb280d928f834bde883a Mon Sep 17 00:00:00 2001 From: Vinicius Monego Date: Thu, 31 Dec 2020 12:58:17 -0300 Subject: gnu: Add emacs-org-roam-bibtex. * gnu/packages/emacs-xyz.scm (emacs-org-roam-bibtex): New variable. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 4893a9c846..81ae90ea31 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -25677,6 +25677,33 @@ as a plug-and-play solution for anyone already using Org mode for their personal wiki.") (license license:gpl3+))) +(define-public emacs-org-roam-bibtex + (package + (name "emacs-org-roam-bibtex") + (version "0.4.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/org-roam/org-roam-bibtex") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "13pll793khyfncpwm2dg24w747sqp7kgf7m3fqw2xzhv9cx2g7nq")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-helm-bibtex" ,emacs-helm-bibtex) + ("emacs-org-ref" ,emacs-org-ref) + ("emacs-org-roam" ,emacs-org-roam))) + (home-page "https://github.com/org-roam/org-roam-bibtex") + (synopsis "Connector between Org Roam, BibTeX-completion, and Org Ref") + (description + "Org Roam BibTeX is a library which offers a tighter integration between +Org Roam, Helm-BibTeX, and Org Ref. It allows users to access their +bibliographical notes in Org Roam directory via Helm BibTeX, Ivy BibTeX, or by +opening Org Ref's @code{cite:} links.") + (license license:gpl3+))) + (define-public emacs-org-generate (package (name "emacs-org-generate") -- cgit v1.2.3 From 267d59473954984ac8fc02a79081642fa26cfe3b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 10 Jan 2021 13:28:55 +0200 Subject: gnu: supercollider: Update to 3.11.2. * gnu/packages/audio.scm (supercollider): Update to 3.11.2. [arguments]: Disable building libscsynth. --- gnu/packages/audio.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index a4f5170a92..6fe441faae 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2015 Andreas Enge ;;; Copyright © 2015 Alex Kost ;;; Copyright © 2015, 2016 Mark H Weaver -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Efraim Flashner +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner ;;; Copyright © 2016, 2017 Alex Griffin ;;; Copyright © 2016 Nikita ;;; Copyright © 2016 Lukas Gradl @@ -2703,7 +2703,7 @@ background file post-processing.") (define-public supercollider (package (name "supercollider") - (version "3.11.0") + (version "3.11.2") (source (origin (method git-fetch) (uri (git-reference @@ -2714,7 +2714,7 @@ background file post-processing.") (file-name (git-file-name name version)) (sha256 (base32 - "02v911w2kdbg3kfl593lb2ig4sjbfxzv20a0vbcymhfzpvp1x6xp")) + "1gi7nrmjmbnjndqkmhfrkk0jchrzvnhl3f6gp6n5wgdd4mxbgxgw")) (modules '((guix build utils) (ice-9 ftw))) (snippet @@ -2744,7 +2744,8 @@ link REQUIRED)")) (arguments `(#:configure-flags '("-DSYSTEM_BOOST=on" "-DSYSTEM_YAMLCPP=on" "-DSC_QT=ON" "-DCMAKE_BUILD_TYPE=Release" - "-DFORTIFY=ON" "-DLIBSCSYNTH=ON" + "-DFORTIFY=ON" + ;"-DLIBSCSYNTH=ON" ; TODO: Re-enable? "-DSC_EL=off") ;scel is packaged individually as ;emacs-scel #:phases -- cgit v1.2.3 From a481c55dc91b9048fee2ef2317827e8d6b88679f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 10 Jan 2021 14:05:03 +0200 Subject: gnu: pulseview: Update to 0.4.2. * gnu/packages/electronics.scm (pulseview): Update to 0.4.2. [source]: Use https. --- gnu/packages/electronics.scm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gnu/packages/electronics.scm b/gnu/packages/electronics.scm index 01796bb91c..491f9daaa0 100644 --- a/gnu/packages/electronics.scm +++ b/gnu/packages/electronics.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2017 Theodoros Foradis ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2019 Clément Lassieur +;;; Copyright © 2021 Efraim Flashner ;;; ;;; This file is part of GNU Guix. ;;; @@ -239,15 +240,15 @@ format support.") (define-public pulseview (package (name "pulseview") - (version "0.4.1") + (version "0.4.2") (source (origin (method url-fetch) (uri (string-append - "http://sigrok.org/download/source/pulseview/pulseview-" + "https://sigrok.org/download/source/pulseview/pulseview-" version ".tar.gz")) (sha256 (base32 - "0bvgmkgz37n2bi9niskpl05hf7rsj1lj972fbrgnlz25s4ywxrwy")))) + "1jxbpz1h3m1mgrxw74rnihj8vawgqdpf6c33cqqbyd8v7rxgfhph")))) (build-system cmake-build-system) (arguments `(#:configure-flags '("-DENABLE_TESTS=y") @@ -262,7 +263,8 @@ format support.") (rmdir "doc")) #t)))))) (native-inputs - `(("pkg-config" ,pkg-config))) + `(("pkg-config" ,pkg-config) + ("qttools" ,qttools))) (inputs `(("boost" ,boost) ("glib" ,glib) -- cgit v1.2.3 From d0fff8f840afc17be40bdc49bff52ed08d5a1a7b Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 10 Jan 2021 14:23:20 +0200 Subject: gnu: pulseview: Fix qt-5.15 compatibility. * gnu/packages/electronics.scm (pulseview)[source]: Add patch. * gnu/packages/patches/pulseview-qt515-compat.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + gnu/packages/electronics.scm | 3 +- gnu/packages/patches/pulseview-qt515-compat.patch | 145 ++++++++++++++++++++++ 3 files changed, 148 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/pulseview-qt515-compat.patch diff --git a/gnu/local.mk b/gnu/local.mk index ec3d6137e7..6893a54fdd 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1502,6 +1502,7 @@ dist_patch_DATA = \ %D%/packages/patches/psm-repro.patch \ %D%/packages/patches/pulseaudio-fix-mult-test.patch \ %D%/packages/patches/pulseaudio-longer-test-timeout.patch \ + %D%/packages/patches/pulseview-qt515-compat.patch \ %D%/packages/patches/purescript-relax-dependencies.patch \ %D%/packages/patches/pybugz-encode-error.patch \ %D%/packages/patches/pybugz-stty.patch \ diff --git a/gnu/packages/electronics.scm b/gnu/packages/electronics.scm index 491f9daaa0..7cf6509b7d 100644 --- a/gnu/packages/electronics.scm +++ b/gnu/packages/electronics.scm @@ -248,7 +248,8 @@ format support.") version ".tar.gz")) (sha256 (base32 - "1jxbpz1h3m1mgrxw74rnihj8vawgqdpf6c33cqqbyd8v7rxgfhph")))) + "1jxbpz1h3m1mgrxw74rnihj8vawgqdpf6c33cqqbyd8v7rxgfhph")) + (patches (search-patches "pulseview-qt515-compat.patch")))) (build-system cmake-build-system) (arguments `(#:configure-flags '("-DENABLE_TESTS=y") diff --git a/gnu/packages/patches/pulseview-qt515-compat.patch b/gnu/packages/patches/pulseview-qt515-compat.patch new file mode 100644 index 0000000000..a7156b2018 --- /dev/null +++ b/gnu/packages/patches/pulseview-qt515-compat.patch @@ -0,0 +1,145 @@ +https://sigrok.org/gitweb/?p=pulseview.git;a=patch;h=ae726b70a7ada9a4be5808e00f0c951318479684 + +From ae726b70a7ada9a4be5808e00f0c951318479684 Mon Sep 17 00:00:00 2001 +From: Valentin Ochs +Date: Sat, 20 Jun 2020 16:01:27 +0200 +Subject: [PATCH] Replace obsolete/deprecated Qt methods + +--- + pv/subwindows/decoder_selector/subwindow.cpp | 2 +- + pv/util.cpp | 21 ++++++++++++++++++-- + pv/util.hpp | 10 ++++++++++ + pv/views/trace/decodetrace.cpp | 3 ++- + pv/views/trace/ruler.cpp | 2 +- + pv/widgets/timestampspinbox.cpp | 2 +- + 6 files changed, 34 insertions(+), 6 deletions(-) + +diff --git a/pv/subwindows/decoder_selector/subwindow.cpp b/pv/subwindows/decoder_selector/subwindow.cpp +index 94ed6f4b..2c65dcf2 100644 +--- a/pv/subwindows/decoder_selector/subwindow.cpp ++++ b/pv/subwindows/decoder_selector/subwindow.cpp +@@ -185,7 +185,7 @@ QToolBar* SubWindow::create_toolbar(QWidget *parent) const + int SubWindow::minimum_width() const + { + QFontMetrics m(info_label_body_->font()); +- const int label_width = m.width(QString(tr(initial_notice))); ++ const int label_width = util::text_width(m, tr(initial_notice)); + + return label_width + min_width_margin; + } +diff --git a/pv/util.cpp b/pv/util.cpp +index 897254e1..dfb8c72b 100644 +--- a/pv/util.cpp ++++ b/pv/util.cpp +@@ -143,7 +143,7 @@ QString format_time_si(const Timestamp& v, SIPrefix prefix, + QString s; + QTextStream ts(&s); + if (sign && !v.is_zero()) +- ts << forcesign; ++ ts.setNumberFlags(ts.numberFlags() | QTextStream::ForceSign); + ts << qSetRealNumberPrecision(precision) << (v * multiplier); + ts << ' ' << prefix << unit; + +@@ -169,7 +169,7 @@ QString format_value_si(double v, SIPrefix prefix, unsigned precision, + QString s; + QTextStream ts(&s); + if (sign && (v != 0)) +- ts << forcesign; ++ ts.setNumberFlags(ts.numberFlags() | QTextStream::ForceSign); + ts.setRealNumberNotation(QTextStream::FixedNotation); + ts.setRealNumberPrecision(precision); + ts << (v * multiplier) << ' ' << prefix << unit; +@@ -279,5 +279,22 @@ vector split_string(string text, string separator) + return result; + } + ++/** ++ * Return the width of a string in a given font. ++ * ++ * @param[in] metric metrics of the font ++ * @param[in] string the string whose width should be determined ++ * ++ * @return width of the string in pixels ++ */ ++std::streamsize text_width(const QFontMetrics &metric, const QString &string) ++{ ++#if QT_VERSION >= QT_VERSION_CHECK(5, 11, 0) ++ return metric.horizontalAdvance(string); ++#else ++ return metric.width(string); ++#endif ++} ++ + } // namespace util + } // namespace pv +diff --git a/pv/util.hpp b/pv/util.hpp +index fab29a14..49ae04b2 100644 +--- a/pv/util.hpp ++++ b/pv/util.hpp +@@ -30,6 +30,7 @@ + + #include + #include ++#include + + using std::string; + using std::vector; +@@ -143,6 +144,15 @@ QString format_time_minutes(const Timestamp& t, signed precision = 0, + + vector split_string(string text, string separator); + ++/** ++ * Return the width of a string in a given font. ++ * @param[in] metric metrics of the font ++ * @param[in] string the string whose width should be determined ++ * ++ * @return width of the string in pixels ++ */ ++std::streamsize text_width(const QFontMetrics &metric, const QString &string); ++ + } // namespace util + } // namespace pv + +diff --git a/pv/views/trace/decodetrace.cpp b/pv/views/trace/decodetrace.cpp +index 67c9b1c4..93c7c5a9 100644 +--- a/pv/views/trace/decodetrace.cpp ++++ b/pv/views/trace/decodetrace.cpp +@@ -161,7 +161,8 @@ DecodeTrace::DecodeTrace(pv::Session &session, + + // Determine shortest string we want to see displayed in full + QFontMetrics m(QApplication::font()); +- min_useful_label_width_ = m.width("XX"); // e.g. two hex characters ++ // e.g. two hex characters ++ min_useful_label_width_ = util::text_width(m, "XX"); + + default_row_height_ = (ViewItemPaintParams::text_height() * 6) / 4; + annotation_height_ = (ViewItemPaintParams::text_height() * 5) / 4; +diff --git a/pv/views/trace/ruler.cpp b/pv/views/trace/ruler.cpp +index 555794fc..83ffed28 100644 +--- a/pv/views/trace/ruler.cpp ++++ b/pv/views/trace/ruler.cpp +@@ -283,7 +283,7 @@ void Ruler::paintEvent(QPaintEvent*) + const int rightedge = width(); + const int x_tick = tick.first; + if ((x_tick > leftedge) && (x_tick < rightedge)) { +- const int x_left_bound = QFontMetrics(font()).width(tick.second) / 2; ++ const int x_left_bound = util::text_width(QFontMetrics(font()), tick.second) / 2; + const int x_right_bound = rightedge - x_left_bound; + const int x_legend = min(max(x_tick, x_left_bound), x_right_bound); + p.drawText(x_legend, ValueMargin, 0, text_height, +diff --git a/pv/widgets/timestampspinbox.cpp b/pv/widgets/timestampspinbox.cpp +index fea8175e..01424a5b 100644 +--- a/pv/widgets/timestampspinbox.cpp ++++ b/pv/widgets/timestampspinbox.cpp +@@ -76,7 +76,7 @@ QSize TimestampSpinBox::minimumSizeHint() const + { + const QFontMetrics fm(fontMetrics()); + const int l = round(value_).str().size() + precision_ + 10; +- const int w = fm.width(QString(l, '0')); ++ const int w = util::text_width(fm, QString(l, '0')); + const int h = lineEdit()->minimumSizeHint().height(); + return QSize(w, h); + } +-- +2.24.0.rc2 + -- cgit v1.2.3