diff options
author | Sam James <sam@gentoo.org> | 2021-03-19 09:51:42 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2021-03-19 10:23:46 +0000 |
commit | e90cd3a78292328d6011bb750cadf46c8bef72b8 (patch) | |
tree | 50681bb6696cb26a5651eb5499b98b7f7da86cdd /dev-ml/merlin | |
parent | dev-ml/merlin: add 3.4.2 (initial import) (diff) | |
download | gentoo-e90cd3a78292328d6011bb750cadf46c8bef72b8.tar.gz gentoo-e90cd3a78292328d6011bb750cadf46c8bef72b8.tar.bz2 gentoo-e90cd3a78292328d6011bb750cadf46c8bef72b8.zip |
dev-ml/merlin: add 4.1
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-ml/merlin')
-rw-r--r-- | dev-ml/merlin/merlin-4.1.ebuild | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/dev-ml/merlin/merlin-4.1.ebuild b/dev-ml/merlin/merlin-4.1.ebuild new file mode 100644 index 000000000000..44da757af904 --- /dev/null +++ b/dev-ml/merlin/merlin-4.1.ebuild @@ -0,0 +1,67 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# TODO: vim-plugin, although it's not clear how to make it work here +inherit elisp-common dune + +DESCRIPTION="Context sensitive completion for OCaml in Vim and Emacs" +HOMEPAGE="https://github.com/ocaml/merlin" +SRC_URI="https://github.com/ocaml/merlin/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="~amd64" +IUSE="emacs +ocamlopt" + +RDEPEND=" + app-emacs/auto-complete + app-emacs/company-mode + dev-ml/csexp:= + dev-ml/yojson:= + =dev-lang/ocaml-4.11*:= + emacs? ( >=app-editors/emacs-23.1:* ) +" +DEPEND="${RDEPEND}" + +SITEFILE="50${PN}-gentoo.el" + +src_prepare() { + default + + # Handle installation via the eclass + rm emacs/dune || die +} + +src_compile() { + dune_src_compile + + if use emacs ; then + # Build the emacs integration + cd emacs || die + + # iedit isn't packaged yet + rm merlin-iedit.el || die + + elisp-compile *.el + fi +} + +src_install() { + dune_src_install + + if use emacs ; then + cd "${S}/emacs" || die + elisp-install ${PN} *.el *.elc + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +} |