pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel/ocaml-ppx_optcomp Added two uncommitted patches ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b1bb1c9b346a
branches:  trunk
changeset: 356712:b1bb1c9b346a
user:      jaapb <jaapb%pkgsrc.org@localhost>
date:      Wed Jan 04 00:10:43 2017 +0000

description:
Added two uncommitted patches & increased revision.

diffstat:

 devel/ocaml-ppx_optcomp/Makefile                         |   3 +-
 devel/ocaml-ppx_optcomp/patches/patch-src_META.ab        |  17 ++++++
 devel/ocaml-ppx_optcomp/patches/patch-src_ppx_optcomp.ml |  41 ++++++++++++++++
 3 files changed, 60 insertions(+), 1 deletions(-)

diffs (78 lines):

diff -r 59895cc76aeb -r b1bb1c9b346a devel/ocaml-ppx_optcomp/Makefile
--- a/devel/ocaml-ppx_optcomp/Makefile  Tue Jan 03 21:50:53 2017 +0000
+++ b/devel/ocaml-ppx_optcomp/Makefile  Wed Jan 04 00:10:43 2017 +0000
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.5 2016/12/30 11:25:33 jaapb Exp $
+# $NetBSD: Makefile,v 1.6 2017/01/04 00:10:43 jaapb Exp $
 
 VERSION=       114.08+89
+PKGREVISION=   1
 GITHUB_PROJECT=        ppx_optcomp
 GITHUB_TAG=    6f1ce80
 DISTNAME=      ${GITHUB_PROJECT}-${VERSION}
diff -r 59895cc76aeb -r b1bb1c9b346a devel/ocaml-ppx_optcomp/patches/patch-src_META.ab
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/ocaml-ppx_optcomp/patches/patch-src_META.ab Wed Jan 04 00:10:43 2017 +0000
@@ -0,0 +1,17 @@
+$NetBSD: patch-src_META.ab,v 1.1 2017/01/04 00:10:43 jaapb Exp $
+
+Add deriving bit - patch from 4.04 branch
+--- src/META.ab.orig   2016-09-02 10:02:01.000000000 +0000
++++ src/META.ab
+@@ -6,3 +6,11 @@ archive(native) = "ppx_optcomp.cmxa"
+ plugin(byte  ) = "ppx_optcomp.cma"
+ plugin(native) = "ppx_optcomp.cmxs"
+ exists_if = "ppx_optcomp.cma"
++
++package "for_ppx_deriving" (
++  description = "Don't use this directly"
++  error(ppx_driver) = "Cannot use ppx_optcomp.for_ppx_deriving when ppx_driver is set"
++  requires = "ppx_core.for_ppx_deriving ppx_deriving"
++  exists_if = "ppx_optcomp.cma"
++  ppxopt = "ppx_deriving,./ppx_optcomp.cma"
++)
diff -r 59895cc76aeb -r b1bb1c9b346a devel/ocaml-ppx_optcomp/patches/patch-src_ppx_optcomp.ml
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/ocaml-ppx_optcomp/patches/patch-src_ppx_optcomp.ml  Wed Jan 04 00:10:43 2017 +0000
@@ -0,0 +1,41 @@
+$NetBSD: patch-src_ppx_optcomp.ml,v 1.1 2017/01/04 00:10:43 jaapb Exp $
+
+Changes to do with OCaml 4.04 (from 4.04 branch)
+--- src/ppx_optcomp.ml.orig    2016-09-02 10:02:01.000000000 +0000
++++ src/ppx_optcomp.ml
+@@ -617,7 +617,7 @@ end = struct
+ 
+   let rec next_directive (lexer : lexer) lexbuf =
+     match lexer lexbuf with
+-    | SHARP -> parse_directive lexer lexbuf
++    | HASH -> parse_directive lexer lexbuf
+     | EOL -> next_directive lexer lexbuf
+     | EOF -> endif_missing lexbuf
+     | _ -> skip_line lexer lexbuf; next_directive lexer lexbuf
+@@ -712,7 +712,7 @@ end = struct
+   (* Return the next token from a stream, interpreting directives. *)
+   let rec lexer_internal (lexer : lexer) lexbuf : Parser.token =
+     match lexer lexbuf with
+-    | SHARP when at_bol lexbuf ->
++    | HASH when at_bol lexbuf ->
+       interpret_directive lexer lexbuf (parse_directive lexer lexbuf);
+       lexer_internal lexer lexbuf
+     | EOF -> Stack.check_eof lexbuf; EOF
+@@ -740,7 +740,7 @@ end = struct
+         (* Special case for ifndef + define. If we fallback to [interpret_if], it will
+            raise, because the variable is not defined. *)
+         match lexer lexbuf with
+-        | SHARP when at_bol lexbuf -> begin
++        | HASH when at_bol lexbuf -> begin
+             match (parse_directive lexer lexbuf).txt with
+             | Define (var', expr) when var'.txt = var.txt ->
+               Stack.enqueue dir;
+@@ -847,7 +847,7 @@ end = struct
+     Location.init lexbuf fn;
+     let rec loop pos acc =
+       match Lexer.token lexbuf with
+-      | SHARP when at_bol lexbuf ->
++      | HASH when at_bol lexbuf ->
+         let acc = (pos, Lexing.lexeme_start lexbuf) :: acc in
+         interpret_directive Lexer.token lexbuf (parse_directive Lexer.token lexbuf);
+         loop (Lexing.lexeme_end lexbuf) acc



Home | Main Index | Thread Index | Old Index