Gentoo Archives: gentoo-commits

From: Alexis Ballier <aballier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ml/js_of_ocaml/
Date: Thu, 22 Jun 2017 14:25:05
Message-Id: 1498141474.0dc5e83d174cd5271de5c6829ee987844a9eb886.aballier@gentoo
1 commit: 0dc5e83d174cd5271de5c6829ee987844a9eb886
2 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jun 22 12:46:29 2017 +0000
4 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
5 CommitDate: Thu Jun 22 14:24:34 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0dc5e83d
7
8 dev-ml/js_of_ocaml: bump to 3.0.0 and update live ebuild
9
10 Package-Manager: Portage-2.3.6, Repoman-2.3.2
11
12 dev-ml/js_of_ocaml/Manifest | 1 +
13 dev-ml/js_of_ocaml/js_of_ocaml-3.0.0.ebuild | 75 +++++++++++++++++++++++++++++
14 dev-ml/js_of_ocaml/js_of_ocaml-9999.ebuild | 72 +++++++++++++++------------
15 dev-ml/js_of_ocaml/metadata.xml | 2 +
16 4 files changed, 119 insertions(+), 31 deletions(-)
17
18 diff --git a/dev-ml/js_of_ocaml/Manifest b/dev-ml/js_of_ocaml/Manifest
19 index 6a21ead28e5..3790dbaf16c 100644
20 --- a/dev-ml/js_of_ocaml/Manifest
21 +++ b/dev-ml/js_of_ocaml/Manifest
22 @@ -1 +1,2 @@
23 DIST js_of_ocaml-2.8.4.tar.gz 1344082 SHA256 74edd38a964fcee930778a908c896b5c9795f64fc34a3c58361ccfa441811725 SHA512 8dc65bac7d60f2d3534e31e0fddb061f1b97bfd8146b1a34b4a1a516574c6a39f66d115646aa9767b7e24a51ec76949b05841088601f97d76972c8899a50c4fd WHIRLPOOL bc444184519ae90d308ae4675078e1d5fd461ea32f4dccf5e74bab25f0a0e8ba49d229f951205effd676b337656633fb7046cd908c2167799253dcee0a61f20f
24 +DIST js_of_ocaml-3.0.0.tar.gz 1433377 SHA256 eb49ca6d66ac51a41cf611f1a6a85269d310dbc1711ac4b819c9a04ee53b5a4e SHA512 dc4bbbfdacb43338aa7f97b7012b6de8a2eac5d7c5f535ceb9565c477c961a212ce5b2a75b1719fcd9f2d57938ee2162f6f04d3364397a469d7a13d1fe4e3908 WHIRLPOOL a43b35000af7714f571f0cf373b529883063194ff0a4b57a9bae9670b257ee38288a5b8f4caf19b9ee18fdceeea0a2f5fc0f45cd503ebfa1281b657115a54fc1
25
26 diff --git a/dev-ml/js_of_ocaml/js_of_ocaml-3.0.0.ebuild b/dev-ml/js_of_ocaml/js_of_ocaml-3.0.0.ebuild
27 new file mode 100644
28 index 00000000000..3a44770cfb6
29 --- /dev/null
30 +++ b/dev-ml/js_of_ocaml/js_of_ocaml-3.0.0.ebuild
31 @@ -0,0 +1,75 @@
32 +# Copyright 1999-2017 Gentoo Foundation
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=5
36 +
37 +inherit findlib eutils
38 +
39 +DESCRIPTION="A compiler from OCaml bytecode to javascript"
40 +HOMEPAGE="http://ocsigen.org/js_of_ocaml/"
41 +
42 +if [ "${PV#9999}" != "${PV}" ] ; then
43 + inherit git-r3
44 + SRC_URI=""
45 + EGIT_REPO_URI="https://github.com/ocsigen/js_of_ocaml"
46 + KEYWORDS=""
47 +else
48 + SRC_URI="https://github.com/ocsigen/js_of_ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz"
49 + KEYWORDS="~amd64"
50 +fi
51 +
52 +LICENSE="LGPL-2.1-with-linking-exception"
53 +SLOT="0/${PV}"
54 +IUSE="+ocamlopt camlp4 lwt doc +deriving +ppx +xml test"
55 +
56 +RDEPEND="
57 + >=dev-lang/ocaml-3.12:=[ocamlopt?]
58 +
59 + camlp4? ( dev-ml/camlp4:= )
60 +
61 + dev-ml/cmdliner:=
62 + dev-ml/cppo:=
63 +
64 + lwt? ( >=dev-ml/lwt-2.4.4:= )
65 +
66 + dev-ml/ocamlbuild:=
67 +
68 + dev-ml/ocaml-migrate-parsetree:=
69 + dev-ml/ppx_tools_versioned:=
70 + dev-ml/uchar:=
71 +
72 + ppx? ( dev-ml/ppx_tools:= dev-ml/ppx_deriving:= )
73 +
74 + xml? ( >=dev-ml/tyxml-4:= dev-ml/reactiveData:= )
75 +"
76 +DEPEND="${RDEPEND}
77 + dev-ml/jbuilder
78 + dev-ml/opam
79 + test? ( dev-util/patdiff )
80 +"
81 +REQUIRED_USE="xml? ( ppx )"
82 +
83 +src_compile() {
84 + emake
85 + use doc && emake doc
86 +}
87 +
88 +oinstall() {
89 + opam-installer -i \
90 + --prefix="${ED}/usr" \
91 + --libdir="${D}/$(ocamlc -where)" \
92 + --docdir="${ED}/usr/share/doc/${PF}" \
93 + --mandir="${ED}/usr/share/man" \
94 + ${1}.install || die
95 +}
96 +
97 +src_install() {
98 + use camlp4 && oinstall js_of_ocaml-camlp4
99 + oinstall js_of_ocaml-compiler
100 + use lwt && oinstall js_of_ocaml-lwt
101 + oinstall js_of_ocaml-ocamlbuild
102 + oinstall js_of_ocaml
103 + use ppx && oinstall js_of_ocaml-ppx
104 + use ppx && oinstall js_of_ocaml-toplevel
105 + use xml && oinstall js_of_ocaml-tyxml
106 +}
107
108 diff --git a/dev-ml/js_of_ocaml/js_of_ocaml-9999.ebuild b/dev-ml/js_of_ocaml/js_of_ocaml-9999.ebuild
109 index 5b17a890bb3..3a44770cfb6 100644
110 --- a/dev-ml/js_of_ocaml/js_of_ocaml-9999.ebuild
111 +++ b/dev-ml/js_of_ocaml/js_of_ocaml-9999.ebuild
112 @@ -20,46 +20,56 @@ fi
113
114 LICENSE="LGPL-2.1-with-linking-exception"
115 SLOT="0/${PV}"
116 -IUSE="+ocamlopt doc +deriving +ppx +react +xml X"
117 +IUSE="+ocamlopt camlp4 lwt doc +deriving +ppx +xml test"
118
119 RDEPEND="
120 - >=dev-lang/ocaml-3.12:=[ocamlopt?,X?]
121 - >=dev-ml/lwt-2.4.4:=[camlp4(+)]
122 - react? ( dev-ml/react:= dev-ml/reactiveData:= )
123 - xml? ( >=dev-ml/tyxml-4:= )
124 - ppx? ( dev-ml/ppx_tools:= dev-ml/ppx_deriving:= dev-ml/ppx_driver:= )
125 + >=dev-lang/ocaml-3.12:=[ocamlopt?]
126 +
127 + camlp4? ( dev-ml/camlp4:= )
128 +
129 dev-ml/cmdliner:=
130 - dev-ml/menhir:=
131 - dev-ml/ocaml-base64:=
132 - dev-ml/camlp4:=
133 dev-ml/cppo:=
134 - dev-ml/uchar:=
135 +
136 + lwt? ( >=dev-ml/lwt-2.4.4:= )
137 +
138 dev-ml/ocamlbuild:=
139 - dev-ml/yojson:=
140 - deriving? ( >=dev-ml/deriving-0.6:= )"
141 -DEPEND="${RDEPEND}"
142 -
143 -src_configure() {
144 - printf "\n\n" >> Makefile.conf
145 - use ocamlopt || echo "BEST := byte" >> Makefile.conf
146 - use ocamlopt || echo "NATDYNLINK := NO" >> Makefile.conf
147 - use deriving || echo "WITH_DERIVING := NO" >> Makefile.conf
148 - use X || echo "WITH_GRAPHICS := NO" >> Makefile.conf
149 - use react || echo "WITH_REACT := NO" >> Makefile.conf
150 - use ppx || echo "WITH_PPX := NO" >> Makefile.conf
151 - use ppx || echo "WITH_PPX_DERIVING := NO" >> Makefile.conf
152 - use ppx || echo "WITH_PPX_DRIVER := NO" >> Makefile.conf
153 - echo "WITH_ASYNC := NO" >> Makefile.conf
154 -}
155 +
156 + dev-ml/ocaml-migrate-parsetree:=
157 + dev-ml/ppx_tools_versioned:=
158 + dev-ml/uchar:=
159 +
160 + ppx? ( dev-ml/ppx_tools:= dev-ml/ppx_deriving:= )
161 +
162 + xml? ( >=dev-ml/tyxml-4:= dev-ml/reactiveData:= )
163 +"
164 +DEPEND="${RDEPEND}
165 + dev-ml/jbuilder
166 + dev-ml/opam
167 + test? ( dev-util/patdiff )
168 +"
169 +REQUIRED_USE="xml? ( ppx )"
170
171 src_compile() {
172 - emake -j1
173 + emake
174 use doc && emake doc
175 }
176
177 +oinstall() {
178 + opam-installer -i \
179 + --prefix="${ED}/usr" \
180 + --libdir="${D}/$(ocamlc -where)" \
181 + --docdir="${ED}/usr/share/doc/${PF}" \
182 + --mandir="${ED}/usr/share/man" \
183 + ${1}.install || die
184 +}
185 +
186 src_install() {
187 - findlib_src_preinst
188 - emake BINDIR="${ED}/usr/bin/" install
189 - dodoc CHANGES README.md
190 - use doc && dohtml -r doc/api/html/
191 + use camlp4 && oinstall js_of_ocaml-camlp4
192 + oinstall js_of_ocaml-compiler
193 + use lwt && oinstall js_of_ocaml-lwt
194 + oinstall js_of_ocaml-ocamlbuild
195 + oinstall js_of_ocaml
196 + use ppx && oinstall js_of_ocaml-ppx
197 + use ppx && oinstall js_of_ocaml-toplevel
198 + use xml && oinstall js_of_ocaml-tyxml
199 }
200
201 diff --git a/dev-ml/js_of_ocaml/metadata.xml b/dev-ml/js_of_ocaml/metadata.xml
202 index 904a7a4498e..a7e813252c7 100644
203 --- a/dev-ml/js_of_ocaml/metadata.xml
204 +++ b/dev-ml/js_of_ocaml/metadata.xml
205 @@ -6,7 +6,9 @@
206 <name>Gentoo ML Project</name>
207 </maintainer>
208 <use>
209 + <flag name="camlp4">Build with camlp4 syntax extensions.</flag>
210 <flag name="deriving">Enable <pkg>dev-ml/deriving</pkg> support for improving the type safety.</flag>
211 + <flag name="lwt">Enable <pkg>dev-ml/lwt</pkg> support.</flag>
212 <flag name="ppx">Enables the ppx syntax extension</flag>
213 <flag name="react">Enable functionnal reactive programming support.</flag>
214 </use>