summaryrefslogtreecommitdiff
path: root/core/perl
diff options
context:
space:
mode:
Diffstat (limited to 'core/perl')
-rw-r--r--core/perl/ChangeLog50
-rw-r--r--core/perl/PKGBUILD208
-rw-r--r--core/perl/fix-h2ph-and-tests.patch104
-rw-r--r--core/perl/perl.install18
-rwxr-xr-xcore/perl/perlbin.sh23
5 files changed, 403 insertions, 0 deletions
diff --git a/core/perl/ChangeLog b/core/perl/ChangeLog
new file mode 100644
index 000000000..2de069d5d
--- /dev/null
+++ b/core/perl/ChangeLog
@@ -0,0 +1,50 @@
+2010-11-07 kevin <kevin@archlinux.org>
+
+ * perl 5.12.2-1
+ - Using /usr/bin/*_perl for script directories
+
+2010-11-06 kevin <kevin@archlinux.org>
+
+ - Removed otherlibdirs directive from Configure
+ - Removed /usr/*/perl5/site_perl/5.10.1 from INC
+ - Finally removed legacy dirs /usr/lib/perl5/current and
+ /usr/lib/perl5/site_perl/current from @INC
+
+2010-05-23 kevin <kevin@archlinux.org>
+
+ * perl 5.12.1-2
+ - Francois updated the provides array.
+
+2010-05-23 kevin <kevin@archlinux.org>
+
+ * perl 5.12.1-1
+
+2010-05-16 kevin <kevin@archlinux.org>
+
+ * perl 5.12.0-2
+
+2010-05-12 kevin <kevin@archlinux.org>
+
+ - FS#19411. Removed the for loop in perlbin.sh which didn't work on zsh.
+ This makes the loop variables unnecessary so the script no longer
+ pollutes the user's environment.
+ - FS#19427. Added /usr/*/perl5/site_perl/5.10.1 to otherlibdirs to support
+ user built modules.
+
+2010-05-09 kevin <kevin@archlinux.org>
+
+ * perl 5.12.0-1
+ - Modified perlbin.sh to only add existing dirs to PATH. Fixes FS#17402,
+ path points to non-existant directories
+
+2010-05-07 kevin <kevin@archlinux.org>
+
+ - Added this changelog.
+ - Added -Dinc_version_list=none to fix FS#19136, double entry in @INC.
+ This removes the duplicates and versioned directory entries.
+ - Change scriptdirs to /usr/lib/perl5/{core,vendor,site}_perl/bin to fix
+ Fix FS#13808, binaries don't follow FHS.
+ - Stopped using versioned directories in sitelib and sitearch.
+
+
+# vim: set ft=changelog ts=4 sw=4 et:
diff --git a/core/perl/PKGBUILD b/core/perl/PKGBUILD
new file mode 100644
index 000000000..37f3a0e91
--- /dev/null
+++ b/core/perl/PKGBUILD
@@ -0,0 +1,208 @@
+# $Id: PKGBUILD 107935 2011-01-27 21:58:49Z angvp $
+# Maintainer: kevin <kevin.archlinux.org>
+# Contributor: judd <jvinet.zeroflux.org>
+# Contributor: francois <francois.archlinux.org>
+pkgname=perl
+pkgver=5.12.3
+pkgrel=1
+pkgdesc="A highly capable, feature-rich programming language"
+arch=(i686 x86_64)
+license=('GPL' 'PerlArtistic')
+url="http://www.perl.org"
+groups=('base')
+depends=('gdbm' 'db>=4.8' 'coreutils' 'glibc' 'sh')
+changelog=ChangeLog
+source=(http://www.cpan.org/src/5.0/perl-${pkgver}.tar.bz2 perlbin.sh fix-h2ph-and-tests.patch)
+install=perl.install
+provides=(
+perl-archive-extract=0.38
+perl-archive-tar=1.54
+perl-attribute-handlers=0.87
+perl-autodie=2.06_01
+perl-autoloader=5.70
+perl-base=2.15
+perl-b-debug=1.12
+perl-bignum=0.23
+perl-b-lint=1.11_01
+perl-cgi=3.49
+perl-class-isa=0.36
+perl-compress-raw-bzip2=2.024
+perl-compress-raw-zlib=2.024
+perl-constant=1.20
+perl-cpan=1.94_56
+perl-cpanplus=0.90
+perl-cpanplus-dist-build=0.46
+perl-data-dumper=2.125
+perl-db_file=1.820
+perl-devel-dprof=20080331.00
+perl-devel-peek=1.04
+perl-devel-ppport=3.19
+perl-digest=1.16
+perl-digest-md5=2.39
+perl-digest-sha=5.47
+perl-encode=2.39
+perl-encoding-warnings=0.11
+perl-exporter=5.64_01
+perl-extutils-cbuilder=0.27
+perl-extutils-command=1.16
+perl-extutils-constant=0.22
+perl-extutils-embed=1.28
+perl-extutils-install=1.55
+perl-extutils-makemaker=6.56
+perl-extutils-manifest=1.57
+perl-extutils-parsexs=2.21
+perl-file-fetch=0.24
+perl-file-path=2.08_01
+perl-file-temp=0.22
+perl-filter=1.37
+perl-filter-simple=0.84
+perl-getopt-long=2.38
+perl-if=0.05
+perl-io=1.25_02
+perl-io-compress=2.024
+perlio-via-quotedprint=0.06
+perl-io-zlib=1.10
+perl-ipc-cmd=0.54
+perl-ipc-sysv=2.01
+perl-libnet=1.22
+perl-locale-codes=2.07
+perl-locale-maketext=1.14
+perl-locale-maketext-simple=0.21
+perl-log-message=0.02
+perl-log-message-simple=0.06
+perl-math-bigint=1.89_01
+perl-math-bigint-fastcalc=0.19
+perl-math-bigrat=0.24
+perl-math-complex=1.56
+perl-memoize=1.01_03
+perl-mime-base64=3.08
+perl-module-build=0.3603
+perl-module-corelist=2.29
+perl-module-load=0.16
+perl-module-load-conditional=0.34
+perl-module-loaded=0.06
+perl-module-pluggable=3.9
+perl-net-ping=2.36
+perl-next=0.64
+perl-object-accessor=0.36
+perl-package-constants=0.02
+perl-params-check=0.26
+perl-parent=0.223
+perl-parse-cpan-meta=1.40
+perl-pathtools=3.31
+perl-pod-escapes=1.04
+perl-pod-latex=0.58
+perl-podlators=2.3.1
+perl-pod-parser=1.37
+perl-pod-perldoc=3.15_02
+perl-pod-plainer=1.02
+perl-pod-simple=3.14
+perl-safe=2.27
+perl-scalar-list-utils=1.22
+perl-selfloader=1.17
+perl-shell=0.72_01
+perl-storable=2.22
+perl-switch=2.16
+perl-sys-syslog=0.27
+perl-term-ansicolor=2.02
+perl-term-cap=1.12
+perl-term-ui=0.20
+perl-test=1.25_02
+perl-test-harness=3.17
+perl-test-simple=0.94
+perl-text-balanced=2.02
+perl-text-parsewords=3.27
+perl-text-soundex=3.03_01
+perl-text-tabs+wraps=2009.0305
+perl-thread-queue=2.11
+perl-threads=1.75
+perl-thread-semaphore=2.09
+perl-threads-shared=1.32
+perl-tie-file=0.97_02
+perl-tie-refhash=1.38
+perl-time-hires=1.9719
+perl-time-local=1.1901_01
+perl-time-piece=1.15_01
+perl-unicode-collate=0.52_01
+perl-unicode-normalize=1.03
+perl-version=0.82
+perl-win32=0.39
+perl-win32api-file=0.1101
+perl-xsloader=0.10
+)
+options=('!makeflags' '!purge')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+
+ if [ "${CARCH}" = "x86_64" ]; then
+ # for x86_64
+ arch_opts="-Dcccdlflags='-fPIC'"
+ else
+ # for i686
+ arch_opts=""
+ fi
+ ./Configure -des -Dusethreads -Duseshrplib -Doptimize="${CFLAGS}" \
+ -Dprefix=/usr -Dinstallprefix=${pkgdir}/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/bin/core_perl \
+ -Dsitescript=/usr/bin/site_perl \
+ -Dvendorscript=/usr/bin/vendor_perl \
+ -Dinc_version_list=none \
+ -Dman1ext=1perl -Dman3ext=3perl ${arch_opts}
+ #-Dotherlibdirs=/usr/lib/perl5/site_perl/5.10.1:/usr/share/perl5/site_perl/5.10.1:/usr/lib/perl5/current:/usr/lib/perl5/site_perl/current \
+ patch -Np1 -i $srcdir/fix-h2ph-and-tests.patch
+ make
+}
+package() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ make install
+
+ ### Perl Settings ###
+ # Change man page extensions for site and vendor module builds.
+ # Use archlinux email address instead of my own.
+ sed -e '/^man1ext=/ s/1perl/1p/' -e '/^man3ext=/ s/3perl/3pm/' \
+ -e "/^cf_email=/ s/'.*'/'kevin@archlinux.org'/" \
+ -e "/^perladmin=/ s/'.*'/'kevin@archlinux.org'/" \
+ -i ${pkgdir}/usr/lib/perl5/core_perl/Config_heavy.pl
+
+ ### 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 ${pkgdir}/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 ${pkgdir}/usr/share/perl5/core_perl/CPANPLUS/Config.pm
+
+ # Profile script so set paths to perl scripts.
+ install -D -m755 ${srcdir}/perlbin.sh \
+ ${pkgdir}/etc/profile.d/perlbin.sh
+
+ (cd ${pkgdir}/usr/bin; mv perl${pkgver} perl)
+ (cd ${pkgdir}/usr/bin/core_perl; ln -sf c2ph pstruct; ln -sf s2p psed)
+ grep -Rl "${pkgdir}" ${pkgdir}/usr | \
+ xargs sed -i "s^${pkgdir}^^g"
+
+ # Remove all pod files *except* those under /usr/share/perl5/core_perl/pod/
+ # (FS#16488)
+ rm -f $pkgdir/usr/share/perl5/core_perl/*.pod
+ for d in $pkgdir/usr/share/perl5/core_perl/*; do
+ if [ -d $d -a $(basename $d) != "pod" ]; then
+ find $d -name *.pod -delete
+ fi
+ done
+ find $pkgdir/usr/lib -name *.pod -delete
+ find $pkgdir -name .packlist -delete
+}
+md5sums=('72f3f7e1c700e79bbf9d9279ca5b42d9'
+ 'f86eb0dba1638ca6d1c8fff1b06c2a71'
+ '294b5311cbfc50e7dcffbee85854da38')
diff --git a/core/perl/fix-h2ph-and-tests.patch b/core/perl/fix-h2ph-and-tests.patch
new file mode 100644
index 000000000..a2d176ec6
--- /dev/null
+++ b/core/perl/fix-h2ph-and-tests.patch
@@ -0,0 +1,104 @@
+From 8d66b3f930dc6d88b524d103e304308ae73a46e7 Mon Sep 17 00:00:00 2001
+From: Robin Barker <rmbarker@cpan.org>
+Date: Thu, 22 Apr 2010 11:51:20 +0100
+Subject: [PATCH 1/1] Fix h2ph and test
+
+---
+ lib/h2ph.t | 12 ++++++++++--
+ utils/h2ph.PL | 28 +++++++++++++++++++++++-----
+ 2 files changed, 33 insertions(+), 7 deletions(-)
+
+diff --git a/lib/h2ph.t b/lib/h2ph.t
+index 27dd7b9..8d62d46 100644
+--- a/lib/h2ph.t
++++ b/lib/h2ph.t
+@@ -18,7 +18,7 @@ if (!(-e $extracted_program)) {
+ exit 0;
+ }
+
+-plan(4);
++plan(5);
+
+ # quickly compare two text files
+ sub txt_compare {
+@@ -41,8 +41,16 @@ $result = runperl( progfile => 'lib/h2ph.pht',
+ stderr => 1 );
+ like( $result, qr/syntax OK$/, "output compiles");
+
++$result = runperl( progfile => '_h2ph_pre.ph',
++ switches => ['-c'],
++ stderr => 1 );
++like( $result, qr/syntax OK$/, "preamble compiles");
++
+ $result = runperl( switches => ["-w"],
+- prog => '$SIG{__WARN__} = sub { die $_[0] }; require q(lib/h2ph.pht);');
++ stderr => 1,
++ prog => <<'PROG' );
++$SIG{__WARN__} = sub { die $_[0] }; require q(lib/h2ph.pht);
++PROG
+ is( $result, '', "output free of warnings" );
+
+ # cleanup
+diff --git a/utils/h2ph.PL b/utils/h2ph.PL
+index 8f56db4..1255807 100644
+--- a/utils/h2ph.PL
++++ b/utils/h2ph.PL
+@@ -401,7 +401,10 @@ if ($opt_e && (scalar(keys %bad_file) > 0)) {
+ exit $Exit;
+
+ sub expr {
+- $new = '"(assembly code)"' and return if /\b__asm__\b/; # freak out.
++ if (/\b__asm__\b/) { # freak out
++ $new = '"(assembly code)"';
++ return
++ }
+ my $joined_args;
+ if(keys(%curargs)) {
+ $joined_args = join('|', keys(%curargs));
+@@ -770,7 +773,7 @@ sub inc_dirs
+ sub build_preamble_if_necessary
+ {
+ # Increment $VERSION every time this function is modified:
+- my $VERSION = 2;
++ my $VERSION = 3;
+ my $preamble = "$Dest_dir/_h2ph_pre.ph";
+
+ # Can we skip building the preamble file?
+@@ -798,7 +801,16 @@ sub build_preamble_if_necessary
+ # parenthesized value: d=(v)
+ $define{$_} = $1;
+ }
+- if ($define{$_} =~ /^([+-]?(\d+)?\.\d+([eE][+-]?\d+)?)[FL]?$/) {
++ if (/^(\w+)\((\w)\)$/) {
++ my($macro, $arg) = ($1, $2);
++ my $def = $define{$_};
++ $def =~ s/$arg/\$\{$arg\}/g;
++ print PREAMBLE <<DEFINE;
++unless (defined &$macro) { sub $macro(\$) { my (\$$arg) = \@_; \"$def\" } }
++
++DEFINE
++ } elsif
++ ($define{$_} =~ /^([+-]?(\d+)?\.\d+([eE][+-]?\d+)?)[FL]?$/) {
+ # float:
+ print PREAMBLE
+ "unless (defined &$_) { sub $_() { $1 } }\n\n";
+@@ -807,8 +819,14 @@ sub build_preamble_if_necessary
+ print PREAMBLE
+ "unless (defined &$_) { sub $_() { $1 } }\n\n";
+ } elsif ($define{$_} =~ /^\w+$/) {
+- print PREAMBLE
+- "unless (defined &$_) { sub $_() { &$define{$_} } }\n\n";
++ my $def = $define{$_};
++ if ($isatype{$def}) {
++ print PREAMBLE
++ "unless (defined &$_) { sub $_() { \"$def\" } }\n\n";
++ } else {
++ print PREAMBLE
++ "unless (defined &$_) { sub $_() { &$def } }\n\n";
++ }
+ } else {
+ print PREAMBLE
+ "unless (defined &$_) { sub $_() { \"",
+--
+1.6.5.2.74.g610f9.dirty
+
diff --git a/core/perl/perl.install b/core/perl/perl.install
new file mode 100644
index 000000000..3f7d58f23
--- /dev/null
+++ b/core/perl/perl.install
@@ -0,0 +1,18 @@
+# arg 1: the new package version
+post_install() {
+ for ver in 5.8.{0,1,2,3,4,5,6,7,8}; do
+ [ -h usr/lib/perl5/$ver ] && rm usr/lib/perl5/$ver
+ [ -h usr/lib/perl5/site_perl/$ver ] && rm usr/lib/perl5/site_perl/$ver
+ [ -h usr/bin/perl$ver ] && rm usr/bin/perl$ver
+ done
+ return 0
+}
+
+post_upgrade() {
+ echo '- The directories /usr/lib/perl5/current, /usr/lib/perl5/site_perl/current,'
+ echo ' /usr/lib/perl5/site_perl/5.10.1, and /usr/share/perl5/site_perl/5.10.1'
+ echo ' have been removed from @INC.'
+
+ echo '- The script/binary directories are now /usr/bin/*_perl instead of'
+ echo ' /usr/lib/perl5/*_perl/bin which will be eventually removed.'
+}
diff --git a/core/perl/perlbin.sh b/core/perl/perlbin.sh
new file mode 100755
index 000000000..09811a8b4
--- /dev/null
+++ b/core/perl/perlbin.sh
@@ -0,0 +1,23 @@
+# Set path to perl scriptdirs if they exist
+# https://wiki.archlinux.org/index.php/Perl_Policy#Binaries_and_Scripts
+# Added /usr/bin/*_perl dirs for scripts
+# Remove /usr/lib/perl5/*_perl/bin in next release
+
+[ -d /usr/bin/site_perl ] &&
+ PATH=$PATH:/usr/bin/site_perl
+[ -d /usr/lib/perl5/site_perl/bin ] &&
+ PATH=$PATH:/usr/lib/perl5/site_perl/bin
+
+[ -d /usr/bin/vendor_perl ] &&
+ PATH=$PATH:/usr/bin/vendor_perl
+[ -d /usr/lib/perl5/vendor_perl/bin ] &&
+ PATH=$PATH:/usr/lib/perl5/vendor_perl/bin
+
+[ -d /usr/bin/core_perl ] &&
+ PATH=$PATH:/usr/bin/core_perl
+
+export PATH
+
+# If you have modules in non-standard directories you can add them here.
+#export PERLLIB=dir1:dir2
+