You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

97 lines
3.6 KiB

  1. ;;; GNU Guix --- Functional package management for GNU
  2. ;;; Copyright © 2012, 2013 Ludovic Courtès <ludo@gnu.org>
  3. ;;;
  4. ;;; This file is part of GNU Guix.
  5. ;;;
  6. ;;; GNU Guix is free software; you can redistribute it and/or modify it
  7. ;;; under the terms of the GNU General Public License as published by
  8. ;;; the Free Software Foundation; either version 3 of the License, or (at
  9. ;;; your option) any later version.
  10. ;;;
  11. ;;; GNU Guix is distributed in the hope that it will be useful, but
  12. ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
  13. ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. ;;; GNU General Public License for more details.
  15. ;;;
  16. ;;; You should have received a copy of the GNU General Public License
  17. ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
  18. (define-module (gnu packages multiprecision)
  19. #:use-module (guix licenses)
  20. #:use-module (gnu packages)
  21. #:use-module (gnu packages m4)
  22. #:use-module (guix packages)
  23. #:use-module (guix download)
  24. #:use-module (guix build-system gnu))
  25. (define-public gmp
  26. (package
  27. (name "gmp")
  28. (version "5.1.3")
  29. (source (origin
  30. (method url-fetch)
  31. (uri
  32. (string-append "mirror://gnu/gmp/gmp-"
  33. version ".tar.xz"))
  34. (sha256
  35. (base32
  36. "0wbhn3wih61vjcs94q531fipfvvzqfq2v4qr03rl3xaggyiyvqny"))))
  37. (build-system gnu-build-system)
  38. (native-inputs `(("m4" ,m4)))
  39. (outputs '("out" "debug"))
  40. (arguments `(#:configure-flags
  41. '(;; Build a "fat binary", with routines for several
  42. ;; sub-architectures.
  43. "--enable-fat"
  44. "--enable-cxx")))
  45. (synopsis "Multiple-precision arithmetic library")
  46. (description
  47. "GMP is a library for arbitrary precision arithmetic, operating on
  48. signed integers, rational numbers and floating point numbers. The precision
  49. is only limited by the available memory. The library is highly optimized,
  50. with a design focus on execution speed. It is aimed at use in, for example,
  51. cryptography and computational algebra.")
  52. (license lgpl3+)
  53. (home-page "http://gmplib.org/")))
  54. (define-public mpfr
  55. (package
  56. (name "mpfr")
  57. (version "3.1.2")
  58. (source (origin
  59. (method url-fetch)
  60. (uri (string-append "mirror://gnu/mpfr/mpfr-" version
  61. ".tar.xz"))
  62. (sha256 (base32
  63. "0fs501qi8l523gs3cpy4jjcnvwxggyfbklcys80wq236xx3hz79r"))))
  64. (build-system gnu-build-system)
  65. (outputs '("out" "debug"))
  66. (propagated-inputs `(("gmp" ,gmp))) ; <mpfr.h> refers to <gmp.h>
  67. (synopsis "C library for arbitrary precision floating-point arithmetic")
  68. (description
  69. "MPFR is a C library for performing multiple-precision, floating-point
  70. computations with correct rounding.")
  71. (license lgpl3+)
  72. (home-page "http://www.mpfr.org/")))
  73. (define-public mpc
  74. (package
  75. (name "mpc")
  76. (version "1.0.1")
  77. (source (origin
  78. (method url-fetch)
  79. (uri (string-append
  80. "mirror://gnu/mpc/mpc-" version ".tar.gz"))
  81. (sha256 (base32
  82. "1zq0fidp1jii2j5k5n9hmx55a6wwid33gjzhimvxq9d5zrf82npd"))))
  83. (build-system gnu-build-system)
  84. (outputs '("out" "debug"))
  85. (propagated-inputs `(("gmp" ,gmp) ; <mpc.h> refers to both
  86. ("mpfr" ,mpfr)))
  87. (synopsis "C library for arbitrary precision complex arithmetic")
  88. (description
  89. "GNU MPC is a C library for performing arithmetic on complex numbers.
  90. It supports arbitrarily high precision and it correctly rounds the results.")
  91. (license lgpl3+)
  92. (home-page "http://mpc.multiprecision.org/")))