diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-ml/xml-light/xml-light-2.2-r3.ebuild |
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-ml/xml-light/xml-light-2.2-r3.ebuild')
-rw-r--r-- | dev-ml/xml-light/xml-light-2.2-r3.ebuild | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/dev-ml/xml-light/xml-light-2.2-r3.ebuild b/dev-ml/xml-light/xml-light-2.2-r3.ebuild new file mode 100644 index 000000000000..f7244b272a18 --- /dev/null +++ b/dev-ml/xml-light/xml-light-2.2-r3.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils multilib + +DESCRIPTION="Minimal Xml parser and printer for OCaml" +HOMEPAGE="http://tech.motion-twin.com/xmllight.html" +SRC_URI="http://tech.motion-twin.com/zip/${P}.zip" + +LICENSE="LGPL-2.1" +SLOT="0/${PV}" +KEYWORDS="amd64 ~arm ~arm64 ~ppc x86" +IUSE="doc +ocamlopt" + +RDEPEND="dev-lang/ocaml:=[ocamlopt?]" +DEPEND="app-arch/unzip + ${RDEPEND}" + +S="${WORKDIR}/${PN}" + +src_prepare() { + EPATCH_FORCE=yes EPATCH_SUFFIX=dpatch EPATCH_SOURCE="${FILESDIR}" \ + epatch +} + +src_compile() { + emake -j1 + if use ocamlopt; then + emake -j1 opt + fi + if use doc;then + emake doc + fi +} + +src_test() { + # There are no tests... + : +} + +src_install() { + dodir /usr/$(get_libdir)/ocaml/${PN} + emake INSTALLDIR="${D}"/usr/$(get_libdir)/ocaml/${PN} install + cat > "${D}"/usr/$(get_libdir)/ocaml/${PN}/META << EOF +name="${PN}" +version="${PV}" +description="${DESCRIPTION}" +requires="" +archive(byte)="xml-light.cma" +EOF + if use ocamlopt; then + emake INSTALLDIR="${D}"/usr/$(get_libdir)/ocaml/${PN} installopt + echo 'archive(native)="xml-light.cmxa"' >> "${D}"/usr/$(get_libdir)/ocaml/${PN}/META + fi + dodoc README + if use doc; then + emake doc + dohtml doc/* + fi +} |