diff options
author | 2021-10-06 01:50:12 +0100 | |
---|---|---|
committer | 2021-10-06 02:00:57 +0100 | |
commit | e957c5cbaf3463ad30b10fc0934ef6cf3ee7ffc3 (patch) | |
tree | 4730c1532abf33e3d37dbb3cef581e7c5104cf54 /dev-ml/ppx_variants_conv | |
parent | dev-ml/base_quickcheck: add 0.14.1 (diff) | |
download | gentoo-e957c5cbaf3463ad30b10fc0934ef6cf3ee7ffc3.tar.gz gentoo-e957c5cbaf3463ad30b10fc0934ef6cf3ee7ffc3.tar.bz2 gentoo-e957c5cbaf3463ad30b10fc0934ef6cf3ee7ffc3.zip |
dev-ml/ppx_variants_conv: fix compatibility with ppxlib-0.23
Closes: https://bugs.gentoo.org/816099
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-ml/ppx_variants_conv')
-rw-r--r-- | dev-ml/ppx_variants_conv/files/ppx_variants_conv-0.14.1-ppxlib-0.23-compatibility.patch | 31 | ||||
-rw-r--r-- | dev-ml/ppx_variants_conv/ppx_variants_conv-0.14.1-r1.ebuild | 29 |
2 files changed, 60 insertions, 0 deletions
diff --git a/dev-ml/ppx_variants_conv/files/ppx_variants_conv-0.14.1-ppxlib-0.23-compatibility.patch b/dev-ml/ppx_variants_conv/files/ppx_variants_conv-0.14.1-ppxlib-0.23-compatibility.patch new file mode 100644 index 000000000000..d8df60aeec71 --- /dev/null +++ b/dev-ml/ppx_variants_conv/files/ppx_variants_conv-0.14.1-ppxlib-0.23-compatibility.patch @@ -0,0 +1,31 @@ +From 6103f6fc56f978c847ba7c1f2d9f38ee93a5e337 Mon Sep 17 00:00:00 2001 +From: Sonja Heinze <sonjaleaheinze@gmail.com> +Date: Tue, 9 Mar 2021 12:57:47 +0100 +Subject: [PATCH] Adapt to Ppxlib's API change + +Ppxlib is removing Lexer.keyword_table from the API in exchange for +the more lightweight Keyword.is_keyword. + +Signed-off-by: Sonja Heinze <sonjaleaheinze@gmail.com> +--- a/ppx_variants_conv.opam ++++ b/ppx_variants_conv.opam +@@ -15,7 +15,7 @@ depends: [ + "base" {>= "v0.14" & < "v0.15"} + "variantslib" {>= "v0.14" & < "v0.15"} + "dune" {>= "2.0.0"} +- "ppxlib" {>= "0.14.0"} ++ "ppxlib" {>= "0.23.0"} + ] + synopsis: "Generation of accessor and iteration functions for ocaml variant types" + description: " +--- a/src/ppx_variants_conv.ml ++++ b/src/ppx_variants_conv.ml +@@ -66,7 +66,7 @@ end + + let variant_name_to_string v = + let s = String.lowercase v in +- if Caml.Hashtbl.mem Lexer.keyword_table s ++ if Keyword.is_keyword s + then s ^ "_" + else s + diff --git a/dev-ml/ppx_variants_conv/ppx_variants_conv-0.14.1-r1.ebuild b/dev-ml/ppx_variants_conv/ppx_variants_conv-0.14.1-r1.ebuild new file mode 100644 index 000000000000..8915cf1f56d1 --- /dev/null +++ b/dev-ml/ppx_variants_conv/ppx_variants_conv-0.14.1-r1.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit dune + +DESCRIPTION="Generation of accessor and iteration functions for ocaml variant types" +HOMEPAGE="https://github.com/janestreet/ppx_variants_conv" +SRC_URI="https://github.com/janestreet/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86" +IUSE="+ocamlopt" + +DEPEND=" + >=dev-ml/base-0.14.0:= + >=dev-ml/variantslib-0.14.0:= + >=dev-ml/ppxlib-0.23.0:= + >=dev-ml/ocaml-compiler-libs-0.11.0:= + >=dev-ml/ocaml-migrate-parsetree-2.0.0:= + dev-ml/cinaps:= +" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}"/${PN}-0.14.1-ppxlib-0.23-compatibility.patch +) |