summaryrefslogtreecommitdiff
blob: 8460f51ef8ba13724760bdfda690b24cf3c794bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=6

inherit findlib

DESCRIPTION="JavaScript parser written in OCaml"
HOMEPAGE="https://github.com/facebook/flow/tree/master/src/parser"
SRC_URI="https://github.com/facebook/flow/archive/v${PV}.tar.gz -> flow-${PV}.tar.gz"

LICENSE="BSD"
SLOT="0/${PV}"
KEYWORDS="~amd64"
IUSE=""

DEPEND="dev-lang/ocaml:="
RDEPEND="${DEPEND}"
DEPEND="${DEPEND}
	dev-ml/ocamlbuild"

S="${WORKDIR}/flow-${PV}/src/parser"

src_compile() {
	ocamlbuild parser_flow.cma parser_flow.cmxa || die
}

src_test() {
	emake test-ocaml
}

src_install() {
	findlib_src_preinst
	emake ocamlfind-install
	dodoc README.md
}