perl: update to 5.12.2, bump abi_depends.
This commit is contained in:
@@ -1,13 +1,11 @@
|
||||
# Template build file for 'perl'.
|
||||
pkgname=perl
|
||||
version=5.10.1
|
||||
revision=2
|
||||
distfiles="http://www.cpan.org/src/$pkgname-$version.tar.gz"
|
||||
build_style=configure
|
||||
configure_script="./Configure"
|
||||
version=5.12.2
|
||||
distfiles="http://www.cpan.org/src/5.0/$pkgname-$version.tar.bz2"
|
||||
build_style=custom-install
|
||||
short_desc="Practical Extraction and Report Language"
|
||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||
checksum=cb7f26ea4b2b28d6644354d87a269d01cac1b635287dae64e88eeafa24b44f35
|
||||
checksum=3b9a75fe4ae7a9a2a17be8c8c64754ef6fd706ca528170737b03e3db7d8eae0e
|
||||
long_desc="
|
||||
Perl is a general-purpose programming language originally developed
|
||||
for text manipulation and now used for a wide range of tasks including
|
||||
@@ -25,25 +23,64 @@ Add_dependency run db
|
||||
Add_dependency build gdbm-devel
|
||||
Add_dependency build db-devel
|
||||
|
||||
pre_configure()
|
||||
do_build()
|
||||
{
|
||||
local p5_base p5_apiver args
|
||||
./Configure \
|
||||
-des -Dusethreads -Duseshrplib \
|
||||
-Dinstallprefix=/usr \
|
||||
-Dprefix=/usr -Dvendorprefix=/usr \
|
||||
-Dprivlib=/usr/share/perl5/core_perl \
|
||||
-Darchlib=/usr/lib/perl5/core_perl \
|
||||
-Dsitelib=/usr/share/perl5/site_perl \
|
||||
-Dsitearch=/usr/lib/perl5/site_perl \
|
||||
-Dvendorlib=/usr/share/perl5/vendor_perl \
|
||||
-Dvendorarch=/usr/lib/perl5/vendor_perl \
|
||||
-Dscriptdir=/usr/lib/perl5/core_perl/bin \
|
||||
-Dsitescript=/usr/lib/perl5/site_perl/bin \
|
||||
-Dvendorscript=/usr/lib/perl5/vendor_perl/bin \
|
||||
-Dinc_version_list=none \
|
||||
-Dman1ext=1p -Dman3ext=3p \
|
||||
-Dcccdlflags="-fPIC" -Doptimize="${XBPS_CFLAGS}"
|
||||
|
||||
cd $wrksrc || return 1
|
||||
# Taken from NetBSD.
|
||||
p5_base="/usr/lib/perl5"
|
||||
p5_apiver="$(awk '/\#define[ ]*PERL_API_REVISION/ { R = $3 } \
|
||||
/\#define[ ]*PERL_API_VERSION/ { r = "."$3 } \
|
||||
/\#define[ ]*PERL_API_SUBVERSION/ { s = "."$3 } \
|
||||
END { printf "%s%s%s\n", R, r, s }' patchlevel.h)"
|
||||
|
||||
args="-Dusethreads -des -Dprefix=/usr \
|
||||
-Duselargefiles -Uusesfio -Dinstallstyle=lib/perl5 \
|
||||
-Uinstallusrbinperl -Duseshrplib \
|
||||
-Dman1dir=/usr/share/man/man1 \
|
||||
-Dman3dir=/usr/share/man/man3 \
|
||||
-Dprivlib=${p5_base}/${p5_apiver} \
|
||||
-Dsitelib=${p5_base}/site_perl/${p5_apiver} \
|
||||
-Dvendorlib=${p5_base}/vendor_perl/${p5_apiver}"
|
||||
export configure_args="${args}"
|
||||
make ${makejobs}
|
||||
}
|
||||
|
||||
do_install()
|
||||
{
|
||||
# We use the same defaults than Arch Linux.
|
||||
make DESTDIR=${DESTDIR} install || return 1
|
||||
|
||||
# Make a link from perl${version} to perl.
|
||||
cd ${DESTDIR}/usr/bin && ln -sf perl${version} perl
|
||||
|
||||
### CPAN Settings ###
|
||||
# Set CPAN default config to use the site directories.
|
||||
sed -e '/(makepl_arg =>/ s/""/"INSTALLDIRS=site"/' \
|
||||
-e '/(mbuildpl_arg =>/ s/""/"installdirs=site"/' \
|
||||
-i ${DESTDIR}/usr/share/perl5/core_perl/CPAN/FirstTime.pm
|
||||
|
||||
### CPANPLUS Settings ###
|
||||
# Set CPANPLUS default config to use the site directories.
|
||||
sed -e "/{'makemakerflags'}/ s/'';/'INSTALLDIRS=site';/" \
|
||||
-e "/{'buildflags'}/ s/'';/'installdirs=site';/" \
|
||||
-i ${DESTDIR}/usr/share/perl5/core_perl/CPANPLUS/Config.pm
|
||||
|
||||
# Profile script so set paths to perl scripts.
|
||||
install -D -m644 ${FILESDIR}/perlbin.sh \
|
||||
${DESTDIR}/etc/profile.d/perlbin.sh
|
||||
|
||||
# Remove all pod files *except* those under
|
||||
# /usr/share/perl5/core_perl/pod/ (FS#16488)
|
||||
rm -f ${DESTDIR}/usr/share/perl5/core_perl/*.pod
|
||||
for d in ${DESTDIR}/usr/share/perl5/core_perl/*; do
|
||||
if [ -d $d -a $(basename $d) != "pod" ]; then
|
||||
find $d -name *.pod -delete
|
||||
fi
|
||||
done
|
||||
find ${DESTDIR}/usr/lib -name *.pod -delete
|
||||
find ${DESTDIR} -name .packlist -delete
|
||||
|
||||
# Make a symlink so that libperl.so is accesible.
|
||||
cd ${DESTDIR}/usr/lib && \
|
||||
ln -sf ./perl5/core_perl/CORE/libperl.so libperl.so
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user