all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Craven <david@craven.ch>
To: guix-devel@gnu.org
Subject: [PATCH 2/2] gnu: Add idris-lightyear.
Date: Thu, 15 Dec 2016 18:28:35 +0100	[thread overview]
Message-ID: <20161215172835.7300-2-david@craven.ch> (raw)
In-Reply-To: <20161215172835.7300-1-david@craven.ch>

* gnu/packages/haskell.scm (idris-lightyear): New variable.
---
 gnu/packages/haskell.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm
index 2f75c6c37..54fdba72f 100644
--- a/gnu/packages/haskell.scm
+++ b/gnu/packages/haskell.scm
@@ -29,6 +29,7 @@
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix packages)
   #:use-module (guix download)
+  #:use-module (guix git-download)
   #:use-module (guix utils)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system haskell)
@@ -6747,6 +6748,51 @@ can be specified precisely in the type.  The language is closely related to
 Epigram and Agda.")
     (license license:bsd-3)))
 
+(define-public idris-lightyear
+  (let ((commit "6d65ad111b4bed2bc131396f8385528fc6b3678a")
+        (revision "1"))
+    (package
+      (name "idris-lightyear")
+      (version (string-append "0.1-" revision "."
+                              (string-take commit 7)))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://github.com/ziman/lightyear")
+                      (commit commit)))
+                (file-name (string-append name "-" version "-checkout"))
+                (sha256
+                 (base32
+                  "1pkxnn3ryr0v0cin4nasw7kgkc9dnnpja1nfbj466mf3qv5s98af"))))
+      ;; Uses the gnu-build-system so that the IDRIS_LIBRARY_PATH is set.
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("idris" ,idris)))
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (delete 'configure)
+           (delete 'build)
+           (delete 'check)
+           (replace 'install
+             (lambda* (#:key inputs outputs #:allow-other-keys)
+               (let* ((out (assoc-ref outputs "out"))
+                      (src (assoc-ref inputs "source"))
+                      (idris (assoc-ref inputs "idris"))
+                      (libs (string-append out "/idris/libs/lightyear")))
+                 (mkdir-p libs)
+                 (zero? (system* (string-append idris "/bin/idris")
+                          "--ibcsubdir" libs
+                          "--install" "lightyear.ipkg"))
+                 ;; Seems to be a bug in idris.
+                 #t))))))
+      (home-page "https://github.com/ziman/lightyear")
+      (synopsis "Lightweight parser combinator library for Idris")
+      (description "Lightweight parser combinator library for Idris, inspired
+by Parsec.  This package is used (almost) the same way as Parsec, except for one
+difference: backtracking.")
+      (license license:bsd-2))))
+
 (define-public ghc-base16-bytestring
   (package
     (name "ghc-base16-bytestring")
-- 
2.11.0

  reply	other threads:[~2016-12-15 17:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-15 17:28 [PATCH 1/2] gnu: idris: Update to 0.99 David Craven
2016-12-15 17:28 ` David Craven [this message]
2016-12-19 14:14   ` [PATCH 2/2] gnu: Add idris-lightyear Ludovic Courtès
2016-12-19 14:13 ` [PATCH 1/2] gnu: idris: Update to 0.99 Ludovic Courtès
2016-12-19 14:17   ` David Craven
2016-12-19 16:22     ` Ludovic Courtès

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

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

  git send-email \
    --in-reply-to=20161215172835.7300-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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.