aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--converters/Makefile1
-rw-r--r--converters/ocaml-jsonm/Makefile35
-rw-r--r--converters/ocaml-jsonm/distinfo2
-rw-r--r--converters/ocaml-jsonm/pkg-descr8
4 files changed, 46 insertions, 0 deletions
diff --git a/converters/Makefile b/converters/Makefile
index d2bce1fa61bc..5a619bc37537 100644
--- a/converters/Makefile
+++ b/converters/Makefile
@@ -50,6 +50,7 @@
SUBDIR += mpack
SUBDIR += nomyso
SUBDIR += o3read
+ SUBDIR += ocaml-jsonm
SUBDIR += osm2mp
SUBDIR += osm2pgsql
SUBDIR += p5-Boulder
diff --git a/converters/ocaml-jsonm/Makefile b/converters/ocaml-jsonm/Makefile
new file mode 100644
index 000000000000..a2e85a0fb5fd
--- /dev/null
+++ b/converters/ocaml-jsonm/Makefile
@@ -0,0 +1,35 @@
+# Created by: Veniamin Gvozdikov <vg@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= jsonm
+PORTVERSION= 0.9.1
+CATEGORIES= converters
+MASTER_SITES= http://erratique.ch/software/jsonm/releases/
+PKGNAMEPREFIX= ocaml-
+
+MAINTAINER= vg@FreeBSD.org
+COMMENT= Non-blocking streaming JSON codec for OCaml
+
+LICENSE= BSD3CLAUSE
+
+BUILD_DEPENDS= ${SA_DIR}/uutf/uutf.a:${PORTSDIR}/devel/ocaml-uutf
+RUN_DEPENDS= ${SA_DIR}/uutf/uutf.a:${PORTSDIR}/devel/ocaml-uutf
+
+USES= tar:tbz
+USE_OCAML= yes
+SA_DIR= ${LOCALBASE}/${OCAML_SITELIBDIR}
+
+USE_OCAML_FINDLIB= yes
+USE_OCAMLFIND_PLIST= yes
+USE_OCAML_LDCONFIG= yes
+
+do-build:
+ cd ${WRKSRC} && ocamlbuild src/jsonm.cmxs src/jsonm.cma src/jsonm.a
+
+do-install:
+ ${MKDIR} ${STAGEDIR}${OCAMLFIND_DESTDIR}/jsonm
+ cd ${WRKSRC} && ocamlfind install -destdir ${STAGEDIR}${PREFIX}/lib/ocaml/site-lib jsonm src/META _build/src/jsonm.a _build/src/jsonm.cma _build/src/jsonm.cmi _build/src/jsonm.cmx _build/src/jsonm.cmxa _build/src/jsonm.cmxs _build/src/jsonm.mli
+ ${INSTALL_LIB} ${WRKSRC}/_build/src/jsonm.cmxs \
+ ${STAGEDIR}${OCAMLFIND_DESTDIR}/jsonm
+
+.include <bsd.port.mk>
diff --git a/converters/ocaml-jsonm/distinfo b/converters/ocaml-jsonm/distinfo
new file mode 100644
index 000000000000..e76db4733fc3
--- /dev/null
+++ b/converters/ocaml-jsonm/distinfo
@@ -0,0 +1,2 @@
+SHA256 (jsonm-0.9.1.tbz) = 3fd4dca045d82332da847e65e981d8b504883571d299a3f7e71447d46bc65f73
+SIZE (jsonm-0.9.1.tbz) = 64843
diff --git a/converters/ocaml-jsonm/pkg-descr b/converters/ocaml-jsonm/pkg-descr
new file mode 100644
index 000000000000..17f9e1f0de69
--- /dev/null
+++ b/converters/ocaml-jsonm/pkg-descr
@@ -0,0 +1,8 @@
+Jsonm is an OCaml non-blocking streaming codec to decode and encode the
+JSON data format. It can process JSON text without blocking on IO and
+without a complete in-memory representation of the data.
+
+The uncut codec also processes whitespace and (non-standard) JSON with
+JavaScript comments.
+
+WWW: http://erratique.ch/software/jsonm