Magellan Linux

Contents of /smage/branches/alx-0_6_0/core/perl/perl-5.12.3-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2506 - (show annotations) (download)
Thu Jun 30 13:55:15 2011 UTC (12 years, 11 months ago) by niro
File size: 2614 byte(s)
-removed STATE variable from smage files, use global distribution file for package/distribution states
1 # $Id$
2
3 PNAME="perl"
4 PVER="5.12.3"
5 PBUILD="r1"
6
7 PCATEGORIE="dev-lang"
8
9 DESCRIPTION="Larry Wall's Practical Extraction and Reporting Language."
10 HOMEPAGE="http://www.perl.org/"
11
12 DEPEND=">= sys-apps/groff-1.21
13 >= sys-libs/zlib-1.2.5"
14
15 SRCFILE="${PNAME}-${PVER}.tar.bz2"
16 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
17
18 REMOVE_DEPRECATED_MAGE_TARGETS=1
19 sminclude alx
20
21 SRC_URI=(
22 http://ftp.funet.fi/pub/CPAN/src/${SRCFILE}
23 http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/distfiles/${SRCFILE}
24 mirror://${PNAME}/${SRCFILE}
25 mirror://${PNAME}/${PNAME}-5.10.1-picdl.patch
26 mirror://${PNAME}/${PNAME}-5.8.7-sharedlinker.patch
27 mirror://${PNAME}/${PNAME}-5.8.7-Configure_multilib-1.patch
28 mirror://${PNAME}/${PNAME}-5.12.1-libc_lib64-1.patch
29 )
30
31 #UP2DATE="updatecmd http://ftp.funet.fi/pub/CPAN/src | grep ${PNAME}- | lasttarball"
32 #UP2DATE="updatecmd ${HOMEPAGE} | grep 'Current Release:' | sed 's/.*: \[.*\]\(.*\).*/\1/'"
33 #UP2DATE="updatecmd ${HOMEPAGE} | grep 'Latest Version:' | sed 's/.*: \[.*\]\(.*\).*/\1/'"
34 UP2DATE="updatecmd ${HOMEPAGE} | grep 'download now' | sed 's/.*\[.*\]\(.*\) -.*/\1/'"
35
36 src_prepare()
37 {
38 munpack ${SRCFILE} || die
39 cd ${SRCDIR}
40
41 # enable dynamic loader
42 mpatch ${PNAME}-5.10.1-picdl.patch || die
43
44 # and proper ldflags for shrlibs
45 mpatch ${PNAME}-5.8.7-sharedlinker.patch || die
46
47 if [[ ${ARCH} = x86_64 ]]
48 then
49 # allow configure to run successfully on multilib builds
50 mpatch ${PNAME}-5.8.7-Configure_multilib-1.patch || die
51 # fix a small issue where perl -V assume libc in /lib
52 mpatch ${PNAME}-5.12.1-libc_lib64-1.patch || die
53 fi
54
55 # force use of system-zlib
56 sed -i -e '/^BUILD_ZLIB/s/True/False/' \
57 -e '/^INCLUDE/s,\./zlib-src,/usr/include,' \
58 -e '/^LIB/s,\./zlib-src,/usr/lib,' \
59 cpan/Compress-Raw-Zlib/config.in \
60 || die
61
62 # tell perl where to install the libs to
63 echo "installstyle=\"$(mlibdir)/perl5\"" >>hints/linux.sh || die
64 }
65
66 src_compile()
67 {
68 cd ${SRCDIR}
69
70 ./Configure \
71 -des \
72 -Darchname=${CHOST} \
73 -Doptimize="${CFLAGS}" \
74 -Dcccdlflags='-fPIC' \
75 -Dccdlflags='-rdynamic' \
76 -Duseshrplib \
77 -Dpager="/bin/less -isR" \
78 -Dcf_by='Magellan' \
79 -Dprefix='/usr' \
80 -Dvendorprefix='/usr' \
81 -Dsiteprefix='/usr' \
82 -Dman1dir=/usr/share/man/man1 \
83 -Dman3dir=/usr/share/man/man3 \
84 -Dinstallman1dir=/usr/share/man/man1 \
85 -Dinstallman3dir=/usr/share/man/man3 \
86 -Dman1ext='1' \
87 -Dman3ext='3pm' \
88 -Dlibpth="/usr/local/$(mlibdir) /$(mlibdir) /usr/$(mlibdir)" \
89 -Ui_db \
90 || die
91
92 mmake || die
93 }
94
95 src_install()
96 {
97 cd ${SRCDIR}
98
99 make DESTDIR=${BINDIR} install || die
100 minstalldocs AUTHORS Artistic Changes* Copying MANIFEST README* || die
101 }