From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Lepiller Subject: [PATCH 06/10] gnu: Add ocaml-ppx-deriving. Date: Tue, 31 Jan 2017 21:58:11 +0100 Message-ID: <20170131205815.14576-7-julien@lepiller.eu> References: <20170131205815.14576-1-julien@lepiller.eu> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:34735) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cYfVq-0007Im-8T for guix-devel@gnu.org; Tue, 31 Jan 2017 15:58:51 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cYfVo-0005Ya-6s for guix-devel@gnu.org; Tue, 31 Jan 2017 15:58:50 -0500 Received: from dau94-h03-89-91-205-84.dsl.sta.abo.bbox.fr ([89.91.205.84]:41364 helo=skaro.lepiller.eu) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cYfVn-0005WM-Te for guix-devel@gnu.org; Tue, 31 Jan 2017 15:58:48 -0500 Received: from localhost (localhost [127.0.0.1]) by skaro.lepiller.eu (Postfix) with ESMTP id 7E9DF80472 for ; Tue, 31 Jan 2017 21:58:45 +0100 (CET) Received: from skaro.lepiller.eu ([127.0.0.1]) by localhost (lepiller.eu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ewOdrnMQPL07 for ; Tue, 31 Jan 2017 21:58:41 +0100 (CET) Received: from localhost.localdomain (128-79-116-134.hfc.dyn.abo.bbox.fr [128.79.116.134]) by skaro.lepiller.eu (Postfix) with ESMTPSA id 1C5AE81227 for ; Tue, 31 Jan 2017 21:58:33 +0100 (CET) In-Reply-To: <20170131205815.14576-1-julien@lepiller.eu> 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/ocaml.scm (ocaml-ppx-deriving): 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 8e525ff10..bcf9d0c9a 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -2147,3 +2147,42 @@ programs. It allows the definition of simple macros and file inclusion. Cpp oi @item simple to install and to maintain. @end enumerate") (license license:bsd-3))) + +;; this package is not reproducible. This is related to temporary filenames +;; such as findlib_initxxxxx where xxxxx is random. +(define-public ocaml-ppx-deriving + (package + (name "ocaml-ppx-deriving") + (version "4.1") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/whitequark/ppx_deriving//archive/v" + version ".tar.gz")) + (sha256 (base32 + "1fr16g121j6zinwcprzlhx2py4271n9jzs2m9hq2f3qli2b1p0vl")) + (file-name (string-append name "-" version ".tar.gz")))) + (build-system ocaml-build-system) + (native-inputs + `(("js-build-tools" ,ocaml-js-build-tools) + ("cppo" ,ocaml-cppo) + ("ounit" ,ocaml-ounit) + ("opam" ,opam))) + (propagated-inputs + `(("result" ,ocaml-result) + ("ppx-tools" ,ocaml-ppx-tools))) + (arguments + `(#:phases + (modify-phases %standard-phases + (delete 'configure) + (add-before 'install 'fix-environment + (lambda* (#:key outputs #:allow-other-keys) + ;; the installation procedures looks for the installed module + (setenv "OCAMLPATH" + (string-append (getenv "OCAMLPATH") ":" + (getenv "OCAMLFIND_DESTDIR")))))))) + (home-page "https://github.com/whitequark/ppx_deriving/") + (synopsis "Type-driven code generation for OCaml >=4.02") + (description "Ppx_deriving provides common infrastructure for generating +code based on type definitions, and a set of useful plugins for common tasks.") + (license license:expat))) -- 2.11.0