devel/ocaml-lwt: Unbreak after Ocaml 4.01 with fix from pkgsrc

The maintainer already fixed this port for Ocaml 4.01 on pkgsrc where
he also maintains it.  Bring the patches over to restore the build.
This commit is contained in:
John Marino 2014-05-07 17:52:29 +00:00
parent 0092448c5e
commit e866ea4c99
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=353185
3 changed files with 31 additions and 1 deletions

View file

@ -3,7 +3,7 @@
PORTNAME= lwt
PORTVERSION= 2.4.3
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= devel
MASTER_SITES= http://ocsigen.org/download/
PKGNAMEPREFIX= ocaml-

View file

@ -0,0 +1,15 @@
$NetBSD: patch-src_unix_lwt_unix.ml,v 1.1 2013/11/01 10:50:03 jaapb Exp $
Patch (from upstream git) to compile with ocaml 4.01
--- src/unix/lwt_unix.ml.orig 2012-12-27 12:29:57.000000000 +0000
+++ src/unix/lwt_unix.ml
@@ -596,6 +596,9 @@ type open_flag =
#if ocaml_version >= (3, 13)
| O_SHARE_DELETE
#endif
+#if ocaml_version >= (4, 01)
+ | O_CLOEXEC
+#endif
#if windows

View file

@ -0,0 +1,15 @@
$NetBSD: patch-src_unix_lwt_unix.mli,v 1.1 2013/11/01 10:50:03 jaapb Exp $
Patch (from upstream git) to compile with ocaml 4.01
--- src/unix/lwt_unix.mli.orig 2012-12-27 12:29:57.000000000 +0000
+++ src/unix/lwt_unix.mli
@@ -315,6 +315,9 @@ type open_flag =
#if ocaml_version >= (3, 13)
| O_SHARE_DELETE
#endif
+#if ocaml_version >= (4, 01)
+ | O_CLOEXEC
+#endif
val openfile : string -> open_flag list -> file_perm -> file_descr Lwt.t
(** Wrapper for [Unix.openfile]. *)