summaryrefslogtreecommitdiff
blob: 2fdd9b6099a3eac83d000c23988dccc78df4ce81 (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
37
38
39
40
41
42
43
44
45
46
47
48
49
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-ml/camlimages/camlimages-2.20.ebuild,v 1.1 2005/02/06 15:28:50 mattam Exp $

inherit findlib

IUSE=""

DESCRIPTION="Library used by active-dvi"
HOMEPAGE="http://pauillac.inria.fr/advi/"
SRC_URI="ftp://ftp.inria.fr/INRIA/caml-light/bazar-ocaml/${P/20/2}.tgz"

LICENSE="LGPL-2.1"
SLOT="0"
KEYWORDS="~x86 ~ppc"

DEPEND=">=dev-lang/ocaml-3.06"

MY_S="${WORKDIR}/${P/20/2}"

src_compile() {
	cd ${MY_S}
	econf || die
	emake || die
	emake opt || die
}

src_test() {
	cd ${MY_S}/test
	make
	./test
	./test.byt
}

src_install() {
	# Use findlib to install properly, especially to avoid
	# the shared library mess
	findlib_src_preinst
	mkdir ${D}/tmp
	cd ${MY_S}
	make CAMLDIR=${D}/tmp \
		LIBDIR=${D}/tmp \
		DESTDIR=${D}/tmp \
		install || die
	sed -e "s/VERSION/${PV}/" ${FILESDIR}/META > ${D}/tmp/META

	ocamlfind install camlimages ${D}/tmp/*
	rm -rf ${D}/tmp
}