/[gentoo-x86]/eclass/perl-module.eclass
Gentoo

Contents of /eclass/perl-module.eclass

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.20 - (hide annotations) (download)
Fri Aug 16 12:20:09 2002 UTC (11 years, 11 months ago) by mcummings
Branch: MAIN
Changes since 1.19: +26 -17 lines
Updated module to sperate pod creations

1 seemant 1.1 # Copyright 2002 Gentoo Technologies, Inc.
2     # Distributed under the terms of the GNU General Public License, v2
3     # Author: Seemant Kulleen <seemant@gentoo.org>
4 mcummings 1.19 # $Header: /home/cvsroot/gentoo-x86/eclass/perl-module.eclass,v 1.18 2002/08/07 01:49:17 mcummings Exp $
5 seemant 1.1 # The perl-module eclass is designed to allow easier installation of perl
6     # modules, and their incorporation into the Gentoo Linux system.
7 seemant 1.3
8     #first inherit the pkg_postinst() and pkg_postrm() functions
9     inherit perl-post
10    
11 danarmak 1.14 ECLASS=perl-module
12 danarmak 1.13 INHERITED="$INHERITED $ECLASS"
13    
14 seemant 1.8 EXPORT_FUNCTIONS src_compile src_install src_test
15 seemant 1.1
16 mcummings 1.19 DEPEND=">=sys-devel/perl-5"
17 seemant 1.1
18 azarah 1.11 SRC_PREP="no"
19    
20 aliz 1.15 perl-module_src_prep() {
21 azarah 1.11
22     SRC_PREP="yes"
23 mcummings 1.18 eval `perl '-V:version'`
24     if [ ${version} == '5.6.1' ];
25     then
26     perl Makefile.PL ${myconf}
27     else
28     perl Makefile.PL ${myconf} \
29 mcummings 1.20 PREFIX=${D}/usr
30 mcummings 1.18 fi
31 azarah 1.11 }
32    
33 aliz 1.15 perl-module_src_compile() {
34 seemant 1.6
35 aliz 1.15 [ "${SRC_PREP}" != "yes" ] && perl-module_src_prep
36 seemant 1.7 make ${mymake} || die "compilation failed"
37 seemant 1.8 }
38    
39 aliz 1.15 perl-module_src_test() {
40 seemant 1.9 make test
41 seemant 1.1 }
42    
43 aliz 1.15 perl-module_src_install() {
44 seemant 1.12
45 seemant 1.16 perl-post_perlinfo
46 seemant 1.1 dodir ${POD_DIR}
47    
48 seemant 1.9 test -z ${mytargets} && mytargets="install"
49    
50 seemant 1.1 make \
51 mcummings 1.20 PREFIX=${D}/usr \
52     INSTALLMAN1DIR=${D}/usr/share/man/man1 \
53     INSTALLMAN2DIR=${D}/usr/share/man/man2 \
54     INSTALLMAN3DIR=${D}/usr/share/man/man3 \
55     INSTALLMAN4DIR=${D}/usr/share/man/man4 \
56     INSTALLMAN5DIR=${D}/usr/share/man/man5 \
57     INSTALLMAN6DIR=${D}/usr/share/man/man6 \
58     INSTALLMAN7DIR=${D}/usr/share/man/man7 \
59     INSTALLMAN8DIR=${D}/usr/share/man/man8 \
60     ${myinst} \
61     ${mytargets} || die
62    
63    
64     if [ -f ${D}${ARCH_LIB}/perllocal.pod ];
65     then
66     sed -e "s:${D}::g" ${D}${ARCH_LIB}/perllocal.pod > ${D}/${POD_DIR}/${P}.pod
67     cp ${D}/${POD_DIR}/${P}.pod ${D}/${POD_DIR}/${P}.pod.arch
68     rm -f ${D}/${ARCH_LIB}/perllocal.pod
69     fi
70 seemant 1.1
71 mcummings 1.20 if [ -f ${D}${SITE_LIB}/perllocal.pod ];
72     then
73     sed -e "s:${D}::g" ${D}${SITE_LIB}/perllocal.pod > ${D}/${POD_DIR}/${P}.pod
74     cp ${D}/${POD_DIR}/${P}.pod ${D}/${POD_DIR}/${P}.pod.site
75     rm -f ${D}/${SITE_LIB}/perllocal.pod
76     fi
77 seemant 1.1
78 seemant 1.9 dodoc Change* MANIFEST* README* ${mydoc}
79 seemant 1.1 }

  ViewVC Help
Powered by ViewVC 1.1.20