summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2016-05-03 19:09:10 +0200
committerAlexis Ballier <aballier@gentoo.org>2016-05-03 19:44:22 +0200
commit0c08a0f853e9fc3bcc089ca5ebf6e059a62272b4 (patch)
tree3424095cdade497ba2b3353915721d621bcbac1d /dev-ml/ppx_fail
parentdev-ml/ppx_fields_conv: fix build with ocaml 4.03 (diff)
downloadgentoo-0c08a0f853e9fc3bcc089ca5ebf6e059a62272b4.tar.gz
gentoo-0c08a0f853e9fc3bcc089ca5ebf6e059a62272b4.tar.bz2
gentoo-0c08a0f853e9fc3bcc089ca5ebf6e059a62272b4.zip
dev-ml/ppx_fail: fix build with ocaml 4.03
Package-Manager: portage-2.2.28 Signed-off-by: Alexis Ballier <aballier@gentoo.org>
Diffstat (limited to 'dev-ml/ppx_fail')
-rw-r--r--dev-ml/ppx_fail/files/oc43.patch35
-rw-r--r--dev-ml/ppx_fail/ppx_fail-113.33.00.ebuild4
2 files changed, 39 insertions, 0 deletions
diff --git a/dev-ml/ppx_fail/files/oc43.patch b/dev-ml/ppx_fail/files/oc43.patch
new file mode 100644
index 000000000000..c5dd6b23eb86
--- /dev/null
+++ b/dev-ml/ppx_fail/files/oc43.patch
@@ -0,0 +1,35 @@
+diff -uNr ppx_fail-113.33.00/_oasis ppx_fail-113.33.00+4.03/_oasis
+--- ppx_fail-113.33.00/_oasis 2016-03-09 16:44:54.000000000 +0100
++++ ppx_fail-113.33.00+4.03/_oasis 2016-03-22 15:13:50.000000000 +0100
+@@ -1,8 +1,8 @@
+ OASISFormat: 0.4
+-OCamlVersion: >= 4.02.3
++OCamlVersion: >= 4.03.0
+ FindlibVersion: >= 1.3.2
+ Name: ppx_fail
+-Version: 113.33.00
++Version: 113.33.00+4.03
+ Synopsis: Add location to calls to failwiths
+ Authors: Jane Street Group, LLC <opensource@janestreet.com>
+ Copyrights: (C) 2015-2016 Jane Street Group LLC <opensource@janestreet.com>
+diff -uNr ppx_fail-113.33.00/opam ppx_fail-113.33.00+4.03/opam
+--- ppx_fail-113.33.00/opam 2016-03-18 12:08:01.000000000 +0100
++++ ppx_fail-113.33.00+4.03/opam 2016-03-22 17:51:36.000000000 +0100
+@@ -17,4 +17,4 @@
+ "ppx_here"
+ "ppx_tools" {>= "0.99.3"}
+ ]
+-available: [ ocaml-version >= "4.02.3" ]
++available: [ ocaml-version >= "4.03.0" ]
+diff -uNr ppx_fail-113.33.00/src/ppx_fail.ml ppx_fail-113.33.00+4.03/src/ppx_fail.ml
+--- ppx_fail-113.33.00/src/ppx_fail.ml 2016-03-09 16:44:54.000000000 +0100
++++ ppx_fail-113.33.00+4.03/src/ppx_fail.ml 2016-03-22 15:13:50.000000000 +0100
+@@ -12,7 +12,7 @@
+ match e.pexp_desc with
+ | Pexp_ident { txt = Lident "failwiths"; _ } ->
+ let loc = e.pexp_loc in
+- pexp_apply e ~loc [("here", Ppx_here_expander.lift_position ~loc)]
++ pexp_apply e ~loc [(Labelled "here", Ppx_here_expander.lift_position ~loc)]
+ | _ -> super#expression e
+ end
+
diff --git a/dev-ml/ppx_fail/ppx_fail-113.33.00.ebuild b/dev-ml/ppx_fail/ppx_fail-113.33.00.ebuild
index e835771ca617..800d18243f5a 100644
--- a/dev-ml/ppx_fail/ppx_fail-113.33.00.ebuild
+++ b/dev-ml/ppx_fail/ppx_fail-113.33.00.ebuild
@@ -23,6 +23,10 @@ DEPEND="dev-ml/ppx_tools:=
RDEPEND="${DEPEND}"
DEPEND="${DEPEND} dev-ml/opam"
+src_prepare() {
+ has_version '>=dev-lang/ocaml-4.03' && epatch "${FILESDIR}/oc43.patch"
+}
+
src_configure() {
emake setup.exe
OASIS_SETUP_COMMAND="./setup.exe" oasis_src_configure