unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: David Craven <david@craven.ch>
To: guix-devel@gnu.org
Subject: [PATCH 2/4] gnu: Add ocaml-zarith.
Date: Mon,  2 Jan 2017 18:38:12 +0100	[thread overview]
Message-ID: <20170102173814.6837-2-david@craven.ch> (raw)
In-Reply-To: <20170102173814.6837-1-david@craven.ch>

* gnu/packages/ocaml.scm (ocaml-zarith): New variable.
---
 gnu/packages/ocaml.scm | 39 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 7bb9c6d7d..f6b79f75c 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -7,6 +7,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2016 David Craven <david@craven.ch>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -46,6 +47,7 @@
   #:use-module (gnu packages perl)
   #:use-module (gnu packages python)
   #:use-module (gnu packages m4)
+  #:use-module (gnu packages multiprecision)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages version-control)
   #:use-module (gnu packages curl))
@@ -296,6 +298,43 @@ concrete syntax of the language (Quotations, Syntax Extensions).")
     ;; Most files are distributed under bsd-3, but ocaml_stuff/* is under qpl.
     (license (list license:bsd-3 license:qpl))))
 
+(define-public ocaml-zarith
+  (package
+    (name "ocaml-zarith")
+    (version "1.4.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://github.com/ocaml/Zarith/archive/"
+                                  "release-" version ".tar.gz"))
+              (file-name (string-append name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0770xwy0kcnba87wjw6sc5grm0r3mylxkc8gmyjhsy44zvjsqdij"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("ocaml" ,ocaml)
+       ("ocaml-findlib" ,ocaml-findlib)
+       ("perl" ,perl)))
+    (propagated-inputs
+     `(("gmp" ,gmp)))
+    (arguments
+     `(#:test-target "tests"
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (lib (string-append out "/lib/ocaml/site-lib")))
+               (mkdir-p lib)
+               ;; Does not use autoconf, automake.
+               (zero? (system* "./configure" "-installdir" lib))))))))
+    (home-page "https://github.com/ocaml/Zarith")
+    (synopsis "Management tool for OCaml libraries")
+    (description "The Zarith library implements arithmetic and logical
+operations over arbitrary-precision integers and rational numbers.  The
+implementation is based on GMP and is very efficient.")
+    (license license:gpl2+)))
+
 (define-public hevea
   (package
     (name "hevea")
-- 
2.11.0

  reply	other threads:[~2017-01-02 17:38 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-02 17:38 [PATCH 1/4] gnu: Use 'license:' prefix in (gnu packages ocaml) David Craven
2017-01-02 17:38 ` David Craven [this message]
2017-01-03 12:30   ` [PATCH 2/4] gnu: Add ocaml-zarith Ludovic Courtès
2017-01-02 17:38 ` [PATCH 3/4] gnu: Reorder imports in (gnu packages ocaml) David Craven
2017-01-03 12:30   ` Ludovic Courtès
2017-01-02 17:38 ` [PATCH 4/4] gnu: ocaml-findlib: Update to 1.7.1 David Craven
2017-01-02 20:51   ` Julien Lepiller
2017-01-03 11:03   ` Ben Woodcroft
2017-01-03 12:29 ` [PATCH 1/4] gnu: Use 'license:' prefix in (gnu packages ocaml) Ludovic Courtès
2017-01-03 15:27 ` Danny Milosavljevic

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170102173814.6837-2-david@craven.ch \
    --to=david@craven.ch \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).