commit: 6e8cb67ebdafac9c72eee9983cbd4a88b2cbf266
Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 1 19:55:07 2016 +0000
Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
CommitDate: Wed Mar 2 19:29:06 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6e8cb67e
dev-ml/camlzip: fix build with ocaml 4.03
Package-Manager: portage-2.2.27
Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org>
dev-ml/camlzip/camlzip-1.05.ebuild | 4 ++++
dev-ml/camlzip/files/ocaml-4.03.patch | 26 ++++++++++++++++++++++++++
2 files changed, 30 insertions(+)
diff --git a/dev-ml/camlzip/camlzip-1.05.ebuild
b/dev-ml/camlzip/camlzip-1.05.ebuild
index 73d097a..bbd81fc 100644
--- a/dev-ml/camlzip/camlzip-1.05.ebuild
+++ b/dev-ml/camlzip/camlzip-1.05.ebuild
@@ -20,6 +20,10 @@ RDEPEND=">=dev-lang/ocaml-3.10.2:=[ocamlopt?]
>=sys-libs/zlib-1.1.3"
DEPEND="${RDEPEND}"
+src_prepare() {
+ epatch "${FILESDIR}/ocaml-4.03.patch"
+}
+
src_compile() {
emake all
if use ocamlopt; then
diff --git a/dev-ml/camlzip/files/ocaml-4.03.patch
b/dev-ml/camlzip/files/ocaml-4.03.patch
new file mode 100644
index 0000000..4982242
--- /dev/null
+++ b/dev-ml/camlzip/files/ocaml-4.03.patch
@@ -0,0 +1,26 @@
+Index: camlzip-1.05/zip.ml
+===================================================================
+--- camlzip-1.05.orig/zip.ml
++++ camlzip-1.05/zip.ml
+@@ -73,8 +73,6 @@ type out_file =
+ mutable of_entries: entry list;
+ of_comment: string }
+
+-exception Error of string * string * string
+-
+ (* Return the position of the last occurrence of s1 in s2, or -1 if not
+ found. *)
+
+Index: camlzip-1.05/zlibstubs.c
+===================================================================
+--- camlzip-1.05.orig/zlibstubs.c
++++ camlzip-1.05/zlibstubs.c
+@@ -168,7 +168,7 @@ value camlzip_inflateEnd(value vzs)
+
+ value camlzip_update_crc32(value crc, value buf, value pos, value len)
+ {
+- return caml_copy_int32(crc32((uint32) Int32_val(crc),
++ return caml_copy_int32(crc32((uint32_t) Int32_val(crc),
+ &Byte_u(buf, Long_val(pos)),
+ Long_val(len)));
+ }