From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50837) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gOs2T-0005gn-MW for guix-patches@gnu.org; Mon, 19 Nov 2018 17:29:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gOs2R-0006A3-ON for guix-patches@gnu.org; Mon, 19 Nov 2018 17:29:05 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:57162) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gOs2R-00069z-L5 for guix-patches@gnu.org; Mon, 19 Nov 2018 17:29:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gOs2R-0008KM-H6 for guix-patches@gnu.org; Mon, 19 Nov 2018 17:29:03 -0500 Subject: [bug#33437] [PATCH 04/10] gnu: ocaml-bitstring: Use dune-build-system. Resent-Message-ID: From: Julien Lepiller Date: Mon, 19 Nov 2018 23:28:15 +0100 Message-Id: <20181119222821.16789-4-julien@lepiller.eu> In-Reply-To: <20181119222821.16789-1-julien@lepiller.eu> References: <20181119222821.16789-1-julien@lepiller.eu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 33437@debbugs.gnu.org * 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