From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id B16BB1395E6 for ; Tue, 29 Nov 2016 15:05:56 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0F8FF21C038; Tue, 29 Nov 2016 15:05:55 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8EB3BE0941 for ; Tue, 29 Nov 2016 15:05:54 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 9DB87340F2F for ; Tue, 29 Nov 2016 15:05:53 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id ECAD749A for ; Tue, 29 Nov 2016 15:05:51 +0000 (UTC) From: "Alexis Ballier" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Alexis Ballier" Message-ID: <1480431922.b16ff5e76b8aa2daf85deddf3eba603c8e263a80.aballier@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ml/ppx_tools/, dev-ml/ppx_tools/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-ml/ppx_tools/files/ocaml404.patch dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild X-VCS-Directories: dev-ml/ppx_tools/files/ dev-ml/ppx_tools/ X-VCS-Committer: aballier X-VCS-Committer-Name: Alexis Ballier X-VCS-Revision: b16ff5e76b8aa2daf85deddf3eba603c8e263a80 X-VCS-Branch: master Date: Tue, 29 Nov 2016 15:05:51 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 07c7bf54-321c-41ab-b802-75cc48263c46 X-Archives-Hash: f5ed54975bbc4aad66d345e01e74571b commit: b16ff5e76b8aa2daf85deddf3eba603c8e263a80 Author: Alexis Ballier gentoo org> AuthorDate: Tue Nov 29 12:37:39 2016 +0000 Commit: Alexis Ballier gentoo org> CommitDate: Tue Nov 29 15:05:22 2016 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b16ff5e7 dev-ml/ppx_tools: backport upstream fixes for ocaml 4.04 Package-Manager: portage-2.3.2 dev-ml/ppx_tools/files/ocaml404.patch | 47 ++++++++++++++++++++++++++++ dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild | 6 +++- 2 files changed, 52 insertions(+), 1 deletion(-) diff --git a/dev-ml/ppx_tools/files/ocaml404.patch b/dev-ml/ppx_tools/files/ocaml404.patch new file mode 100644 index 00000000..8a2ccee --- /dev/null +++ b/dev-ml/ppx_tools/files/ocaml404.patch @@ -0,0 +1,47 @@ +Index: ppx_tools-5.0-4.03.0/ast_mapper_class.ml +=================================================================== +--- ppx_tools-5.0-4.03.0.orig/ast_mapper_class.ml ++++ ppx_tools-5.0-4.03.0/ast_mapper_class.ml +@@ -335,6 +335,7 @@ module P = struct + | Ppat_unpack s -> unpack ~loc ~attrs (map_loc sub s) + | Ppat_exception p -> exception_ ~loc ~attrs (sub # pat p) + | Ppat_extension x -> extension ~loc ~attrs (sub # extension x) ++ | Ppat_open (l, p) -> open_ ~loc ~attrs (map_loc sub l) (sub # pat p) + end + + module CE = struct +Index: ppx_tools-5.0-4.03.0/genlifter.ml +=================================================================== +--- ppx_tools-5.0-4.03.0.orig/genlifter.ml ++++ ppx_tools-5.0-4.03.0/genlifter.ml +@@ -49,8 +49,8 @@ module Main : sig end = struct + let rec gen ty = + if Hashtbl.mem printed ty then () + else let tylid = Longident.parse ty in +- let (_, td) = +- try Env.lookup_type tylid env ++ let td = ++ try Env.find_type (Env.lookup_type tylid env) env + with Not_found -> + Format.eprintf "** Cannot resolve type %s@." ty; + exit 2 +Index: ppx_tools-5.0-4.03.0/rewriter.ml +=================================================================== +--- ppx_tools-5.0-4.03.0.orig/rewriter.ml ++++ ppx_tools-5.0-4.03.0/rewriter.ml +@@ -92,13 +92,13 @@ let () = + | `Struct -> + let pstr = Parse.implementation lexer in + let pstr = Pparse.apply_rewriters (* ~restore:true *) ~tool_name:!tool_name +- Config.ast_impl_magic_number pstr in ++ Pparse.Structure pstr in + Pprintast.structure fmt pstr; + Format.pp_print_newline fmt () + | `Sig -> + let psig = Parse.interface lexer in + let psig = Pparse.apply_rewriters (* ~restore:true *) ~tool_name:!tool_name +- Config.ast_intf_magic_number psig in ++ Pparse.Signature psig in + Pprintast.signature fmt psig; + Format.pp_print_newline fmt ()) + with exn -> diff --git a/dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild b/dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild index 0caa4d7..1b7a860 100644 --- a/dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild +++ b/dev-ml/ppx_tools/ppx_tools-5.0.4.03.0.ebuild @@ -4,7 +4,7 @@ EAPI=5 -inherit findlib versionator +inherit findlib versionator eutils MY_PV=$(replace_version_separator 2 '+') DESCRIPTION="Tools for authors of ppx rewriters" @@ -20,6 +20,10 @@ DEPEND=">=dev-lang/ocaml-4.03.0:=" RDEPEND="${DEPEND}" S="${WORKDIR}/${PN}-$(replace_version_separator 2 '-')" +src_prepare() { + has_version '>=dev-lang/ocaml-4.04_beta' && epatch "${FILESDIR}/ocaml404.patch" +} + src_compile() { emake -j1 }