summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/CPAN.pm3
-rw-r--r--lib/ExtUtils/Installed.pm2
-rw-r--r--lib/ExtUtils/MM_Unix.pm3
-rw-r--r--lib/ExtUtils/Mksymlists.pm2
-rw-r--r--lib/Pod/Man.pm7
-rwxr-xr-xlib/diagnostics.pm4
-rw-r--r--lib/lib.pm3
7 files changed, 14 insertions, 10 deletions
diff --git a/lib/CPAN.pm b/lib/CPAN.pm
index 432e72da05..2f22b773c7 100644
--- a/lib/CPAN.pm
+++ b/lib/CPAN.pm
@@ -3325,7 +3325,8 @@ sub perl {
$perl ||= $candidate if MM->maybe_command($candidate);
unless ($perl) {
my ($component,$perl_name);
- DIST_PERLNAME: foreach $perl_name ($^X, 'perl', 'perl5', "perl$]") {
+ DIST_PERLNAME:
+ foreach $perl_name ($^X, 'perl', 'perl5', "perl$Config::Config{version}") {
PATH_COMPONENT: foreach $component (MM->path(),
$Config::Config{'binexp'}) {
next unless defined($component) && $component;
diff --git a/lib/ExtUtils/Installed.pm b/lib/ExtUtils/Installed.pm
index dda594e784..41f3c9b3b8 100644
--- a/lib/ExtUtils/Installed.pm
+++ b/lib/ExtUtils/Installed.pm
@@ -56,7 +56,7 @@ my $self = {};
# Read the core packlist
$self->{Perl}{packlist} =
ExtUtils::Packlist->new("$Config{installarchlib}/.packlist");
-$self->{Perl}{version} = $];
+$self->{Perl}{version} = $Config{version};
# Read the module packlists
my $sub = sub
diff --git a/lib/ExtUtils/MM_Unix.pm b/lib/ExtUtils/MM_Unix.pm
index 438ab01cba..f4329e13d7 100644
--- a/lib/ExtUtils/MM_Unix.pm
+++ b/lib/ExtUtils/MM_Unix.pm
@@ -2004,7 +2004,8 @@ usually solves this kind of problem.
push @defpath, $component if defined $component;
}
$self->{PERL} ||=
- $self->find_perl(5.0, [ $self->canonpath($^X), 'miniperl','perl','perl5',"perl$]" ],
+ $self->find_perl(5.0, [ $self->canonpath($^X), 'miniperl',
+ 'perl','perl5',"perl$Config{version}" ],
\@defpath, $Verbose );
# don't check if perl is executable, maybe they have decided to
# supply switches with perl
diff --git a/lib/ExtUtils/Mksymlists.pm b/lib/ExtUtils/Mksymlists.pm
index cfc1e7dff8..9dcedbf35e 100644
--- a/lib/ExtUtils/Mksymlists.pm
+++ b/lib/ExtUtils/Mksymlists.pm
@@ -78,7 +78,7 @@ sub _write_os2 {
}
my $distname = $data->{DISTNAME} || $data->{NAME};
$distname = "Distribution $distname";
- my $comment = "Perl (v$]$threaded) module $data->{NAME}";
+ my $comment = "Perl (v$Config::Config{version}$threaded) module $data->{NAME}";
if ($data->{INSTALLDIRS} and $data->{INSTALLDIRS} eq 'perl') {
$distname = 'perl5-porters@perl.org';
$comment = "Core $comment";
diff --git a/lib/Pod/Man.pm b/lib/Pod/Man.pm
index 87de42efb3..9aadd42dea 100644
--- a/lib/Pod/Man.pm
+++ b/lib/Pod/Man.pm
@@ -338,9 +338,10 @@ sub initialize {
# but we shouldn't need that any more. Get the version from the running
# Perl.
if (!defined $$self{release}) {
- my ($version, $patch) = ($] =~ /^(.{5})(\d{2})?/);
- $$self{release} = "perl $version";
- $$self{release} .= ", patch $patch" if $patch;
+ my ($rev, $ver, $sver) = ($] =~ /^(\d+)\.(\d{3})(\d{0,3})$/);
+ $sver ||= 0; $sver *= 10 ** (3-length($sver));
+ $rev += 0; $ver += 0; $sver += 0;
+ $$self{release} = "perl v$rev.$ver.$sver";
}
# Double quotes in things that will be quoted.
diff --git a/lib/diagnostics.pm b/lib/diagnostics.pm
index 532505e5d1..e6a9127158 100755
--- a/lib/diagnostics.pm
+++ b/lib/diagnostics.pm
@@ -181,10 +181,10 @@ if ($^O eq 'VMS') {
}
@trypod = (
"$archlib/pod/perldiag.pod",
- "$privlib/pod/perldiag-$].pod",
+ "$privlib/pod/perldiag-$Config{version}.pod",
"$privlib/pod/perldiag.pod",
"$archlib/pods/perldiag.pod",
- "$privlib/pods/perldiag-$].pod",
+ "$privlib/pods/perldiag-$Config{version}.pod",
"$privlib/pods/perldiag.pod",
);
# handy for development testing of new warnings etc
diff --git a/lib/lib.pm b/lib/lib.pm
index d35510df86..afc979bb45 100644
--- a/lib/lib.pm
+++ b/lib/lib.pm
@@ -4,6 +4,7 @@ use vars qw(@ORIG_INC);
use Config;
my $archname = $Config{'archname'};
+my $ver = $Config{'version'};
@ORIG_INC = @INC; # take a handy copy of 'original' value
@@ -26,7 +27,7 @@ sub import {
# looks like $_ has an archlib directory below it.
if (-d "$_/$archname") {
unshift(@INC, "$_/$archname") if -d "$_/$archname/auto";
- unshift(@INC, "$_/$archname/$]") if -d "$_/$archname/$]/auto";
+ unshift(@INC, "$_/$archname/$ver") if -d "$_/$archname/$ver/auto";
}
}