/[gentoo-x86]/eclass/findlib.eclass
Gentoo

Contents of /eclass/findlib.eclass

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (hide annotations) (download)
Sun Feb 24 15:46:09 2008 UTC (6 years, 10 months ago) by aballier
Branch: MAIN
Changes since 1.7: +13 -4 lines
make findlib eclass ready for eclass manpages, thanks to mren <bugs@rennings.net> in bug #210638

1 aballier 1.8 # Copyright 1999-2008 Gentoo Foundation
2 mattam 1.1 # Distributed under the terms of the GNU General Public License v2
3 aballier 1.8 # $Header: $
4    
5     # @ECLASS: findlib.eclass
6     # @MAINTAINER:
7     # ml@gentoo.org
8 mattam 1.1 #
9 betelgeuse 1.7 # Original author : Matthieu Sozeau <mattam@gentoo.org> (retired)
10 mattam 1.1 #
11 betelgeuse 1.7 # Changes: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/findlib.eclass?view=log
12 aballier 1.8 # @BLURB: ocamlfind (a.k.a. findlib) eclass
13     # @DESCRIPTION:
14 mattam 1.1 # ocamlfind (a.k.a. findlib) eclass
15 aballier 1.8
16 mattam 1.1
17    
18     # From this findlib version there is proper stublibs support.
19     DEPEND=">=dev-ml/findlib-1.0.4-r1"
20 betelgeuse 1.6 [[ ${FINDLIB_USE} ]] && DEPEND="${FINDLIB_USE}? ( ${DEPEND} )"
21 mattam 1.1
22     check_ocamlfind() {
23     if [ ! -x /usr/bin/ocamlfind ]
24     then
25 betelgeuse 1.7 eerror "In findlib.eclass: could not find the ocamlfind executable"
26     eerror "Please report this bug on gentoo's bugzilla, assigning to ml@gentoo.org"
27     die "ocamlfind executabled not found"
28 mattam 1.1 fi
29     }
30    
31 aballier 1.8 # @FUNCTION: findlib_src_preinst
32     # @DESCRIPTION:
33 mattam 1.1 # Prepare the image for a findlib installation.
34     # We use the stublibs style, so no ld.conf needs to be
35     # updated when a package installs C shared libraries.
36     findlib_src_preinst() {
37     check_ocamlfind
38    
39     # destdir is the ocaml sitelib
40     local destdir=`ocamlfind printconf destdir`
41    
42 swegener 1.5 dodir ${destdir} || die "dodir failed"
43 mattam 1.1 export OCAMLFIND_DESTDIR=${D}${destdir}
44    
45     # stublibs style
46 mattam 1.2 dodir ${destdir}/stublibs || die "dodir failed"
47 mattam 1.1 export OCAMLFIND_LDCONF=ignore
48     }
49    
50 aballier 1.8 # @FUNCTION: findlib_src_install
51     # @DESCRIPTION:
52 mattam 1.1 # Install with a properly setup findlib
53     findlib_src_install() {
54     findlib_src_preinst
55 mattam 1.2 make DESTDIR=${D} "$@" install || die "make failed"
56 mattam 1.1 }

  ViewVC Help
Powered by ViewVC 1.1.20