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

Diff of /eclass/perl-module.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.25 Revision 1.33
1# Copyright 2002 Gentoo Technologies, Inc. 1# Copyright 1999-2003 Gentoo Technologies, Inc.
2# Distributed under the terms of the GNU General Public License, v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/perl-module.eclass,v 1.33 2003/02/16 04:26:21 vapier Exp $
4#
3# Author: Seemant Kulleen <seemant@gentoo.org> 5# Author: Seemant Kulleen <seemant@gentoo.org>
4# $Header: /var/cvsroot/gentoo-x86/eclass/perl-module.eclass,v 1.25 2002/09/17 01:09:17 mcummings Exp $ 6#
5# The perl-module eclass is designed to allow easier installation of perl 7# The perl-module eclass is designed to allow easier installation of perl
6# modules, and their incorporation into the Gentoo Linux system. 8# modules, and their incorporation into the Gentoo Linux system.
7 9
8#first inherit the pkg_postinst() and pkg_postrm() functions 10#first inherit the pkg_postinst() and pkg_postrm() functions
9inherit perl-post 11inherit perl-post
12INHERITED="$INHERITED $ECLASS" 14INHERITED="$INHERITED $ECLASS"
13 15
14EXPORT_FUNCTIONS src_compile src_install src_test 16EXPORT_FUNCTIONS src_compile src_install src_test
15 17
16eval `perl '-V:version'` 18eval `perl '-V:version'`
17echo "Version is: ${version}" 19DEPEND="sys-devel/perl
18if [ ${version} == '5.6.1' ];
19 then
20 DEPEND="${DEPEND} >=sys-devel/perl-5 \
21 =dev-perl/ExtUtils-MakeMaker-6.03-r1" 20 >=dev-perl/ExtUtils-MakeMaker-6.05-r1
22 else 21 ${DEPEND}"
23 DEPEND="${DEPEND} >=sys-devel/perl-5"
24fi
25SRC_PREP="no" 22SRC_PREP="no"
26 23
27perl-module_src_prep() { 24perl-module_src_prep() {
28 25
29 SRC_PREP="yes" 26 SRC_PREP="yes"
45 42
46 perl-post_perlinfo 43 perl-post_perlinfo
47 dodir ${POD_DIR} 44 dodir ${POD_DIR}
48 45
49 test -z ${mytargets} && mytargets="install" 46 test -z ${mytargets} && mytargets="install"
47 eval `perl '-V:installsitearch'`
48 SITE_ARCH=${installsitearch}
49 eval `perl '-V:installarchlib'`
50 ARCH_LIB=${installarchlib}
51
50 52
51 make \ 53 make \
52 PREFIX=${D}/usr \ 54 PREFIX=${D}/usr \
53 INSTALLMAN1DIR=${D}/usr/share/man/man1 \ 55 INSTALLMAN1DIR=${D}/usr/share/man/man1 \
54 INSTALLMAN2DIR=${D}/usr/share/man/man2 \ 56 INSTALLMAN2DIR=${D}/usr/share/man/man2 \
55 INSTALLMAN3DIR=${D}/usr/share/man/man3 \ 57 INSTALLMAN3DIR=${D}/usr/share/man/man3 \
56 INSTALLMAN4DIR=${D}/usr/share/man/man4 \ 58 INSTALLMAN4DIR=${D}/usr/share/man/man4 \
57 INSTALLMAN5DIR=${D}/usr/share/man/man5 \ 59 INSTALLMAN5DIR=${D}/usr/share/man/man5 \
58 INSTALLMAN6DIR=${D}/usr/share/man/man6 \ 60 INSTALLMAN6DIR=${D}/usr/share/man/man6 \
59 INSTALLMAN7DIR=${D}/usr/share/man/man7 \ 61 INSTALLMAN7DIR=${D}/usr/share/man/man7 \
60 INSTALLMAN8DIR=${D}/usr/share/man/man8 \ 62 INSTALLMAN8DIR=${D}/usr/share/man/man8 \
63 INSTALLSITEMAN1DIR=${D}/usr/share/man/man1 \
64 INSTALLSITEMAN2DIR=${D}/usr/share/man/man2 \
65 INSTALLSITEMAN3DIR=${D}/usr/share/man/man3 \
66 INSTALLSITEMAN4DIR=${D}/usr/share/man/man4 \
67 INSTALLSITEMAN5DIR=${D}/usr/share/man/man5 \
68 INSTALLSITEMAN6DIR=${D}/usr/share/man/man6 \
69 INSTALLSITEMAN7DIR=${D}/usr/share/man/man7 \
70 INSTALLSITEMAN8DIR=${D}/usr/share/man/man8 \
71 INSTALLSITEARCH=${D}/${SITE_ARCH} \
72 INSTALLSCRIPT=${D}/usr/bin \
61 ${myinst} \ 73 ${myinst} \
62 ${mytargets} || die 74 ${mytargets} || die
63 75
64 76
65 if [ -f ${D}${ARCH_LIB}/perllocal.pod ]; 77 if [ -f ${D}${ARCH_LIB}/perllocal.pod ];
66 then 78 then
67 touch ${D}/${POD_DIR}/${P}.pod 79 touch ${D}/${POD_DIR}/${P}.pod
80 sed -e "s:${D}::g" \
68 sed -e "s:${D}::g" ${D}${ARCH_LIB}/perllocal.pod >> ${D}/${POD_DIR}/${P}.pod 81 ${D}${ARCH_LIB}/perllocal.pod >> ${D}/${POD_DIR}/${P}.pod
69 touch ${D}/${POD_DIR}/${P}.pod.arch 82 touch ${D}/${POD_DIR}/${P}.pod.arch
70 cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.arch 83 cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.arch
71 rm -f ${D}/${ARCH_LIB}/perllocal.pod 84 rm -f ${D}/${ARCH_LIB}/perllocal.pod
72 fi 85 fi
73 86
74 if [ -f ${D}${SITE_LIB}/perllocal.pod ]; 87 if [ -f ${D}${SITE_LIB}/perllocal.pod ];
75 then 88 then
76 touch ${D}/${POD_DIR}/${P}.pod 89 touch ${D}/${POD_DIR}/${P}.pod
90 sed -e "s:${D}::g" \
77 sed -e "s:${D}::g" ${D}${SITE_LIB}/perllocal.pod >> ${D}/${POD_DIR}/${P}.pod 91 ${D}${SITE_LIB}/perllocal.pod >> ${D}/${POD_DIR}/${P}.pod
78 touch ${D}/${POD_DIR}/${P}.pod.site 92 touch ${D}/${POD_DIR}/${P}.pod.site
79 cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.site 93 cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.site
80 rm -f ${D}/${SITE_LIB}/perllocal.pod 94 rm -f ${D}/${SITE_LIB}/perllocal.pod
81 fi 95 fi
82 96
83 dodoc Change* MANIFEST* README* ${mydoc} 97 dodoc Change* MANIFEST* README* ${mydoc}
84} 98}

Legend:
Removed from v.1.25  
changed lines
  Added in v.1.33

  ViewVC Help
Powered by ViewVC 1.1.20