dev-ml/num: x86 stable wrt bug #723500
[gentoo.git] / dev-ml / labltk / labltk-8.06.7.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 inherit findlib eutils
7
8 DESCRIPTION="OCaml interface to the Tcl/Tk GUI framework"
9 HOMEPAGE="https://garrigue.github.io/labltk/"
10 SRC_URI="https://github.com/garrigue/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
11
12 LICENSE="QPL-1.0 LGPL-2"
13 SLOT="0/${PV}"
14 KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 ~sparc x86 ~amd64-linux ~x86-linux"
15 IUSE="+ocamlopt X"
16
17 RDEPEND=">=dev-lang/tk-8.0.3:=
18         >=dev-lang/ocaml-4.08:=[ocamlopt?,X(+)?]"
19 DEPEND="${RDEPEND}
20         >=dev-ml/findlib-1.5.5-r1"
21
22 PATCHES=(
23         "${FILESDIR}/findlib.patch"
24 )
25
26 src_configure() {
27         ./configure --use-findlib --verbose $(usex X "--tk-x11" "--tk-no-x11") || die "configure failed!"
28 }
29
30 src_compile() {
31         emake -j1
32         use ocamlopt && emake -j1 opt
33 }
34
35 src_install() {
36         findlib_src_preinst
37         dodir /usr/bin
38         emake \
39                 INSTALLDIR="${D}$(ocamlc -where)/labltk" \
40                 INSTALLBINDIR="${ED}/usr/bin/" \
41                 install
42         dodoc Changes README.mlTk
43 }