From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Craven Subject: [PATCH 2/2] gnu: Add idris-lightyear. Date: Thu, 15 Dec 2016 18:28:35 +0100 Message-ID: <20161215172835.7300-2-david@craven.ch> References: <20161215172835.7300-1-david@craven.ch> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60807) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cHZqG-0001uZ-6g for guix-devel@gnu.org; Thu, 15 Dec 2016 12:29:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cHZqB-0008F0-9G for guix-devel@gnu.org; Thu, 15 Dec 2016 12:29:16 -0500 Received: from so254-10.mailgun.net ([198.61.254.10]:64474) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cHZqB-0007yJ-4C for guix-devel@gnu.org; Thu, 15 Dec 2016 12:29:11 -0500 In-Reply-To: <20161215172835.7300-1-david@craven.ch> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org * 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