;;; Copyright © 2016, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org>
-;;; Copyright © 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2018, 2019, 2021 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2021 Vinicius Monego <monego@posteo.net>
;;;
;;; This file is part of GNU Guix.
;;;
(define-public gmp
(package
(name "gmp")
- (version "6.2.0")
+ (version "6.2.1")
(source (origin
(method url-fetch)
(uri
version ".tar.xz"))
(sha256
(base32
- "09hmg8k63mbfrx1x3yy6y1yzbbq85kw5avbibhcgrg9z3ganr3i5"))
+ "1wml97fdmpcynsbw9yl77rj29qibfp652d0w3222zlfx5j8jjj7x"))
(patches (search-patches "gmp-faulty-test.patch"))))
(build-system gnu-build-system)
- (native-inputs `(("m4" ,m4)))
+ (native-inputs (list m4))
(outputs '("out" "debug"))
(arguments
`(#:parallel-tests? #f ; mpz/reuse fails otherwise
(define-public mpfr
(package
(name "mpfr")
- (version "4.0.2")
+ (version "4.1.0")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/mpfr/mpfr-" version
".tar.xz"))
(sha256 (base32
- "12m3amcavhpqygc499s3fzqlb8f2j2rr7fkqsm10xbjfc04fffqx"))))
+ "0zwaanakrqjf84lfr5hfsdr7hncwv9wj0mchlr7cmxigfgqs760c"))))
(build-system gnu-build-system)
(outputs '("out" "debug"))
- (propagated-inputs `(("gmp" ,gmp))) ; <mpfr.h> refers to <gmp.h>
+ (propagated-inputs (list gmp)) ; <mpfr.h> refers to <gmp.h>
(synopsis "C library for arbitrary-precision floating-point arithmetic")
(description
"GNU@tie{}@acronym{MPFR, Multiple Precision Floating-Point Reliably} is a C
(define-public mpc
(package
(name "mpc")
- (version "1.1.0")
+ (version "1.2.1")
(source (origin
(method url-fetch)
(uri (string-append
"mirror://gnu/mpc/mpc-" version ".tar.gz"))
(sha256
(base32
- "0biwnhjm3rx3hc0rfpvyniky4lpzsvdcwhmcn7f0h4iw2hwcb1b9"))))
+ "0n846hqfqvmsmim7qdlms0qr86f1hck19p12nq3g3z2x74n3sl0p"))))
(build-system gnu-build-system)
(outputs '("out" "debug"))
- (propagated-inputs `(("gmp" ,gmp) ; <mpc.h> refers to both
- ("mpfr" ,mpfr)))
+ (propagated-inputs (list gmp ; <mpc.h> refers to both
+ mpfr))
(synopsis "C library for arbitrary-precision complex arithmetic")
(description
"GNU@tie{}@acronym{MPC, Multiple Precision Complex library} is a C library
("libtool" ,libtool)
("texinfo" ,texinfo)))
(propagated-inputs
- `(("gmp" ,gmp) ; <mpfi.h> refers to both
- ("mpfr" ,mpfr)))
+ (list gmp ; <mpfi.h> refers to both
+ mpfr))
(home-page "https://gforge.inria.fr/projects/mpfi/")
(synopsis "C library for arbitrary-precision interval arithmetic")
(description
(sha256
(base32 "1cdmvb4hsa161rfdjqyhd9sb3fcr43p3a6nsj7cb4kn9f94qmjpj"))))
(build-system gnu-build-system)
- (propagated-inputs `(("gmp" ,gmp) ; <mpfi.h> refers to both
- ("mpfr" ,mpfr)))
+ (propagated-inputs (list gmp ; <mpfi.h> refers to both
+ mpfr))
(arguments
`(#:parallel-build? #f))
(synopsis "C++ package for real arithmetic based on the Real-RAM concept")
(define-public qd
(package
(name "qd")
- (version "2.3.22")
+ (version "2.3.23")
(source
(origin
(method url-fetch)
(uri (string-append "https://crd-legacy.lbl.gov/~dhbailey/mpdist/qd-"
version ".tar.gz"))
(sha256
- (base32 "1lq609rsp6zpg7zda75lyxzzk1fabzp4jn88j7xfk84mdgjgzh9h"))))
+ (base32 "09pfd77rmy370hy7qdqw84z21y9zpl3fcwzf93rhiv0kwhfg9smk"))))
(build-system gnu-build-system)
(native-inputs
- `(("gfortran" ,gfortran)))
+ (list gfortran))
(arguments
`(#:configure-flags `("--disable-enable_fma" ;weird :/
+ "--disable-static"
"--enable-shared"
,,@(if (string-prefix? "aarch64"
(or (%current-target-system)
and numerical quadrature programs are included.")
(license bsd-3)))
+(define-public cln
+ (package
+ (name "cln")
+ (version "1.3.6")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.ginac.de/CLN/cln-"
+ version ".tar.bz2"))
+ (sha256
+ (base32 "0jlq9l4hphk7qqlgqj9ihjp4m3rwjbhk6q4v00lsbgbri07574pl"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:configure-flags (list "--disable-static")))
+ (inputs
+ (list gmp))
+ (home-page "https://www.ginac.de/CLN/")
+ (synopsis "Library for arbitrary precision computations")
+ (description "CLN is a C++ library for efficient computations with all
+kinds of numbers in arbitrary precision. It provides a rich set of number
+classes and elementary, logical and transcendental functions.")
+ (license gpl2+)))
+
(define-public tomsfastmath
(package
(name "tomsfastmath")
"0f0pmiaskh89sp0q933pafxb914shpaj5ad8sb5rzk1wv8d7mja7"))))
(build-system gnu-build-system)
(native-inputs
- `(("libtool" ,libtool)))
+ (list libtool))
(arguments
`(#:make-flags (list "-f" "makefile.shared"
(string-append "LIBPATH=" %output "/lib")
multiplies.")
(license public-domain)))
+(define-public libtomcrypt
+ (package
+ (name "libtomcrypt")
+ (version "1.18.2")
+ (outputs '("out" "static"))
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/libtom/libtomcrypt"
+ "/releases/download/v" version
+ "/crypt-" version ".tar.xz"))
+ (sha256
+ (base32
+ "113vfrgapyv72lalhd3nkw7jnks8az0gcb5wqn9hj19nhcxlrbcn"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; Patch CVE-2019-17362
+ ;; https://github.com/libtom/libtomcrypt/commit/25c26a3b7a9ad8192ccc923e15cf62bf0108ef94
+ (substitute* "src/pk/asn1/der/utf8/der_decode_utf8_string.c"
+ (("z > 4") "z == 1 || z > 4"))
+ #t))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (delete 'configure) ; no configure
+ (add-after 'unpack 'prepare-build
+ (lambda _
+ ;; We want the shared library by default so force it to be the
+ ;; default makefile target.
+ (delete-file "makefile")
+ (symlink "makefile.shared" "makefile")
+ ;; We link to libtommath, so we need to add it to the pc file
+ (substitute* "libtomcrypt.pc.in"
+ (("-ltomcrypt") "-ltomcrypt -ltommath"))
+ #t))
+ (add-after 'build 'build-static
+ (lambda* (#:key make-flags #:allow-other-keys)
+ (apply invoke "make" "-f" "makefile.unix" make-flags)))
+ (replace 'check
+ (lambda* (#:key test-target make-flags #:allow-other-keys)
+ (apply invoke "make" "-f" "makefile.unix" test-target make-flags)
+ (invoke "./test")))
+ (add-after 'install 'install-static-library
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (static (assoc-ref outputs "static")))
+ (mkdir-p (string-append static "/lib"))
+ (mkdir-p (string-append static "/include"))
+ (rename-file (string-append out "/lib/libtomcrypt.a")
+ (string-append static "/lib/libtomcrypt.a"))
+ (copy-recursively (string-append out "/include")
+ (string-append static "/include"))
+ #t))))
+ #:test-target "test"
+ #:make-flags
+ (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
+ "CFLAGS += -DLTM_DESC -DUSE_LTM"
+ (string-append "EXTRALIBS="
+ (search-input-file %build-inputs
+ "/lib/libtommath.so"))
+ (string-append "CC=" ,(cc-for-target)))))
+ (native-inputs
+ (list libtool))
+ (inputs
+ (list libtommath))
+ (home-page "https://www.libtom.net/LibTomCrypt/")
+ (synopsis "Cryptographic toolkit")
+ (description "LibTomCrypt is a fairly comprehensive, modular and portable
+cryptographic toolkit that provides developers with a vast array of well known
+published block ciphers, one-way hash functions, chaining modes, pseudo-random
+number generators, public key cryptography and a plethora of other routines.")
+ (properties `((lint-hidden-cve . ("CVE-2019-17362"))))
+ (license unlicense)))
+
(define-public libtommath
(package
(name "libtommath")
#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
"CC=gcc")))
(native-inputs
- `(("libtool" ,libtool)))
+ (list libtool))
(home-page "https://www.libtom.net/LibTomMath/")
(synopsis "Portable number theoretic multiple-precision integer library")
(description "LibTomMath is a portable number theoretic multiple-precision