/[gentoo-x86]/dev-ml/ocamlduce/ocamlduce-3.12.0.0-r20.ebuild
Gentoo

Contents of /dev-ml/ocamlduce/ocamlduce-3.12.0.0-r20.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (hide annotations) (download)
Thu Jul 7 20:35:57 2011 UTC (8 years, 7 months ago) by aballier
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
remove old

(Portage version: 2.2.0_alpha43/cvs/Linux x86_64)

1 aballier 1.1 # Copyright 1999-2011 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 aballier 1.2 # $Header: /var/cvsroot/gentoo-x86/dev-ml/ocamlduce/ocamlduce-3.12.0.0-r20.ebuild,v 1.1 2011/07/06 16:32:39 aballier Exp $
4 aballier 1.1
5     EAPI="2"
6    
7     inherit versionator eutils toolchain-funcs flag-o-matic multilib
8    
9     OCAML_VERSION=3.12.1
10     OCAML_TARBALL=ocaml-${OCAML_VERSION}.tar.bz2
11     OCAML_PATCHLEVEL=3
12     OCAML_GENTOO_PATCHES=ocaml-patches-${OCAML_PATCHLEVEL}.tar.bz2
13    
14     DESCRIPTION="OCamlDuce is a merger between OCaml and CDuce"
15     HOMEPAGE="http://ocamlduce.forge.ocamlcore.org/"
16     SRC_URI="https://forge.ocamlcore.org/frs/download.php/441/${P}.tar.gz
17     ftp://ftp.inria.fr/INRIA/cristal/ocaml/ocaml-$(get_version_component_range 1-2 ${OCAML_VERSION})/${OCAML_TARBALL}
18     mirror://gentoo/${OCAML_GENTOO_PATCHES}"
19    
20     LICENSE="QPL-1.0 LGPL-2"
21     SLOT="0"
22     KEYWORDS="~amd64 ~x86 ~x86-fbsd"
23     IUSE="+ocamlopt"
24    
25     DEPEND="~dev-lang/ocaml-${OCAML_VERSION/+/_}[ocamlopt?]
26     >=dev-ml/findlib-1.2.4-r1
27     !!<dev-ml/${P}"
28    
29     RDEPEND="${DEPEND}"
30    
31     S=${WORKDIR}/${P}/ocaml-${OCAML_VERSION}
32    
33     src_unpack() {
34     unpack ${P}.tar.gz ${OCAML_GENTOO_PATCHES}
35     }
36    
37     src_prepare() {
38     cd "${WORKDIR}/${P}"
39     epatch "${FILESDIR}/ocaml-${OCAML_VERSION}.patch"
40     emake OCAML_SOURCE="${DISTDIR}/${OCAML_TARBALL}" prepare || die "failed to prepare"
41     cd "${S}"
42     EPATCH_SUFFIX="patch" epatch "${WORKDIR}/patches"
43     }
44    
45     src_configure() {
46     RAW_LDFLAGS="$(raw-ldflags)" ./configure -prefix /usr \
47     --bindir /usr/bin \
48     --libdir /usr/$(get_libdir)/ocaml \
49     --mandir /usr/share/man \
50     -host "${CHOST}" \
51     -cc "$(tc-getCC)" \
52     -as "$(tc-getAS)" \
53     -aspp "$(tc-getCC) -c" \
54     --with-pthread || die "configure failed!"
55     }
56    
57     src_compile() {
58     if use ocamlopt; then
59     emake -f Makefile.ocamlduce -j1 world.opt || die
60     else
61     emake -f Makefile.ocamlduce -j1 world || die
62     fi
63     }
64    
65     src_install() {
66     emake -f Makefile.ocamlduce BINDIR="${D}/usr/bin" LIBDIR="${D}/usr/$(get_libdir)/ocaml" installbyte || die
67     if use ocamlopt; then
68     emake -f Makefile.ocamlduce BINDIR="${D}/usr/bin" LIBDIR="${D}/usr/$(get_libdir)/ocaml" installopt || die
69     fi
70     dodoc Changes README
71     }

  ViewVC Help
Powered by ViewVC 1.1.20