blob: 1d316a75af7e34ba614da0189515196b902f8fad (
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
|
# Copyright 1999-2004 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-perl/ExtUtils-MakeMaker/ExtUtils-MakeMaker-6.21.ebuild,v 1.4 2004/02/22 20:39:54 agriffis Exp $
DESCRIPTION="MakeMaker Perl Module"
SRC_URI="http://cpan.valueclick.com/modules/by-module/ExtUtils/${P}.tar.gz"
HOMEPAGE="http://cpan.valueclick.com/modules/by-module/ExtUtils/${P}.readme"
IUSE=""
SLOT="0"
LICENSE="Artistic | GPL-2"
KEYWORDS="~x86 ~amd64 ~sparc ppc alpha ~mips ~hppa ppc64 ia64"
DEPEND=">=dev-lang/perl-5.8.0-r12 >=sys-apps/sed-4"
src_compile() {
perl Makefile.PL INSTALLDIRS=vendor DESTDIR="${D}" ${myconf} || die
make test || die "self-test failed"
}
src_install () {
perlinfo
dodir ${POD_DIR}
test -z ${mytargets} && mytargets="install"
make \
${myinst} \
${mytargets} || die
if [ -f ${D}${ARCH_LIB}/perllocal.pod ];
then
touch ${D}/${POD_DIR}/${P}.pod
sed -e "s:${D}::g" ${D}${ARCH_LIB}/perllocal.pod \
>> ${D}/${POD_DIR}/${P}.pod
touch ${D}/${POD_DIR}/${P}.pod.arch
cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.arch
rm -f ${D}/${ARCH_LIB}/perllocal.pod
fi
if [ -f ${D}${SITE_LIB}/perllocal.pod ];
then
touch ${D}/${POD_DIR}/${P}.pod
sed -e "s:${D}::g" ${D}${SITE_LIB}/perllocal.pod \
>> ${D}/${POD_DIR}/${P}.pod
touch ${D}/${POD_DIR}/${P}.pod.site
cat ${D}/${POD_DIR}/${P}.pod >>${D}/${POD_DIR}/${P}.pod.site
rm -f ${D}/${SITE_LIB}/perllocal.pod
fi
for FILE in `find ${D} -type f -name "*.html" -o -name ".packlist"`; do
sed -ie "s:${D}:/:g" ${FILE}
done
dodoc Change* MANIFEST* README* ${mydoc}
}
pkg_setup() {
perlinfo
}
pkg_preinst() {
perlinfo
}
pkg_postinst() {
updatepod
}
pkg_prerm() {
updatepod
}
pkg_postrm() {
updatepod
}
perlinfo() {
if [ -f /usr/bin/perl ]
then
eval `perl '-V:installarchlib'`
eval `perl '-V:installsitearch'`
eval `perl '-V:installvendorarch'`
eval `perl '-V:installvendorlib'`
ARCH_LIB=${installarchlib}
SITE_LIB=${installsitearch}
VENDOR_ARCH=${installvendorarch}
VENDOR_LIB=${installvendorlib}
eval `perl '-V:version'`
POD_DIR="/usr/share/perl/gentoo-pods/${version}"
fi
}
updatepod() {
perlinfo
if [ -d "${POD_DIR}" ]
then
for FILE in `find ${POD_DIR} -type f -name "*.pod.arch"`; do
cat ${FILE} >> ${ARCH_LIB}/perllocal.pod
rm -f ${FILE}
done
for FILE in `find ${POD_DIR} -type f -name "*.pod.site"`; do
cat ${FILE} >> ${SITE_LIB}/perllocal.pod
rm -f ${FILE}
done
#cat ${POD_DIR}/*.pod.arch >> ${ARCH_LIB}/perllocal.pod
#cat ${POD_DIR}/*.pod.site >> ${SITE_LIB}/perllocal.pod
#rm -f ${POD_DIR}/*.pod.site
#rm -f ${POD_DIR}/*.pod.site
fi
}
|