From unknown Sun Jun 22 11:29:40 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#33437 <33437@debbugs.gnu.org> To: bug#33437 <33437@debbugs.gnu.org> Subject: Status: [PATCH] Add dune-build-system Reply-To: bug#33437 <33437@debbugs.gnu.org> Date: Sun, 22 Jun 2025 18:29:40 +0000 retitle 33437 [PATCH] Add dune-build-system reassign 33437 guix-patches submitter 33437 Julien Lepiller severity 33437 normal tag 33437 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:26:13 2018 Received: (at submit) by debbugs.gnu.org; 19 Nov 2018 22:26:13 +0000 Received: from localhost ([127.0.0.1]:33152 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOrzh-0008E3-Fi for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:26:13 -0500 Received: from eggs.gnu.org ([208.118.235.92]:40678) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOrzf-0008Dq-SU for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:26:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gOrzZ-0004cE-Ta for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:26:06 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:40296) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gOrzZ-0004c8-Qu for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:26:05 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50282) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gOrzY-0004qP-Gb for guix-patches@gnu.org; Mon, 19 Nov 2018 17:26:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gOrzU-0004Yf-JV for guix-patches@gnu.org; Mon, 19 Nov 2018 17:26:04 -0500 Received: from lepiller.eu ([2a00:5884:8208::1]:36768) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gOrzU-0004XR-9l for guix-patches@gnu.org; Mon, 19 Nov 2018 17:26:00 -0500 Received: from localhost (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id ead75328 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for ; Mon, 19 Nov 2018 22:23:43 +0000 (UTC) Date: Mon, 19 Nov 2018 23:25:37 +0100 From: Julien Lepiller To: guix-patches@gnu.org Subject: [PATCH] Add dune-build-system Message-ID: <20181119232537.66d2a822@lepiller.eu> X-Mailer: Claws Mail 3.17.1 (GTK+ 2.24.32; x86_64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) Hi, here is a small patch series to add dune-build-system and convert a few packages to it. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:44 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:44 +0000 Received: from localhost ([127.0.0.1]:33159 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs27-0008Hs-Ta for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:44 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs25-0008HY-3c for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:41 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id cf5c52f9 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:25 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 01/10] build: Add dune-build-system. Date: Mon, 19 Nov 2018 23:28:12 +0100 Message-Id: <20181119222821.16789-1-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * guix/build/dune-build-system.scm, guix/build-system/dune.scm: New files. * Makefile.am (MODULES): Add them. * doc/guix.texi (Build Systems): Document dune-build-system. * guix/build-system/ocaml.scm (lower, default-findlib, default-ocaml): Export them. (package-with-explicit-ocaml): Also transform packages built with dune-build-system. --- Makefile.am | 2 + doc/guix.texi | 22 +++++ guix/build-system/dune.scm | 158 +++++++++++++++++++++++++++++++ guix/build-system/ocaml.scm | 16 +++- guix/build/dune-build-system.scm | 69 ++++++++++++++ 5 files changed, 265 insertions(+), 2 deletions(-) create mode 100644 guix/build-system/dune.scm create mode 100644 guix/build/dune-build-system.scm diff --git a/Makefile.am b/Makefile.am index c63b65ba5..956ba8622 100644 --- a/Makefile.am +++ b/Makefile.am @@ -102,6 +102,7 @@ MODULES = \ guix/build-system/cargo.scm \ guix/build-system/cmake.scm \ guix/build-system/dub.scm \ + guix/build-system/dune.scm \ guix/build-system/emacs.scm \ guix/build-system/font.scm \ guix/build-system/go.scm \ @@ -139,6 +140,7 @@ MODULES = \ guix/build/cargo-build-system.scm \ guix/build/cmake-build-system.scm \ guix/build/dub-build-system.scm \ + guix/build/dune-build-system.scm \ guix/build/emacs-build-system.scm \ guix/build/meson-build-system.scm \ guix/build/minify-build-system.scm \ diff --git a/doc/guix.texi b/doc/guix.texi index a9c6e975a..51a3b191b 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -4412,6 +4412,28 @@ debugging information''), which roughly means that code is compiled with @code{-O2 -g}, as is the case for Autoconf-based packages by default. @end defvr +@defvr {Scheme Variable} dune-build-system +This variable is exported by @code{(guix build-system dune)}. It +supports builds of packaes using Dune, a build tool for the +@uref{https://ocaml.org, OCaml programming language}. It is implemented +as an extension of the @code{ocaml-build-system} which is describe below. +As such, the @code{#:ocaml} and @code{#:findlib} parameters can be passed +to this build system. + +It automically adds the @code{dune} package to the set of inputs. +Which package is used can be specified with the @code{#:dune} +parameter. + +The @code{'configure} phase is removed as dune packages typically +don't need to be configured. The @code{#:build-flags} parameter is +taken as a list of flags passed to the @code{dune} command during the +build. + +The @code{#:legacy?} parameter can be passed to use the @code{jbuild} +command instead of the more recent @code{dune} command while building +a package. Its default value is @code{#f}. +@end defvr + @defvr {Scheme Variable} go-build-system This variable is exported by @code{(guix build-system go)}. It implements a build procedure for Go packages using the standard diff --git a/guix/build-system/dune.scm b/guix/build-system/dune.scm new file mode 100644 index 000000000..1937c7df4 --- /dev/null +++ b/guix/build-system/dune.scm @@ -0,0 +1,158 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2016, 2017, 2018 Julien Lepiller +;;; Copyright © 2017 Ben Woodcroft +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . +(define-module (guix build-system dune) + #:use-module (guix store) + #:use-module (guix utils) + #:use-module (guix derivations) + #:use-module (guix search-paths) + #:use-module (guix build-system) + #:use-module ((guix build-system gnu) #:prefix gnu:) + #:use-module ((guix build-system ocaml) #:prefix ocaml:) + #:use-module (guix packages) + #:use-module (ice-9 match) + #:use-module (srfi srfi-1) + #:export (%dune-build-system-modules + dune-build + dune-build-system)) + +;; Commentary: +;; +;; Standard build procedure for packages using dune. This is implemented as an +;; extension of `ocaml-build-system'. +;; +;; Code: + +(define %dune-build-system-modules + ;; Build-side modules imported by default. + `((guix build dune-build-system) + ,@ocaml:%ocaml-build-system-modules)) + +(define (default-dune) + "Return the default OCaml package." + + ;; Do not use `@' to avoid introducing circular dependencies. + (let ((module (resolve-interface '(gnu packages ocaml)))) + (module-ref module 'dune))) + +(define* (lower name + #:key source inputs native-inputs outputs system target + (dune (default-dune)) + (ocaml (ocaml:default-ocaml)) + (findlib (ocaml:default-findlib)) + #:allow-other-keys + #:rest arguments) + "Return a bag for NAME." + (define private-keywords + '(#:source #:target #:dune #:findlib #:ocaml #:inputs #:native-inputs)) + + (and (not target) ;XXX: no cross-compilation + (let ((base (ocaml:lower name + #:source source + #:inputs inputs + #:native-inputs native-inputs + #:outputs outputs + #:system system + #:target target + #:ocaml ocaml + #:findlib findlib + arguments))) + (bag + (inherit base) + (build-inputs `(("dune" ,dune) + ,@(bag-build-inputs base))) + (build dune-build) + (arguments (strip-keyword-arguments private-keywords arguments)))))) + +(define* (dune-build store name inputs + #:key (guile #f) + (outputs '("out")) + (search-paths '()) + (build-flags ''()) + (out-of-source? #t) + (legacy? #f) + (tests? #t) + (test-flags ''()) + (test-target "test") + (install-target "install") + (validate-runpath? #t) + (patch-shebangs? #t) + (strip-binaries? #t) + (strip-flags ''("--strip-debug")) + (strip-directories ''("lib" "lib64" "libexec" + "bin" "sbin")) + (phases '(@ (guix build dune-build-system) + %standard-phases)) + (system (%current-system)) + (imported-modules %dune-build-system-modules) + (modules '((guix build dune-build-system) + (guix build utils)))) + "Build SOURCE using OCAML, and with INPUTS. This assumes that SOURCE +provides a 'setup.ml' file as its build system." + (define builder + `(begin + (use-modules ,@modules) + (dune-build #:source ,(match (assoc-ref inputs "source") + (((? derivation? source)) + (derivation->output-path source)) + ((source) + source) + (source + source)) + #:system ,system + #:outputs %outputs + #:inputs %build-inputs + #:search-paths ',(map search-path-specification->sexp + search-paths) + #:phases ,phases + #:test-flags ,test-flags + #:build-flags ,build-flags + #:out-of-source? ,out-of-source? + #:legacy? ,legacy? + #:tests? ,tests? + #:test-target ,test-target + #:install-target ,install-target + #:validate-runpath? ,validate-runpath? + #:patch-shebangs? ,patch-shebangs? + #:strip-binaries? ,strip-binaries? + #:strip-flags ,strip-flags + #:strip-directories ,strip-directories))) + + (define guile-for-build + (match guile + ((? package?) + (package-derivation store guile system #:graft? #f)) + (#f ; the default + (let* ((distro (resolve-interface '(gnu packages commencement))) + (guile (module-ref distro 'guile-final))) + (package-derivation store guile system #:graft? #f))))) + + (build-expression->derivation store name builder + #:system system + #:inputs inputs + #:modules imported-modules + #:outputs outputs + #:guile-for-build guile-for-build)) + +(define dune-build-system + (build-system + (name 'dune) + (description "The standard Dune build system") + (lower lower))) + +;;; dune.scm ends here diff --git a/guix/build-system/ocaml.scm b/guix/build-system/ocaml.scm index e5b715f55..07c69fac7 100644 --- a/guix/build-system/ocaml.scm +++ b/guix/build-system/ocaml.scm @@ -31,6 +31,9 @@ package-with-ocaml4.02 strip-ocaml4.01-variant strip-ocaml4.02-variant + default-findlib + default-ocaml + lower ocaml-build ocaml-build-system)) @@ -76,6 +79,13 @@ (let ((module (resolve-interface '(gnu packages ocaml)))) (module-ref module 'ocaml-findlib))) +(define (default-dune-build-system) + "Return the dune-build-system." + + ;; Do not use `@' to avoid introducing circular dependencies. + (let ((module (resolve-interface '(guix build-system dune)))) + (module-ref module 'dune-build-system))) + (define (default-ocaml4.01) (let ((ocaml (resolve-interface '(gnu packages ocaml)))) (module-ref ocaml 'ocaml-4.01))) @@ -119,7 +129,8 @@ pre-defined variants." => force) ;; Otherwise build the new package object graph. - ((eq? (package-build-system p) ocaml-build-system) + ((or (eq? (package-build-system p) ocaml-build-system) + (eq? (package-build-system p) (default-dune-build-system))) (package (inherit p) (location (package-location p)) @@ -138,7 +149,8 @@ pre-defined variants." (else p))) (define (cut? p) - (or (not (eq? (package-build-system p) ocaml-build-system)) + (or (not (or (eq? (package-build-system p) ocaml-build-system) + (eq? (package-build-system p) (default-dune-build-system)))) (package-variant p))) (package-mapping transform cut?)) diff --git a/guix/build/dune-build-system.scm b/guix/build/dune-build-system.scm new file mode 100644 index 000000000..08a63d2ab --- /dev/null +++ b/guix/build/dune-build-system.scm @@ -0,0 +1,69 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2018 Julien Lepiller +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +(define-module (guix build dune-build-system) + #:use-module ((guix build ocaml-build-system) #:prefix ocaml:) + #:use-module (guix build utils) + #:use-module (ice-9 match) + #:export (%standard-phases + dune-build)) + +;; Commentary: +;; +;; Builder-side code of the standard dune build procedure. +;; +;; Code: + +(define* (build #:key (build-flags '()) (legacy? #f) + (use-make? #f) #:allow-other-keys) + "Build the given package." + (let ((program (if legacy? "jbuilder" "dune"))) + (apply invoke program "build" "@install" build-flags)) + #t) + +(define* (check #:key (test-flags '()) (test-target "test") tests? + (legacy? #f) #:allow-other-keys) + "Test the given package." + (when tests? + (let ((program (if legacy? "jbuilder" "dune"))) + (apply invoke program "runtest" test-target test-flags))) + #t) + +(define* (install #:key outputs (install-target "install") (legacy? #f) + #:allow-other-keys) + "Install the given package." + (let ((out (assoc-ref outputs "out")) + (program (if legacy? "jbuilder" "dune"))) + (invoke program install-target "--prefix" out)) + #t) + +(define %standard-phases + ;; Everything is as with the GNU Build System except for the `configure' + ;; , `build', `check' and `install' phases. + (modify-phases ocaml:%standard-phases + (delete 'configure) + (replace 'build build) + (replace 'check check) + (replace 'install install))) + +(define* (dune-build #:key inputs (phases %standard-phases) + #:allow-other-keys #:rest args) + "Build the given package, applying all of PHASES in order." + (apply ocaml:ocaml-build #:inputs inputs #:phases phases args)) + +;;; dune-build-system.scm ends here -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:45 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:45 +0000 Received: from localhost ([127.0.0.1]:33163 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs28-0008Hw-Kk for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:45 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs26-0008HY-9B for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:43 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id aeb7f600 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:25 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 02/10] gnu: ocaml-migrate-parsetree: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:13 +0100 Message-Id: <20181119222821.16789-2-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-migrate-parsetree): Use dune-build-system. --- gnu/packages/ocaml.scm | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index e1323582a..a1f6adc8b 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -62,6 +62,7 @@ #:use-module (gnu packages web-browsers) #:use-module (gnu packages xml) #:use-module (gnu packages xorg) + #:use-module (guix build-system dune) #:use-module (guix build-system gnu) #:use-module (guix build-system ocaml) #:use-module (guix download) @@ -1536,26 +1537,13 @@ following a very simple s-expression syntax.") (sha256 (base32 "01zjp1q4hryqaxv4apkjd868fycz2kf887r6lkb6x2a545h1lh7f")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments `(#:tests? #f - #:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "jbuilder" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "jbuilder" "install" - "--prefix" (assoc-ref outputs "out")) - #t))))) + #:legacy? #t)) (propagated-inputs `(("ocamlbuild" ,ocamlbuild) ("ocaml-result" ,ocaml-result))) - (native-inputs - `(("dune" ,dune))) (home-page "https://github.com/ocaml-ppx/ocaml-migrate-parsetree") (synopsis "OCaml parsetree convertor") (description "This library converts between parsetrees of different OCaml -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:46 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:46 +0000 Received: from localhost ([127.0.0.1]:33169 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2A-0008IZ-37 for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:46 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs27-0008HY-Af for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:43 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id 5643589a (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:25 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 03/10] gnu: ocaml-ppx-tools-versioned: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:14 +0100 Message-Id: <20181119222821.16789-3-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-ppx-tools-versioned): Use dune-build-system. Remove duplicate definition. --- gnu/packages/ocaml.scm | 55 ++---------------------------------------- 1 file changed, 2 insertions(+), 53 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index a1f6adc8b..fe8871152 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -1564,60 +1564,9 @@ functions to the next and/or previous version.") (sha256 (base32 "1x2xfjpkzbcz4rza1d7gh3ipliw6jqfcklbsln82v3561qgkqgmh")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))))) - (native-inputs - `(("dune" ,dune))) - (propagated-inputs - `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree))) - (home-page "https://github.com/let-def/ppx_tools_versioned") - (synopsis "Variant of ppx_tools") - (description "This package is a variant of ppx_tools based on -ocaml-migrate-parsetree") - (license license:expat))) - -(define-public ocaml-ppx-tools-versioned - (package - (name "ocaml-ppx-tools-versioned") - (version "5.2.1") - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/ocaml-ppx/" - "ppx_tools_versioned/archive/" - version ".tar.gz")) - (file-name (string-append name "-" version ".tar.gz")) - (sha256 - (base32 - "1x2xfjpkzbcz4rza1d7gh3ipliw6jqfcklbsln82v3561qgkqgmh")))) - (build-system ocaml-build-system) - (arguments - `(#:tests? #f - #:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))))) - (native-inputs - `(("dune" ,dune))) + `(#:test-target ".")) (propagated-inputs `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree))) (home-page "https://github.com/let-def/ppx_tools_versioned") -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:47 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:47 +0000 Received: from localhost ([127.0.0.1]:33172 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2A-0008Ig-GH for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:46 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs28-0008HY-1W for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:44 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id c798740d (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:25 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 04/10] gnu: ocaml-bitstring: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:15 +0100 Message-Id: <20181119222821.16789-4-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-bitstring): Use dune-build-system. (ocaml4.02-bitstring)[build-system]: Use ocaml-build-system explicitly. --- gnu/packages/ocaml.scm | 95 +++++++++++++++++++----------------------- 1 file changed, 42 insertions(+), 53 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index fe8871152..bf4fcc47f 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -1587,31 +1587,19 @@ ocaml-migrate-parsetree") (sha256 (base32 "15jjk2pq1vx311gl49s5ag6x5y0654x35w75z07g7kr2q334hqps")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (native-inputs `(("camlp4" ,camlp4) ("time" ,time) ("autoconf" ,autoconf) ("automake" ,automake) - ("bisect" ,ocaml-bisect) - ("dune" ,dune))) + ("bisect" ,ocaml-bisect))) (propagated-inputs `(("camlp4" ,camlp4) ("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned))) (arguments `(#:tests? #f; Tests fail to build - #:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "jbuilder" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))))) + #:legacy? #t)) (properties `((ocaml4.02-variant . ,(delay ocaml4.02-bitstring)))) (home-page "https://github.com/xguerin/bitstring") @@ -1637,44 +1625,45 @@ powerful.") (base32 "0vy8ibrxccii1jbsk5q6yh1kxjigqvi7lhhcmizvd5gfhf7mfyc8")) (patches (search-patches "ocaml-bitstring-fix-configure.patch")))) - (arguments - `(#:ocaml ,ocaml-4.02 - #:findlib ,ocaml4.02-findlib - #:configure-flags - (list "CAMLP4OF=camlp4of" "--enable-coverage") - #:make-flags - (list (string-append "BISECTLIB=" - (assoc-ref %build-inputs "bisect") - "/lib/ocaml/site-lib") - (string-append "OCAMLCFLAGS=-g -I " - (assoc-ref %build-inputs "camlp4") - "/lib/ocaml/site-lib/camlp4 -I " - "$(BISECTLIB)/bisect") - (string-append "OCAMLOPTFLAGS=-g -I " - (assoc-ref %build-inputs "camlp4") - "/lib/ocaml/site-lib/camlp4 -I " - "$(BISECTLIB)/bisect")) - #:phases - (modify-phases %standard-phases - (add-after 'install 'link-lib - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (stubs (string-append out - "/lib/ocaml/site-lib/stubslibs")) - (lib (string-append out - "/lib/ocaml/site-lib/bitstring"))) - (mkdir-p stubs) - (symlink (string-append lib "/dllbitstring.so") - (string-append stubs "/dllbitstring.so"))) - #t)) - (add-before 'configure 'fix-configure - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "Makefile.in" - (("@abs_top_builddir@") - (string-append "@abs_top_builddir@:" (getenv "LIBRARY_PATH")))) - (substitute* "configure" - (("-/bin/sh") (string-append "-" (assoc-ref inputs "bash") - "/bin/sh")))))))) + (build-system ocaml-build-system) + (arguments + `(#:ocaml ,ocaml-4.02 + #:findlib ,ocaml4.02-findlib + #:configure-flags + (list "CAMLP4OF=camlp4of" "--enable-coverage") + #:make-flags + (list (string-append "BISECTLIB=" + (assoc-ref %build-inputs "bisect") + "/lib/ocaml/site-lib") + (string-append "OCAMLCFLAGS=-g -I " + (assoc-ref %build-inputs "camlp4") + "/lib/ocaml/site-lib/camlp4 -I " + "$(BISECTLIB)/bisect") + (string-append "OCAMLOPTFLAGS=-g -I " + (assoc-ref %build-inputs "camlp4") + "/lib/ocaml/site-lib/camlp4 -I " + "$(BISECTLIB)/bisect")) + #:phases + (modify-phases %standard-phases + (add-after 'install 'link-lib + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (stubs (string-append out + "/lib/ocaml/site-lib/stubslibs")) + (lib (string-append out + "/lib/ocaml/site-lib/bitstring"))) + (mkdir-p stubs) + (symlink (string-append lib "/dllbitstring.so") + (string-append stubs "/dllbitstring.so"))) + #t)) + (add-before 'configure 'fix-configure + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "Makefile.in" + (("@abs_top_builddir@") + (string-append "@abs_top_builddir@:" (getenv "LIBRARY_PATH")))) + (substitute* "configure" + (("-/bin/sh") (string-append "-" (assoc-ref inputs "bash") + "/bin/sh")))))))) (native-inputs `(("camlp4" ,camlp4-4.02) ("time" ,time) -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:50 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:50 +0000 Received: from localhost ([127.0.0.1]:33174 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2E-0008J0-0u for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:50 -0500 Received: from lepiller.eu ([89.234.186.109]:44102) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs28-0008Ht-Ea for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:44 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id f2ce1c07 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:25 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 05/10] gnu: ocaml-lwt: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:16 +0100 Message-Id: <20181119222821.16789-5-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-lwt): Use dune-build-system. --- gnu/packages/ocaml.scm | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index bf4fcc47f..c6ae4e78f 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -2133,26 +2133,18 @@ through Transport Layer Security (@dfn{TLS}) encrypted connections.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "0mhh019bjkg5xfvpy1pxs4xdxb759fyydmgb6l4j0qww1qgr8klp")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments `(#:tests? #f; require lwt_ppx + #:legacy? #t #:phases (modify-phases %standard-phases - (replace 'configure + (add-before 'build 'configure (lambda _ (invoke "ocaml" "src/util/configure.ml" "-use-libev" "true") - #t)) - (replace 'build - (lambda _ - (invoke "jbuilder" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "jbuilder" "install" "--prefix" (assoc-ref outputs "out")) #t))))) (native-inputs - `(("dune" ,dune) - ("ocaml-cppo" ,ocaml-cppo) + `(("ocaml-cppo" ,ocaml-cppo) ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree) ("pkg-config" ,pkg-config) ("ppx-tools-versioned" ,ocaml-ppx-tools-versioned))) -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:50 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:50 +0000 Received: from localhost ([127.0.0.1]:33176 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2E-0008J3-F2 for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:50 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs28-0008HY-Vc for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:45 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id 404100ff (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:26 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 06/10] gnu: ocaml-lwt-log: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:17 +0100 Message-Id: <20181119222821.16789-6-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-lwt-log): Use dune-build-system. --- gnu/packages/ocaml.scm | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index c6ae4e78f..5d322c273 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -2178,22 +2178,10 @@ locks or other synchronization primitives.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "1lr62j2266pbsi54xmzsfvl2z7fi7smhak7fp1ybl8hssxwi6in2")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments `(#:tests? #f; require lwt_ppx - #:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "jbuilder" "build" "@install") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "jbuilder" "install" "--prefix" (assoc-ref outputs "out")) - #t))))) - (native-inputs - `(("dune" ,dune))) + #:legacy? #t)) (propagated-inputs `(("lwt" ,ocaml-lwt))) (home-page "https://github.com/aantron/lwt_log") -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:51 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:51 +0000 Received: from localhost ([127.0.0.1]:33178 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2E-0008JA-OU for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:50 -0500 Received: from lepiller.eu ([89.234.186.109]:44102) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs29-0008Ht-71 for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:45 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id f8f835e0 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:26 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 07/10] gnu: ocaml-cppo: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:18 +0100 Message-Id: <20181119222821.16789-7-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-cppo): Use dune-build-system. --- gnu/packages/ocaml.scm | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 5d322c273..fe844b82d 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -2995,24 +2995,12 @@ provide a tool that can be used to: (sha256 (base32 "1dkm3d5h6h56y937gcdk2wixlpzl59vv5pmiafglr89p20kf7gqf")) (file-name (string-append name "-" version ".tar.gz")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install" "--profile" "release") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))) - #:tests? #f)) + `(#:tests? #f + #:build-flags (list "--profile" "release"))) (native-inputs - `(("dune" ,dune) - ("ocamlbuild" ,ocamlbuild))) + `(("ocamlbuild" ,ocamlbuild))) (home-page "https://github.com/mjambon/cppo") (synopsis "Equivalent of the C preprocessor for OCaml programs") (description "Cppo is an equivalent of the C preprocessor for OCaml -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:51 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:51 +0000 Received: from localhost ([127.0.0.1]:33180 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2F-0008JH-1h for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:51 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs29-0008HY-J7 for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:45 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id 582d8094 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:26 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 08/10] gnu: ocaml-re: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:19 +0100 Message-Id: <20181119222821.16789-8-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-re): Use dune-build-system. --- gnu/packages/ocaml.scm | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index fe844b82d..5ba9a9ad6 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -3635,26 +3635,14 @@ standard iterator type starting from 4.07.") (sha256 (base32 "1pdb0mr6z5ax6szblr3f5lbdnqq9grm97cmsfjmdma60yrx2rqhd")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments `(#:tests? #f - #:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install" "--profile" "release") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))))) + #:build-flags (list "--profile" "release"))) (propagated-inputs `(("ocaml-seq" ,ocaml-seq))) (native-inputs - `(("dune" ,dune) - ("ounit" ,ocaml-ounit))) + `(("ounit" ,ocaml-ounit))) (home-page "https://github.com/ocaml/ocaml-re/") (synopsis "Regular expression library for OCaml") (description "Pure OCaml regular expressions with: -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:51 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:51 +0000 Received: from localhost ([127.0.0.1]:33182 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2F-0008JP-BS for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:51 -0500 Received: from lepiller.eu ([89.234.186.109]:44102) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs29-0008Ht-RP for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:46 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id 298fa8d5 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:26 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 09/10] gnu: ocaml-camomile: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:20 +0100 Message-Id: <20181119222821.16789-9-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-camomile): Use dune-build-system. --- gnu/packages/ocaml.scm | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 5ba9a9ad6..896f3840a 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -4376,23 +4376,11 @@ the plugins facilitate extensibility, and the frontends serve as entry points.") (sha256 (base32 "01ssjrqz41jvrqh27jxnh9cx7ywi9b5sgsykd00i7z9nrcwhlfy2")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (native-inputs - `(("camlp4" ,camlp4) - ("dune" ,dune))) + `(("camlp4" ,camlp4))) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install" "--profile" "release") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))) + `(#:build-flags (list "--profile" "realease") #:tests? #f)) (synopsis "Comprehensive Unicode library") (description "Camomile is a Unicode library for OCaml. Camomile provides -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 19 17:28:51 2018 Received: (at 33437) by debbugs.gnu.org; 19 Nov 2018 22:28:51 +0000 Received: from localhost ([127.0.0.1]:33184 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2F-0008JX-KE for submit@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:51 -0500 Received: from lepiller.eu ([89.234.186.109]:44100) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gOs2A-0008HY-6C for 33437@debbugs.gnu.org; Mon, 19 Nov 2018 17:28:46 -0500 Received: from localhost.localdomain (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id ada2c578 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437@debbugs.gnu.org>; Mon, 19 Nov 2018 22:26:26 +0000 (UTC) From: Julien Lepiller To: 33437@debbugs.gnu.org Subject: [PATCH 10/10] gnu: ocaml-lambda-term: Use dune-build-system. Date: Mon, 19 Nov 2018 23:28:21 +0100 Message-Id: <20181119222821.16789-10-julien@lepiller.eu> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) * gnu/packages/ocaml.scm (ocaml-lambda-term): Use dune-build-system. --- gnu/packages/ocaml.scm | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 896f3840a..7ed5c1951 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -4481,23 +4481,10 @@ connect an engine to your inputs and rendering functions to get an editor.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "1hy5ryagqclgdm9lzh1qil5mrynlypv7mn6qm858hdcnmz9zzn0l")))) - (build-system ocaml-build-system) + (build-system dune-build-system) (arguments - `(#:phases - (modify-phases %standard-phases - (delete 'configure) - (replace 'build - (lambda _ - (invoke "dune" "build" "@install" "--profile" "release") - #t)) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (invoke "dune" "install" - "--prefix" (assoc-ref outputs "out")) - #t))) + `(#:build-flags (list "--profile" "release") #:tests? #f)) - (native-inputs - `(("dune" ,dune))) (propagated-inputs `(("lwt" ,ocaml-lwt) ("lwt-log" ,ocaml-lwt-log) -- 2.19.1 From debbugs-submit-bounces@debbugs.gnu.org Sat Nov 24 16:17:24 2018 Received: (at 33437) by debbugs.gnu.org; 24 Nov 2018 21:17:24 +0000 Received: from localhost ([127.0.0.1]:45841 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gQfIq-0003ed-1G for submit@debbugs.gnu.org; Sat, 24 Nov 2018 16:17:24 -0500 Received: from eggs.gnu.org ([208.118.235.92]:58936) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gQfIo-0003eP-7Y for 33437@debbugs.gnu.org; Sat, 24 Nov 2018 16:17:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gQfIh-0000YU-D6 for 33437@debbugs.gnu.org; Sat, 24 Nov 2018 16:17:16 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39250) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gQfIh-0000YE-7L; Sat, 24 Nov 2018 16:17:15 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=43872 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gQfIg-000684-Sy; Sat, 24 Nov 2018 16:17:15 -0500 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) To: Julien Lepiller Subject: Re: [bug#33437] [PATCH 01/10] build: Add dune-build-system. References: <20181119232537.66d2a822@lepiller.eu> <20181119222821.16789-1-julien@lepiller.eu> Date: Sat, 24 Nov 2018 22:17:13 +0100 In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> (Julien Lepiller's message of "Mon, 19 Nov 2018 23:28:12 +0100") Message-ID: <87k1l2yy3q.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 33437 Cc: 33437@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) Hello Julien! Julien Lepiller skribis: > * guix/build/dune-build-system.scm, > guix/build-system/dune.scm: New files. > * Makefile.am (MODULES): Add them. > * doc/guix.texi (Build Systems): Document dune-build-system. > * guix/build-system/ocaml.scm (lower, default-findlib, default-ocaml): Ex= port > them. > (package-with-explicit-ocaml): Also transform packages built with > dune-build-system. Nice! > +@defvr {Scheme Variable} dune-build-system > +This variable is exported by @code{(guix build-system dune)}. It > +supports builds of packaes using Dune, a build tool for the ^ Typo. > +@uref{https://ocaml.org, OCaml programming language}. It is implemented Maybe add a link for Dune rather than for OCaml? > +as an extension of the @code{ocaml-build-system} which is describe below. ^ Typo. > +It automically adds the @code{dune} package to the set of inputs. ^^ =E2=80=9Cautomatically=E2=80=9D > +The @code{'configure} phase is removed as dune packages typically Maybe: =E2=80=9CThere is no @code{configure} phase because Dune packages=E2= =80=A6=E2=80=9D? > +The @code{#:legacy?} parameter can be passed to use the @code{jbuild} > +command instead of the more recent @code{dune} command while building > +a package. Its default value is @code{#f}. Should it be called #:jbuild? instead? Because eventually everything becomes =E2=80=9Clegacy=E2=80=9D. :-) > +;;; along with GNU Guix. If not, see . > +(define-module (guix build-system dune) Nitpick: please insert a newline before =E2=80=98define-module=E2=80=99. = :-) > +(define* (dune-build store name inputs > + #:key (guile #f) > + (outputs '("out")) > + (search-paths '()) > + (build-flags ''()) > + (out-of-source? #t) > + (legacy? #f) > + (tests? #t) > + (test-flags ''()) > + (test-target "test") > + (install-target "install") > + (validate-runpath? #t) > + (patch-shebangs? #t) > + (strip-binaries? #t) > + (strip-flags ''("--strip-debug")) > + (strip-directories ''("lib" "lib64" "libexec" > + "bin" "sbin")) > + (phases '(@ (guix build dune-build-system) > + %standard-phases)) > + (system (%current-system)) > + (imported-modules %dune-build-system-modules) > + (modules '((guix build dune-build-system) > + (guix build utils)))) Would it make sense to add (guix build ocaml-build-system) as well to the default #:modules? > +++ b/guix/build-system/ocaml.scm > @@ -31,6 +31,9 @@ > package-with-ocaml4.02 > strip-ocaml4.01-variant > strip-ocaml4.02-variant > + default-findlib > + default-ocaml > + lower > ocaml-build > ocaml-build-system)) >=20=20 > @@ -76,6 +79,13 @@ > (let ((module (resolve-interface '(gnu packages ocaml)))) > (module-ref module 'ocaml-findlib))) >=20=20 > +(define (default-dune-build-system) > + "Return the dune-build-system." > + > + ;; Do not use `@' to avoid introducing circular dependencies. > + (let ((module (resolve-interface '(guix build-system dune)))) > + (module-ref module 'dune-build-system))) > + > (define (default-ocaml4.01) > (let ((ocaml (resolve-interface '(gnu packages ocaml)))) > (module-ref ocaml 'ocaml-4.01))) > @@ -119,7 +129,8 @@ pre-defined variants." > =3D> force) >=20=20 > ;; Otherwise build the new package object graph. > - ((eq? (package-build-system p) ocaml-build-system) > + ((or (eq? (package-build-system p) ocaml-build-system) > + (eq? (package-build-system p) (default-dune-build-system))) I don=E2=80=99t have a better solution to offer here, but this whole =E2=80=98package-with-explicit-XYZ=E2=80=99 is clearly showing its limits h= ere. :-/ Otherwise LGTM, thank you! Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Sat Nov 24 16:18:36 2018 Received: (at 33437) by debbugs.gnu.org; 24 Nov 2018 21:18:36 +0000 Received: from localhost ([127.0.0.1]:45845 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gQfK0-0003gX-F7 for submit@debbugs.gnu.org; Sat, 24 Nov 2018 16:18:36 -0500 Received: from eggs.gnu.org ([208.118.235.92]:59205) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gQfJy-0003gG-W4 for 33437@debbugs.gnu.org; Sat, 24 Nov 2018 16:18:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gQfJt-0001iv-01 for 33437@debbugs.gnu.org; Sat, 24 Nov 2018 16:18:29 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39259) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gQfJs-0001io-Sl; Sat, 24 Nov 2018 16:18:28 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=43874 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gQfJs-0006Cg-LD; Sat, 24 Nov 2018 16:18:28 -0500 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) To: Julien Lepiller Subject: Re: [bug#33437] [PATCH 10/10] gnu: ocaml-lambda-term: Use dune-build-system. References: <20181119222821.16789-1-julien@lepiller.eu> <20181119222821.16789-10-julien@lepiller.eu> Date: Sat, 24 Nov 2018 22:18:27 +0100 In-Reply-To: <20181119222821.16789-10-julien@lepiller.eu> (Julien Lepiller's message of "Mon, 19 Nov 2018 23:28:21 +0100") Message-ID: <87ftvqyy1o.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 33437 Cc: 33437@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) The remaining patches LGTM. Perhaps it would be best to commit all this to =E2=80=98core-updates=E2=80=99, to avoid gratuitous rebuilds of all the = OCaml packages now that we=E2=80=99re close to merging =E2=80=98core-updates=E2= =80=99. Thank you! Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Tue Dec 18 16:41:58 2018 Received: (at 33437-done) by debbugs.gnu.org; 18 Dec 2018 21:41:58 +0000 Received: from localhost ([127.0.0.1]:53793 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gZN7l-0004GO-Um for submit@debbugs.gnu.org; Tue, 18 Dec 2018 16:41:58 -0500 Received: from lepiller.eu ([89.234.186.109]:45646) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gZN7j-0004GC-Oe for 33437-done@debbugs.gnu.org; Tue, 18 Dec 2018 16:41:56 -0500 Received: from localhost (static-176-182-42-79.ncc.abo.bbox.fr [176.182.42.79]) by lepiller.eu (OpenSMTPD) with ESMTPSA id 23969d53 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO) for <33437-done@debbugs.gnu.org>; Tue, 18 Dec 2018 21:38:50 +0000 (UTC) Date: Tue, 18 Dec 2018 22:41:47 +0100 From: Julien Lepiller To: 33437-done@debbugs.gnu.org Subject: Re: [bug#33437] [PATCH] Add dune-build-system Message-ID: <20181218224147.0e3aa1ef@lepiller.eu> In-Reply-To: <20181119232537.66d2a822@lepiller.eu> References: <20181119232537.66d2a822@lepiller.eu> X-Mailer: Claws Mail 3.17.1 (GTK+ 2.24.32; x86_64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 33437-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Le Mon, 19 Nov 2018 23:25:37 +0100, Julien Lepiller a =C3=A9crit : > Hi, here is a small patch series to add dune-build-system and convert > a few packages to it. pushed as 6e8986c8388e889eb74509999aea826fd440dcc4 - 34d5314e9c826b1f602f9aaa8d707ca594736aaf From unknown Sun Jun 22 11:29:40 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 16 Jan 2019 12:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator